mirror of
https://github.com/cryb-to/cryb-to.git
synced 2024-12-26 14:31:08 +00:00
Reorganize the configure script. Move the header and function checks
up so they're not affected by the debugging / developer options.
This commit is contained in:
parent
c9536ec04b
commit
4c59fd979b
1 changed files with 41 additions and 17 deletions
58
configure.ac
58
configure.ac
|
@ -6,6 +6,11 @@ AC_CONFIG_MACRO_DIR([m4])
|
||||||
AM_INIT_AUTOMAKE([foreign])
|
AM_INIT_AUTOMAKE([foreign])
|
||||||
AM_CONFIG_HEADER([include/config.h])
|
AM_CONFIG_HEADER([include/config.h])
|
||||||
|
|
||||||
|
############################################################################
|
||||||
|
#
|
||||||
|
# Toolchain
|
||||||
|
#
|
||||||
|
|
||||||
# C compiler and features
|
# C compiler and features
|
||||||
AC_LANG(C)
|
AC_LANG(C)
|
||||||
AC_PROG_CC
|
AC_PROG_CC
|
||||||
|
@ -23,21 +28,18 @@ LT_INIT()
|
||||||
# other programs
|
# other programs
|
||||||
AC_PROG_INSTALL
|
AC_PROG_INSTALL
|
||||||
|
|
||||||
# OpenSSL versions of the unit tests for comparison
|
############################################################################
|
||||||
AC_ARG_WITH([openssl],
|
#
|
||||||
AC_HELP_STRING([--with-openssl],
|
# Headers and functions
|
||||||
[build unit tests with OpenSSL support]),
|
#
|
||||||
[],
|
|
||||||
[with_openssl=no])
|
|
||||||
AM_CONDITIONAL([WITH_OPENSSL], [test x"$with_openssl" = x"yes"])
|
|
||||||
|
|
||||||
# RSAREF versions of the unit tests for comparison
|
AC_CHECK_HEADERS([endian.h sys/endian.h])
|
||||||
AC_ARG_WITH([rsaref],
|
AC_CHECK_FUNCS([strlcat strlcmp strlcpy])
|
||||||
AC_HELP_STRING([--with-rsaref],
|
|
||||||
[build unit tests with RSAREF support]),
|
############################################################################
|
||||||
[],
|
#
|
||||||
[with_rsaref=no])
|
# Build options
|
||||||
AM_CONDITIONAL([WITH_RSAREF], [test x"$with_rsaref" = x"yes"])
|
#
|
||||||
|
|
||||||
# Documentation
|
# Documentation
|
||||||
AC_ARG_WITH([doc],
|
AC_ARG_WITH([doc],
|
||||||
|
@ -71,6 +73,27 @@ AC_ARG_WITH([oath],
|
||||||
[with_oath=yes])
|
[with_oath=yes])
|
||||||
AM_CONDITIONAL([WITH_OATH], [test x"$with_oath" = x"yes"])
|
AM_CONDITIONAL([WITH_OATH], [test x"$with_oath" = x"yes"])
|
||||||
|
|
||||||
|
############################################################################
|
||||||
|
#
|
||||||
|
# Debugging
|
||||||
|
#
|
||||||
|
|
||||||
|
# OpenSSL versions of the unit tests for comparison
|
||||||
|
AC_ARG_WITH([openssl],
|
||||||
|
AC_HELP_STRING([--with-openssl],
|
||||||
|
[build unit tests with OpenSSL support]),
|
||||||
|
[],
|
||||||
|
[with_openssl=no])
|
||||||
|
AM_CONDITIONAL([WITH_OPENSSL], [test x"$with_openssl" = x"yes"])
|
||||||
|
|
||||||
|
# RSAREF versions of the unit tests for comparison
|
||||||
|
AC_ARG_WITH([rsaref],
|
||||||
|
AC_HELP_STRING([--with-rsaref],
|
||||||
|
[build unit tests with RSAREF support]),
|
||||||
|
[],
|
||||||
|
[with_rsaref=no])
|
||||||
|
AM_CONDITIONAL([WITH_RSAREF], [test x"$with_rsaref" = x"yes"])
|
||||||
|
|
||||||
# Developer-friendly compiler flags
|
# Developer-friendly compiler flags
|
||||||
AC_ARG_ENABLE([developer-warnings],
|
AC_ARG_ENABLE([developer-warnings],
|
||||||
AS_HELP_STRING([--enable-developer-warnings],
|
AS_HELP_STRING([--enable-developer-warnings],
|
||||||
|
@ -85,9 +108,10 @@ AC_ARG_ENABLE([werror],
|
||||||
[use -Werror (default is NO)]),
|
[use -Werror (default is NO)]),
|
||||||
[CFLAGS="${CFLAGS} -Werror"])
|
[CFLAGS="${CFLAGS} -Werror"])
|
||||||
|
|
||||||
AC_CHECK_HEADERS([endian.h sys/endian.h])
|
############################################################################
|
||||||
|
#
|
||||||
AC_CHECK_FUNCS([strlcat strlcmp strlcpy])
|
# Output
|
||||||
|
#
|
||||||
|
|
||||||
AC_CONFIG_FILES([
|
AC_CONFIG_FILES([
|
||||||
Makefile
|
Makefile
|
||||||
|
|
Loading…
Reference in a new issue