source: acro-utilib/trunk/configure.ac @ 7018

Revision 7018, 42.8 KB checked in by wehart, 4 years ago (diff)

Update from bootstrap

  • Property svn:eol-style set to LF
  • Property svn:keywords set to Author Date Id Revision
Line 
1#
2# CAUTION!
3#
4# This file should only be edited in the bootstrap/packages directory!
5#
6
7#
8# TODO: Setup ACRO_BUILD_DATE macro (e.g. 20050221)
9#
10
11
12###############################################################
13# boilerplate
14
15AC_PREREQ(2.59)
16AC_INIT([acro], [VOTD], [acro-help@software.sandia.gov])
17
18rm -f packages/dummy/Makefile.in
19if test -d packages ; then : ; else mkdir packages ; fi
20if test -d packages/dummy ; then : ; else mkdir packages/dummy ; fi
21touch packages/dummy/Makefile.in
22
23###############################################################
24# A file or directory that should be found here, so we know
25# we are in the right place.
26
27AC_CONFIG_SRCDIR([config/MakeMacros.mk])
28
29###############################################################
30# Location of our m4 macros.  These test for the features
31# we are interested.  This doesn't actually work.  Documentation
32# says it will in the future.  We need to define
33# ACLOCAL_AMFLAGS in Makefile.am instead.  autoconf looks there
34# for some reason.
35
36AC_CONFIG_MACRO_DIR([config])
37AC_CONFIG_AUX_DIR([config])
38
39###############################################################
40# Create this header file which will help configure our Makefiles
41# and source files at build time.
42
43AC_CONFIG_HEADERS([include/config.h])
44AX_PREFIX_CONFIG_H([include/acro_config.h])
45AH_BOTTOM(
46#ifndef ACRO_HAVE_EXPLICIT
47#ifndef explicit
48#define explicit
49#endif
50#endif
51#ifdef ACRO_USING_UTILIB
52#include <utilib_config.h>
53#endif
54)
55
56
57
58
59###############################################################
60#
61# Acro and cache files and MPI - issues
62#
63#    Acro has many options which are not compatible with cache
64#    files.  These are options like --with-debugging which change
65#    standard environment variables like CXXFLAGS.
66#
67#    Also, Acro has subpackages which should all be built with the
68#    same compile environment.  In addition, Acro has subpackages
69#    that must know whether or not they are being built with MPI.
70#    The --enable-mpi option must appear on the configure command
71#    line for these subpackages if MPI compilers are being used.
72#    In addition, some subpackages are AC_CONFIG_SUBDIR'd and some
73#    can not be, so we configure them ourselves from a Makefile.
74#
75#    These are the required behaviors:
76#
77#    If we are not using a cache file (use_ac_cv_env=no):
78#
79#      Run through all our build configure options, and assign
80#      values to the standard build environment variables.
81#
82#      Export the standard build environment variables so that
83#      AC_CONFIG_SUBDIR'd packages can find them.
84#
85#      Write the standard build environment variables to a Makefile
86#      variable (ENV_ARGS) so we can include them when we configure
87#      subpackages from a Makefile (mtl, coin-cbc and trilinos)
88#
89#    If we are getting our build environment from a cache file
90#    (use_ac_cv_env=yes and ac_cv_env_empty=no):
91#
92#      Skip all of our configure options which alter the standard
93#      build environment variables.
94#
95#      If we detect that MPI is being used (either --enable-mpi
96#      was specified, or we had previously saved mpi command line
97#      arguments in a cache file) then set the HAVE_MPI macro and
98#      the BUILD_MPI Makefile variable.
99#
100#      Add --enable-mpi to the configure command line of subpackages
101#      that we configure that need it.  (trilinos only at present)
102#
103#      Pass along the --cache-file= or -C configure command line
104#      option to subpackages that we configure.  (mtl, coin-cbc and trilinos)
105#
106#      Add --enable-mpi to our configure command line if it is not
107#      there (so AC_CONFIG_SUBDIR'd packages that need it will know
108#      they are using MPI) (for appspack and utilib)
109#
110#    If a cache file is specified, but doesn't exist yet
111#    (use_ac_cv_env=yes and ac_cv_env_empty=yes):
112#
113#      Do everything we do if no cache file is specified.
114#
115#      Pass along the --cache-file= or -C configure command line
116#      option to subpackages that we configure.  (mtl, coin-cbc and trilinos)
117#     
118#      Set the standard cache file variables (ac_cv_env*) to the
119#      build environment variables, and set special MPI variables
120#      (acro_cv_with_mpi_*) in the cache file.
121#
122#  Subpackages that we configure: mtl, coin-cbc and trilinos
123#  Subpackages that require --enable-mpi in order to know that
124#  they are using MPI: utilib, appspack and trilinos
125#
126
127# Are we using a cache file, and if so does the cache file already
128# exist, or is it empty and we are initializing it?
129
130use_ac_cv_env=no
131ac_cv_env_empty=yes
132CACHE_FILE_ARG=""
133
134if test "$cache_file" != "/dev/null" ; then
135  use_ac_cv_env=yes
136  CACHE_FILE_ARG="--cache-file=$PWD/$cache_file"
137  if test X$ac_cv_env_CCASFLAGS_set = Xset ; then
138    ac_cv_env_empty=no
139  fi
140fi
141
142#For mtl, coin-cbc and trilinos
143AC_SUBST([CACHE_FILE_ARG])
144
145if test "$ac_cv_env_empty" = "no" ; then
146  AC_MSG_NOTICE([=====================================================================])
147  AC_MSG_NOTICE([Compile environment obtained from standard GNU environment variables.])
148  AC_MSG_NOTICE([Acro's special options for the compile environment])
149  AC_MSG_NOTICE([(for example "--with-debugging") will be ignored.])
150  AC_MSG_NOTICE([=====================================================================])
151fi
152
153###############################################################
154# Setup platform information and initialize automake
155
156AC_CANONICAL_BUILD
157AC_CANONICAL_HOST
158AC_CANONICAL_TARGET
159AM_INIT_AUTOMAKE([foreign -Wall -Werror filename-length-max=256 tar-ustar])
160#AM_INIT_AUTOMAKE([1.9 foreign -Wall -Werror tar-ustar])
161
162
163###############################################################
164# Platform ID
165
166ACRO_PLATFORM
167
168
169###############################################################
170# Configure command line options
171# Default compilation flags: -O2 plus maybe some arch/compiler
172# special flags
173
174ACRO_BOOST_DEPENDENCE([available])
175
176# --with-compiler=mingw
177ACRO_COMPILER_OPTION
178
179if test $ac_cv_env_empty = yes ; then
180  # Various special options to override compiler flags.
181  # Only legal if we're not using cache file settings.
182  ACRO_COMPILER_OPTIONS
183fi
184
185# Control whether UTILIB DEBUGPR output is used
186ACRO_DEBUGPR_OPTION
187# Control whether UTILIB CommonIO mapping is used
188ACRO_COMMONIO_OPTION
189# Control whether UTILIB memory debugging utilities are used
190ACRO_MEMDEBUG_OPTION
191# Control whether UTILIB checksum is used
192ACRO_CHECKSUM_OPTION
193# Control whether executables are built
194ACRO_EXECUTABLES_OPTION
195# Control whether test codes are built
196ACRO_TEST_OPTION
197# Control whether code validation is used
198ACRO_VALIDATING_OPTION
199
200###############################################################
201
202# User can set --enable-mpi.  It will be set to "yes" automatically
203# if they specify any of the --with-mpi-* options.
204#
205# Also, DAKOTA sets --enable-mpi when it builds Acro with a cache
206# file, so we know whether or not we are building with MPI
207#
208AC_ARG_ENABLE(mpi,
209AS_HELP_STRING([--enable-mpi],[Enable MPI support]),
210[ENABLE_MPI=$enableval],
211[ENABLE_MPI=no]
212)
213
214if test $ac_cv_env_empty = yes ; then
215  # Various options to setup the use of MPI.
216  # Only legal if we're not using cache file settings.
217  # Creates cache variables for --with-mpi-* options that will go
218  # to cache file if a cache file is created.
219  ACRO_MPI_OPTIONS
220fi
221
222if test "X$ENABLE_MPI" = "Xyes" ; then
223  using_mpi=yes
224elif test "X$acro_cv_with_mpi_set" = "Xyes" ; then
225  using_mpi=yes
226else
227  using_mpi=no
228fi
229
230#For utilib and appspack (actually utilib is smart enough to look
231# in the cache file for acro_cv_with_mpi_* variables).
232if test "$using_mpi" = "yes" && test "X$ENABLE_MPI" != "Xyes" ; then
233  new_configure_args="$ac_configure_args --enable-mpi"
234  ac_configure_args="$new_configure_args"
235fi
236
237#
238# Hard-coding UTILIB configuration
239#
240pwd=`pwd`
241if test -d tpl/cxxtest; then
242   new_configure_args="$ac_configure_args --with-cxxtest=$pwd/tpl/cxxtest"
243   ac_configure_args="$new_configure_args"
244fi
245
246###############################################################
247# Checks for programs
248
249#c_compilers=notset
250#cpp_compilers=notset
251#f77_compilers=notset
252#fc_compilers=notset
253
254if test $ac_cv_env_empty = yes ; then
255
256  temp_fflags=${FFLAGS}
257  temp_fcflags=${FCFLAGS}
258  temp_cflags=${CFLAGS}
259  temp_cxxflags=${CXXFLAGS}
260 
261  if test "X${MPI_CC}" = "Xnone" ; then
262    if test X${USERDEF_CC} = Xnotset ; then
263#      if test X$with_vendor_compilers = Xyes ; then
264#        c_compilers="icc pgcc xlc cc gcc"
265#      else
266#        c_compilers="cc gcc"
267#      fi
268       c_compilers=notset
269    else
270      CC="${USERDEF_CC}"
271    fi
272  else
273    CC="${MPI_CC}"
274  fi
275 
276  if test "X${MPI_CXX}" = "Xnone" ; then
277    if test X${USERDEF_CXX} = Xnotset ; then
278      if test X${build_os} = Xcygwin ; then
279        cpp_compilers="g++"
280      else
281#        if test X$with_vendor_compilers = Xyes ; then
282#          cpp_compilers="icpc pgCC xlC CC c++ g++"
283#        else
284#          cpp_compilers="c++ g++"
285#        fi
286         cpp_compilers=notset
287      fi
288    else
289      CXX="${USERDEF_CXX}"
290    fi
291  else
292    CXX="${MPI_CXX}"
293  fi
294 
295  if test "X${MPI_F90}" = "Xnone" ; then
296    if test X${USERDEF_F77} = Xnotset ; then
297#      if test X$with_vendor_compilers = Xyes ; then
298#        f77_compilers="ifort pgf77 xlf90 gfortran g77 f77 f90"
299#      else
300#        f77_compilers="gfortran g77 f77 f90 ifort pgf77 xlf90"
301#      fi
302       f77_compilers=notset
303    else
304      F77="${USERDEF_F77}"
305    fi
306  else
307    F77="${MPI_F90}"
308    FC="${MPI_F90}"
309  fi
310
311fi
312
313# Problem: AC_PROG_CC is not the same as AC_PROG_CC([""])
314
315AC_PROG_CC
316AC_PROG_CXX
317AC_PROG_FC
318AC_PROG_F77
319
320if test $ac_cv_env_empty = yes ; then
321  # AC_PROG_* macros overwrote our flags
322  FFLAGS=${temp_fflags}
323  FCFLAGS=${temp_fcflags}
324  CFLAGS=${temp_cflags}
325  CXXFLAGS=${temp_cxxflags}
326
327fi
328
329if test "X${FC}" = "X" && test "X${F77}" = "X"; then
330  ac_cv_have_fortran=no
331  scolib_warn="scolib will be built without blas or lapack, because these require fortran"
332  gnlp_warn="gnlp will be built without npsol, blas, or lapack, because they require fortran"
333  pico_warn="pico will be built without blas or lapack, because they require fortran"
334  #
335  # appspack has 1 fortran source file, but it looks like it is never built
336  #
337else
338  ac_cv_have_fortran=yes
339fi
340
341AC_PROG_LIBTOOL
342AC_PROG_CXXCPP
343AC_PROG_LN_S
344##
345## AM_* are automake macros.  Some automake macros are created as
346## needed by automake because autoconf has not created them.  When
347## an autoconf version is released that defines the following two
348## macros, it is important to convert to using the AC_* versions.
349##
350AM_PROG_AS
351AM_PROG_CC_C_O
352
353AC_CACHE_SAVE
354
355###############################################################
356
357# Ensure they did not say --enable-shared, which is unsupported
358ACRO_NO_SHARED
359
360# # # # # # # # # # # #
361# These two warnings were previously in acro_no_shared.m4, but we
362# get an aclocal error when they are there.  I was unabled to figure
363# out why, so I moved them into configure.ac.  (It was "diversion"
364# related, which has to do with a stack of tasks.  So maybe being
365# in an m4 macro called by configure.ac, the stack spilled over?)
366#
367if test X${ENABLE_SHARED} = Xyes ; then
368    AC_MSG_WARN([[--enable-shared: Only libtoolized projects will build a shared library.]])
369fi
370
371if test X${ENABLE_STATIC} = Xno ; then
372    AC_MSG_WARN([[--disable-static: Know that non-libtoolized projects will only build static libraries in spite of your request.]])
373fi
374# # # # # # # # # # # #
375
376# Request executables that are linked only with static libraries,
377# default is to use shared when available
378
379ACRO_STATIC_EXECUTABLES
380
381# Ensure they did not say --enable-shared, which is unsupported  lafisk
382
383AC_CACHE_SAVE
384
385###############################################################
386# Platform-specific compiler options
387
388# Setup CXX flags
389AC_CXX_COMPILER_VENDOR([CXX_VENDOR])
390
391if test $ac_cv_env_empty = yes ; then
392  AC_CXX_CPPFLAGS_STD_LANG([CXXFLAGS])
393  ACRO_PLATFORM_COMPILER_FLAGS
394fi
395
396AM_CONDITIONAL(HAVE_GNU_COMPILER,false)
397AM_CONDITIONAL(HAVE_PGI_COMPILER,false)
398
399if test X$ac_cv_cxx_compiler_vendor = Xpgi ; then
400  AM_CONDITIONAL(HAVE_PGI_COMPILER,true)
401else
402  if test X$ac_cv_cxx_compiler_vendor = Xgnu ; then
403    AM_CONDITIONAL(HAVE_GNU_COMPILER,true)
404  fi
405fi
406
407AC_CACHE_SAVE
408###############################################################
409# Setup compiler flags
410#    this macro depends on values previously set in
411#       acro_compiler_options
412#       acro_platform_compiler_flags
413
414if test $ac_cv_env_empty = yes ; then
415  ACRO_COMPILER_FLAGS
416fi
417
418###############################################################
419# checks for headers
420
421AC_HEADER_STDC
422
423if test "X$ac_cv_header_stdc" = "Xyes"; then
424  AM_CONDITIONAL(HAVE_ANSI_C_HEADERS, true)
425else
426  AM_CONDITIONAL(HAVE_ANSI_C_HEADERS, false)
427fi
428
429AC_CHECK_HEADERS([values.h strings.h unistd.h])
430
431AC_CACHE_SAVE
432###############################################################
433# Checks for libraries
434
435if test "X${ac_cv_have_fortran}" = "Xyes" ; then
436
437  if test $ac_cv_env_empty = yes ; then
438
439    if test "X${FC}" == "X" ; then
440      # Find F77 link flags, create FLIBS
441      AC_F77_LIBRARY_LDFLAGS
442    else
443      # Find F90  link flags, create FCLIBS
444      AC_FC_LIBRARY_LDFLAGS
445    fi
446
447    # Unfortunately when using GCC compilers, -lgcc_s (a
448    # shared-only library) is always added to the link line.
449    if test X${ENABLE_STATIC_EXECUTABLES} = Xyes; then
450      FLIBS=`echo $FLIBS | sed 's/-lgcc_s//g'`
451      FCLIBS=`echo $FCLIBS | sed 's/-lgcc_s//g'`
452    fi
453  fi
454
455  if test "X${F77}" == "X${FC}" ; then
456    FLIBS=${FCLIBS}
457  fi
458
459  ACX_BLAS(,[AC_MSG_WARN([No BLAS --- either because it is disabled or could not be found])])
460
461  ACX_LAPACK(,[AC_MSG_WARN([No LAPACK --- either because it is disabled or could not be found])])
462
463  # Define F77_FUNC - used for correctly munging Fortran function calls
464  AC_F77_WRAPPERS
465
466  ACX_NPSOLLIB(,[AC_MSG_WARN([No NPSOL --- either because it is disabled or could not be found])])
467
468  ACX_SNOPTLIB
469else
470  BLAS_LIBS=""
471  acx_blas_ok=no
472  AC_SUBST(BLAS_LIBS)
473
474  LAPACK_LIBS=""
475  acx_lapack_ok=no
476  AC_SUBST(LAPACK_LIBS)
477
478  NPSOL_LIBS=""
479  acx_npsol_ok=no
480  AC_SUBST(NPSOL_LIBS)
481
482  SNOPT_LIBS=""
483  acx_snoptlibs_ok=no
484  AC_SUBST(SNOPT_LIBS)
485
486fi
487
488ACRO_CPLEX_OPTIONS
489
490AC_CACHE_SAVE
491###############################################################
492# Validate MPI builds
493
494AM_CONDITIONAL(BUILD_MPI, false)
495
496if test $ac_cv_env_empty = yes ; then
497
498  if test $using_mpi = yes ; then
499    #Try compiling with MPI, and set BUILD_MPI to true on success.
500    ACRO_MPI_TESTS
501  fi
502else
503  if test $using_mpi = yes ; then
504    AM_CONDITIONAL(BUILD_MPI, true)
505    AC_DEFINE(HAVE_MPI,,[define that mpi is being used])
506  fi
507fi
508
509###############################################################
510# checks for typedefs, structures and compiler behavior
511
512AC_TYPE_SIZE_T
513
514if test "X${ac_cv_type_size}" = "Xyes" ; then
515  AM_CONDITIONAL(HAVE_SIZE_T, true)
516else
517  AM_CONDITIONAL(HAVE_SIZE_T, false)
518fi
519
520AC_CACHE_SAVE
521
522###############################################################
523# checks for compiler behavior
524#
525# AC_CXX_* are checks for C++ behavior
526 
527# Defines HAVE_NAMESPACES if we can use them
528#   TODO - find out if the means std namespace only, or any namespace
529#          is it possible we can declare namespaces, but there's no std?
530#          Modifying sources to use HAVE_NAMESPACES is not complete
531AC_CXX_NAMESPACES
532
533if test X${ac_cv_cxx_namespaces} = Xyes ; then
534  AM_CONDITIONAL(HAVE_NAMESPACES, true)
535else
536  AM_CONDITIONAL(HAVE_NAMESPACES, false)
537fi
538 
539# WEH - turned off because these are not portable
540# Defines HAVE_TEMPLATES_AS_TEMPLATE_ARGUMENTS if we can pass a template
541# argument in for a template parameter
542#AC_CXX_TEMPLATES_AS_TEMPLATE_ARGUMENTS
543
544# Defines HAVE_EXCEPTIONS if we can use throw/catch
545AC_CXX_EXCEPTIONS
546 
547# Defines HAVE_STD if we can include ISO C++ headers
548# (iostream, map, iomanip and cmath)
549AC_CXX_HAVE_STD
550
551if test X${ac_cv_cxx_have_std} = Xyes ; then
552  AM_CONDITIONAL(HAVE_ANSI_CPP_HEADERS, true)
553else
554  AM_CONDITIONAL(HAVE_ANSI_CPP_HEADERS, false)
555fi
556 
557# Define HAVE_SSTREAM if we have stringstreams
558AC_CXX_HAVE_SSTREAM
559 
560# Define HAVE_EXPLICIT if we can use the explicit keyword
561AC_CXX_EXPLICIT
562 
563# Define HAVE_MEMBER_TEMPLATES if class member functions can be templated
564AC_CXX_MEMBER_TEMPLATES
565
566AC_CXX_HAVE_SSTREAM
567
568AC_CACHE_SAVE
569
570###############################################################
571# Platform-specific C++ compiler settings
572
573case "$ac_cv_cxx_compiler_vendor" in
574    gnu)
575        AX_CXXFLAGS_GCC_OPTION([-fpermissive])
576    ;;
577    compaq)
578        AX_CXXFLAGS_OSF_OPTION([-tlocal -distinguish_nested_enums])
579    ;;
580    sgi)
581        AX_CXXFLAGS_IRIX_OPTION([-ptused])
582    ;;
583    *)
584    ;;
585esac
586
587AC_CACHE_SAVE
588
589###############################################################
590# checks for functions
591
592AC_CHECK_FUNCS([getrusage],
593  [AM_CONDITIONAL(HAVE_GETRUSAGE, true)],
594  [AM_CONDITIONAL(HAVE_GETRUSAGE, false)])
595
596AC_CHECK_FUNCS([strerror],
597  [AM_CONDITIONAL(HAVE_STRERROR, true)],
598  [AM_CONDITIONAL(HAVE_STRERROR, false)])
599
600# Find DLOPEN (defines DLOPEN_LIBS to contain the libraries needed to link)
601ACX_FUNC_DLOPEN
602
603AC_CACHE_SAVE
604###############################################################
605# more checks
606
607AC_C_BIGENDIAN()
608
609if test X${ac_cv_c_bigendian} = Xyes ; then
610  AM_CONDITIONAL(WORDS_BIGENDIAN, true)
611else
612  AM_CONDITIONAL(WORDS_BIGENDIAN, false)
613fi
614
615AC_CACHE_SAVE
616
617AC_SUBST([abs_top_builddir])
618
619###############################################################
620# We are all done with actions which modify the compilers
621# and build flags. 
622#
623
624# For mtl, coin-cbc and trilinos
625ENV_ARGS="CCAS=\"$CCAS\" CCASFLAGS=\"$CCASFLAGS\" \
626      CXXCPP=\"$CXXCPP\" CC=\"$CC\" CFLAGS=\"$CFLAGS\" \
627      CPP=\"$CPP\" CPPFLAGS=\"$CPPFLAGS\" \
628      CXX=\"$CXX\" CXXFLAGS=\"$CXXFLAGS\" \
629      F77=\"$F77\" FFLAGS=\"$FFLAGS\" FLIBS=\"$FLIBS\" \
630      FC=\"$FC\" FCFLAGS=\"$FCFLAGS\" FCLIBS=\"$FCLIBS\" \
631      LIBS=\"$LIBS\" LDFLAGS=\"$LDFLAGS\""
632
633AC_SUBST([ENV_ARGS])
634
635if test $ac_cv_env_empty = yes ; then
636
637  # For AC_CONFIG_SUBDIR'd packages
638  export CCAS
639  export CCASFLAGS
640  export CXXCPP
641  export CC
642  export CFLAGS
643  export CPP
644  export CPPFLAGS
645  export CXX
646  export CXXFLAGS
647  export F77
648  export FC
649  export FFLAGS
650  export FCFLAGS
651  export LIBS
652  export FLIBS
653  export FCLIBS
654  export LDFLAGS
655
656  AC_MSG_NOTICE([Adding standard GNU compile environment variables to])
657  AC_MSG_NOTICE([the subpackages' configure options.])
658fi
659
660if test $use_ac_cv_env = yes && test $ac_cv_env_empty = yes ; then
661
662#  Create the cache variables for the standard GNU compile
663#  environment variables.  They don't exist because we specified
664#  these with non-standard Acro configure options.
665
666  ac_cv_env_CCASFLAGS_value=$CCASFLAGS
667  ac_cv_env_CCASFLAGS_set=set
668  ac_cv_env_CCAS_value=$CCAS
669  ac_cv_env_CCAS_set=set
670  ac_cv_env_CC_value=$CC
671  ac_cv_env_CC_set=set
672  ac_cv_env_CFLAGS_value=$CFLAGS
673  ac_cv_env_CFLAGS_set=set
674  ac_cv_env_CPPFLAGS_value=$CPPFLAGS
675  ac_cv_env_CPPFLAGS_set=set
676  ac_cv_env_CPP_value=$CPP
677  ac_cv_env_CPP_set=set
678  ac_cv_env_CXXCPP_value=$CXXCPP
679  ac_cv_env_CXXCPP_set=set
680  ac_cv_env_CXXFLAGS_value=$CXXFLAGS
681  ac_cv_env_CXXFLAGS_set=set
682  ac_cv_env_CXX_value=$CXX
683  ac_cv_env_CXX_set=set
684  ac_cv_env_F77_value=$F77
685  ac_cv_env_F77_set=set
686  ac_cv_env_FC_value=$FC
687  ac_cv_env_FC_set=set
688  ac_cv_env_FFLAGS_value=$FFLAGS
689  ac_cv_env_FFLAGS_set=set
690  ac_cv_env_FCFLAGS_value=$FCFLAGS
691  ac_cv_env_FCFLAGS_set=set
692  ac_cv_env_LDFLAGS_value=$LDFLAGS
693  ac_cv_env_LDFLAGS_set=set
694  ac_cv_env_LIBS_value=$LIBS
695  ac_cv_env_LIBS_set=set
696  ac_cv_env_FLIBS_value=$FLIBS
697  ac_cv_env_FLIBS_set=set
698  ac_cv_env_FCLIBS_value=$FCLIBS
699  ac_cv_env_FCLIBS_set=set
700
701  AC_MSG_NOTICE([Adding standard GNU compile environment variables to])
702  AC_MSG_NOTICE([the cache file.])
703fi
704
705if test -d userapps ; then
706   suffix=$(date +%m.%d.%y.%H.%M.%S%p)
707   if test -f userapps/buildFlags.txt ; then
708     mv userapps/buildFlags.txt userapps/buildFlags.$suffix
709   fi
710   
711   echo "## " >> userapps/buildFlags.txt
712   echo "## Generated $suffix by configure" >> userapps/buildFlags.txt
713   echo "## " >> userapps/buildFlags.txt
714   echo "CCASFLAGS=$CCASFLAGS" >> userapps/buildFlags.txt
715   echo "CCAS=$CCAS" >> userapps/buildFlags.txt
716   echo "CC=$CC" >> userapps/buildFlags.txt
717   echo "CFLAGS=$CFLAGS" >> userapps/buildFlags.txt
718   echo "CPPFLAGS=$CPPFLAGS" >> userapps/buildFlags.txt
719   echo "CPP=$CPP" >> userapps/buildFlags.txt
720   echo "CXXCPP=$CXXCPP" >> userapps/buildFlags.txt
721   echo "CXXFLAGS=$CXXFLAGS" >> userapps/buildFlags.txt
722   echo "CXX=$CXX" >> userapps/buildFlags.txt
723   echo "F77=$F77" >> userapps/buildFlags.txt
724   echo "FC=$FC" >> userapps/buildFlags.txt
725   echo "FFLAGS=$FFLAGS" >> userapps/buildFlags.txt
726   echo "LDFLAGS=$LDFLAGS" >> userapps/buildFlags.txt
727   echo "LIBS=$LIBS" >> userapps/buildFlags.txt
728   echo "FLIBS=$FLIBS" >> userapps/buildFlags.txt
729   echo "FCLIBS=$FCLIBS" >> userapps/buildFlags.txt
730fi
731
732###############################################################
733# Platform specific flags for some Acro source files.
734
735ACRO_PLATFORM_CODE_FLAGS
736
737###############################################################
738# Options related to including packages and reconfiguring
739# autoconf'd subpackages.
740
741# Application Test Dirs
742if test -d ${srcdir}/snl-user ; then
743      AC_CONFIG_FILES([snl-user/dummy/Makefile:snl-user/dummy/Makefile.in:packages/dummy/Makefile.in])
744fi
745if test -e ${srcdir}/userapps/Makefile.am ; then
746   AC_CONFIG_FILES([userapps/Makefile:userapps/Makefile.in:packages/dummy/Makefile.in])
747fi
748
749# sacache
750ACRO_ARG_ENABLE_PACKAGE(sacache, SACACHE, sacache,
751       ${srcdir}/packages/sacache/Makefile.am, yes)
752ACRO_ARG_ENABLE_PACKAGE_RECONFIG(sacache, packages/sacache/config.status, yes)
753if test X${ac_cv_reconfigure_sacache} = Xyes ; then
754   if test -d ${srcdir}/packages/sacache ; then
755      AC_CONFIG_SUBDIRS([packages/sacache])
756   fi
757fi
758
759# utilib
760ACRO_ARG_ENABLE_PACKAGE(utilib, UTILIB, utilib,
761       ${srcdir}/packages/utilib/Makefile.am, yes)
762ACRO_ARG_ENABLE_PACKAGE_RECONFIG(utilib, packages/utilib/config.status, yes)
763if test X${ac_cv_reconfigure_utilib} = Xyes ; then
764   if test -d ${srcdir}/packages/utilib ; then
765      AC_CONFIG_SUBDIRS([packages/utilib])
766   fi
767fi
768
769# 3po
770ACRO_ARG_ENABLE_PACKAGE(3po, THREEPO, 3po,
771       ${srcdir}/tpl/3po/cobyla2c/cobyla.c, yes)
772if test X${ac_cv_enable_3po} = Xyes ; then
773   if test -d ${srcdir}/tpl/3po ; then
774      AC_CONFIG_FILES([tpl/3po/Makefile:tpl/3po/Makefile.in:packages/dummy/Makefile.in])
775   fi
776fi
777
778# ampl
779ACRO_ARG_ENABLE_PACKAGE(ampl, AMPL, ampl,
780       ${srcdir}/tpl/ampl/con2val.c, yes)
781if test X${ac_cv_enable_ampl} = Xyes ; then
782   if test -d ${srcdir}/tpl/ampl ; then
783      AC_CONFIG_SUBDIRS([tpl/ampl])
784   fi
785fi
786#if test X${ac_cv_enable_ampl} = Xyes ; then
787   #if test -d ${srcdir}/tpl/ampl ; then
788      #AC_CONFIG_FILES([tpl/ampl/Makefile:tpl/ampl/Makefile.in:packages/dummy/Makefile.in])
789   #fi
790#fi
791
792# appspack
793ACRO_ARG_ENABLE_PACKAGE(appspack, APPSPACK, appspack,
794       ${srcdir}/tpl/appspack/src/APPSPACK_Vector.cpp, yes)
795ACRO_ARG_ENABLE_PACKAGE_RECONFIG(appspack, tpl/appspack/config.status, yes)
796if test X${ac_cv_reconfigure_appspack} = Xyes ; then
797  if test -d ${srcdir}/tpl/appspack ; then
798     AC_CONFIG_SUBDIRS([tpl/appspack])
799  fi
800fi
801
802# coin-bonmin
803ACRO_ARG_ENABLE_PACKAGE(coin_bonmin, COIN_BONMIN, coin-bonmin,
804       ${srcdir}/tpl/coin-bonmin/Makefile.am, yes)
805if test X${ac_cv_enable_coin_bonmin} = Xyes ; then
806   if test -d ${srcdir}/tpl/coin-bonmin ; then
807      AC_CONFIG_FILES([tpl/coin-bonmin/Makefile:tpl/coin-bonmin/Makefile.in:packages/dummy/Makefile.in])
808   fi
809fi
810
811# coin-cbc
812ACRO_ARG_ENABLE_PACKAGE(coin_cbc, COIN_CBC, coin-cbc,
813       ${srcdir}/tpl/coin-cbc/Makefile.am, yes)
814if test X${ac_cv_enable_coin_cbc} = Xyes ; then
815   if test -d ${srcdir}/tpl/coin-cbc ; then
816      AC_CONFIG_FILES([tpl/coin-cbc/Makefile:tpl/coin-cbc/Makefile.in:packages/dummy/Makefile.in])
817   fi
818fi
819
820# coin-ipopt
821ACRO_ARG_ENABLE_PACKAGE(coin_ipopt, COIN_IPOPT, coin-ipopt,
822       ${srcdir}/tpl/coin-ipopt/Makefile.am, no)
823if test X${ac_cv_enable_coin_ipopt} = Xyes ; then
824   if test -d ${srcdir}/tpl/coin-ipopt ; then
825      AC_CONFIG_FILES([tpl/coin-ipopt/Makefile:tpl/coin-ipopt/Makefile.in:packages/dummy/Makefile.in])
826   fi
827fi
828
829# colin
830ACRO_ARG_ENABLE_PACKAGE(colin, COLIN, colin,
831       ${srcdir}/packages/colin/Makefile.am, yes)
832if test X${ac_cv_enable_colin} = Xyes ; then
833   if test -d ${srcdir}/packages/colin ; then
834      ACRO_BOOST_DEPENDENCE([required])
835
836      AC_CONFIG_FILES([packages/colin/Makefile:packages/colin/Makefile.in:packages/dummy/Makefile.in])
837      AC_CONFIG_FILES([packages/colin/doc/Makefile:packages/colin/doc/Makefile.in:packages/dummy/Makefile.in])
838      AC_CONFIG_FILES([packages/colin/test/Makefile:packages/colin/test/Makefile.in:packages/dummy/Makefile.in])
839      AC_CONFIG_FILES([packages/colin/test/studies/Makefile:packages/colin/test/studies/Makefile.in:packages/dummy/Makefile.in])
840      AC_CONFIG_FILES([packages/colin/test/driver/Makefile:packages/colin/test/driver/Makefile.in:packages/dummy/Makefile.in])
841      AC_CONFIG_FILES([packages/colin/test/unit/Makefile:packages/colin/test/unit/Makefile.in:packages/dummy/Makefile.in])
842      AC_CONFIG_FILES([packages/colin/src/Makefile:packages/colin/src/Makefile.in:packages/dummy/Makefile.in])
843   fi
844fi
845
846# scolib
847ACRO_ARG_ENABLE_PACKAGE(scolib, SCOLIB, scolib,
848       ${srcdir}/packages/scolib/Makefile.am, yes)
849if test X${ac_cv_enable_scolib} = Xyes ; then
850   if test -d ${srcdir}/packages/scolib ; then
851      AC_CONFIG_FILES([packages/scolib/Makefile:packages/scolib/Makefile.in:packages/dummy/Makefile.in])
852      AC_CONFIG_FILES([packages/scolib/doc/Makefile:packages/scolib/doc/Makefile.in:packages/dummy/Makefile.in])
853      AC_CONFIG_FILES([packages/scolib/src/Makefile:packages/scolib/src/Makefile.in:packages/dummy/Makefile.in])
854      AC_CONFIG_FILES([packages/scolib/test/Makefile:packages/scolib/test/Makefile.in:packages/dummy/Makefile.in])
855   fi
856   if test "X${ac_cv_have_fortran}"="Xno" ; then
857     AC_MSG_WARN([$scolib_warn])
858   fi
859fi
860
861# conmin
862ACRO_ARG_ENABLE_PACKAGE(conmin, CONMIN, conmin,
863       ${srcdir}/tpl/conmin/Makefile.am, yes)
864if test X${ac_cv_enable_conmin} = Xyes ; then
865   if test -d ${srcdir}/tpl/conmin ; then
866      AC_CONFIG_FILES([tpl/conmin/Makefile:tpl/conmin/Makefile.in:packages/dummy/Makefile.in])
867      AC_CONFIG_FILES([tpl/conmin/src/Makefile:tpl/conmin/src/Makefile.in:packages/dummy/Makefile.in])
868   fi
869fi
870
871# dot
872ACRO_ARG_ENABLE_PACKAGE(dot, DOT, dot,
873       ${srcdir}/tpl/dot/Makefile.am, yes)
874if test X${ac_cv_enable_dot} = Xyes ; then
875   if test -d ${srcdir}/tpl/dot ; then
876      AC_CONFIG_FILES([tpl/dot/Makefile:tpl/dot/Makefile.in:packages/dummy/Makefile.in])
877   fi
878fi
879
880# dscpack
881ACRO_ARG_ENABLE_PACKAGE(dscpack, DSCPACK, dscpack,
882       ${srcdir}/tpl/dscpack/Makefile.am, yes)
883if test X${ENABLE_MPI} = Xyes ; then
884   if test X${ac_cv_enable_dscpack} = Xyes ; then
885      if test -d ${srcdir}/tpl/dscpack ; then
886         AC_CONFIG_FILES([tpl/dscpack/Makefile:tpl/dscpack/Makefile.in:packages/dummy/Makefile.in])
887      fi
888   fi
889else
890   DSCPACK_DIR=""
891   BUILD_DSCPACK_TRUE='#'
892   BUILD_DSCPACK_FALSE=
893
894fi
895
896# eo
897ACRO_ARG_ENABLE_PACKAGE(eo, EO, eo,
898       ${srcdir}/tpl/eo/Makefile.am, yes)
899if test X${ac_cv_enable_eo} = Xyes ; then
900   if test -d ${srcdir}/tpl/eo ; then
901      AC_CONFIG_FILES([tpl/eo/Makefile:tpl/eo/Makefile.in:packages/dummy/Makefile.in])
902   fi
903fi
904
905# filib
906ACRO_ARG_ENABLE_PACKAGE(filib, FILIB, filib,
907       ${srcdir}/tpl/filib/filib/bsd/strtod.h, yes)
908if test X${ac_cv_enable_filib} = Xyes ; then
909   if test -d ${srcdir}/tpl/filib ; then
910      AC_CONFIG_FILES([tpl/filib/Makefile:tpl/filib/Makefile.in:packages/dummy/Makefile.in])
911   fi
912fi
913
914# glpk
915ACRO_ARG_ENABLE_PACKAGE(glpk, GLPK, glpk,
916       ${srcdir}/tpl/glpk/glpk/ChangeLog, yes)
917ACRO_ARG_ENABLE_PACKAGE_RECONFIG(glpk,
918     tpl/glpk/glpk/config.status, no)
919if test X${ac_cv_enable_glpk} = Xyes ; then
920   if test -d ${srcdir}/tpl/glpk ; then
921      if test X${ac_cv_reconfigure_glpk} = Xyes ; then
922        AC_CONFIG_SUBDIRS([tpl/glpk/glpk])
923      fi
924      AC_CONFIG_FILES([tpl/glpk/Makefile:tpl/glpk/Makefile.in:packages/dummy/Makefile.in])
925   fi
926
927    # If libgmp is available, use it when we build glpk
928    AC_CHECK_LIB([gmp], [__gmp_randclear], [GMP="yes"], [GMP="no"])
929     
930    if test $GMP == "yes" ; then
931      AC_MSG_NOTICE(["GLPK will use libgmp"])
932      AM_CONDITIONAL(USE_GMP_LIB, true)
933    else
934      AC_MSG_NOTICE(["GLPK will NOT use libgmp, it is not found"])
935      AM_CONDITIONAL(USE_GMP_LIB, false)
936    fi
937else
938    AM_CONDITIONAL(USE_GMP_LIB, false)
939fi
940
941# gnlp
942ACRO_ARG_ENABLE_PACKAGE(gnlp, GNLP, gnlp,
943       ${srcdir}/packages/gnlp/src/gnlp/gnlpdag.cpp, yes)
944if test X${ac_cv_enable_gnlp} = Xyes ; then
945   if test -d ${srcdir}/packages/gnlp ; then
946      AC_CONFIG_FILES([packages/gnlp/Makefile:packages/gnlp/Makefile.in:packages/dummy/Makefile.in])
947      AC_CONFIG_FILES([packages/gnlp/doc/Makefile:packages/gnlp/doc/Makefile.in:packages/dummy/Makefile.in])
948      AC_CONFIG_FILES([packages/gnlp/src/Makefile:packages/gnlp/src/Makefile.in:packages/dummy/Makefile.in])
949      AC_CONFIG_FILES([packages/gnlp/src/headers/Makefile:packages/gnlp/src/headers/Makefile.in:packages/dummy/Makefile.in])
950      AC_CONFIG_FILES([packages/gnlp/test/Makefile:packages/gnlp/test/Makefile.in:packages/dummy/Makefile.in])
951   fi
952   if test "X${ac_cv_have_fortran}"="Xno" ; then
953     AC_MSG_WARN([$gnlp_warn])
954   fi
955fi
956
957# hsl
958ACRO_ARG_ENABLE_PACKAGE(hsl, HSL, hsl,
959       ${srcdir}/tpl/hsl/Makefile.am, yes)
960if test X${ac_cv_enable_hsl} = Xyes ; then
961   if test -d ${srcdir}/tpl/hsl ; then
962      AC_CONFIG_FILES([tpl/hsl/Makefile:tpl/hsl/Makefile.in:packages/dummy/Makefile.in])
963   fi
964fi
965
966# interfaces
967ACRO_ARG_ENABLE_PACKAGE(interfaces, INTERFACES, interfaces,
968       ${srcdir}/packages/interfaces/Makefile.am, yes)
969if test X${ac_cv_enable_interfaces} = Xyes ; then
970   if test -d ${srcdir}/packages/interfaces ; then
971      AC_CONFIG_FILES([packages/interfaces/Makefile:packages/interfaces/Makefile.in:packages/dummy/Makefile.in])
972      AC_CONFIG_FILES([packages/interfaces/doc/Makefile:packages/interfaces/doc/Makefile.in:packages/dummy/Makefile.in])
973      AC_CONFIG_FILES([packages/interfaces/test/Makefile:packages/interfaces/test/Makefile.in:packages/dummy/Makefile.in])
974      AC_CONFIG_FILES([packages/interfaces/src/Makefile:packages/interfaces/src/Makefile.in:packages/dummy/Makefile.in])
975   fi
976fi
977
978# jega
979ACRO_ARG_ENABLE_PACKAGE(jega, JEGA, jega,
980       ${srcdir}/packages/jega/Makefile.am, yes)
981ACRO_ARG_ENABLE_PACKAGE_RECONFIG(jega, packages/jega/config.status, yes)
982if test X${ac_cv_reconfigure_jega} = Xyes ; then
983   if test -d ${srcdir}/packages/jega ; then
984      AC_CONFIG_SUBDIRS([packages/jega])
985   fi
986fi
987
988# momhlib
989ACRO_ARG_ENABLE_PACKAGE(momhlib, MOMHLIB, momhlib,
990       ${srcdir}/tpl/momhlib/Makefile.am, yes)
991if test X${ac_cv_enable_momhlib} = Xyes ; then
992   if test -d ${srcdir}/tpl/momhlib ; then
993      AC_CONFIG_FILES([tpl/momhlib/Makefile:tpl/momhlib/Makefile.in:packages/dummy/Makefile.in])
994   fi
995fi
996
997# mtl
998ACRO_ARG_ENABLE_PACKAGE(mtl, MTL, mtl,
999       ${srcdir}/tpl/mtl/mtl/Makefile.am, yes)
1000  #
1001  # WEH - reconfiguration doesn't really make sense here
1002  #
1003  #AM_CONDITIONAL(RECONFIGURE_MTL, false)
1004  #ACRO_ARG_ENABLE_PACKAGE_RECONFIG(mtl, tpl/mtl/mtl/config.status, $reconfigure_all)
1005  #if test X${ac_cv_reconfigure_mtl} = Xyes ; then
1006  #  AM_CONDITIONAL(RECONFIGURE_MTL, true)
1007  #fi
1008  #
1009  # We don't AC_CONFIG_SUBDIRS because of errors.  We configure
1010  # instead from the makefile.
1011  #
1012if test X${ac_cv_enable_mtl} = Xyes ; then
1013   if test -d ${srcdir}/tpl/mtl ; then
1014      AC_CONFIG_FILES([tpl/mtl/Makefile:tpl/mtl/Makefile.in:packages/dummy/Makefile.in])
1015   fi
1016fi
1017
1018# mumps
1019ACRO_ARG_ENABLE_PACKAGE(mumps, MUMPS, mumps,
1020       ${srcdir}/tpl/mumps/Makefile.am, no)
1021if test X${ac_cv_enable_mumps} = Xyes ; then
1022   if test -d ${srcdir}/tpl/mumps ; then
1023      AC_CONFIG_FILES([tpl/mumps/Makefile:tpl/mumps/Makefile.in:packages/dummy/Makefile.in])
1024   fi
1025fi
1026
1027# npsol
1028ACRO_ARG_ENABLE_PACKAGE(npsol, NPSOL, npsol,
1029       ${srcdir}/tpl/npsol/Makefile.am, yes)
1030if test X${ac_cv_enable_npsol} = Xyes ; then
1031   if test -d ${srcdir}/tpl/npsol ; then
1032      AC_CONFIG_FILES([tpl/npsol/Makefile:tpl/npsol/Makefile.in:packages/dummy/Makefile.in])
1033   fi
1034fi
1035
1036# OPT++
1037if test X$ac_cv_cxx_compiler_vendor = Xpgi ; then
1038  AC_MSG_NOTICE([Omitting Opt++ build because it is not yet ported to PGI])
1039  AM_CONDITIONAL(BUILD_OPTPP,false)
1040else
1041  ACRO_ARG_ENABLE_PACKAGE(optpp, OPTPP, optpp,
1042         ${srcdir}/packages/optpp/Makefile.am, yes)
1043  ACRO_ARG_ENABLE_PACKAGE_RECONFIG(optpp, packages/optpp/config.status, yes)
1044  if test X${ac_cv_reconfigure_optpp} = Xyes ; then
1045     if test -d ${srcdir}/packages/optpp ; then
1046        AC_CONFIG_SUBDIRS([packages/optpp])
1047     fi
1048  fi
1049fi
1050
1051# parpcx
1052ACRO_ARG_ENABLE_PACKAGE(parpcx, PARPCX, parpcx,
1053       ${srcdir}/packages/parpcx/src/main/io.cc, no)
1054if test X${ac_cv_enable_parpcx} = Xyes ; then
1055   if test -d ${srcdir}/packages/parpcx ; then
1056      AC_CONFIG_FILES([packages/parpcx/Makefile:packages/parpcx/Makefile.in:packages/dummy/Makefile.in])
1057      AC_CONFIG_FILES([packages/parpcx/src/Makefile:packages/parpcx/src/Makefile.in:packages/dummy/Makefile.in])
1058      AC_CONFIG_FILES([packages/parpcx/doc/Makefile:packages/parpcx/doc/Makefile.in:packages/dummy/Makefile.in])
1059      AC_CONFIG_FILES([packages/parpcx/src/headers/Makefile:packages/parpcx/src/headers/Makefile.in:packages/dummy/Makefile.in])
1060      AC_CONFIG_FILES([packages/parpcx/src/pcx/Makefile:packages/parpcx/src/pcx/Makefile.in:packages/dummy/Makefile.in])
1061      AC_CONFIG_FILES([packages/parpcx/test/Makefile:packages/parpcx/test/Makefile.in:packages/dummy/Makefile.in])
1062   fi
1063fi
1064
1065# pebbl
1066ACRO_ARG_ENABLE_PACKAGE(pebbl, PEBBL, pebbl,
1067       ${srcdir}/packages/pebbl/src/bb/pebbl/branching.h, yes)
1068if test X${ac_cv_enable_pebbl} = Xyes ; then
1069   if test -d ${srcdir}/packages/pebbl ; then
1070      AC_CONFIG_FILES([packages/pebbl/Makefile:packages/pebbl/Makefile.in:packages/dummy/Makefile.in])
1071      AC_CONFIG_FILES([packages/pebbl/doc/Makefile:packages/pebbl/doc/Makefile.in:packages/dummy/Makefile.in])
1072      AC_CONFIG_FILES([packages/pebbl/src/Makefile:packages/pebbl/src/Makefile.in:packages/dummy/Makefile.in])
1073      AC_CONFIG_FILES([packages/pebbl/src/headers/Makefile:packages/pebbl/src/headers/Makefile.in:packages/dummy/Makefile.in])
1074      AC_CONFIG_FILES([packages/pebbl/test/Makefile:packages/pebbl/test/Makefile.in:packages/dummy/Makefile.in])
1075   fi
1076fi
1077
1078# pico
1079AM_CONDITIONAL(PICO_TEST_DIR_COMPILES, false)
1080ACRO_ARG_ENABLE_PACKAGE(pico, PICO, pico,
1081       ${srcdir}/packages/pico/src/milp/pico/parMilp.h, yes)
1082if test X${ac_cv_enable_pico} = Xyes ; then
1083   if test -d ${srcdir}/packages/pico ; then
1084      AC_CONFIG_FILES([packages/pico/Makefile:packages/pico/Makefile.in:packages/dummy/Makefile.in])
1085      AC_CONFIG_FILES([packages/pico/doc/Makefile:packages/pico/doc/Makefile.in:packages/dummy/Makefile.in])
1086      AC_CONFIG_FILES([packages/pico/src/Makefile:packages/pico/src/Makefile.in:packages/dummy/Makefile.in])
1087      AC_CONFIG_FILES([packages/pico/src/headers/Makefile:packages/pico/src/headers/Makefile.in:packages/dummy/Makefile.in])
1088      AC_CONFIG_FILES([packages/pico/test/Makefile:packages/pico/test/Makefile.in:packages/dummy/Makefile.in])
1089   fi
1090   if test "X${ac_cv_have_fortran}"="Xno" ; then
1091     AC_MSG_WARN([$pico_warn])
1092   fi
1093fi
1094
1095# snopt
1096ACRO_ARG_ENABLE_PACKAGE(snopt, SNOPT, snopt,
1097       ${srcdir}/tpl/snopt/Makefile.am, yes)
1098if test X${ac_cv_enable_snopt} = Xyes ; then
1099   if test -d ${srcdir}/tpl/snopt ; then
1100      AC_CONFIG_FILES([tpl/snopt/Makefile:tpl/snopt/Makefile.in:packages/dummy/Makefile.in])
1101   fi
1102fi
1103
1104# soplex
1105ACRO_ARG_ENABLE_PACKAGE(soplex, SOPLEX, soplex,
1106       ${srcdir}/tpl/soplex/SOPLEX/README, yes)
1107if test X${ac_cv_enable_soplex} = Xyes ; then
1108   if test -d ${srcdir}/tpl/soplex ; then
1109      AC_CONFIG_FILES([tpl/soplex/Makefile:tpl/soplex/Makefile.in:packages/dummy/Makefile.in])
1110   fi
1111fi
1112
1113# sundry
1114ACRO_ARG_ENABLE_PACKAGE(sundry, SUNDRY, sundry,
1115       ${srcdir}/packages/sundry/sundry/sundry.h, yes)
1116if test X${ac_cv_enable_sundry} = Xyes ; then
1117   if test -d ${srcdir}/packages/sundry ; then
1118      AC_CONFIG_FILES([packages/sundry/Makefile:packages/sundry/Makefile.in:packages/dummy/Makefile.in])
1119      AC_CONFIG_FILES([packages/sundry/test/Makefile:packages/sundry/test/Makefile.in:packages/dummy/Makefile.in])
1120      AC_CONFIG_FILES([packages/sundry/sundry/Makefile:packages/sundry/sundry/Makefile.in:packages/dummy/Makefile.in])
1121      AC_CONFIG_FILES([packages/sundry/src/Makefile:packages/sundry/src/Makefile.in:packages/dummy/Makefile.in])
1122   fi
1123fi
1124
1125# tinyxml
1126ACX_TINYXML([tpl/tinyxml])
1127ACRO_ARG_ENABLE_PACKAGE(tinyxml, TINYXML, tinyxml,
1128       ${srcdir}/tpl/tinyxml/Makefile.am, $acx_tinyxml_ok)
1129if test X${ac_cv_enable_tinyxml} = Xyes ; then
1130   if test -d ${srcdir}/tpl/tinyxml ; then
1131      AC_CONFIG_FILES([tpl/tinyxml/Makefile:tpl/tinyxml/Makefile.in:packages/dummy/Makefile.in])
1132   fi
1133fi
1134
1135# tmf
1136ACRO_ARG_ENABLE_PACKAGE(tmf, TMF, tmf,
1137       ${srcdir}/packages/tmf/src/dummy.cpp, yes)
1138if test X${ac_cv_enable_tmf} = Xyes ; then
1139   if test -d ${srcdir}/packages/tmf ; then
1140      AC_CONFIG_FILES([packages/tmf/Makefile:packages/tmf/Makefile.in:packages/dummy/Makefile.in])
1141      AC_CONFIG_FILES([packages/tmf/doc/Makefile:packages/tmf/doc/Makefile.in:packages/dummy/Makefile.in])
1142      AC_CONFIG_FILES([packages/tmf/src/Makefile:packages/tmf/src/Makefile.in:packages/dummy/Makefile.in])
1143      AC_CONFIG_FILES([packages/tmf/src/headers/Makefile:packages/tmf/src/headers/Makefile.in:packages/dummy/Makefile.in])
1144      AC_CONFIG_FILES([packages/tmf/test/Makefile:packages/tmf/test/Makefile.in:packages/dummy/Makefile.in])
1145   fi
1146fi
1147
1148# tracecache
1149ACRO_ARG_ENABLE_PACKAGE(tracecache, TRACECACHE, tracecache,
1150       ${srcdir}/packages/tracecache/src/dummy.cpp, yes)
1151if test X${ac_cv_enable_tracecache} = Xyes ; then
1152   if test -d ${srcdir}/packages/tracecache ; then
1153      AC_CONFIG_FILES([packages/tracecache/Makefile:packages/tracecache/Makefile.in:packages/dummy/Makefile.in])
1154      AC_CONFIG_FILES([packages/tracecache/doc/Makefile:packages/tracecache/doc/Makefile.in:packages/dummy/Makefile.in])
1155      AC_CONFIG_FILES([packages/tracecache/src/Makefile:packages/tracecache/src/Makefile.in:packages/dummy/Makefile.in])
1156      AC_CONFIG_FILES([packages/tracecache/src/headers/Makefile:packages/tracecache/src/headers/Makefile.in:packages/dummy/Makefile.in])
1157      AC_CONFIG_FILES([packages/tracecache/test/Makefile:packages/tracecache/test/Makefile.in:packages/dummy/Makefile.in])
1158   fi
1159fi
1160
1161# trilinos
1162ACRO_ARG_ENABLE_PACKAGE(trilinos, TRILINOS, trilinos,
1163       ${srcdir}/tpl/trilinos/trilinos/CHANGELOG, yes)
1164if test X${ac_cv_enable_trilinos} = Xyes ; then
1165   if test -d ${srcdir}/tpl/trilinos ; then
1166      AC_CONFIG_FILES([tpl/trilinos/Makefile:tpl/trilinos/Makefile.in:packages/dummy/Makefile.in])
1167      #AC_CONFIG_SUBDIRS([tpl/trilinos/trilinos])
1168   fi
1169fi
1170
1171AC_CONFIG_FILES([packages/dummy/Makefile])
1172
1173# ------------------------------------------------------------------------
1174# Other package options
1175# ------------------------------------------------------------------------
1176
1177#
1178# --enable-clp=yes is the default
1179#
1180AC_ARG_ENABLE(clp,
1181AS_HELP_STRING([--disable-clp],[Turn off the CLP LP solver]),
1182[ENABLE_CLP=$enableval],
1183[ENABLE_CLP=yes]
1184)
1185
1186if test X${ENABLE_CLP} = Xyes ; then
1187  AC_DEFINE(USING_CLP,1,[define that clp is being used])
1188fi
1189
1190#
1191## TODO: are we using this anywhere?
1192# --enable-cobyla=yes is the default
1193#
1194AC_ARG_ENABLE(cobyla,
1195AS_HELP_STRING([--disable-cobyla],[Turn off the Cobyla solver]),
1196[ENABLE_COBYLA=$enableval],
1197[ENABLE_COBYLA=yes]
1198)
1199
1200if test X${ENABLE_COBYLA} = Xyes ; then
1201  AC_DEFINE(USING_COBYLA,1,[define that cobyla is being used])
1202fi
1203
1204#
1205# --enable-plgo=yes is the default
1206#
1207AC_ARG_ENABLE(plgo,
1208AS_HELP_STRING([--disable-plgo],[Turn off the PLGO solver]),
1209[ENABLE_PLGO=$enableval],
1210[ENABLE_PLGO=yes]
1211)
1212
1213if test X${ENABLE_PLGO} = Xyes ; then
1214  AC_DEFINE(USING_PLGO,1,[define that plgo is being used])
1215fi
1216
1217AC_MSG_CHECKING([whether to build PICO with GLPK support])
1218
1219AC_ARG_WITH(glpk-in-pico,
1220      [AS_HELP_STRING([--without-glpk-in-pico],[Do not link GLPK into the PICO executable])],
1221      [WITH_GLPK_PICO=$withval],
1222      [WITH_GLPK_PICO=$ac_cv_enable_pico])
1223
1224if test X${WITH_GLPK_PICO} = Xyes ; then
1225  AC_DEFINE([USING_GLPK_IN_PICO],1,[Define if we want to use GLPK in PICO])
1226  if test X${ac_cv_enable_glpk} = Xno ; then
1227    AC_MSG_ERROR("--with-glpk-in-pico=yes but --enable-glpk=no")
1228  fi
1229  AC_MSG_RESULT(yes)
1230else
1231  AC_MSG_RESULT(no)
1232fi
1233
1234
1235
1236#
1237# --with-soplex-1-2-1 will build the old version of soplex instead
1238#
1239#AC_ARG_WITH(soplex-1-2-1,
1240#AS_HELP_STRING([--with-soplex-1-2-1],[Build this older revision of soplex instead of the current one]),
1241#[WITH_OLD_SOPLEX=$withval],
1242#[WITH_OLD_SOPLEX=no]
1243#)
1244
1245#AM_CONDITIONAL(BUILD_SOPLEX, true)
1246#if test X${WITH_OLD_SOPLEX} = Xyes ; then
1247#  AM_CONDITIONAL(BUILD_SOPLEX, true)
1248#else
1249#  AM_CONDITIONAL(BUILD_SOPLEX, false)
1250#fi
1251
1252#AM_CONDITIONAL(BUILD_COIN_20050626, false)
1253#AM_CONDITIONAL(BUILD_COIN_20060202, false)
1254
1255###############################################################
1256# Boost configuration - we do this last so that optional packages may
1257# "up" the Boost dependence requirement
1258AC_MSG_NOTICE([boost dependence: [[$acro_boost_dependence]]])
1259AX_BOOST_BASE([1.37], [$acro_boost_dependence], [tpl/boost])
1260if test "$ac_boost_build_tpl" = "yes"; then
1261        AC_MSG_NOTICE([will build bundled boost TPL.])
1262        AC_CONFIG_SUBDIRS([tpl/boost])
1263else
1264        AC_MSG_NOTICE([skipping bundled boost TPL.])
1265fi
1266
1267###############################################################
1268# Output of autoconf/automake
1269
1270AC_CONFIG_FILES([Makefile] [doc/Makefile] [packages/Makefile] [tpl/Makefile])
1271
1272#
1273# If we are configuring from a cache file, TRILINOS and APPSPACK
1274# both need the original "--with-mpi*=" options or they will
1275# not know they are building with MPI.  Add these options now.
1276#
1277if test $use_ac_cv_env = yes && test "X$acro_cv_with_mpi_set" = "Xyes" ; then
1278  ac_configure_args="$acro_cv_with_mpi_options $ac_configure_args"
1279fi
1280
1281AC_ARG_WITH(python,
1282AS_HELP_STRING([--without-python],[Skip creation of python environment]),
1283[DO_PYINSTALL=$withval],
1284[DO_PYINSTALL=yes])
1285
1286if test X${DO_PYINSTALL} = Xyes; then
1287  AM_CONDITIONAL(DO_PYINSTALL, true)
1288else
1289  AM_CONDITIONAL(DO_PYINSTALL, false)
1290fi
1291
1292# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
1293
1294AC_OUTPUT
1295
1296if test $use_ac_cv_env = no && test $cache_file != "/dev/null" ; then
1297  AC_MSG_WARN([ ============== COMPILE ENVIRONMENT ============== ])
1298fi
1299
1300AC_MSG_NOTICE(CCAS=\"$CCAS\" CCASFLAGS=\"$CCASFLAGS\")
1301AC_MSG_NOTICE(CXXCPP=\"$CXXCPP\" CC=\"$CC\" CFLAGS=\"$CFLAGS\")
1302AC_MSG_NOTICE(CPP=\"$CPP\" CPPFLAGS=\"$CPPFLAGS\")
1303AC_MSG_NOTICE(CXX=\"$CXX\" CXXFLAGS=\"$CXXFLAGS\")
1304AC_MSG_NOTICE(F77=\"$F77\" FC=\"$FC\" FFLAGS=\"$FFLAGS\" )
1305AC_MSG_NOTICE(FLIBS=\"$FLIBS\" )
1306AC_MSG_NOTICE(FCLIBS=\"$FCLIBS\" )
1307AC_MSG_NOTICE(LDFLAGS=\"$LDFLAGS\" LIBS=\"$LIBS\")
1308
1309if test $use_ac_cv_env = no && test $cache_file != "/dev/null" ; then
1310  AC_MSG_WARN([ ================================================= ])
1311  AC_MSG_WARN([ In subsequent configure runs that use the "-C" or ])
1312  AC_MSG_WARN([ "--cache-file=" options, you must provide the ])
1313  AC_MSG_WARN([ compile environment on the configure command line ])
1314  AC_MSG_WARN([ using the above flags.  The Acro compile environment ])
1315  AC_MSG_WARN([ options (like "--with-debugging" or "--with-cc=") are not ])
1316  AC_MSG_WARN([ compatible with GNU autoconf's cache variable feature.])
1317  AC_MSG_WARN([ ================================================= ])
1318fi
1319
1320
1321echo ""
1322echo "---"
1323echo "--- Thank you for downloading Acro. Please register your"
1324echo "--- copy of Acro by subscribing to our announce list at"
1325echo "--- http://software.sandia.gov/mailman/listinfo/acro-announce"
1326echo "---"
1327echo "--- For more information, visit the Acro web pages at"
1328echo "--- http://software.sandia.gov/Acro/"
1329echo "---"
1330echo ""
Note: See TracBrowser for help on using the repository browser.