* [PATCH 0/3] Fix overriding PACKAGE_ARCH for MACHINE specific SRC_URI [v2]
@ 2012-02-22 1:46 Joshua Lock
2012-02-22 1:46 ` [PATCH 1/3] base.bbclass: check all entries of FILESPATH for MACHINE overrides Joshua Lock
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: Joshua Lock @ 2012-02-22 1:46 UTC (permalink / raw)
To: openembedded-core
This series includes a fix for base.bbclass so that PACKAGE_ARCH is correctly set to
MACHINE_ARCH for all recipes which include a MACHINE OVERRIDE in SRC_URI.
Cheers,
Joshua
The following changes since commit d4ffe12ca36bf10be4e0f9565d7c3d8e6f4a265a:
iputils: Add base_libdir to VPATH in order to find the crypto library (2012-02-21 17:59:21 +0000)
are available in the git repository at:
git://git.openembedded.org/openembedded-core-contrib josh/work
http://cgit.openembedded.org/cgit.cgi/openembedded-core-contrib/log/?h=josh/work
Joshua Lock (3):
base.bbclass: check all entries of FILESPATH for MACHINE overrides
external-csl-toolchain: skip parsing if CSL_VER_MAIN isn't set
netbase: remove redundant assignments
meta/classes/base.bbclass | 14 ++++++++------
meta/recipes-core/meta/external-csl-toolchain.bb | 8 ++++++++
meta/recipes-core/netbase/netbase_4.47.bb | 4 ----
3 files changed, 16 insertions(+), 10 deletions(-)
--
1.7.7.6
^ permalink raw reply [flat|nested] 5+ messages in thread* [PATCH 1/3] base.bbclass: check all entries of FILESPATH for MACHINE overrides 2012-02-22 1:46 [PATCH 0/3] Fix overriding PACKAGE_ARCH for MACHINE specific SRC_URI [v2] Joshua Lock @ 2012-02-22 1:46 ` Joshua Lock 2012-02-22 1:46 ` [PATCH 2/3] external-csl-toolchain: skip parsing if CSL_VER_MAIN isn't set Joshua Lock ` (2 subsequent siblings) 3 siblings, 0 replies; 5+ messages in thread From: Joshua Lock @ 2012-02-22 1:46 UTC (permalink / raw) To: openembedded-core The logic which looks for MACHINE overrides in SRC_URI and updates PACKAGE_ARCH was checking only certain subdirectories of the recipes parent which, amongst other issues, doesn't account for SRC_URI overrides in layers. This patch changes the logic such that all FILESPATH entries are checked for children named for MACHINE. Signed-off-by: Joshua Lock <josh@linux.intel.com> --- meta/classes/base.bbclass | 14 ++++++++------ 1 files changed, 8 insertions(+), 6 deletions(-) diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass index a26ac94..e80e874 100644 --- a/meta/classes/base.bbclass +++ b/meta/classes/base.bbclass @@ -453,13 +453,15 @@ python () { # We always try to scan SRC_URI for urls with machine overrides # unless the package sets SRC_URI_OVERRIDES_PACKAGE_ARCH=0 # - override = d.getVar('SRC_URI_OVERRIDES_PACKAGE_ARCH', 1) + override = d.getVar('SRC_URI_OVERRIDES_PACKAGE_ARCH', True) if override != '0': paths = [] - for p in [ "${PF}", "${P}", "${PN}", "files", "" ]: - path = bb.data.expand(os.path.join("${FILE_DIRNAME}", p, "${MACHINE}"), d) - if os.path.isdir(path): - paths.append(path) + fpaths = (d.getVar('FILESPATH', True) or '').split(':') + machine = d.getVar('MACHINE', True) + for p in fpaths: + if os.path.basename(p) == machine and os.path.isdir(p): + paths.append(p) + if len(paths) != 0: for s in srcuri.split(): if not s.startswith("file://"): @@ -468,7 +470,7 @@ python () { local = fetcher.localpath(s) for mp in paths: if local.startswith(mp): - #bb.note("overriding PACKAGE_ARCH from %s to %s" % (pkg_arch, mach_arch)) + #bb.note("overriding PACKAGE_ARCH from %s to %s for %s" % (pkg_arch, mach_arch, pn)) d.setVar('PACKAGE_ARCH', "${MACHINE_ARCH}") return -- 1.7.7.6 ^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH 2/3] external-csl-toolchain: skip parsing if CSL_VER_MAIN isn't set 2012-02-22 1:46 [PATCH 0/3] Fix overriding PACKAGE_ARCH for MACHINE specific SRC_URI [v2] Joshua Lock 2012-02-22 1:46 ` [PATCH 1/3] base.bbclass: check all entries of FILESPATH for MACHINE overrides Joshua Lock @ 2012-02-22 1:46 ` Joshua Lock 2012-02-22 1:46 ` [PATCH 3/3] netbase: remove redundant assignments Joshua Lock 2012-02-22 22:54 ` [PATCH 0/3] Fix overriding PACKAGE_ARCH for MACHINE specific SRC_URI [v2] Richard Purdie 3 siblings, 0 replies; 5+ messages in thread From: Joshua Lock @ 2012-02-22 1:46 UTC (permalink / raw) To: openembedded-core Signed-off-by: Joshua Lock <josh@linux.intel.com> --- meta/recipes-core/meta/external-csl-toolchain.bb | 8 ++++++++ 1 files changed, 8 insertions(+), 0 deletions(-) diff --git a/meta/recipes-core/meta/external-csl-toolchain.bb b/meta/recipes-core/meta/external-csl-toolchain.bb index d15578b..07c3e30 100644 --- a/meta/recipes-core/meta/external-csl-toolchain.bb +++ b/meta/recipes-core/meta/external-csl-toolchain.bb @@ -150,3 +150,11 @@ FILES_linux-libc-headers = "${includedir}/asm* \ " FILES_gdbserver = "${bindir}/gdbserver ${libdir}/bin/sysroot-gdbserver" FILES_gdbserver-dbg = "${bindir}/.debug/gdbserver" + +CSL_VER_MAIN ??= "" + +python () { + if not d.getVar("CSL_VER_MAIN"): + raise bb.parse.SkipPackage("External CSL toolchain not configured (CSL_VER_MAIN not set).") +} + -- 1.7.7.6 ^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH 3/3] netbase: remove redundant assignments 2012-02-22 1:46 [PATCH 0/3] Fix overriding PACKAGE_ARCH for MACHINE specific SRC_URI [v2] Joshua Lock 2012-02-22 1:46 ` [PATCH 1/3] base.bbclass: check all entries of FILESPATH for MACHINE overrides Joshua Lock 2012-02-22 1:46 ` [PATCH 2/3] external-csl-toolchain: skip parsing if CSL_VER_MAIN isn't set Joshua Lock @ 2012-02-22 1:46 ` Joshua Lock 2012-02-22 22:54 ` [PATCH 0/3] Fix overriding PACKAGE_ARCH for MACHINE specific SRC_URI [v2] Richard Purdie 3 siblings, 0 replies; 5+ messages in thread From: Joshua Lock @ 2012-02-22 1:46 UTC (permalink / raw) To: openembedded-core There's no need to explicitly set PACKAGE_ARCH = MACHINE_ARCH, base.bbclass takes care of setting this value for us based on the interfaces for those machines being an OVERRIDE. Signed-off-by: Joshua Lock <josh@linux.intel.com> --- meta/recipes-core/netbase/netbase_4.47.bb | 4 ---- 1 files changed, 0 insertions(+), 4 deletions(-) diff --git a/meta/recipes-core/netbase/netbase_4.47.bb b/meta/recipes-core/netbase/netbase_4.47.bb index ddfa8ad..3aa4915 100644 --- a/meta/recipes-core/netbase/netbase_4.47.bb +++ b/meta/recipes-core/netbase/netbase_4.47.bb @@ -47,7 +47,3 @@ do_install () { } CONFFILES_${PN} = "${sysconfdir}/hosts ${sysconfdir}/network/interfaces" - -PACKAGE_ARCH_qemuarm = "${MACHINE_ARCH}" -PACKAGE_ARCH_qemux86 = "${MACHINE_ARCH}" -PACKAGE_ARCH_qemux86-64 = "${MACHINE_ARCH}" -- 1.7.7.6 ^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH 0/3] Fix overriding PACKAGE_ARCH for MACHINE specific SRC_URI [v2] 2012-02-22 1:46 [PATCH 0/3] Fix overriding PACKAGE_ARCH for MACHINE specific SRC_URI [v2] Joshua Lock ` (2 preceding siblings ...) 2012-02-22 1:46 ` [PATCH 3/3] netbase: remove redundant assignments Joshua Lock @ 2012-02-22 22:54 ` Richard Purdie 3 siblings, 0 replies; 5+ messages in thread From: Richard Purdie @ 2012-02-22 22:54 UTC (permalink / raw) To: Patches and discussions about the oe-core layer On Tue, 2012-02-21 at 17:46 -0800, Joshua Lock wrote: > This series includes a fix for base.bbclass so that PACKAGE_ARCH is correctly set to > MACHINE_ARCH for all recipes which include a MACHINE OVERRIDE in SRC_URI. > > Cheers, > Joshua > > The following changes since commit d4ffe12ca36bf10be4e0f9565d7c3d8e6f4a265a: > > iputils: Add base_libdir to VPATH in order to find the crypto library (2012-02-21 17:59:21 +0000) > > are available in the git repository at: > git://git.openembedded.org/openembedded-core-contrib josh/work > http://cgit.openembedded.org/cgit.cgi/openembedded-core-contrib/log/?h=josh/work > > Joshua Lock (3): > base.bbclass: check all entries of FILESPATH for MACHINE overrides > external-csl-toolchain: skip parsing if CSL_VER_MAIN isn't set > netbase: remove redundant assignments Merged to master, thanks. Richard ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2012-02-22 23:03 UTC | newest] Thread overview: 5+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2012-02-22 1:46 [PATCH 0/3] Fix overriding PACKAGE_ARCH for MACHINE specific SRC_URI [v2] Joshua Lock 2012-02-22 1:46 ` [PATCH 1/3] base.bbclass: check all entries of FILESPATH for MACHINE overrides Joshua Lock 2012-02-22 1:46 ` [PATCH 2/3] external-csl-toolchain: skip parsing if CSL_VER_MAIN isn't set Joshua Lock 2012-02-22 1:46 ` [PATCH 3/3] netbase: remove redundant assignments Joshua Lock 2012-02-22 22:54 ` [PATCH 0/3] Fix overriding PACKAGE_ARCH for MACHINE specific SRC_URI [v2] Richard Purdie
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox