source: configure.ac@ 305e7e

Action_Thermostats Add_AtomRandomPerturbation Add_FitFragmentPartialChargesAction Add_RotateAroundBondAction Add_SelectAtomByNameAction Added_ParseSaveFragmentResults AddingActions_SaveParseParticleParameters Adding_Graph_to_ChangeBondActions Adding_MD_integration_tests Adding_ParticleName_to_Atom Adding_StructOpt_integration_tests AtomFragments Automaking_mpqc_open AutomationFragmentation_failures Candidate_v1.5.4 Candidate_v1.6.0 Candidate_v1.6.1 ChangeBugEmailaddress ChangingTestPorts ChemicalSpaceEvaluator CombiningParticlePotentialParsing Combining_Subpackages Debian_Package_split Debian_package_split_molecuildergui_only Disabling_MemDebug Docu_Python_wait EmpiricalPotential_contain_HomologyGraph EmpiricalPotential_contain_HomologyGraph_documentation Enable_parallel_make_install Enhance_userguide Enhanced_StructuralOptimization Enhanced_StructuralOptimization_continued Example_ManyWaysToTranslateAtom Exclude_Hydrogens_annealWithBondGraph FitPartialCharges_GlobalError Fix_BoundInBox_CenterInBox_MoleculeActions Fix_ChargeSampling_PBC Fix_ChronosMutex Fix_FitPartialCharges Fix_FitPotential_needs_atomicnumbers Fix_ForceAnnealing Fix_IndependentFragmentGrids Fix_ParseParticles Fix_ParseParticles_split_forward_backward_Actions Fix_PopActions Fix_QtFragmentList_sorted_selection Fix_Restrictedkeyset_FragmentMolecule Fix_StatusMsg Fix_StepWorldTime_single_argument Fix_Verbose_Codepatterns Fix_fitting_potentials Fixes ForceAnnealing_goodresults ForceAnnealing_oldresults ForceAnnealing_tocheck ForceAnnealing_with_BondGraph ForceAnnealing_with_BondGraph_continued ForceAnnealing_with_BondGraph_continued_betteresults ForceAnnealing_with_BondGraph_contraction-expansion FragmentAction_writes_AtomFragments FragmentMolecule_checks_bonddegrees GeometryObjects Gui_Fixes Gui_displays_atomic_force_velocity ImplicitCharges IndependentFragmentGrids IndependentFragmentGrids_IndividualZeroInstances IndependentFragmentGrids_IntegrationTest IndependentFragmentGrids_Sole_NN_Calculation JobMarket_RobustOnKillsSegFaults JobMarket_StableWorkerPool JobMarket_unresolvable_hostname_fix MoreRobust_FragmentAutomation ODR_violation_mpqc_open PartialCharges_OrthogonalSummation PdbParser_setsAtomName PythonUI_with_named_parameters QtGui_reactivate_TimeChanged_changes Recreated_GuiChecks Rewrite_FitPartialCharges RotateToPrincipalAxisSystem_UndoRedo SaturateAtoms_findBestMatching SaturateAtoms_singleDegree StoppableMakroAction Subpackage_CodePatterns Subpackage_JobMarket Subpackage_LinearAlgebra Subpackage_levmar Subpackage_mpqc_open Subpackage_vmg Switchable_LogView ThirdParty_MPQC_rebuilt_buildsystem TrajectoryDependenant_MaxOrder TremoloParser_IncreasedPrecision TremoloParser_MultipleTimesteps TremoloParser_setsAtomName Ubuntu_1604_changes stable
Last change on this file since 305e7e was 455573, checked in by Frederik Heber <heber@…>, 14 years ago

Large Commit: SUBDIRS in src/Makefile.am replaced by include.

  • This should let make decide on the dependencies automatically.
  • We had to change each Makefile.am due to different relative location now.
  • FIX: convenience libs were not created due to lib_LT... instead of noinst_LT... (thanks, Ralf!)
  • FIX: convenience libs cannot pass on dependencies on real libs, these (seemingly: libLinearAlgebra) have to be re-specified.
  • FIX: RANDOMSOURCE/HEADER were still present to include in libMolecuilder although RandomNumbers have been outsourced for some time already.
  • this should make it a lot easier for unit tests to get away with the massive dependencies because we may now include single libs and can construct stubs in replacement.
  • Property mode set to 100644
File size: 7.5 KB
Line 
1# -*- Autoconf -*-
2# Process this file with autoconf to produce a configure script.
3
4AC_PREREQ(2.59)
5AC_INIT(MoleCuilder, 1.1.1, [heber@ins.uni-bonn.de], [molecuilder], [http://trac.ins.uni-bonn.de/projects/molecuilder/])
6AC_CONFIG_AUX_DIR([build-aux])
7AC_CONFIG_SRCDIR([src/builder.cpp])
8AC_CONFIG_HEADER([config.h libmolecuilder_config.h])
9AC_CONFIG_MACRO_DIR([m4])
10AC_CONFIG_SUBDIRS([LinearAlgebra])
11
12AM_INIT_AUTOMAKE([dist-bzip2 1.11 parallel-tests color-tests])
13
14# Checks for programs.
15AM_PATH_CPPUNIT(1.9.6)
16AC_PROG_CXX
17AC_PROG_CC
18AC_PROG_INSTALL
19AC_CHECK_PROG([LATEX],[latex],[latex],[:])
20AC_CHECK_PROG([BIBTEX],[bibtex],[bibtex],[:])
21AC_CHECK_PROG([DVIPS],[dvips],[dvips],[:])
22AC_CHECK_PROG([PDFLATEX],[pdflatex],[pdflatex],[:])
23AC_CHECK_PROG([XMLTO],[xmlto],[xmlto],[:])
24AM_MISSING_PROG([DOXYGEN], [doxygen])
25
26LT_INIT([static])
27
28# Define these substitions here to keep all version information in one place.
29# For information on how to properly maintain the library version information,
30# refer to the libtool manual, section "Updating library version information":
31# http://www.gnu.org/software/libtool/manual/html_node/Updating-version-info.html
32AC_SUBST([MOLECUILDER_SO_VERSION], [3:0:0])
33AC_SUBST([MOLECUILDER_API_VERSION], [1.1.1])
34
35# for libLinearAlgebra
36AC_SUBST([LINEARALGEBRA_SO_VERSION], [1:0:0])
37
38dnl this macro is used to get the arguments supplied
39dnl to the configure script (./configure --enable-debug)
40dnl Check if we have enable debug support.
41AC_MSG_CHECKING(whether to enable debugging)
42default="no"
43have_debug="no"
44AC_ARG_ENABLE(debug, [ --enable-debug=[no/yes/full] turn on debugging
45 [default=$default]],, enable_debug=$default)
46if test "x$enable_debug" = "xyes"; then
47 AC_DEFINE(MEMDEBUG,1, ["Use memory debugger."])
48 AC_DEFINE(HAVE_DEBUG,1, ["Use debug setting to compile code."])
49 have_debug="yes"
50elif test "x$enable_debug" = "xfull"; then
51 AC_DEFINE(MEMDEBUG,1, ["Use memory debugger."])
52 AC_DEFINE(LOG_OBSERVER,1, ["Use observer log."])
53 AC_DEFINE(HAVE_DEBUG,2, ["Use debug setting to compile code."])
54 have_debug="full"
55else
56 AC_DEFINE(NDEBUG,1, ["Don't compile in debugging code."])
57 AC_DEFINE(HAVE_DEBUG,0, ["Use debug setting to compile code."])
58 have_debug="no"
59fi
60AC_MSG_RESULT($have_debug)
61AC_SUBST(HAVE_DEBUG)
62
63dnl this macro is used to get the arguments supplied
64dnl to the configure script (./configure --enable-debug)
65dnl Check if we have enable debug support.
66AC_MSG_CHECKING([whether to enable internal caching of values (speedup!)])
67default="yes"
68AC_ARG_ENABLE(cache, [ --enable-cache=[no/yes] turn on caching
69 [default=$default]],, enable_cache=$default)
70if test "x$enable_cache" = "xno"; then
71 AC_DEFINE(NO_CACHING,1, ["Don't use caching code."])
72 AC_DEFINE(HAVE_CACHE,0, ["cache variables to speed up the code."])
73 AC_MSG_RESULT(no)
74else
75 AC_DEFINE(HAVE_CACHE,1, ["cache variables to speed up the code."])
76 AC_MSG_RESULT(yes)
77fi
78AC_SUBST(HAVE_CACHE)
79
80#AC_MSG_CHECKING(whether to enable profiling)
81#default="no"
82#AC_ARG_ENABLE(debug, [ --enable-profile=[no/yes] turn on profiling
83# [default=$default]],, enable_profile=$default)
84#if test "x$enable_profile" = "xyes"; then
85# CXXFLAGS="$CXXFLAGS -g -DDEBUG -pg"
86# DEBUG=-pg;
87# AC_MSG_RESULT(yes)
88#else
89# AC_MSG_RESULT(no)
90#fi
91
92#AC_MSG_CHECKING(whether to enable serialization)
93#default="no"
94#AC_ARG_ENABLE(debug, [ --enable-serialization=[no/yes] turn on serialization support
95# [default=$default]],, enable_serialization=$default)
96#if test "x$enable_serialization" = "xyes"; then
97# CXXFLAGS="$CXXFLAGS -DSERIALIZATION"
98# serialization=yes;
99# AC_MSG_RESULT(yes)
100#else
101# serialization=no;
102# AC_MSG_RESULT(no)
103#fi
104
105# Checks for libraries.
106AC_CHECK_LIB(m, sqrt, , AC_MSG_ERROR([compatible libc math library not found]))
107
108# Boost libraries
109AX_BOOST_BASE([1.40])
110AX_BOOST_PROGRAM_OPTIONS
111AX_BOOST_SYSTEM
112AX_BOOST_FILESYSTEM
113AX_BOOST_THREAD
114#AX_BOOST_SERIALIZATION
115
116#QT4 libraries
117gw_CHECK_QT4
118AX_CHECK_GLU
119#AC_MSG_NOTICE(["GLU_CFLAGS: $GLU_CFLAGS, GLU_CXXFLAGS: $GLU_CXXFLAGS, GLU_LDFLAGS: $GLU_LDFLAGS, GLU_LIBS: $GLU_LIBS"])
120
121# CodePatterns library (needs operator<<(.., range<>) )
122AM_PATH_CODEPATTERNS([1.0.13], $have_debug,,[AC_MSG_ERROR([Missing CodePatterns library, please specify PKG_CONFIG_PATH or use --with-codepatterns...])])
123
124# Checks for header files.
125AC_HEADER_STDC
126AC_CHECK_HEADERS([sys/time.h])
127AC_HEADER_STDBOOL
128
129AC_FUNC_MALLOC
130AC_FUNC_REALLOC
131AC_CHECK_FUNCS([floor pow sqrt strchr])
132
133# Checks for typedefs, structures, and compiler characteristics.
134AC_C_CONST
135AC_C_INLINE
136AC_C_RESTRICT
137AC_TYPE_SIZE_T
138
139# Checks for library functions.
140# check for GNU Scientific Library
141AC_CHECK_HEADERS([gsl/gsl_blas.h])
142AC_SEARCH_LIBS(dnrm2, goto blas cblas gslblas gslcblas)
143AC_CHECK_LIB(gsl, main, [],
144 [AC_SEARCH_LIBS(cblas_dnrm2, blas cblas gslblas gslcblas)])
145AC_CHECK_LIB(gsl, gsl_blas_dnrm2, , [AC_MSG_ERROR(["No working BLAS found for GSL, stopping."])])
146
147# add replacement/saturation hydrogen or not
148AC_ARG_ENABLE([hydrogen],AS_HELP_STRING([--enable-hydrogen],[Adding saturation hydrogen (default is yes)]),
149 [enable_hydrogen=$enableval], [enable_hydrogen=yes])
150if test x"$enable_hydrogen" = xyes; then
151 AC_DEFINE(ADDHYDROGEN,1, ["Adding saturation hydrogen"])
152 AC_SUBST(ADDHYDROGEN)
153fi
154
155# use CppUnit TestRunner or not
156AC_ARG_ENABLE([ecut],AS_HELP_STRING([--enable-ecut],[Use ECut TestRunnerClient (default is no)]),
157 [enable_ecut=$enableval], [enable_ecut=no])
158if test x"$enable_ecut" = xyes; then
159 AC_DEFINE(HAVE_ECUT,1, ["Use ECut TestRunnerClient instead of our own."])
160 AC_SUBST(HAVE_ECUT)
161fi
162
163# with valgrinding testsuite or not
164AC_ARG_WITH([valgrind],AS_HELP_STRING([--with-valgrind],[Use Valgrind on the testsuite (default is no)]),
165 [with_valgrind=$withval], [with_valgrind=no])
166if test x"$with_valgrind" = xyes; then
167 AC_CHECK_HEADER([valgrind/valgrind.h],
168 [
169 # check header
170 AC_DEFINE(HAVE_VALGRIND_TESTSUITE,1, ["Use Valgrind to check the testsuite."])
171 # check path
172 AC_PATH_PROG(VALGRIND, [valgrind], [/bin/false])
173 # set variables
174 AC_SUBST(HAVE_VALGRIND_TESTSUITE)
175 AC_SUBST(VALGRIND)
176 ],
177 [
178 AC_MSG_ERROR(["Valgrind support requested but headers not available."])
179 ]
180 )
181fi
182
183# Check for "extern inline", using a modified version
184# of the test for AC_C_INLINE from acspecific.mt
185AC_CACHE_CHECK([for extern inline], ac_cv_c_extern_inline,
186[ac_cv_c_extern_inline=no
187AC_TRY_COMPILE([extern $ac_cv_c_inline double foo(double x);
188extern $ac_cv_c_inline double foo(double x) { return x+1.0; };
189double foo (double x) { return x + 1.0; };],
190[ foo(1.0) ],
191[ac_cv_c_extern_inline="yes"])
192])
193
194if test "$ac_cv_c_inline" != no ; then
195 AC_DEFINE(HAVE_INLINE,1, ["May use inline routines"])
196 AC_SUBST(HAVE_INLINE)
197fi
198
199#AC_MSG_NOTICE(["CFLAGS: $CFLAGS, CXXFLAGS: $CXXFLAGS, LDFLAGS: $LDFLAGS, CC: $CC, CXX:, $CXX, MPICC: $MPICC, MPILIBS: $MPILIBS, LIBS: $LIBS"])
200
201# test suite
202AC_CONFIG_TESTDIR(tests/regression)
203AC_CONFIG_FILES([
204 tests/Makefile
205 tests/regression/atlocal
206 tests/regression/Makefile])
207AC_CONFIG_FILES([tests/regression/molecuilder], [chmod +x tests/regression/molecuilder])
208AC_CONFIG_FILES([
209 tests/CodeChecks/atlocal
210 tests/CodeChecks/Makefile])
211AC_CONFIG_FILES([
212 tests/Fragmentations/Makefile
213 tests/Fragmentations/defs])
214AC_CONFIG_FILES([
215 tests/Tesselations/Makefile
216 tests/Tesselations/defs])
217AC_CONFIG_FILES([
218 doc/molecuilder.xml])
219AC_CONFIG_FILES([
220 MoleCuilder.pc:MoleCuilder.pc.in])
221AC_CONFIG_FILES([
222 Makefile
223 doc/Makefile
224 src/Makefile
225])
226AC_CONFIG_FILES([
227 src/unittests/Makefile
228])
229AC_OUTPUT
Note: See TracBrowser for help on using the repository browser.