summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2011-05-18 00:03:02 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2011-05-31 12:56:38 +0100
commit26e5e5feb695864b11e47e24017e254c28f14494 (patch)
tree754537dc0577fdcb6cf753bfbd926aeb74183789
parent5c3f39c56d1a7402c1f1f3b6db1f2764fcc8f190 (diff)
downloadopenembedded-core-contrib-26e5e5feb695864b11e47e24017e254c28f14494.tar.gz
Improve handling of 'all' architecture recipes and their interaction with sstate
The existing PACKAGE_ARCH = "all" mechanism of sharing packages is problematic with sstate since there are a variety of variables which have target specific values and the sstate package therefore correctly changes signature depending on the MACHINE setting. This patch creates a new "allarch" class which sets: PACKAGE_ARCH = "all" (as per the existing convention) INHIBIT_DEFAULT_DEPS = "1" (since its not target specific and therefore can't depend on the cross compiler or target libc) TARGET_ARCH = "all" TARGET_OS = "linux" TARGET_CC_ARCH = "none" (since these variables shouldn't change between the different packages and target compiler flags shouldn't be getting used) PACKAGE_EXTRA_ARCHS = "" (since we shouldn't be depending on any architecture specific package architectures) Not all PACKAGE_ARCH = "all" recipes can use this class since some run configure checks on the compiler. This means they have target specific components and therefore the "all" classification is incorrect. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/classes/allarch.bbclass15
-rw-r--r--meta/classes/siteinfo.bbclass1
-rw-r--r--meta/recipes-bsp/hostap/hostap-conf_1.0.bb5
-rw-r--r--meta/recipes-bsp/orinoco/orinoco-conf_1.0.bb5
-rw-r--r--meta/recipes-bsp/qemu-config/qemu-config.bb5
-rw-r--r--meta/recipes-connectivity/bluez/bluez-dtl1-workaround_1.0.bb6
-rw-r--r--meta/recipes-connectivity/ppp-dialin/ppp-dialin_0.1.bb6
-rw-r--r--meta/recipes-core/initrdscripts/initramfs-boot_1.0.bb5
-rw-r--r--meta/recipes-core/initrdscripts/initramfs-live-boot_1.0.bb5
-rw-r--r--meta/recipes-core/initrdscripts/initramfs-live-install_1.0.bb5
-rw-r--r--meta/recipes-core/update-rc.d/update-rc.d_0.7.bb4
-rw-r--r--meta/recipes-graphics/x11-common/x11-common_0.1.bb5
-rw-r--r--meta/recipes-kernel/update-modules/update-modules_1.0.bb5
13 files changed, 47 insertions, 25 deletions
diff --git a/meta/classes/allarch.bbclass b/meta/classes/allarch.bbclass
new file mode 100644
index 00000000000..b7c37c3dd1a
--- /dev/null
+++ b/meta/classes/allarch.bbclass
@@ -0,0 +1,15 @@
+#
+# This class is used for architecture independent recipes/data files (usally scripts)
+#
+
+PACKAGE_ARCH = "all"
+
+# No need for virtual/libc or a cross compiler
+INHIBIT_DEFAULT_DEPS = "1"
+
+# Set these to a common set of values, we shouldn't be using them other that for WORKDIR directory
+# naming anyway
+TARGET_ARCH = "all"
+TARGET_OS = "linux"
+TARGET_CC_ARCH = "none"
+PACKAGE_EXTRA_ARCHS = ""
diff --git a/meta/classes/siteinfo.bbclass b/meta/classes/siteinfo.bbclass
index 0b59e578fc6..6c272a75bcd 100644
--- a/meta/classes/siteinfo.bbclass
+++ b/meta/classes/siteinfo.bbclass
@@ -19,6 +19,7 @@ def get_siteinfo_list(d):
target = bb.data.getVar('HOST_ARCH', d, 1) + "-" + bb.data.getVar('HOST_OS', d, 1)
targetinfo = {\
+ "all-linux": "",\
"armeb-linux": "endian-big bit-32 common-glibc arm-common",\
"armeb-linux-gnueabi": "endian-big bit-32 common-glibc arm-common armeb-linux",\
"armeb-linux-uclibc": "endian-big bit-32 common-uclibc arm-common",\
diff --git a/meta/recipes-bsp/hostap/hostap-conf_1.0.bb b/meta/recipes-bsp/hostap/hostap-conf_1.0.bb
index de72b769a95..c602e8c6406 100644
--- a/meta/recipes-bsp/hostap/hostap-conf_1.0.bb
+++ b/meta/recipes-bsp/hostap/hostap-conf_1.0.bb
@@ -4,12 +4,13 @@ PRIORITY = "optional"
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
RDEPENDS_${PN} = "update-modules"
-PACKAGE_ARCH = "all"
-PR = "r12"
+PR = "r14"
SRC_URI = "file://hostap_cs.modalias \
file://COPYING.patch"
+inherit allarch
+
do_compile() {
}
diff --git a/meta/recipes-bsp/orinoco/orinoco-conf_1.0.bb b/meta/recipes-bsp/orinoco/orinoco-conf_1.0.bb
index 1c25e02dccf..98d3aed2ca7 100644
--- a/meta/recipes-bsp/orinoco/orinoco-conf_1.0.bb
+++ b/meta/recipes-bsp/orinoco/orinoco-conf_1.0.bb
@@ -4,12 +4,13 @@ PRIORITY = "optional"
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
RDEPENDS_${PN} = "update-modules"
-PACKAGE_ARCH = "all"
-PR = "r6"
+PR = "r7"
SRC_URI = "file://orinoco_cs.conf \
file://COPYING.patch"
+inherit allarch
+
do_install() {
install -d ${D}${sysconfdir}/modutils
install -m 0644 ${WORKDIR}/orinoco_cs.conf ${D}${sysconfdir}/modutils/
diff --git a/meta/recipes-bsp/qemu-config/qemu-config.bb b/meta/recipes-bsp/qemu-config/qemu-config.bb
index f91875e74e3..70a113e8dc0 100644
--- a/meta/recipes-bsp/qemu-config/qemu-config.bb
+++ b/meta/recipes-bsp/qemu-config/qemu-config.bb
@@ -5,7 +5,7 @@ LIC_FILES_CHKSUM = "file://${WORKDIR}/COPYING.GPL;md5=751419260aa954499f7abaabaa
COMPATIBLE_MACHINE = "(qemuarm|qemux86|qemumips|qemuppc)"
-PR = "r20"
+PR = "r21"
SRC_URI = "file://distcc.sh \
file://anjuta-remote-run \
@@ -33,9 +33,8 @@ do_install() {
}
RDEPENDS_${PN} = "distcc dbus-x11 task-core-nfs-server oprofileui-server rsync bash"
-PACKAGE_ARCH = "all"
-inherit update-rc.d
+inherit update-rc.d allarch
INITSCRIPT_NAME = "qemu-autostart"
INITSCRIPT_PARAMS = "start 999 5 2 . stop 20 0 1 6 ."
diff --git a/meta/recipes-connectivity/bluez/bluez-dtl1-workaround_1.0.bb b/meta/recipes-connectivity/bluez/bluez-dtl1-workaround_1.0.bb
index 4dfdcb247ac..b6b3d7dcfda 100644
--- a/meta/recipes-connectivity/bluez/bluez-dtl1-workaround_1.0.bb
+++ b/meta/recipes-connectivity/bluez/bluez-dtl1-workaround_1.0.bb
@@ -3,11 +3,13 @@ LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
SECTION = "console"
PRIORITY = "optional"
-PR = "r2"
+PR = "r3"
SRC_URI = "file://02dtl1_cs.sh \
file://COPYING.patch"
+inherit allarch
+
do_install() {
install -d ${D}${sysconfdir}/apm/event.d/
install -m 0755 ${WORKDIR}/02dtl1_cs.sh ${D}${sysconfdir}/apm/event.d/
@@ -15,5 +17,3 @@ do_install() {
#Package 02dtl1_cs.sh, which is a nasty hack to get dtl1c_cs cards working with suspend/resume
FILES_${PN} += "${sysconfdir}/apm/"
-
-PACKAGE_ARCH = "all"
diff --git a/meta/recipes-connectivity/ppp-dialin/ppp-dialin_0.1.bb b/meta/recipes-connectivity/ppp-dialin/ppp-dialin_0.1.bb
index 5cdba2ba110..d4ac77e9210 100644
--- a/meta/recipes-connectivity/ppp-dialin/ppp-dialin_0.1.bb
+++ b/meta/recipes-connectivity/ppp-dialin/ppp-dialin_0.1.bb
@@ -2,7 +2,7 @@ SECTION = "console/network"
DESCRIPTION = "Enables PPP dial-in through a serial connection"
DEPENDS = "ppp"
RDEPENDS_${PN} = "ppp"
-PR = "r6"
+PR = "r7"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58 \
file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
@@ -10,6 +10,8 @@ LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3
SRC_URI = "file://host-peer \
file://ppp-dialin"
+inherit allarch
+
do_install() {
install -d ${D}${sysconfdir}/ppp/peers
install -m 0644 ${WORKDIR}/host-peer ${D}${sysconfdir}/ppp/peers/host
@@ -18,8 +20,6 @@ do_install() {
install -m 0755 ${WORKDIR}/ppp-dialin ${D}${sbindir}
}
-PACKAGE_ARCH = "all"
-
pkg_postinst_${PN} () {
if test "x$D" != "x"; then
exit 1
diff --git a/meta/recipes-core/initrdscripts/initramfs-boot_1.0.bb b/meta/recipes-core/initrdscripts/initramfs-boot_1.0.bb
index b372fddbbaf..704c2718a04 100644
--- a/meta/recipes-core/initrdscripts/initramfs-boot_1.0.bb
+++ b/meta/recipes-core/initrdscripts/initramfs-boot_1.0.bb
@@ -3,11 +3,12 @@ LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
SRC_URI = "file://init-boot.sh"
-PR = "r0"
+PR = "r1"
do_install() {
install -m 0755 ${WORKDIR}/init-boot.sh ${D}/init
}
-PACKAGE_ARCH = "all"
+inherit allarch
+
FILES_${PN} += " /init "
diff --git a/meta/recipes-core/initrdscripts/initramfs-live-boot_1.0.bb b/meta/recipes-core/initrdscripts/initramfs-live-boot_1.0.bb
index f6a6a8a4cbc..7051cbd32af 100644
--- a/meta/recipes-core/initrdscripts/initramfs-live-boot_1.0.bb
+++ b/meta/recipes-core/initrdscripts/initramfs-live-boot_1.0.bb
@@ -3,11 +3,12 @@ LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
SRC_URI = "file://init-live.sh"
-PR = "r2"
+PR = "r3"
do_install() {
install -m 0755 ${WORKDIR}/init-live.sh ${D}/init
}
-PACKAGE_ARCH = "all"
+inherit allarch
+
FILES_${PN} += " /init "
diff --git a/meta/recipes-core/initrdscripts/initramfs-live-install_1.0.bb b/meta/recipes-core/initrdscripts/initramfs-live-install_1.0.bb
index c599be5c58e..fdda71819f7 100644
--- a/meta/recipes-core/initrdscripts/initramfs-live-install_1.0.bb
+++ b/meta/recipes-core/initrdscripts/initramfs-live-install_1.0.bb
@@ -3,7 +3,7 @@ LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
SRC_URI = "file://init-install.sh"
-PR = "r3"
+PR = "r4"
RDEPENDS="grub parted e2fsprogs-mke2fs"
@@ -11,7 +11,8 @@ do_install() {
install -m 0755 ${WORKDIR}/init-install.sh ${D}/install.sh
}
-PACKAGE_ARCH = "all"
+inherit allarch
+
FILES_${PN} = " /install.sh "
# Alternatives to grub need adding for other arch support
diff --git a/meta/recipes-core/update-rc.d/update-rc.d_0.7.bb b/meta/recipes-core/update-rc.d/update-rc.d_0.7.bb
index 6a43d809ed9..38da4233ea4 100644
--- a/meta/recipes-core/update-rc.d/update-rc.d_0.7.bb
+++ b/meta/recipes-core/update-rc.d/update-rc.d_0.7.bb
@@ -2,18 +2,18 @@ SUMMARY = "manage symlinks in /etc/rcN.d."
DESCRIPTION = "update-rc.d is a utilities that allows the management of symlinks to the initscripts in the /etc/rcN.d directory structure."
SECTION = "base"
PRIORITY = "standard"
-PACKAGE_ARCH = "all"
LICENSE = "GPLv2+"
LIC_FILES_CHKSUM = "file://update-rc.d;beginline=5;endline=15;md5=148a48321b10eb37c1fa3ee02b940a75"
-PR = "r3"
+PR = "r4"
SRC_URI = "git://github.com/philb/update-rc.d.git;tag=update-rc.d_${PV};protocol=git \
file://add-verbose.patch;striplevel=1"
S = "${WORKDIR}/git"
+inherit allarch
do_compile() {
}
diff --git a/meta/recipes-graphics/x11-common/x11-common_0.1.bb b/meta/recipes-graphics/x11-common/x11-common_0.1.bb
index 6951cf37717..b6bd61a74ca 100644
--- a/meta/recipes-graphics/x11-common/x11-common_0.1.bb
+++ b/meta/recipes-graphics/x11-common/x11-common_0.1.bb
@@ -2,13 +2,15 @@ DESCRIPTION = "Common X11 scripts and configuration files"
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
SECTION = "x11"
-PR = "r43"
+PR = "r44"
SRC_URI = "file://etc \
file://gplv2-license.patch"
S = ${WORKDIR}
+inherit allarch
+
do_install() {
cp -R ${S}/etc ${D}/etc
chmod -R 755 ${D}/etc
@@ -17,5 +19,4 @@ do_install() {
}
RDEPENDS_${PN} = "dbus-x11 xmodmap xdpyinfo xtscal xinit formfactor"
-PACKAGE_ARCH = "all"
diff --git a/meta/recipes-kernel/update-modules/update-modules_1.0.bb b/meta/recipes-kernel/update-modules/update-modules_1.0.bb
index 336bca2e9b1..1ea97a85300 100644
--- a/meta/recipes-kernel/update-modules/update-modules_1.0.bb
+++ b/meta/recipes-kernel/update-modules/update-modules_1.0.bb
@@ -3,13 +3,14 @@ SECTION = "base"
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://${WORKDIR}/COPYING.GPL;md5=751419260aa954499f7abaabaa882bbe"
-PACKAGE_ARCH = "all"
RDEPENDS_${PN} = "${@base_contains("MACHINE_FEATURES", "kernel26", "module-init-tools-depmod","modutils-depmod",d)} "
-PR = "r9"
+PR = "r10"
SRC_URI = "file://update-modules \
file://COPYING.GPL"
+inherit allarch
+
pkg_postinst_${PN} () {
if [ "x$D" != "x" ]; then
exit 1