source: trunk/Cbc/src/Makefile.am @ 945

Last change on this file since 945 was 945, checked in by jpgoncal, 11 years ago

Added two new versions of diving heuristics.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 11.3 KB
Line 
1# Copyright (C) 2006, 2007 International Business Machines and others.
2# All Rights Reserved.
3# This file is distributed under the Common Public License.
4
5## $Id: Makefile.am 945 2008-05-16 20:30:51Z jpgoncal $
6
7# Author:  Andreas Waechter           IBM    2006-04-13
8
9AUTOMAKE_OPTIONS = foreign
10
11########################################################################
12#                               libCbc                                 #
13########################################################################
14
15# Name of the library compiled in this directory.  We want it to be installed
16# in the 'lib' directory
17lib_LTLIBRARIES = libCbc.la libCbcSolver.la
18
19# List all source files for this library, including headers
20libCbc_la_SOURCES = \
21        Cbc_C_Interface.cpp Cbc_C_Interface.h \
22        CbcConfig.h \
23        CbcBranchActual.cpp CbcBranchActual.hpp \
24        CbcBranchBase.cpp CbcBranchBase.hpp \
25        CbcBranchCut.cpp CbcBranchCut.hpp \
26        CbcBranchDynamic.cpp CbcBranchDynamic.hpp \
27        CbcBranchLotsize.cpp CbcBranchLotsize.hpp \
28        CbcCompareActual.cpp CbcCompareActual.hpp \
29        CbcCompareBase.hpp \
30        CbcCountRowCut.cpp CbcCountRowCut.hpp \
31        CbcCutGenerator.cpp CbcCutGenerator.hpp \
32        CbcEventHandler.cpp CbcEventHandler.hpp \
33        CbcFathom.cpp CbcFathom.hpp \
34        CbcFathomDynamicProgramming.cpp CbcFathomDynamicProgramming.hpp \
35        CbcFeasibilityBase.hpp \
36        CbcHeuristic.cpp CbcHeuristic.hpp \
37        CbcHeuristicDive.cpp CbcHeuristicDive.hpp \
38        CbcHeuristicDiveCoefficient.cpp CbcHeuristicDiveCoefficient.hpp \
39        CbcHeuristicDiveFractional.cpp CbcHeuristicDiveFractional.hpp \
40        CbcHeuristicDiveGuided.cpp CbcHeuristicDiveGuided.hpp \
41        CbcHeuristicDiveLineSearch.cpp CbcHeuristicDiveLineSearch.hpp \
42        CbcHeuristicDivePseudoCost.cpp CbcHeuristicDivePseudoCost.hpp \
43        CbcHeuristicDiveVectorLength.cpp CbcHeuristicDiveLength.hpp \
44        CbcHeuristicFPump.cpp CbcHeuristicFPump.hpp \
45        CbcHeuristicGreedy.cpp CbcHeuristicGreedy.hpp \
46        CbcHeuristicLocal.cpp CbcHeuristicLocal.hpp \
47        CbcHeuristicRINS.cpp CbcHeuristicRINS.hpp \
48        CbcMessage.cpp CbcMessage.hpp \
49        CbcModel.cpp CbcModel.hpp \
50        CbcNode.cpp CbcNode.hpp \
51        CbcStatistics.cpp CbcStatistics.hpp \
52        CbcStrategy.cpp CbcStrategy.hpp \
53        CbcTree.cpp CbcTree.hpp \
54        CbcTreeLocal.cpp CbcTreeLocal.hpp
55
56libCbcSolver_la_SOURCES = \
57        CbcCbcParam.cpp \
58        Cbc_ampl.cpp Cbc_ampl.h \
59        ClpConstraintAmpl.hpp ClpAmplObjective.hpp ClpAmplStuff.cpp \
60        CbcLinked.cpp CbcLinked.hpp \
61        unitTestClp.cpp CbcSolver.cpp
62
63#Stefan: added unitTestClp.cpp because CbcSolver defines reference to it
64
65## If we have the Ampl solver library, we need to add additional things
66## also see lower down
67## new idea is to add in source code anyway
68##libCbc_la_SOURCES += Cbc_ampl.cpp Cbc_ampl.h
69
70
71# This is for libtool (on Windows)
72
73libCbc_la_LDFLAGS = $(LT_LDFLAGS)
74libCbcSolver_la_LDFLAGS = $(LT_LDFLAGS)
75
76# Some common setup for cbc and cbc-generic.
77
78bin_PROGRAMS =
79AM_CPPFLAGS =
80
81LIBS += `cat $(CGLOBJDIR)/cgl_addlibs.txt` \
82        `cat $(OSIOBJDIR)/osi_addlibs.txt` \
83        `cat $(COINUTILSOBJDIR)/coinutils_addlibs.txt` $(ADDLIBS)
84
85
86########################################################################
87#                            cbc program                               #
88########################################################################
89
90if COIN_HAS_CLP
91
92# Name of the executable compiled in this directory.  We want it to be
93# installed in the 'bin' directory
94bin_PROGRAMS += cbc
95
96# List all source files for this executable, including headers
97cbc_SOURCES = \
98        CoinSolve.cpp
99
100# Additional COIN libraries
101cbc_LDADD = libCbcSolver.la \
102        libCbc.la \
103        $(CGLOBJDIR)/src/libCgl.la \
104        $(OSIOBJDIR)/src/OsiClp/libOsiClp.la \
105        $(OSIOBJDIR)/src/libOsi.la \
106        $(CLPOBJDIR)/src/libClp.la \
107        $(COINUTILSOBJDIR)/src/libCoinUtils.la
108
109# Finally, the -rpath flag is used by libtool to make sure that the shared
110# library is found (in the lib install directory) when we are using dynamic
111# libraries.
112cbc_LDFLAGS = -rpath $(libdir)
113
114# Add locations of include files.
115
116AM_CPPFLAGS += -I`$(CYGPATH_W) $(CLPSRCDIR)/src` \
117        -I`$(CYGPATH_W) $(OSISRCDIR)/src/OsiClp` \
118        -I`$(CYGPATH_W) $(CLPOBJDIR)/inc`
119LIBS  += `cat $(CLPOBJDIR)/clp_addlibs.txt`
120
121# If we have the Ampl solver library, we need to add additional things
122if COIN_HAS_ASL
123#cbc_SOURCES += Cbc_ampl.cpp Cbc_ampl.h
124cbc_LDADD += $(ASLLIB)
125AM_CPPFLAGS += $(ASL_CPPFLAGS) -DCOIN_HAS_ASL
126endif
127
128endif
129
130
131########################################################################
132#                        cbc-generic program                           #
133########################################################################
134
135if CBC_BUILD_CBC_GENERIC
136
137# Name of the executable compiled in this directory.  We want it to be
138# installed in the 'bin' directory
139
140bin_PROGRAMS += cbc-generic
141
142# List all source files for this executable, including headers
143
144cbc_generic_SOURCES = \
145        CbcGenBaB.cpp \
146        CbcGenCbcParam.cpp CbcGenCbcParam.hpp CbcGenCbcParamUtils.cpp \
147        CbcGenCtlBlk.cpp CbcGenCtlBlk.hpp \
148        CbcGeneric.cpp \
149        CbcGenMessages.cpp CbcGenMessages.hpp \
150        CbcGenOsiParam.cpp CbcGenOsiParam.hpp CbcGenOsiParamUtils.cpp \
151        CbcGenParam.cpp CbcGenParam.hpp CbcGenParamUtils.cpp \
152        CbcGenSolution.cpp \
153        CbcGenSolvers.cpp
154
155cbc_generic_LDADD = libCbcSolver.la \
156        libCbc.la \
157        $(CGLOBJDIR)/src/libCgl.la
158
159# List all additionally required solver and Osi libraries
160
161if COIN_HAS_CLP
162  AM_CPPFLAGS += -I`$(CYGPATH_W) $(CLPSRCDIR)/src` \
163        -I`$(CYGPATH_W) $(OSISRCDIR)/src/OsiClp` \
164        -I`$(CYGPATH_W) $(CLPOBJDIR)/inc`
165  cbc_generic_LDADD += $(OSIOBJDIR)/src/OsiClp/libOsiClp.la \
166        $(CLPOBJDIR)/src/libClp.la
167  LIBS  += `cat $(CLPOBJDIR)/clp_addlibs.txt`
168endif
169
170if COIN_HAS_CPX
171  AM_CPPFLAGS += -I`$(CYGPATH_W) $(CPXINCDIR)` \
172        -I`$(CYGPATH_W) $(OSISRCDIR)/src/OsiCpx`
173  cbc_generic_LDADD += $(OSIOBJDIR)/src/OsiCpx/libOsiCpx.la
174endif
175
176if COIN_HAS_DYLP
177  AM_CPPFLAGS += -I`$(CYGPATH_W) $(DYLPSRCDIR)/src/DylpStdLib` \
178        -I`$(CYGPATH_W) $(DYLPSRCDIR)/src/Dylp` \
179        -I`$(CYGPATH_W) $(DYLPOBJDIR)/inc` \
180        -I`$(CYGPATH_W) $(OSISRCDIR)/src/OsiDylp`
181  cbc_generic_LDADD += $(OSIOBJDIR)/src/OsiDylp/libOsiDylp.la \
182        $(DYLPOBJDIR)/src/Dylp/libDylp.la
183  LIBS += `cat $(DYLPOBJDIR)/dylp_addlibs.txt`
184endif
185
186if COIN_HAS_FMP
187  AM_CPPFLAGS += -I`$(CYGPATH_W) $(OSISRCDIR)/src/OsiFmp`
188  cbc_generic_LDADD += $(OSIOBJDIR)/src/OsiFmp/libOsiFmp.la
189endif
190
191if COIN_HAS_GLPK
192  AM_CPPFLAGS += -I`$(CYGPATH_W) $(GLPKINCDIR)` \
193        -I`$(CYGPATH_W) $(OSISRCDIR)/src/OsiGlpk`
194  cbc_generic_LDADD += $(OSIOBJDIR)/src/OsiGlpk/libOsiGlpk.la
195endif
196
197if COIN_HAS_MSK
198  AM_CPPFLAGS += -I`$(CYGPATH_W) $(MSKINCDIR)` \
199        -I`$(CYGPATH_W) $(OSISRCDIR)/src/OsiMsk`
200  cbc_generic_LDADD += $(OSIOBJDIR)/src/OsiMsk/libOsiMsk.la
201endif
202
203if COIN_HAS_OSL
204  AM_CPPFLAGS += -I`$(CYGPATH_W) $(OSLINCDIR)` \
205        -I`$(CYGPATH_W) $(OSISRCDIR)/src/OsiOsl`
206  cbc_generic_LDADD += $(OSIOBJDIR)/src/OsiOsl/libOsiOsl.la
207endif
208
209if COIN_HAS_SPX
210  AM_CPPFLAGS += -I`$(CYGPATH_W) $(SPXINCDIR)` \
211        -I`$(CYGPATH_W) $(OSISRCDIR)/src/OsiSpx`
212  cbc_generic_LDADD += $(OSIOBJDIR)/src/OsiSpx/libOsiSpx.la
213endif
214
215if COIN_HAS_SYMPHONY
216  AM_CPPFLAGS += -I`$(CYGPATH_W) $(SYMPHONYSRCDIR)/src` \
217        -I`$(CYGPATH_W) $(OSISRCDIR)/src/OsiSym`
218  cbc_generic_LDADD += $(OSIOBJDIR)/src/OsiSym/libOsiSym.la \
219        $(SYMPHONYOBJDIR)/src/libSym.la
220  LIBS += `cat $(SYMPHONYOBJDIR)/sym_addlibs.txt`
221endif
222
223if COIN_HAS_VOL
224  AM_CPPFLAGS += -I`$(CYGPATH_W) $(VOLSRCDIR)/src` \
225        -I`$(CYGPATH_W) $(OSISRCDIR)/src/OsiVol`
226  cbc_generic_LDADD += $(OSIOBJDIR)/src/OsiVol/libOsiVol.la \
227        $(VOLOBJDIR)/src/libVol.la
228  LIBS += `cat $(VOLOBJDIR)/vol_addlibs.txt`
229endif
230
231if COIN_HAS_XPR
232  AM_CPPFLAGS += -I`$(CYGPATH_W) $(XPRINCDIR)` \
233        -I`$(CYGPATH_W) $(OSISRCDIR)/src/OsiXpr`
234  cbc_generic_LDADD += $(OSIOBJDIR)/src/OsiXpr/libOsiXpr.la
235endif
236
237if COIN_HAS_ASL
238  cbc_generic_LDADD += $(ASLLIB)
239  AM_CPPFLAGS += $(ASL_CPPFLAGS) -DCOIN_HAS_ASL
240endif
241
242# Finally the Osi Coin library (many of the above need it)
243cbc_generic_LDADD += $(OSIOBJDIR)/src/libOsi.la \
244        $(COINUTILSOBJDIR)/src/libCoinUtils.la
245
246# Finally, the -rpath flag is used by libtool to make sure that the shared
247# library is found (in the lib install directory) when we are using dynamic
248# libraries.
249
250cbc_generic_LDFLAGS = -rpath $(libdir)
251
252endif
253
254########################################################################
255#                            Additional flags                          #
256########################################################################
257
258# Here list all include flags, relative to this "srcdir" directory.  This
259# "cygpath" stuff is necessary to compile with native compilers on Windows.
260# "top_srcdir" refers to the basic directory for the main package that is
261# being compiled.
262AM_CPPFLAGS += \
263        -I`$(CYGPATH_W) $(CGLSRCDIR)/src` \
264        -I`$(CYGPATH_W) $(CGLSRCDIR)/src/CglClique` \
265        -I`$(CYGPATH_W) $(CGLSRCDIR)/src/CglDuplicateRow` \
266        -I`$(CYGPATH_W) $(CGLSRCDIR)/src/CglFlowCover` \
267        -I`$(CYGPATH_W) $(CGLSRCDIR)/src/CglGomory` \
268        -I`$(CYGPATH_W) $(CGLSRCDIR)/src/CglKnapsackCover` \
269        -I`$(CYGPATH_W) $(CGLSRCDIR)/src/CglMixedIntegerRounding` \
270        -I`$(CYGPATH_W) $(CGLSRCDIR)/src/CglMixedIntegerRounding2` \
271        -I`$(CYGPATH_W) $(CGLSRCDIR)/src/CglOddHole` \
272        -I`$(CYGPATH_W) $(CGLSRCDIR)/src/CglPreProcess` \
273        -I`$(CYGPATH_W) $(CGLSRCDIR)/src/CglProbing` \
274        -I`$(CYGPATH_W) $(CGLSRCDIR)/src/CglRedSplit` \
275        -I`$(CYGPATH_W) $(CGLSRCDIR)/src/CglTwomir` \
276        -I`$(CYGPATH_W) $(CGLSRCDIR)/src/CglLandP` \
277        -I`$(CYGPATH_W) $(CGLSRCDIR)/src/CglResidualCapacity` \
278        -I`$(CYGPATH_W) $(COINUTILSSRCDIR)/src` \
279        -I`$(CYGPATH_W) $(COINUTILSOBJDIR)/inc` \
280        -I`$(CYGPATH_W) $(OSISRCDIR)/src` \
281        -I`$(CYGPATH_W) $(OSIOBJDIR)/inc`
282
283# List additional defines
284AM_CPPFLAGS += -DCOIN_NO_CLP_MESSAGE -DUSE_CBCCONFIG
285
286# This line is necessary to allow VPATH compilation with MS compilers
287# on Cygwin
288DEFAULT_INCLUDES = -I. -I`$(CYGPATH_W) $(srcdir)` -I$(top_builddir)/inc
289
290########################################################################
291#                Headers that need to be installed                     #
292########################################################################
293
294# Here list all the header files that are required by a user of the library,
295# and that therefore should be installed in 'install/coin'
296includecoindir = $(includedir)/coin
297includecoin_HEADERS = \
298        ../inc/config_cbc.h \
299        Cbc_C_Interface.h \
300        CbcBranchActual.hpp \
301        CbcBranchBase.hpp \
302        CbcBranchDynamic.hpp \
303        CbcBranchLotsize.hpp \
304        CbcBranchCut.hpp \
305        CbcCompareActual.hpp \
306        CbcCompareBase.hpp \
307        CbcCutGenerator.hpp \
308        CbcFathom.hpp \
309        CbcEventHandler.hpp \
310        CbcFeasibilityBase.hpp \
311        CbcHeuristic.hpp \
312        CbcHeuristicDive.hpp \
313        CbcHeuristicDiveCoefficient.hpp \
314        CbcHeuristicDiveFractional.hpp \
315        CbcHeuristicDiveGuided.hpp \
316        CbcHeuristicDiveLineSearch.hpp \
317        CbcHeuristicDivePseudoCost.hpp \
318        CbcHeuristicDiveVectorLength.hpp \
319        CbcHeuristicFPump.hpp \
320        CbcHeuristicGreedy.hpp \
321        CbcHeuristicLocal.hpp \
322        CbcHeuristicRINS.hpp \
323        CbcMessage.hpp \
324        CbcModel.hpp \
325        CbcNode.hpp \
326        CbcStrategy.hpp \
327        CbcSolver.hpp \
328        CbcTree.hpp \
329        CbcLinked.hpp \
330        CbcTreeLocal.hpp \
331        ClpConstraintAmpl.hpp \
332        ClpAmplObjective.hpp
333
334#############################################################################
335# Create the Config.h file that always defines HAVE_CONFIG_H and install it #
336#############################################################################
337
338# You only need to adapt the following line
339ConfigHeader = CbcConfig.h
340
341install-exec-local:
342        echo "#ifndef HAVE_CONFIG_H" >bla
343        echo "#define HAVE_CONFIG_H" >>bla
344        echo "#endif" >> bla
345        cat $(srcdir)/$(ConfigHeader) >> bla
346        $(install_sh_DATA) bla $(DESTDIR)$(includecoindir)/$(ConfigHeader)
347        rm -f bla
348
349uninstall-local:
350        rm -f $(DESTDIR)$(includecoindir)/$(ConfigHeader)
Note: See TracBrowser for help on using the repository browser.