Merge "BuildSystem: Re-check for another UUID library only when previous check failed."

This commit is contained in:
Jenkins2
2018-03-13 18:17:22 -05:00
committed by Gerrit Code Review
2 changed files with 29 additions and 23 deletions

19
configure vendored
View File

@@ -13890,6 +13890,10 @@ _ACEOF
fi fi
if test "x$LIBUUID_LIB" != "x" ; then
UUID_INCLUDE="$LIBUUID_INCLUDE"
UUID_LIB="$LIBUUID_LIB"
else
if test "x${PBX_E2FSUUID}" != "x1" -a "${USE_E2FSUUID}" != "no"; then if test "x${PBX_E2FSUUID}" != "x1" -a "${USE_E2FSUUID}" != "no"; then
pbxlibdir="" pbxlibdir=""
@@ -13986,6 +13990,10 @@ _ACEOF
fi fi
if test "x$E2FSUUID_LIB" != "x" ; then
UUID_INCLUDE="$E2FSUUID_INCLUDE"
UUID_LIB="$E2FSUUID_LIB"
else
for ac_func in uuid_generate_random for ac_func in uuid_generate_random
do : do :
ac_fn_c_check_func "$LINENO" "uuid_generate_random" "ac_cv_func_uuid_generate_random" ac_fn_c_check_func "$LINENO" "uuid_generate_random" "ac_cv_func_uuid_generate_random"
@@ -13999,19 +14007,14 @@ else
fi fi
done done
if test "x$SYSUUID" != "x" ; then
if test "x$LIBUUID_LIB" != "x" ; then
UUID_INCLUDE="$LIBUUID_INCLUDE"
UUID_LIB="$LIBUUID_LIB"
elif test "x$E2FSUUID_LIB" != "x" ; then
UUID_INCLUDE="$E2FSUUID_INCLUDE"
UUID_LIB="$E2FSUUID_LIB"
elif test "x$SYSUUID" != "x" ; then
UUID_INCLUDE="" UUID_INCLUDE=""
UUID_LIB="" UUID_LIB=""
else else
as_fn_error $? "*** uuid support not found (this typically means the uuid development package is missing)" "$LINENO" 5 as_fn_error $? "*** uuid support not found (this typically means the uuid development package is missing)" "$LINENO" 5
fi fi
fi
fi

View File

@@ -638,21 +638,24 @@ AC_SUBST(EDITLINE_LIB)
# * -le2fs-uuid on OpenBSD # * -le2fs-uuid on OpenBSD
# * in libsystem on OS X # * in libsystem on OS X
AST_EXT_LIB_CHECK([LIBUUID], [uuid], [uuid_generate_random], [uuid/uuid.h], []) AST_EXT_LIB_CHECK([LIBUUID], [uuid], [uuid_generate_random], [uuid/uuid.h], [])
AST_EXT_LIB_CHECK([E2FSUUID], [e2fs-uuid], [uuid_generate_random], [uuid/uuid.h], [])
AC_CHECK_FUNCS([uuid_generate_random], [SYSUUID=true], [SYSUUID=""])
if test "x$LIBUUID_LIB" != "x" ; then if test "x$LIBUUID_LIB" != "x" ; then
UUID_INCLUDE="$LIBUUID_INCLUDE" UUID_INCLUDE="$LIBUUID_INCLUDE"
UUID_LIB="$LIBUUID_LIB" UUID_LIB="$LIBUUID_LIB"
elif test "x$E2FSUUID_LIB" != "x" ; then else
AST_EXT_LIB_CHECK([E2FSUUID], [e2fs-uuid], [uuid_generate_random], [uuid/uuid.h], [])
if test "x$E2FSUUID_LIB" != "x" ; then
UUID_INCLUDE="$E2FSUUID_INCLUDE" UUID_INCLUDE="$E2FSUUID_INCLUDE"
UUID_LIB="$E2FSUUID_LIB" UUID_LIB="$E2FSUUID_LIB"
elif test "x$SYSUUID" != "x" ; then else
AC_CHECK_FUNCS([uuid_generate_random], [SYSUUID=true], [SYSUUID=""])
if test "x$SYSUUID" != "x" ; then
UUID_INCLUDE="" UUID_INCLUDE=""
UUID_LIB="" UUID_LIB=""
else else
AC_MSG_ERROR([*** uuid support not found (this typically means the uuid development package is missing)]) AC_MSG_ERROR([*** uuid support not found (this typically means the uuid development package is missing)])
fi fi
fi
fi
AC_SUBST(UUID_INCLUDE) AC_SUBST(UUID_INCLUDE)
AC_SUBST(UUID_LIB) AC_SUBST(UUID_LIB)