[Lemon-commits] Alpar Juttner: Add HAVE_LP and HAVE_MIP #defines
Lemon HG
hg at lemon.cs.elte.hu
Mon Jan 12 13:44:44 CET 2009
details: http://lemon.cs.elte.hu/hg/lemon/rev/69928a704ffb
changeset: 480:69928a704ffb
user: Alpar Juttner <alpar [at] cs.elte.hu>
date: Mon Jan 12 12:22:11 2009 +0000
description:
Add HAVE_LP and HAVE_MIP #defines
diffstat:
5 files changed, 19 insertions(+)
configure.ac | 3 +++
lemon/config.h.in | 6 ++++++
m4/lx_check_cplex.m4 | 4 ++++
m4/lx_check_glpk.m4 | 4 ++++
m4/lx_check_soplex.m4 | 2 ++
diffs (66 lines):
diff --git a/configure.ac b/configure.ac
--- a/configure.ac
+++ b/configure.ac
@@ -54,6 +54,9 @@
#LX_CHECK_CPLEX
#LX_CHECK_SOPLEX
+AM_CONDITIONAL([HAVE_LP], [test x"$lx_lp_found" = x"yes"])
+AM_CONDITIONAL([HAVE_MIP], [test x"$lx_mip_found" = x"yes"])
+
dnl Disable/enable building the demo programs.
AC_ARG_ENABLE([demo],
AS_HELP_STRING([--enable-demo], [build the demo programs])
diff --git a/lemon/config.h.in b/lemon/config.h.in
--- a/lemon/config.h.in
+++ b/lemon/config.h.in
@@ -1,3 +1,9 @@
+/* Define to 1 if you have any LP solver. */
+#undef HAVE_LP
+
+/* Define to 1 if you have any MIP solver. */
+#undef HAVE_MIP
+
/* Define to 1 if you have CPLEX. */
#undef HAVE_CPLEX
diff --git a/m4/lx_check_cplex.m4 b/m4/lx_check_cplex.m4
--- a/m4/lx_check_cplex.m4
+++ b/m4/lx_check_cplex.m4
@@ -62,6 +62,10 @@
if test x"$lx_cplex_found" = x"yes"; then
AC_DEFINE([HAVE_CPLEX], [1], [Define to 1 if you have CPLEX.])
+ lx_lp_found=yes
+ AC_DEFINE([HAVE_LP], [1], [Define to 1 if you have any LP solver.])
+ lx_mip_found=yes
+ AC_DEFINE([HAVE_MIP], [1], [Define to 1 if you have any MIP solver.])
AC_MSG_RESULT([yes])
else
CPLEX_CFLAGS=""
diff --git a/m4/lx_check_glpk.m4 b/m4/lx_check_glpk.m4
--- a/m4/lx_check_glpk.m4
+++ b/m4/lx_check_glpk.m4
@@ -60,6 +60,10 @@
if test x"$lx_glpk_found" = x"yes"; then
AC_DEFINE([HAVE_GLPK], [1], [Define to 1 if you have GLPK.])
+ lx_lp_found=yes
+ AC_DEFINE([HAVE_LP], [1], [Define to 1 if you have any LP solver.])
+ lx_mip_found=yes
+ AC_DEFINE([HAVE_MIP], [1], [Define to 1 if you have any MIP solver.])
AC_MSG_RESULT([yes])
else
GLPK_CFLAGS=""
diff --git a/m4/lx_check_soplex.m4 b/m4/lx_check_soplex.m4
--- a/m4/lx_check_soplex.m4
+++ b/m4/lx_check_soplex.m4
@@ -56,6 +56,8 @@
if test x"$lx_soplex_found" = x"yes"; then
AC_DEFINE([HAVE_SOPLEX], [1], [Define to 1 if you have SOPLEX.])
+ lx_lp_found=yes
+ AC_DEFINE([HAVE_LP], [1], [Define to 1 if you have any LP solver.])
AC_MSG_RESULT([yes])
else
SOPLEX_CXXFLAGS=""
More information about the Lemon-commits
mailing list