From: Arran Cudbard-Bell Date: Fri, 1 Mar 2013 05:42:43 +0000 (-0500) Subject: Be extremely verbose about where were looking for things X-Git-Tag: debian/3.0.0git+dfsg+moonshot3-2~68 X-Git-Url: http://www.project-moonshot.org/gitweb/?p=freeradius.git;a=commitdiff_plain;h=4c14a49c9fce64fcb968fd58006209765eb3ae9f Be extremely verbose about where were looking for things --- diff --git a/acinclude.m4 b/acinclude.m4 index 6bc3e6d..f334c09 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -188,7 +188,6 @@ AC_DEFUN([FR_SMART_CHECK_LIB], [ sm_lib_safe=`echo "$1" | sed 'y%./+-%__p_%'` sm_func_safe=`echo "$2" | sed 'y%./+-%__p_%'` -AC_MSG_CHECKING([for $2 in -l$1]) old_LIBS="$LIBS" smart_lib= @@ -200,13 +199,16 @@ dnl # the wrong version. dnl # if test "x$smart_try_dir" != "x"; then for try in $smart_try_dir; do + AC_MSG_CHECKING([for $2 in -l$1 in $try]) LIBS="-L$try -l$1 $old_LIBS -Wl,-rpath,$try" AC_TRY_LINK([extern char $2();], - [ $2()], - smart_lib="-L$try -l$1 -rpath$try") - if test "x$smart_lib" != "x"; then - break; - fi + [$2()], + [ + smart_lib="-L$try -l$1 -rpath$try" + AC_MSG_RESULT(yes) + break + ], + [AC_MSG_RESULT(no)]) done LIBS="$old_LIBS" fi @@ -215,10 +217,15 @@ dnl # dnl # Try using the default library path dnl # if test "x$smart_lib" = "x"; then + AC_MSG_CHECKING([for $2 in -l$1]) LIBS="-l$1 $old_LIBS" AC_TRY_LINK([extern char $2();], - [ $2()], - smart_lib="-l$1") + [$2()], + [ + smart_lib="-l$1" + AC_MSG_RESULT(yes) + ], + [AC_MSG_RESULT(no)]) LIBS="$old_LIBS" fi @@ -230,13 +237,16 @@ if test "x$smart_lib" = "x"; then FR_LOCATE_DIR(smart_lib_dir,[lib$1.a]) for try in $smart_lib_dir /usr/local/lib /opt/lib; do + AC_MSG_CHECKING([for $2 in -l$1 in $try]) LIBS="-L$try -rpath$try -l$1 $old_LIBS -Wl,-rpath,$try" AC_TRY_LINK([extern char $2();], - [ $2()], - smart_lib="-L$try -l$1,-rpath$try") - if test "x$smart_lib" != "x"; then - break; - fi + [$2()], + [ + smart_lib="-L$try -l$1,-rpath$try" + AC_MSG_RESULT(yes) + break + ], + [AC_MSG_RESULT(no)]) done LIBS="$old_LIBS" fi @@ -245,12 +255,9 @@ dnl # dnl # Found it, set the appropriate variable. dnl # if test "x$smart_lib" != "x"; then - AC_MSG_RESULT(yes) eval "ac_cv_lib_${sm_lib_safe}_${sm_func_safe}=yes" LIBS="$smart_lib $old_LIBS" SMART_LIBS="$smart_lib $SMART_LIBS" -else - AC_MSG_RESULT(no) fi ]) @@ -263,8 +270,6 @@ dnl # AC_DEFUN([FR_SMART_CHECK_INCLUDE], [ ac_safe=`echo "$1" | sed 'y%./+-%__pm%'` -AC_MSG_CHECKING([for $1]) - old_CFLAGS="$CFLAGS" smart_include= smart_include_dir= @@ -275,15 +280,20 @@ dnl # the wrong version. dnl # if test "x$smart_try_dir" != "x"; then for try in $smart_try_dir; do + AC_MSG_CHECKING([for $1 in $try]) CFLAGS="$old_CFLAGS -I$try" AC_TRY_COMPILE([$2 #include <$1>], - [ int a = 1;], - smart_include="-I$try", - smart_include=) - if test "x$smart_include" != "x"; then - break; - fi + [int a = 1;], + [ + smart_include="-I$try" + AC_MSG_RESULT(yes) + break + ], + [ + smart_include= + AC_MSG_RESULT(no) + ]) done CFLAGS="$old_CFLAGS" fi @@ -292,11 +302,19 @@ dnl # dnl # Try using the default includes. dnl # if test "x$smart_include" = "x"; then + AC_MSG_CHECKING([for $1]) AC_TRY_COMPILE([$2 #include <$1>], - [ int a = 1;], - smart_include=" ", - smart_include=) + [int a = 1;], + [ + smart_include=" " + AC_MSG_RESULT(yes) + break + ], + [ + smart_include= + AC_MSG_RESULT(no) + ]) fi dnl # @@ -304,17 +322,21 @@ dnl # Try to guess possible locations. dnl # if test "x$smart_include" = "x"; then FR_LOCATE_DIR(smart_include_dir,$1) - for try in $smart_include_dir /usr/local/include /opt/include; do + AC_MSG_CHECKING([for $1 in $try]) CFLAGS="$old_CFLAGS -I$try" AC_TRY_COMPILE([$2 #include <$1>], - [ int a = 1;], - smart_include="-I$try", - smart_include=) - if test "x$smart_include" != "x"; then - break; - fi + [int a = 1;], + [ + smart_include="-I$try" + AC_MSG_RESULT(yes) + break + ], + [ + smart_include= + AC_MSG_RESULT(no) + ]) done CFLAGS="$old_CFLAGS" fi @@ -323,12 +345,9 @@ dnl # dnl # Found it, set the appropriate variable. dnl # if test "x$smart_include" != "x"; then - AC_MSG_RESULT(yes) eval "ac_cv_header_$ac_safe=yes" CFLAGS="$old_CFLAGS $smart_include" SMART_CFLAGS="$SMART_CFLAGS $smart_include" -else - AC_MSG_RESULT(no) fi ]) @@ -427,9 +446,9 @@ AC_DEFUN([VL_LIB_READLINE], [ [Define if you have a readline compatible library]) AC_CHECK_HEADERS(readline.h readline/readline.h) AC_CACHE_CHECK([whether readline supports history], - vl_cv_lib_readline_history, [ + [vl_cv_lib_readline_history], [ vl_cv_lib_readline_history="no" - AC_TRY_LINK_FUNC(add_history, vl_cv_lib_readline_history="yes") + AC_TRY_LINK_FUNC([add_history], [vl_cv_lib_readline_history="yes"]) ]) if test "$vl_cv_lib_readline_history" = "yes"; then AC_DEFINE(HAVE_READLINE_HISTORY, 1, diff --git a/src/modules/rlm_sql/drivers/rlm_sql_db2/configure b/src/modules/rlm_sql/drivers/rlm_sql_db2/configure index 66f3c79..401576f 100755 --- a/src/modules/rlm_sql/drivers/rlm_sql_db2/configure +++ b/src/modules/rlm_sql/drivers/rlm_sql_db2/configure @@ -2638,8 +2638,6 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu sm_lib_safe=`echo "db2" | sed 'y%./+-%__p_%'` sm_func_safe=`echo "SQLConnect" | sed 'y%./+-%__p_%'` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SQLConnect in -ldb2" >&5 -$as_echo_n "checking for SQLConnect in -ldb2... " >&6; } old_LIBS="$LIBS" smart_lib= @@ -2647,31 +2645,40 @@ smart_lib_dir= if test "x$smart_try_dir" != "x"; then for try in $smart_try_dir; do - LIBS="-L$try -ldb2 $old_LIBS" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SQLConnect in -ldb2 in $try" >&5 +$as_echo_n "checking for SQLConnect in -ldb2 in $try... " >&6; } + LIBS="-L$try -ldb2 $old_LIBS -Wl,-rpath,$try" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ extern char SQLConnect(); int main () { - SQLConnect() +SQLConnect() ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - smart_lib="-L$try -ldb2" + + smart_lib="-L$try -ldb2 -rpath$try" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + break + +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext - if test "x$smart_lib" != "x"; then - break; - fi done LIBS="$old_LIBS" fi if test "x$smart_lib" = "x"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SQLConnect in -ldb2" >&5 +$as_echo_n "checking for SQLConnect in -ldb2... " >&6; } LIBS="-ldb2 $old_LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -2679,13 +2686,20 @@ extern char SQLConnect(); int main () { - SQLConnect() +SQLConnect() ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - smart_lib="-ldb2" + + smart_lib="-ldb2" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext @@ -2749,39 +2763,41 @@ eval "smart_lib_dir=\"\$smart_lib_dir $DIRS\"" for try in $smart_lib_dir /usr/local/lib /opt/lib; do - LIBS="-L$try -ldb2 $old_LIBS" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SQLConnect in -ldb2 in $try" >&5 +$as_echo_n "checking for SQLConnect in -ldb2 in $try... " >&6; } + LIBS="-L$try -rpath$try -ldb2 $old_LIBS -Wl,-rpath,$try" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ extern char SQLConnect(); int main () { - SQLConnect() +SQLConnect() ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - smart_lib="-L$try -ldb2" + + smart_lib="-L$try -ldb2,-rpath$try" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + break + +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext - if test "x$smart_lib" != "x"; then - break; - fi done LIBS="$old_LIBS" fi if test "x$smart_lib" != "x"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } eval "ac_cv_lib_${sm_lib_safe}_${sm_func_safe}=yes" LIBS="$smart_lib $old_LIBS" SMART_LIBS="$smart_lib $SMART_LIBS" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } fi if test "x$ac_cv_lib_db2_SQLConnect" != xyes; then @@ -2792,15 +2808,14 @@ fi ac_safe=`echo "sqlcli.h" | sed 'y%./+-%__pm%'` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqlcli.h" >&5 -$as_echo_n "checking for sqlcli.h... " >&6; } - old_CFLAGS="$CFLAGS" smart_include= smart_include_dir= if test "x$smart_try_dir" != "x"; then for try in $smart_try_dir; do + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqlcli.h in $try" >&5 +$as_echo_n "checking for sqlcli.h in $try... " >&6; } CFLAGS="$old_CFLAGS -I$try" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -2809,25 +2824,33 @@ if test "x$smart_try_dir" != "x"; then int main () { - int a = 1; +int a = 1; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - smart_include="-I$try" + + smart_include="-I$try" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + break + else - smart_include= + + smart_include= + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - if test "x$smart_include" != "x"; then - break; - fi done CFLAGS="$old_CFLAGS" fi if test "x$smart_include" = "x"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqlcli.h" >&5 +$as_echo_n "checking for sqlcli.h... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -2835,15 +2858,24 @@ if test "x$smart_include" = "x"; then int main () { - int a = 1; +int a = 1; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - smart_include=" " + + smart_include=" " + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + break + else - smart_include= + + smart_include= + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi @@ -2876,8 +2908,9 @@ fi eval "smart_include_dir=\"\$smart_include_dir $DIRS\"" - for try in $smart_include_dir /usr/local/include /opt/include; do + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqlcli.h in $try" >&5 +$as_echo_n "checking for sqlcli.h in $try... " >&6; } CFLAGS="$old_CFLAGS -I$try" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -2886,33 +2919,34 @@ eval "smart_include_dir=\"\$smart_include_dir $DIRS\"" int main () { - int a = 1; +int a = 1; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - smart_include="-I$try" + + smart_include="-I$try" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + break + else - smart_include= + + smart_include= + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - if test "x$smart_include" != "x"; then - break; - fi done CFLAGS="$old_CFLAGS" fi if test "x$smart_include" != "x"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } eval "ac_cv_header_$ac_safe=yes" CFLAGS="$old_CFLAGS $smart_include" SMART_CFLAGS="$SMART_CFLAGS $smart_include" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } fi if test "x$ac_cv_header_sqlcli_h" != xyes; then