diff options
author | Nathan Rossi <nathan@nathanrossi.com> | 2022-03-02 00:55:32 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-03-09 17:30:49 +0000 |
commit | 4c7c64cc6eb3b1e53d09d1a26c230d0a599536f2 (patch) | |
tree | 6d078e42114af7719420b1a64682c8ecb171afd3 /meta/classes | |
parent | 820be4beeb72e55e3866d22859b6a4d305a8fe59 (diff) | |
download | poky-4c7c64cc6eb3b1e53d09d1a26c230d0a599536f2.tar.gz |
cml1.bbclass: Handle ncurses-native being available via pkg-config
The linux kernel will by default use pkg-config to get ncurses(w) paths,
falling back to absolute path checks otherwise. If the build host does
not have ncurses installed this will fail as pkg-config will not search
the native sysroot for ncurses.
To more all kernel/kconfig sources, inject the equivalent native
pkg-config variables similar to what is done by the pkg-config-native
script. This only affects the menuconfig python task itself and the
oe_terminal call inside it.
(cherry picked from commit abb95c421bb67d452691819e3f63dabd02e2ba37)
(From OE-Core rev: dc6b20475a69c9fbab9a97a93119aeedf54deb23)
Signed-off-by: Nathan Rossi <nathan@nathanrossi.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Steve Sakoman <steve@sakoman.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
-rw-r--r-- | meta/classes/cml1.bbclass | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/meta/classes/cml1.bbclass b/meta/classes/cml1.bbclass index 8ab240589a..46a19fce32 100644 --- a/meta/classes/cml1.bbclass +++ b/meta/classes/cml1.bbclass | |||
@@ -36,6 +36,14 @@ python do_menuconfig() { | |||
36 | except OSError: | 36 | except OSError: |
37 | mtime = 0 | 37 | mtime = 0 |
38 | 38 | ||
39 | # setup native pkg-config variables (kconfig scripts call pkg-config directly, cannot generically be overriden to pkg-config-native) | ||
40 | d.setVar("PKG_CONFIG_DIR", "${STAGING_DIR_NATIVE}${libdir_native}/pkgconfig") | ||
41 | d.setVar("PKG_CONFIG_PATH", "${PKG_CONFIG_DIR}:${STAGING_DATADIR_NATIVE}/pkgconfig") | ||
42 | d.setVar("PKG_CONFIG_LIBDIR", "${PKG_CONFIG_DIR}") | ||
43 | d.setVarFlag("PKG_CONFIG_SYSROOT_DIR", "unexport", "1") | ||
44 | # ensure that environment variables are overwritten with this tasks 'd' values | ||
45 | d.appendVar("OE_TERMINAL_EXPORTS", " PKG_CONFIG_DIR PKG_CONFIG_PATH PKG_CONFIG_LIBDIR PKG_CONFIG_SYSROOT_DIR") | ||
46 | |||
39 | oe_terminal("sh -c \"make %s; if [ \\$? -ne 0 ]; then echo 'Command failed.'; printf 'Press any key to continue... '; read r; fi\"" % d.getVar('KCONFIG_CONFIG_COMMAND'), | 47 | oe_terminal("sh -c \"make %s; if [ \\$? -ne 0 ]; then echo 'Command failed.'; printf 'Press any key to continue... '; read r; fi\"" % d.getVar('KCONFIG_CONFIG_COMMAND'), |
40 | d.getVar('PN') + ' Configuration', d) | 48 | d.getVar('PN') + ' Configuration', d) |
41 | 49 | ||