rootfs_rpm.bbclass: fix a regression introduced by list_installed_packages change
A regression was introduced by commit:
190cb591 that it doesn't
consider the situation that some archs contain "_" originally, so it
results in issues when dealing with archs like qemux86_64, x85_64.
Added a conditional statment in to handle that case.
(From OE-Core rev:
8567991639fda8d2a1e88169b86c72e14cc6c82d)
Signed-off-by: Ming Liu <ming.liu@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>