source: ThirdParty/SoPlex/stable/1.2/configure.ac @ 3042

Last change on this file since 3042 was 3042, checked in by stefan, 6 years ago

temporarily committing release candidate

File size: 3.2 KB
Line 
1# Copyright (C) 2010,2011 Stefan Vigerske
2# All Rights Reserved.
3# This file is distributed under the Common Public License.
4
5## $Id: configure.ac 928 2010-09-14 12:18:54Z stefan $
6
7#############################################################################
8#                       Names and other basic things                        #
9#############################################################################
10
11AC_PREREQ(2.59)
12
13AC_INIT([ThirdPartySoplex],[1.2.3],[http://projects.coin-or.org/BuildTools/newticket])
14
15AC_COPYRIGHT([
16Copyright 2010,2011 Stefan Vigerske and others.
17All Rights Reserved.
18This file is part of the open source package COIN-OR which is distributed
19under the Eclipse Public License.])
20
21# List one file in the package so that the configure script can test
22# whether the package is actually there
23AC_CONFIG_SRCDIR(soplex/src/soplex.h)
24
25# Where should everything be installed by default?  Here, we want it
26# to be installed directly in 'bin', 'lib', 'include' subdirectories
27# of the directory where configure is run.  The default would be
28# /usr/local.
29AC_PREFIX_DEFAULT([`pwd`])
30
31AC_COIN_PROJECTDIR_INIT(SoPlex,3:3:2)
32
33#############################################################################
34#                         Standard build tool stuff                         #
35#############################################################################
36
37# Get the system type
38AC_CANONICAL_BUILD
39
40# Check if user wants to produce debugging code
41AC_COIN_DEBUG_COMPILE(SoPlex)
42
43# Get the name of the C compiler and appropriate compiler options
44AC_COIN_PROG_CC
45
46# Get the name of the C++ compiler and appropriate compiler options
47AC_COIN_PROG_CXX
48
49# Check if pkg-config is available (to setup addlibs file)
50AC_COIN_HAS_PKGCONFIG
51
52# Initialize automake
53AC_COIN_INIT_AUTO_TOOLS
54
55###########################################################################
56#                         ZLIB and compiler flags                         #
57###########################################################################
58
59AC_COIN_CHECK_GNU_ZLIB(SOPLEX)
60if test $coin_has_zlib = "yes"; then
61  CXXFLAGS="$CXXFLAGS -DWITH_ZLIB"
62fi
63
64SOPLEX_WITH_GMP_CFLAG=
65AC_COIN_CHECK_GMP
66if test $coin_has_gmp = yes; then
67  AC_MSG_CHECKING([for gmpxx])
68  AC_LANG_PUSH(C++)
69  SAVED_LDFLAGS="$LDFLAGS"
70  LDFLAGS="-lgmpxx -lgmp $LDFLAGS"
71  AC_LINK_IFELSE(
72    [AC_LANG_PROGRAM([#include <gmpxx.h>],[mpq_class pq])],
73    [AC_MSG_RESULT(yes)
74     SOPLEX_WITH_GMP_CFLAG=-DSOPLEX_WITH_GMP
75     CXXFLAGS="$CXXFLAGS $SOPLEX_WITH_GMP_CFLAG"
76     SOPLEX_LIBS="-lgmpxx -lgmp $SOPLEX_LIBS"
77     SOPLEX_PCLIBS="-lgmpxx -lgmp $SOPLEX_PCLIBS"
78     SOPLEX_LIBS_INSTALLED="-lgmpxx -lgmp $SOPLEX_LIBS_INSTALLED"
79    ],
80    [AC_MSG_RESULT(no)
81     coin_has_gmp=no])
82  LDFLAGS="$SAVED_LDFLAGS"
83  AC_LANG_POP(C++)
84fi
85AC_SUBST(SOPLEX_WITH_GMP_CFLAG)
86
87###########################################################################
88#                               finish up                                 #
89###########################################################################
90
91AC_CONFIG_FILES([Makefile coinsoplex.pc coinsoplex-uninstalled.pc])
92
93# dummy header file to avoid many extra compiler flags
94AC_CONFIG_HEADER([config_soplex.h])
95
96AC_SUBST(SOPLEX_PCLIBS)
97 
98AC_COIN_FINALIZE
Note: See TracBrowser for help on using the repository browser.