configure: use AC_PATH_TOOL for pkg-config
AC_CHECK_PROGS will find the tool using exactly the name given: it only searches for "pkg-config". When doing native builds, this is generally fine. However, when cross-compiling, this is not ideal as `pkg-config` is often configured for the build system, not the system we want to cross-compile for. Switch to using the AC_PATH_TOOL tool instead. This will look for "pkg-config" with a $host- prefix first before falling back to the plain "pkg-config". When doing native builds, things should still behave the same, but now things work better out of the box when we cross-compile. For example, `./configure --host=aarch64-linux-gnu` will first look for "aarch64-linux-gnu-pkg-config" before falling back to the plain "pkg-config".
This commit is contained in:
parent
b94dd4b770
commit
e9a21197ec
1 changed files with 1 additions and 1 deletions
|
|
@ -459,7 +459,7 @@ else
|
|||
alllang_default=yes
|
||||
fi
|
||||
|
||||
AC_CHECK_PROGS([PKG_CONFIG], [pkg-config])
|
||||
AC_PATH_TOOL([PKG_CONFIG], [pkg-config])
|
||||
|
||||
#--------------------------------------------------------------------
|
||||
# Look for Tcl
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue