summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorLinus Nordberg <linus@nordu.net>2011-09-27 17:04:49 +0200
committerLinus Nordberg <linus@nordu.net>2011-09-27 17:04:49 +0200
commit8eeb47547e346475e7cf27a20c949a49d3e54116 (patch)
tree19608aced1fb4d78f8bddf8a656e1da0edbe7733 /configure.ac
parent1a80ea4372d745267ed10c32b2a7067a7e25a83b (diff)
Add --enable-fticks to configure.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac20
1 files changed, 18 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac
index 24cbf05..3ff1cc3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -48,9 +48,25 @@ AC_ARG_ENABLE(dtls,
fi
])
+AC_ARG_ENABLE(fticks,
+AC_HELP_STRING([--enable-fticks],[build with F-Ticks support [default=no]]),
+[case $enableval in
+yes|no) ;;
+*) AC_MSG_ERROR([bad value $enableval for --enable-fticks, need yes or no]) ;;
+esac],
+[enable_fticks=no])
+
+if test "$enable_fticks" = "yes"; then
AC_CHECK_LIB([nettle], [nettle_sha256_init],,
- AC_MSG_ERROR([required library nettle not found]))
-
+ [AC_MSG_WARN([required library nettle not found, fticks support disabled])
+ enable_fticks=no])
+fi
+
+if test "$enable_fticks" = "yes"; then
+AC_DEFINE([WANT_FTICKS], [1])
+fi
+AM_CONDITIONAL(WANT_FTICKS, test "$enable_fticks" = "yes")
+
dnl Check if we're on Solaris and set CFLAGS accordingly
AC_CANONICAL_SYSTEM
case "${target_os}" in