diff options
| author | Tom Hochstein <tom.hochstein@oss.nxp.com> | 2024-12-22 10:22:30 -0600 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2024-12-23 11:32:26 +0000 |
| commit | 3675ea0765e72673752b2ef6e2603b1545cfe90f (patch) | |
| tree | 960c66034df9f3dc8aea3a8726e09d24680bc753 /meta/recipes-devtools/pkgconfig/pkgconfig_git.bb | |
| parent | 9dbeec7fa712ec6149b955721343bf2651fd72de (diff) | |
| download | poky-3675ea0765e72673752b2ef6e2603b1545cfe90f.tar.gz | |
pkgconfig: Add pkg-config-native to SDK
Building weston with an SDK fails to find pkg-config-native:
```
Did not find pkg-config by name 'pkg-config-native'
Found pkg-config: NO
Found CMake: /opt/poky/5.1/sysroots/x86_64-pokysdk-linux/usr/bin/cmake (3.31.0)
Build-time dependency wayland-scanner found: NO (tried cmake)
protocol/meson.build:1:14: ERROR: Dependency lookup for wayland-scanner with method 'pkgconfig' failed: Pkg-config for machine build machine not found. Giving up.
```
Fix the problem by extending the pkg-config-native wrapper install to
class-nativesdk.
(From OE-Core rev: 065ab44943b78ccb806477684b1167d69d5d1d6d)
Signed-off-by: Tom Hochstein <tom.hochstein@oss.nxp.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/pkgconfig/pkgconfig_git.bb')
| -rw-r--r-- | meta/recipes-devtools/pkgconfig/pkgconfig_git.bb | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/meta/recipes-devtools/pkgconfig/pkgconfig_git.bb b/meta/recipes-devtools/pkgconfig/pkgconfig_git.bb index 6f13d0177e..2b298eb5e8 100644 --- a/meta/recipes-devtools/pkgconfig/pkgconfig_git.bb +++ b/meta/recipes-devtools/pkgconfig/pkgconfig_git.bb | |||
| @@ -46,9 +46,9 @@ FILES:${PN} += "${datadir}/aclocal/pkg.m4" | |||
| 46 | # specifying an appropriate provide. | 46 | # specifying an appropriate provide. |
| 47 | RPROVIDES:${PN} += "pkgconfig(pkg-config)" | 47 | RPROVIDES:${PN} += "pkgconfig(pkg-config)" |
| 48 | 48 | ||
| 49 | # Install a pkg-config-native wrapper that will use the native sysroot instead | ||
| 50 | # of the MACHINE sysroot, for using pkg-config when building native tools. | ||
| 51 | do_install:append:class-native () { | 49 | do_install:append:class-native () { |
| 50 | # Install a pkg-config-native wrapper that will use the native sysroot instead | ||
| 51 | # of the MACHINE sysroot, for using pkg-config when building native tools. | ||
| 52 | sed -e "s|@PATH_NATIVE@|${PKG_CONFIG_PATH}|" \ | 52 | sed -e "s|@PATH_NATIVE@|${PKG_CONFIG_PATH}|" \ |
| 53 | -e "s|@LIBDIR_NATIVE@|${PKG_CONFIG_LIBDIR}|" \ | 53 | -e "s|@LIBDIR_NATIVE@|${PKG_CONFIG_LIBDIR}|" \ |
| 54 | < ${UNPACKDIR}/pkg-config-native.in > ${B}/pkg-config-native | 54 | < ${UNPACKDIR}/pkg-config-native.in > ${B}/pkg-config-native |
| @@ -59,6 +59,15 @@ do_install:append:class-native () { | |||
| 59 | install -m755 ${B}/pkg-config-esdk ${D}${bindir}/pkg-config-esdk | 59 | install -m755 ${B}/pkg-config-esdk ${D}${bindir}/pkg-config-esdk |
| 60 | } | 60 | } |
| 61 | 61 | ||
| 62 | do_install:append:class-nativesdk () { | ||
| 63 | # Install a pkg-config-native wrapper that will use the native sysroot instead | ||
| 64 | # of the MACHINE sysroot, for using pkg-config when building native tools. | ||
| 65 | sed -e "s|@PATH_NATIVE@|\$OECORE_NATIVE_SYSROOT|" \ | ||
| 66 | -e "s|@LIBDIR_NATIVE@|\$OECORE_NATIVE_SYSROOT/usr/lib/pkgconfig|" \ | ||
| 67 | < ${UNPACKDIR}/pkg-config-native.in > ${B}/pkg-config-native | ||
| 68 | install -m755 ${B}/pkg-config-native ${D}${bindir}/pkg-config-native | ||
| 69 | } | ||
| 70 | |||
| 62 | pkgconfig_sstate_fixup_esdk () { | 71 | pkgconfig_sstate_fixup_esdk () { |
| 63 | if [ "${BB_CURRENTTASK}" = "populate_sysroot_setscene" -a "${WITHIN_EXT_SDK}" = "1" ] ; then | 72 | if [ "${BB_CURRENTTASK}" = "populate_sysroot_setscene" -a "${WITHIN_EXT_SDK}" = "1" ] ; then |
| 64 | pkgconfdir="${SSTATE_INSTDIR}/recipe-sysroot-native/${bindir_native}" | 73 | pkgconfdir="${SSTATE_INSTDIR}/recipe-sysroot-native/${bindir_native}" |
