1SUMMARY = "Helper tool used when compiling" 2DESCRIPTION = "pkg-config is a helper tool used when compiling applications and libraries. It helps determined \ 3the correct compiler/link options. It is also language-agnostic." 4HOMEPAGE = "http://pkg-config.freedesktop.org/wiki/" 5BUGTRACKER = "http://bugs.freedesktop.org/buglist.cgi?product=pkg-config" 6SECTION = "console/utils" 7 8LICENSE = "GPL-2.0-or-later" 9LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" 10 11SRCREV = "d97db4fae4c1cd099b506970b285dc2afd818ea2" 12PV = "0.29.2+git${SRCPV}" 13 14SRC_URI = "git://gitlab.freedesktop.org/pkg-config/pkg-config.git;branch=master;protocol=https \ 15 file://pkg-config-esdk.in \ 16 file://pkg-config-native.in \ 17 file://0001-glib-gettext.m4-Update-AM_GLIB_GNU_GETTEXT-to-match-.patch \ 18 file://0001-autotools-remove-support-for-the-__int64-type.-See-1.patch \ 19 file://0001-autotools-use-C99-printf-format-specifiers-on-Window.patch \ 20 " 21 22S = "${WORKDIR}/git" 23 24inherit autotools 25 26# Because of a faulty test, the current auto mode always evaluates to no, 27# so just continue that behaviour. 28# 29EXTRA_OECONF += "--disable-indirect-deps" 30 31PACKAGECONFIG ??= "glib" 32PACKAGECONFIG:class-native = "" 33PACKAGECONFIG:class-nativesdk = "" 34 35PACKAGECONFIG[glib] = "--without-internal-glib,--with-internal-glib,glib-2.0 pkgconfig-native" 36 37acpaths = "-I ." 38 39BBCLASSEXTEND = "native nativesdk" 40 41# Set an empty dev package to ensure the base PN package gets 42# the pkg.m4 macros, pkgconfig does not deliver any other -dev 43# files. 44FILES:${PN}-dev = "" 45FILES:${PN} += "${datadir}/aclocal/pkg.m4" 46 47# When using the RPM generated automatic package dependencies, some packages 48# will end up requiring 'pkgconfig(pkg-config)'. Allow this behavior by 49# specifying an appropriate provide. 50RPROVIDES:${PN} += "pkgconfig(pkg-config)" 51 52# Install a pkg-config-native wrapper that will use the native sysroot instead 53# of the MACHINE sysroot, for using pkg-config when building native tools. 54do_install:append:class-native () { 55 sed -e "s|@PATH_NATIVE@|${PKG_CONFIG_PATH}|" \ 56 -e "s|@LIBDIR_NATIVE@|${PKG_CONFIG_LIBDIR}|" \ 57 < ${WORKDIR}/pkg-config-native.in > ${B}/pkg-config-native 58 install -m755 ${B}/pkg-config-native ${D}${bindir}/pkg-config-native 59 sed -e "s|@PATH_NATIVE@|${PKG_CONFIG_PATH}|" \ 60 -e "s|@LIBDIR_NATIVE@|${PKG_CONFIG_LIBDIR}|" \ 61 < ${WORKDIR}/pkg-config-esdk.in > ${B}/pkg-config-esdk 62 install -m755 ${B}/pkg-config-esdk ${D}${bindir}/pkg-config-esdk 63} 64 65pkgconfig_sstate_fixup_esdk () { 66 if [ "${BB_CURRENTTASK}" = "populate_sysroot_setscene" -a "${WITHIN_EXT_SDK}" = "1" ] ; then 67 pkgconfdir="${SSTATE_INSTDIR}/recipe-sysroot-native/${bindir_native}" 68 mv $pkgconfdir/pkg-config $pkgconfdir/pkg-config.real 69 ln -rs $pkgconfdir/pkg-config-esdk $pkgconfdir/pkg-config 70 sed -i -e "s|^pkg-config|pkg-config.real|" $pkgconfdir/pkg-config-native 71 fi 72} 73 74SSTATEPOSTUNPACKFUNCS:append:class-native = " pkgconfig_sstate_fixup_esdk" 75