Mercurial > hg > octave-kai > gnulib-hg
changeset 2491:9108f5af9d61
(jm_FUNC_NANOSLEEP): Save and restore LIBS around
AC_SEARCH_LIBS call for nanosleep.
(LIB_NANOSLEEP): Set and AC_SUBST.
author | Jim Meyering <jim@meyering.net> |
---|---|
date | Sat, 06 May 2000 14:03:19 +0000 |
parents | 315d957d8608 |
children | d4146c377abc |
files | m4/nanosleep.m4 |
diffstat | 1 files changed, 7 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/m4/nanosleep.m4 +++ b/m4/nanosleep.m4 @@ -1,4 +1,4 @@ -#serial 5 +#serial 6 dnl From Jim Meyering. dnl Check for the nanosleep function. @@ -7,9 +7,12 @@ AC_DEFUN(jm_FUNC_NANOSLEEP, [ + nanosleep_save_libs=$LIBS + # Solaris 2.5.1 needs -lposix4 to get the nanosleep function. # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4. - AC_SEARCH_LIBS(nanosleep, [rt posix4]) + AC_SEARCH_LIBS(nanosleep, [rt posix4], [LIB_NANOSLEEP=$ac_cv_search_nanosleep]) + AC_SUBST(LIB_NANOSLEEP) AC_CACHE_CHECK([whether nanosleep works], jm_cv_func_nanosleep_works, @@ -47,4 +50,6 @@ AC_DEFINE_UNQUOTED(nanosleep, rpl_nanosleep, [Define to rpl_nanosleep if the replacement function should be used.]) fi + + LIBS=$nanosleep_save_libs ])