configure.ac revision 6acdc8efa73ceb0c3b515cd34c333d929e8b4273
1# -*- Autoconf -*- 2# Process this file with autoconf to produce a configure script. 3AC_PREREQ(2.59) 4 5AC_INIT([rt-test],[0.3],[linux-rt-users@vger.kernel.org]) 6AC_CONFIG_HEADERS([include/rttests_config.h]) 7#AC_CONFIG_SRCDIR([internal/examples/libstats_test.c]) 8AC_CONFIG_MACRO_DIR([config/m4]) 9AC_CONFIG_AUX_DIR([config/autoconf]) 10AC_CANONICAL_BUILD 11AC_CANONICAL_HOST 12 13AM_MAINTAINER_MODE 14 15CFLAGS="${CFLAGS} -Wall -I/usr/include/nptl" 16LDFLAGS="-L/usr/lib/nptl -lpthread" 17 18AM_INIT_AUTOMAKE([foreign no-exeext dist-bzip2]) 19 20AC_PROG_RANLIB 21 22# 23# Checks for header files. 24# 25AC_HEADER_DIRENT 26AC_HEADER_STDC 27AC_HEADER_SYS_WAIT 28dnl AC_CHECK_HEADERS([limits.h]) 29 30 31# 32# Checks for typedefs, structures, and compiler characteristics. 33# 34AC_C_CONST 35AC_C_INLINE 36AC_TYPE_SIZE_T 37AC_HEADER_TIME 38 39 40# 41# Checks for library functions. 42# 43 44AC_CHECK_FUNCS([pthread_mutexattr_setprotocol]) 45AM_CONDITIONAL( 46 [HAVE_PTHREAD_MUTEXATTR_SETPROTOCOL], 47 [test "$ac_cv_func_pthread_mutexattr_setprotocol" = "yes"]) 48 49AC_CHECK_FUNCS([pthread_mutexattr_setrobust_np]) 50AM_CONDITIONAL( 51 [HAVE_PTHREAD_MUTEXATTR_SETROBUST_NP], 52 [test "$ac_cv_func_pthread_mutexattr_setrobust_np" = "yes"]) 53 54# 55# Debugging 56# 57AC_MSG_CHECKING([whether to enable debugging]) 58AC_ARG_ENABLE(debug, 59 AS_HELP_STRING([--enable-debug], [enable debugging @<:@default=yes@:>@]), 60 [case "$enableval" in 61 y | yes) CONFIG_DEBUG=yes ;; 62 *) CONFIG_DEBUG=no ;; 63 esac], 64 [CONFIG_DEBUG=yes]) 65AC_MSG_RESULT([${CONFIG_DEBUG}]) 66if test "${CONFIG_DEBUG}" = "yes"; then 67 CFLAGS="${CFLAGS} -Wsign-compare -Wfloat-equal -Wformat-security -Werror -g -O1" 68 AC_DEFINE(DEBUG, 1, [debugging]) 69else 70 CFLAGS="${CFLAGS} -O2" 71fi 72 73AC_CONFIG_FILES([ 74 include/GNUmakefile 75 lib/GNUmakefile 76 config/GNUmakefile 77 stress/pi-tests/GNUmakefile 78 stress/GNUmakefile 79 GNUmakefile 80 perf/latency/GNUmakefile 81 perf/GNUmakefile 82 func/sched_latency/GNUmakefile 83 func/async_handler/GNUmakefile 84 func/hrtimer-prio/GNUmakefile 85 func/sched_jitter/GNUmakefile 86 func/sched_football/GNUmakefile 87 func/matrix_mult/GNUmakefile 88 func/pi-tests/GNUmakefile 89 func/prio-wake/GNUmakefile 90 func/measurement/GNUmakefile 91 func/gtod_latency/GNUmakefile 92 func/pthread_kill_latency/GNUmakefile 93 func/periodic_cpu_load/GNUmakefile 94 func/pi_perf/GNUmakefile 95 func/GNUmakefile 96 func/prio-preempt/GNUmakefile 97 func/thread_clock/GNUmakefile 98]) 99 100AC_OUTPUT 101