diff options
author | Mike Frysinger <vapier@gentoo.org> | 2014-09-17 17:25:23 -0400 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2014-09-17 17:25:23 -0400 |
commit | 8863e239450466dda4c174d3d473b48f2b8053ea (patch) | |
tree | 5f16e3c01dad90421c595a96919c8688d2b609e5 /wrappers | |
parent | switch from PORTDIR/PORTDIR_OVERLAY to repositories_configuration (diff) | |
download | crossdev-8863e239450466dda4c174d3d473b48f2b8053ea.tar.gz crossdev-8863e239450466dda4c174d3d473b48f2b8053ea.tar.bz2 crossdev-8863e239450466dda4c174d3d473b48f2b8053ea.zip |
cross-pkg-config: probe pkgconfig dir directly
Since we're looking for the pkgconfig dir, let's probe it directly rather
than rely on specific C library files.
URL: https://bugs.gentoo.org/518790
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'wrappers')
-rwxr-xr-x | wrappers/cross-pkg-config | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/wrappers/cross-pkg-config b/wrappers/cross-pkg-config index f928bd0..000d6ad 100755 --- a/wrappers/cross-pkg-config +++ b/wrappers/cross-pkg-config @@ -85,9 +85,9 @@ var="LIBDIR_${ABI}" libdir=${!var} if [ -z "${libdir}" ] ; then # Fall back to probing the compiler. - libc=$(realpath $(${CC:-${CHOST}-gcc} ${CFLAGS} ${LDFLAGS} -print-file-name=libc.so)) + libdir=$(realpath "$(${CC:-${CHOST}-gcc} ${CFLAGS} ${LDFLAGS} -print-file-name=pkgconfig)/..") # Chopping the basename isn't exactly correct, but it's good enough for now. - libdir=$(basename "${libc%/*}") + libdir=$(basename "${libdir}") fi : ${libdir:=lib} export PKG_CONFIG_SYSTEM_LIBRARY_PATH="/usr/${libdir}:/${libdir}" |