havelib: Fix for Solaris 11 OpenIndiana and Solaris 11 OmniOS.
[gnulib.git] / m4 / thread.m4
blobd1e62b82ae20486fc49207f0ed53620d4511863a
1 # thread.m4 serial 3
2 dnl Copyright (C) 2008-2020 Free Software Foundation, Inc.
3 dnl This file is free software; the Free Software Foundation
4 dnl gives unlimited permission to copy and/or distribute it,
5 dnl with or without modifications, as long as this notice is preserved.
7 AC_DEFUN([gl_THREAD],
9   AC_REQUIRE([gl_THREADLIB])
11   if test $gl_threads_api = posix; then
12     gl_save_LIBS="$LIBS"
13     LIBS="$LIBS $LIBMULTITHREAD"
14     AC_CHECK_FUNCS([pthread_atfork])
15     LIBS="$gl_save_LIBS"
16   fi