forked from DEploid-dev/DEploid
-
Notifications
You must be signed in to change notification settings - Fork 2
/
configure.ac
67 lines (50 loc) · 2.17 KB
/
configure.ac
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
AC_INIT([dEploid], esyscmd([sh -c "cat VERSION | tr -d '\n'"]),[https://github.com/mcveanlab/DEploid/issues])
#AM_INIT_AUTOMAKE([subdir-objects -Wall foreign])
AM_INIT_AUTOMAKE([1.9 tar-ustar subdir-objects -Wall foreign])
# Use -O3 as default optimization level
: ${CXXFLAGS="-O3"}
# Suppress output at compilation
m4_ifndef([AM_SILENT_RULES], [m4_define([AM_SILENT_RULES],[])])
AM_SILENT_RULES([yes])
# Load macros in 'm4'-dir
#AC_CONFIG_MACRO_DIR([m4])
AC_PROG_INSTALL
AC_PREREQ
AC_CANONICAL_HOST
# Checks for programs.
AC_PROG_RANLIB
# Check for C++11
#AX_CXX_COMPILE_STDCXX_11(,mandatory)
# Checks for libraries
AC_CHECK_LIB(cppunit,TestCase,[])
# Checks for header files.
AC_HEADER_STDC
AC_LANG(C++)
AC_CHECK_HEADERS([zlib.h])
# Checks for typedefs, structures, and compiler characteristics.
AC_C_CONST
AC_C_INLINE
AC_TYPE_SIZE_T
## Enable Link-time optimization if supported (gcc only)
#if test x$CXX = xg++; then
#AX_CHECK_COMPILE_FLAG([-flto], [OPT_CXXFLAGS="$OPT_CXXFLAGS -flto"], [], [-Werror])
#AC_SUBST(OPT_CXXFLAGS)
#fi
# Enable Warnings
AX_CXXFLAGS_WARN_ALL
#AX_CHECK_COMPILE_FLAG([-Wextra], [OPT_CXXFLAGS="$OPT_CXXFLAGS -Wextra"], [], [-Werror])
## AX_CHECK_COMPILE_FLAG([-Wshadow], [OPT_CXXFLAGS="$OPT_CXXFLAGS -Wshadow"], [], [-Werror])
#AX_CHECK_COMPILE_FLAG([-Wnon-virtual-dtor], [OPT_CXXFLAGS="$OPT_CXXFLAGS -Wnon-virtual-dtor"], [], [-Werror])
##AX_CHECK_COMPILE_FLAG([-Wold-style-cast], [OPT_CXXFLAGS="$OPT_CXXFLAGS -Wold-style-cast"], [], [-Werror])
#AX_CHECK_COMPILE_FLAG([-Wcast-align], [OPT_CXXFLAGS="$OPT_CXXFLAGS -Wcast-align"], [], [-Werror])
#AX_CHECK_COMPILE_FLAG([-Wunused], [OPT_CXXFLAGS="$OPT_CXXFLAGS -Wunused"], [], [-Werror])
#AX_CHECK_COMPILE_FLAG([-Woverloaded-virtual], [OPT_CXXFLAGS="$OPT_CXXFLAGS -Woverloaded-virtual"], [], [-Werror])
#AX_CHECK_COMPILE_FLAG([-pedantic], [OPT_CXXFLAGS="$OPT_CXXFLAGS -pedantic"], [], [-Werror])
AC_CHECK_PROGS([DOXYGEN], [doxygen])
if test -z "$DOXYGEN";
then AC_MSG_WARN([Doxygen not found - continuing without Doxygen support])
fi
AM_CONDITIONAL([HAVE_DOXYGEN],
[test -n "$DOXYGEN"])AM_COND_IF([HAVE_DOXYGEN], [AC_CONFIG_FILES([docs/doxygen/Doxyfile])])
AC_CONFIG_FILES([Makefile docs/doxygen/Makefile])
AC_OUTPUT