base/perlnative/pythonnative/gzipnative: Add a new variable to enable easier handling of native path issues
If something is listed in ASSUME_PROVIDED but also manually built (like bzip2-native and bzip2-replacement-native), we need to ensure that the installed binaries are only accessed for things which list the provider in DEPENDS. This patch adds a generic mechanism to handle this instead of everything reinventing the wheel. EXTRANATIVEPATH += "perl-native" will ensure that ${STAGING_BINDIR_NATIVE}/perl-native is added to PATH. This means that: a) Such providers should install to ${bindir}/xxx-native b) Should PROVIDE += "xxxx-replacement-native" c) That users should DEPEND on xxx-replacement-native and have EXTRANATIVEPATH += "xxx-native" This patch enables this at the core level, the bzip2 recipe still needs adjusting to work like this along with adjustment of the users of bzip2-replacement-native (python-native?). (From OE-Core rev: 14b70cd222519e5bccaca955334787f123d9fc54) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
parent
f3d5e08e65
commit
5157c85776
|
@ -74,6 +74,15 @@ FILESPATH = "${@base_set_filespath([ "${FILE_DIRNAME}/${PF}", "${FILE_DIRNAME}/$
|
||||||
# in the context of the location its used (:=)
|
# in the context of the location its used (:=)
|
||||||
THISDIR = "${@os.path.dirname(d.getVar('FILE', True))}"
|
THISDIR = "${@os.path.dirname(d.getVar('FILE', True))}"
|
||||||
|
|
||||||
|
def extra_path_elements(d):
|
||||||
|
path = ""
|
||||||
|
elements = (d.getVar('EXTRANATIVEPATH', True) or "").split()
|
||||||
|
for e in elements:
|
||||||
|
path = path + "${STAGING_BINDIR_NATIVE}/" + e + ":"
|
||||||
|
return path
|
||||||
|
|
||||||
|
PATH_prepend = "${@extra_path_elements(d)}"
|
||||||
|
|
||||||
addtask fetch
|
addtask fetch
|
||||||
do_fetch[dirs] = "${DL_DIR}"
|
do_fetch[dirs] = "${DL_DIR}"
|
||||||
do_fetch[file-checksums] = "${@bb.fetch.get_checksum_file_list(d)}"
|
do_fetch[file-checksums] = "${@bb.fetch.get_checksum_file_list(d)}"
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
PATH_prepend = "${STAGING_BINDIR_NATIVE}/pigz-native:${STAGING_BINDIR_NATIVE}/gzip-native:"
|
EXTRANATIVEPATH += "pigz-native gzip-native"
|
||||||
DEPENDS += "gzip-native"
|
DEPENDS += "gzip-native"
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
PATH_prepend = "${STAGING_BINDIR_NATIVE}/perl-native:"
|
EXTRANATIVEPATH += "perl-native"
|
||||||
DEPENDS += "perl-native"
|
DEPENDS += "perl-native"
|
||||||
OECMAKE_PERLNATIVE_DIR = "${STAGING_BINDIR_NATIVE}/perl-native"
|
OECMAKE_PERLNATIVE_DIR = "${STAGING_BINDIR_NATIVE}/perl-native"
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
PYTHON="${STAGING_BINDIR_NATIVE}/python-native/python"
|
PYTHON="${STAGING_BINDIR_NATIVE}/python-native/python"
|
||||||
PATH_prepend = "${STAGING_BINDIR_NATIVE}/python-native:"
|
EXTRANATIVEPATH += "python-native"
|
||||||
DEPENDS += " python-native "
|
DEPENDS += " python-native "
|
||||||
|
|
Loading…
Reference in New Issue