Changeset 1546 for trunk/Cbc/examples


Ignore:
Timestamp:
Dec 5, 2010 9:54:40 AM (8 years ago)
Author:
stefan
Message:

update examples Makefile for cygwin/cl/no-pkgconfig

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Cbc/examples/Makefile.in

    r1541 r1546  
    4545##########################################################################
    4646
     47COIN_HAS_PKGCONFIG = @COIN_HAS_PKGCONFIG_TRUE@TRUE
     48COIN_CXX_IS_CL = @COIN_CXX_IS_CL_TRUE@TRUE
     49COIN_HAS_SAMPLE = @COIN_HAS_SAMPLE_TRUE@TRUE
     50COIN_HAS_MIPLIB3 = @COIN_HAS_MIPLIB3_TRUE@TRUE
     51
    4752# C++ Compiler command
    4853CXX = @CXX@
     
    5055# C++ Compiler options
    5156CXXFLAGS = @CXXFLAGS@
    52 @COIN_HAS_SAMPLE_TRUE@@COIN_HAS_PKGCONFIG_TRUE@CXXFLAGS += -DSAMPLEDIR=\"`PKG_CONFIG_PATH=@COIN_PKG_CONFIG_PATH@ @PKG_CONFIG@ --variable=datadir coindatasample`\"
    53 @COIN_HAS_SAMPLE_TRUE@@COIN_HAS_PKGCONFIG_FALSE@CXXFLAGS += -DSAMPLEDIR=\"@SAMPLE_DATA_INSTALLED@\"
    54 @COIN_HAS_MIPLIB3_TRUE@@COIN_HAS_PKGCONFIG_TRUE@CXXFLAGS += -DMIPLIB3DIR=\"`PKG_CONFIG_PATH=@COIN_PKG_CONFIG_PATH@ @PKG_CONFIG@ --variable=datadir coindatamiplib3`\"
    55 @COIN_HAS_MIPLIB3_TRUE@@COIN_HAS_PKGCONFIG_FALSE@CXXFLAGS += -DMIPLIB3DIR=\"@MIPLIB3_DATA_INSTALLED@\"
    5657
    5758# C Compiler options
    5859CFLAGS = @CFLAGS@
    59 @COIN_HAS_SAMPLE_TRUE@CFLAGS += -DSAMPLEDIR=\"@SAMPLE_DATA@\"
    6060
    6161# additional C++ Compiler options for linking
    6262CXXLINKFLAGS = @RPATH_FLAGS@
    6363
    64 # Compiler flags (we use the CYGPATH_W variables to allow compilation with Windows compilers)
    65 @COIN_HAS_PKGCONFIG_TRUE@INCL = `PKG_CONFIG_PATH=@COIN_PKG_CONFIG_PATH@ @PKG_CONFIG@ --cflags cbc` $(ADDINCFLAGS)
    66 @COIN_HAS_PKGCONFIG_FALSE@INCL = @CBCLIB_CFLAGS_INSTALLED@ $(ADDINCFLAGS)
     64# Sample data directory
     65ifeq ($(COIN_HAS_SAMPLE), TRUE)
     66  ifeq ($(COIN_HAS_PKGCONFIG), TRUE)
     67    CXXFLAGS += -DSAMPLEDIR=\"`PKG_CONFIG_PATH=@COIN_PKG_CONFIG_PATH@ @PKG_CONFIG@ --variable=datadir coindatasample`\"
     68      CFLAGS += -DSAMPLEDIR=\"`PKG_CONFIG_PATH=@COIN_PKG_CONFIG_PATH@ @PKG_CONFIG@ --variable=datadir coindatasample`\"
     69  else
     70    CXXFLAGS += -DSAMPLEDIR=\"@SAMPLE_DATA_INSTALLED@\"
     71      CFLAGS += -DSAMPLEDIR=\"@SAMPLE_DATA_INSTALLED@\"
     72  endif
     73endif
     74
     75# Miplib3 data directory
     76ifeq ($(COIN_HAS_MIPLIB3), TRUE)
     77  ifeq ($(COIN_HAS_PKGCONFIG), TRUE)
     78    CXXFLAGS += -DMIPLIB3DIR=\"`PKG_CONFIG_PATH=@COIN_PKG_CONFIG_PATH@ @PKG_CONFIG@ --variable=datadir coindatamiplib3`\"
     79  else
     80    CXXFLAGS += -DMIPLIB3DIR=\"@MIPLIB3_DATA_INSTALLED@\"
     81  endif
     82endif
     83
     84# Include directories (we use the CYGPATH_W variables to allow compilation with Windows compilers)
     85ifeq ($(COIN_HAS_PKGCONFIG), TRUE)
     86  INCL = `PKG_CONFIG_PATH=@COIN_PKG_CONFIG_PATH@ @PKG_CONFIG@ --cflags cbc`
     87else
     88  INCL = @CBCLIB_CFLAGS_INSTALLED@
     89endif
     90INCL += $(ADDINCFLAGS)
    6791
    6892# Linker flags
    69 @COIN_HAS_PKGCONFIG_TRUE@@COIN_CXX_IS_CL_FALSE@LIBS = `PKG_CONFIG_PATH=@COIN_PKG_CONFIG_PATH@ @PKG_CONFIG@ --libs cbc`
    70 @COIN_HAS_PKGCONFIG_TRUE@@COIN_CXX_IS_CL_TRUE@LIBS = /link: `PKG_CONFIG_PATH=@COIN_PKG_CONFIG_PATH@ @PKG_CONFIG@ --msvc-syntax --libs cbc`
    71 @COIN_HAS_PKGCONFIG_FALSE@LIBS = -L@abs_lib_dir@ -lCbcSolver -lCbc -lOsiCbc @CBCLIB_LIBS_INSTALLED@
     93ifeq ($(COIN_HAS_PKGCONFIG), TRUE)
     94  LIBS = `PKG_CONFIG_PATH=@COIN_PKG_CONFIG_PATH@ @PKG_CONFIG@ --libs cbc`
     95else
     96  ifeq ($(COIN_CXX_IS_CL), TRUE)
     97    LIBS = /link /libpath:`$(CYGPATH_W) @abs_lib_dir@` libCbcSolver.lib libCbc.lib libOsiCbc.lib @CBCLIB_LIBS_INSTALLED@
     98  else
     99    LIBS = -L@abs_lib_dir@ -lCbcSolver -lCbc -lOsiCbc @CBCLIB_LIBS_INSTALLED@
     100  endif
     101endif
    72102
    73103# The following is necessary under cygwin, if native compilers are used
Note: See TracChangeset for help on using the changeset viewer.