diff options
author | Arvind Sankar <[email protected]> | 2020-07-09 16:31:41 -0400 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2020-07-10 14:26:40 -0700 |
commit | f040a7b0f8bad1cea97b0148076608db0c183d2a (patch) | |
tree | 38d4ed0d2c602da6f2bd72fa3dfcd6c3549ee8ed /config/user-libtirpc.m4 | |
parent | 3e597dee1128db8907a2b757c675c41cfdbf21aa (diff) |
Fix up FIND_SYSTEM_LIBRARY to work with cross-compiling
Make FIND_SYSTEM_LIBRARY respect a configured sysroot, otherwise it
might find headers from the build machine and assume the library is
available on the host/target.
Tighten up error checking: if pkg-config or the user specified _CFLAGS
or _LIBS but we can't find the header/library, issue a fatal error.
Fix the -L flag to /usr/local/lib instead of just /usr/local.
Clean out the _CFLAGS and _LIBS if we located something that we later
find doesn't work.
Rename FIND_SYSTEM_LIBRARY into the ZFS_AC_ scope.
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Arvind Sankar <[email protected]>
Closes #10538
Diffstat (limited to 'config/user-libtirpc.m4')
-rw-r--r-- | config/user-libtirpc.m4 | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/config/user-libtirpc.m4 b/config/user-libtirpc.m4 index 19c02c9d5..aa7ab4a1f 100644 --- a/config/user-libtirpc.m4 +++ b/config/user-libtirpc.m4 @@ -19,7 +19,7 @@ AC_DEFUN([ZFS_AC_CONFIG_USER_LIBTIRPC], [ ]) AS_IF([test "x$have_xdr" = "x"], [ - FIND_SYSTEM_LIBRARY(LIBTIRPC, [libtirpc], [rpc/xdr.h], [tirpc], [tirpc], [xdrmem_create], [], [ + ZFS_AC_FIND_SYSTEM_LIBRARY(LIBTIRPC, [libtirpc], [rpc/xdr.h], [tirpc], [tirpc], [xdrmem_create], [], [ AS_IF([test "x$with_tirpc" = "xyes"], [ AC_MSG_FAILURE([--with-tirpc was given, but libtirpc is not available, try installing libtirpc-devel]) ],[dnl ELSE |