| dnl Process this file with autoconf to produce a configure script. |
| AC_INIT(src/stress.c) |
| AM_INIT_AUTOMAKE(stress, 1.0.4) |
| |
| dnl Checks for programs. |
| AC_PROG_CC |
| |
| dnl Checks for libraries. |
| |
| dnl Checks for header files. |
| AC_HEADER_STDC |
| AC_CHECK_HEADERS(unistd.h) |
| |
| dnl Checks for typedefs, structures, and compiler characteristics. |
| |
| dnl Checks for library functions. |
| AC_CHECK_LIB(m,sqrt) |
| AC_CHECK_LIB(gen,basename) |
| |
| dnl Options that alter compile and link. |
| AC_ARG_ENABLE([static], |
| AC_HELP_STRING([--enable-static], |
| [build static library @<:@default=no@:>@]), |
| [static=$enableval], |
| [static=no]) |
| |
| if test "$static" = yes; then |
| # if we're using gcc, add `-static' to LDFLAGS |
| if test -n "$GCC" || test "$ac_cv_prog_gcc" = "yes"; then |
| STATIC_LD="-static" |
| LDFLAGS="$LDFLAGS -static" |
| fi |
| fi |
| |
| AC_OUTPUT(Makefile src/Makefile doc/Makefile test/Makefile) |