Patchwork [1/2] package_rpm.bbclass: change the arch's "-" to "_" for platform

login
register
mail settings
Submitter Robert Yang
Date Sept. 25, 2012, 1:38 p.m.
Message ID <352cdca21cbdaec95d82f141f7fe0bd86615eedb.1348561895.git.liezhi.yang@windriver.com>
Download mbox | patch
Permalink /patch/37193/
State Accepted
Commit 9880a5261ca509c69efbafa27cddd9b2b8ca08f0
Headers show

Comments

Robert Yang - Sept. 25, 2012, 1:38 p.m.
The platform and platform_extra will be written to /etc/rpm/platform,
the rpm's arch has changed the "-" to "_", so the value in platform
should also be updated.

[YOCTO #3159]

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
 meta/classes/package_rpm.bbclass | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
Saul Wold - Sept. 27, 2012, 3:43 p.m.
On 09/25/2012 06:38 AM, Robert Yang wrote:
> The platform and platform_extra will be written to /etc/rpm/platform,
> the rpm's arch has changed the "-" to "_", so the value in platform
> should also be updated.
>
> [YOCTO #3159]
>
> Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
> ---
>   meta/classes/package_rpm.bbclass | 4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/meta/classes/package_rpm.bbclass b/meta/classes/package_rpm.bbclass
> index 64689d8..be6bd45 100644
> --- a/meta/classes/package_rpm.bbclass
> +++ b/meta/classes/package_rpm.bbclass
> @@ -276,8 +276,8 @@ process_pkg_list_rpm() {
>   package_install_internal_rpm () {
>
>   	local target_rootfs="${INSTALL_ROOTFS_RPM}"
> -	local platform="${INSTALL_PLATFORM_RPM}"
> -	local platform_extra="${INSTALL_PLATFORM_EXTRA_RPM}"
> +	local platform="`echo ${INSTALL_PLATFORM_RPM} | sed 's#-#_#g'`"
> +	local platform_extra="`echo ${INSTALL_PLATFORM_EXTRA_RPM} | sed 's#-#_#g'`"
>   	local confbase="${INSTALL_CONFBASE_RPM}"
>   	local package_to_install="${INSTALL_PACKAGES_RPM}"
>   	local package_attemptonly="${INSTALL_PACKAGES_ATTEMPTONLY_RPM}"
>

Merged into OE-Core

Thanks
	Sau!

Patch

diff --git a/meta/classes/package_rpm.bbclass b/meta/classes/package_rpm.bbclass
index 64689d8..be6bd45 100644
--- a/meta/classes/package_rpm.bbclass
+++ b/meta/classes/package_rpm.bbclass
@@ -276,8 +276,8 @@  process_pkg_list_rpm() {
 package_install_internal_rpm () {
 
 	local target_rootfs="${INSTALL_ROOTFS_RPM}"
-	local platform="${INSTALL_PLATFORM_RPM}"
-	local platform_extra="${INSTALL_PLATFORM_EXTRA_RPM}"
+	local platform="`echo ${INSTALL_PLATFORM_RPM} | sed 's#-#_#g'`"
+	local platform_extra="`echo ${INSTALL_PLATFORM_EXTRA_RPM} | sed 's#-#_#g'`"
 	local confbase="${INSTALL_CONFBASE_RPM}"
 	local package_to_install="${INSTALL_PACKAGES_RPM}"
 	local package_attemptonly="${INSTALL_PACKAGES_ATTEMPTONLY_RPM}"