source: trunk/configure.ac @ 2

Last change on this file since 2 was 2, checked in by Jari Häkkinen, 17 years ago

Added initial support for automake/autoconf.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 1.3 KB
Line 
1# $Id: configure.ac 2 2003-02-19 14:27:27Z jari $
2
3AC_INIT(src)
4
5AM_CONFIG_HEADER(config.h)
6
7AM_INIT_AUTOMAKE(c++_tools,0.1,jari@thep.lu.se)
8
9AC_PREFIX_DEFAULT(/usr/local)
10
11# Checks for programs.
12AC_PROG_CXX
13AC_PROG_INSTALL
14
15## BEGIN COMMON DENOMINATOR of DISTRIBUTION COMPILATION CFLAG
16##
17## variables used to pass to CFLAG:
18## gcc_cflags       standard optimization flags
19## gcc_cflags_cpu   cpu detection
20## gcc_cflags_arch  architecture detection
21
22## Tests if --enable-debug, --enable-warning or --enable-purify are given
23AC_ARG_ENABLE(debug,
24[  --enable-debug          debug (-g option on compiler)])
25if test "${enable_debug}" = "yes" ; then
26  CFLAGS="-g"
27fi
28AC_ARG_ENABLE(warnings,
29[  --enable-warnings          warnings (-Wall option on compiler)])
30if test "${enable_warnings}" = "yes" ; then
31  CFLAGS="$CFLAGS -Wall"
32fi
33AC_MSG_CHECKING(for purify)
34if(purify -version) < /dev/null > /dev/null 2>&1; then
35   AC_MSG_RESULT(yes)
36   AC_ARG_ENABLE(purify,
37   [  --enable-purify          purify ])
38   if test "${enable_purify}" = "yes" ; then
39     CFLAGS="-g"
40   fi         
41else
42   AC_MSG_RESULT(no)
43fi
44
45CXXFLAGS="-O3 -Wall"
46AC_SUBST(CXXFLAGS)
47
48# Misc libs, these should of course be set automatically
49BLAS_LIB="-lcblas -latlas"
50AC_SUBST(BLAS_LIB)
51GSL_LIB="-lgsl"
52AC_SUBST(GSL_LIB)
53MATH_LIB="-lm"
54AC_SUBST(MATH_LIB)
55
56# BASE specific settings
57
58AC_OUTPUT([
59  Makefile
60  src/Makefile
61    ])
Note: See TracBrowser for help on using the repository browser.