diff options
author | Holger Weiss <holger@zedat.fu-berlin.de> | 2009-05-20 00:32:10 +0200 |
---|---|---|
committer | Holger Weiss <holger@zedat.fu-berlin.de> | 2009-05-20 00:32:10 +0200 |
commit | 50b3ff7b91e78a61aca93247bee586d6d7eb27c8 (patch) | |
tree | db4c7eee24479ac7ee6888ce1562facf60159b71 /gl/m4/lib-link.m4 | |
parent | 2701ccd500e60537a8c2977a81549ff33eeaef3f (diff) | |
download | monitoring-plugins-50b3ff7b91e78a61aca93247bee586d6d7eb27c8.tar.gz |
Sync with the latest Gnulib code (cb75dc5)
Signed-off-by: Holger Weiss <holger@zedat.fu-berlin.de>
Diffstat (limited to 'gl/m4/lib-link.m4')
-rw-r--r-- | gl/m4/lib-link.m4 | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/gl/m4/lib-link.m4 b/gl/m4/lib-link.m4 index fcd3391b..21442033 100644 --- a/gl/m4/lib-link.m4 +++ b/gl/m4/lib-link.m4 | |||
@@ -1,4 +1,4 @@ | |||
1 | # lib-link.m4 serial 18 (gettext-0.18) | 1 | # lib-link.m4 serial 19 (gettext-0.18) |
2 | dnl Copyright (C) 2001-2009 Free Software Foundation, Inc. | 2 | dnl Copyright (C) 2001-2009 Free Software Foundation, Inc. |
3 | dnl This file is free software; the Free Software Foundation | 3 | dnl This file is free software; the Free Software Foundation |
4 | dnl gives unlimited permission to copy and/or distribute it, | 4 | dnl gives unlimited permission to copy and/or distribute it, |
@@ -43,12 +43,13 @@ AC_DEFUN([AC_LIB_LINKFLAGS], | |||
43 | popdef([Name]) | 43 | popdef([Name]) |
44 | ]) | 44 | ]) |
45 | 45 | ||
46 | dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode) | 46 | dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode, [missing-message]) |
47 | dnl searches for libname and the libraries corresponding to explicit and | 47 | dnl searches for libname and the libraries corresponding to explicit and |
48 | dnl implicit dependencies, together with the specified include files and | 48 | dnl implicit dependencies, together with the specified include files and |
49 | dnl the ability to compile and link the specified testcode. If found, it | 49 | dnl the ability to compile and link the specified testcode. The missing-message |
50 | dnl sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME} and | 50 | dnl defaults to 'no' and may contain additional hints for the user. |
51 | dnl LTLIB${NAME} variables and augments the CPPFLAGS variable, and | 51 | dnl If found, it sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME} |
52 | dnl and LTLIB${NAME} variables and augments the CPPFLAGS variable, and | ||
52 | dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs | 53 | dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs |
53 | dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty. | 54 | dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty. |
54 | dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname | 55 | dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname |
@@ -74,12 +75,14 @@ AC_DEFUN([AC_LIB_HAVE_LINKFLAGS], | |||
74 | AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [ | 75 | AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [ |
75 | ac_save_LIBS="$LIBS" | 76 | ac_save_LIBS="$LIBS" |
76 | LIBS="$LIBS $LIB[]NAME" | 77 | LIBS="$LIBS $LIB[]NAME" |
77 | AC_TRY_LINK([$3], [$4], [ac_cv_lib[]Name=yes], [ac_cv_lib[]Name=no]) | 78 | AC_TRY_LINK([$3], [$4], |
79 | [ac_cv_lib[]Name=yes], | ||
80 | [ac_cv_lib[]Name='m4_if([$5], [], [no], [[$5]])']) | ||
78 | LIBS="$ac_save_LIBS" | 81 | LIBS="$ac_save_LIBS" |
79 | ]) | 82 | ]) |
80 | if test "$ac_cv_lib[]Name" = yes; then | 83 | if test "$ac_cv_lib[]Name" = yes; then |
81 | HAVE_LIB[]NAME=yes | 84 | HAVE_LIB[]NAME=yes |
82 | AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the $1 library.]) | 85 | AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the lib[]$1 library.]) |
83 | AC_MSG_CHECKING([how to link with lib[]$1]) | 86 | AC_MSG_CHECKING([how to link with lib[]$1]) |
84 | AC_MSG_RESULT([$LIB[]NAME]) | 87 | AC_MSG_RESULT([$LIB[]NAME]) |
85 | else | 88 | else |