2
0
mirror of https://gitlab.isc.org/isc-projects/kea synced 2025-08-29 04:57:52 +00:00

[#2049] AX_FIND_LIBRARY: look in lib64 also

This commit is contained in:
Andrei Pavel 2021-09-14 11:27:16 +03:00
parent cc2c293206
commit 6fe151c002
No known key found for this signature in database
GPG Key ID: 86E9385BC2203766

View File

@ -88,7 +88,6 @@ AC_DEFUN([AX_FIND_LIBRARY], [
if ! "${LIBRARY_FOUND}"; then
for p in /usr /usr/local; do
headers_found=true
libraries_found=true
for i in ${list_of_headers}; do
if test ! -f "${p}/include/${i}"; then
AX_ADD_TO_LIBRARY_WARNINGS([${library} header ${i} not found in ${p}])
@ -101,17 +100,24 @@ AC_DEFUN([AX_FIND_LIBRARY], [
LIBRARY_INCLUDEDIR="-I${p}/include"
fi
libraries_found=true
LIBRARY_LIBS="-L${p}/lib -Wl,-rpath=${p}/lib"
for i in ${list_of_libraries}; do
i_found=false
for l in lib lib64; do
if test ! -f "${p}/${l}/${i}"; then
if test -f "${p}/${l}/${i}"; then
lib=$(printf '%s' "${i}" | sed 's/^lib//g;s/.so$//g')
LIBRARY_LIBS="${LIBRARY_LIBS} -l${lib}"
i_found=true
break
else
AX_ADD_TO_LIBRARY_WARNINGS([${library} library ${i} not found in ${p}/${l}])
libraries_found=false
break 2
fi
lib=$(printf '%s' "${i}" | sed 's/^lib//g;s/.so$//g')
LIBRARY_LIBS="${LIBRARY_LIBS} -l${lib}"
done
if ! "${i_found}"; then
libraries_found=false
break
fi
done
if "${headers_found}" && "${libraries_found}"; then