Changeset 1543 for branches


Ignore:
Timestamp:
Apr 24, 2010 12:57:01 PM (10 years ago)
Author:
stefan
Message:

fixes for fallbacks

Location:
branches/split/Clp
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/split/Clp/configure

    r1542 r1543  
    2074320743
    2074420744
    20745 
    20746 if test $coin_has_coinutils != "yes" ; then
     20745if test $coin_has_coinutils != yes ; then
     20746  #if we have to use the fallback routines, then obviously it will not find CoinUtils dependencies
     20747  #thus, we check whether ThirdParty/Blas and ThirdParty/Lapack have been setup and
     20748  #assume that if present then they are dependencies of CoinUtils
     20749
     20750if test x$coin_has_blas != "xyes" ; then
     20751echo "$as_me:$LINENO: checking for COIN-OR module Blas (fallback)" >&5
     20752echo $ECHO_N "checking for COIN-OR module Blas (fallback)... $ECHO_C" >&6
     20753
     20754coin_has_blas=notGiven
     20755
     20756# check if user wants to skip module in any case
     20757if test x"$COIN_SKIP_PROJECTS" != x; then
     20758  for dir in $COIN_SKIP_PROJECTS; do
     20759    if test $dir = "Blas"; then
     20760      coin_has_blas=skipping
     20761    fi
     20762  done
     20763fi
     20764
     20765BLAS_LIBS=
     20766BLAS_CFLAGS=
     20767BLAS_DATA=
     20768
     20769
     20770if test $coin_has_blas != "skipping" ; then
     20771  # if the project is available and configured, then a project-uninstalled.pc file should have been created
     20772  if test -r ../ThirdParty/Blas/coinblas-uninstalled.pc ; then
     20773    # read CFLAGS and LIBS from coinblas-uninstalled.pc file
     20774    # add CYGPATH_W cludge into include flags
     20775    # replace -L${libdir} by absolute path to build directory in linker flags
     20776    # we assume that the build directory is ../ThirdParty/Blas/src if this directory exists, otherwise we assume that it is ../ThirdParty/Blas
     20777    BLAS_CFLAGS=`sed -n -e 's/Cflags://' -e 's/-I\([^ ]*\)/-I\`${CYGPATH_W} \1\`/gp' ../ThirdParty/Blas/coinblas-uninstalled.pc`
     20778    projectlibs=`sed -n -e 's/Libs://' -e 's/-L\${libdir}//p' ../ThirdParty/Blas/coinblas-uninstalled.pc`
     20779    if test "x$projectlibs" != x ; then
     20780      if test -d ../ThirdParty/Blas/src ; then
     20781        BLAS_LIBS="-L`cd ../ThirdParty/Blas/src; pwd` $projectlibs"
     20782      else
     20783        BLAS_LIBS="-L`cd ../ThirdParty/Blas; pwd` $projectlibs"
     20784      fi
     20785    fi
     20786    BLAS_DATA=`sed -n -e 's/datadir=//gp' ../ThirdParty/Blas/coinblas-uninstalled.pc`
     20787
     20788
     20789
     20790
     20791
     20792    coin_has_blas=yes
     20793  fi
     20794fi
     20795
     20796#if user did not disable setting of makefile conditional, do it
     20797
     20798
     20799echo "$as_me:$LINENO: result: $coin_has_blas" >&5
     20800echo "${ECHO_T}$coin_has_blas" >&6
     20801fi
     20802
     20803
     20804if test x$coin_has_lapack != "xyes" ; then
     20805echo "$as_me:$LINENO: checking for COIN-OR module Lapack (fallback)" >&5
     20806echo $ECHO_N "checking for COIN-OR module Lapack (fallback)... $ECHO_C" >&6
     20807
     20808coin_has_lapack=notGiven
     20809
     20810# check if user wants to skip module in any case
     20811if test x"$COIN_SKIP_PROJECTS" != x; then
     20812  for dir in $COIN_SKIP_PROJECTS; do
     20813    if test $dir = "Lapack"; then
     20814      coin_has_lapack=skipping
     20815    fi
     20816  done
     20817fi
     20818
     20819LAPACK_LIBS=
     20820LAPACK_CFLAGS=
     20821LAPACK_DATA=
     20822
     20823
     20824if test $coin_has_lapack != "skipping" ; then
     20825  # if the project is available and configured, then a project-uninstalled.pc file should have been created
     20826  if test -r ../ThirdParty/Lapack/coinlapack-uninstalled.pc ; then
     20827    # read CFLAGS and LIBS from coinlapack-uninstalled.pc file
     20828    # add CYGPATH_W cludge into include flags
     20829    # replace -L${libdir} by absolute path to build directory in linker flags
     20830    # we assume that the build directory is ../ThirdParty/Lapack/src if this directory exists, otherwise we assume that it is ../ThirdParty/Lapack
     20831    LAPACK_CFLAGS=`sed -n -e 's/Cflags://' -e 's/-I\([^ ]*\)/-I\`${CYGPATH_W} \1\`/gp' ../ThirdParty/Lapack/coinlapack-uninstalled.pc`
     20832    projectlibs=`sed -n -e 's/Libs://' -e 's/-L\${libdir}//p' ../ThirdParty/Lapack/coinlapack-uninstalled.pc`
     20833    if test "x$projectlibs" != x ; then
     20834      if test -d ../ThirdParty/Lapack/src ; then
     20835        LAPACK_LIBS="-L`cd ../ThirdParty/Lapack/src; pwd` $projectlibs"
     20836      else
     20837        LAPACK_LIBS="-L`cd ../ThirdParty/Lapack; pwd` $projectlibs"
     20838      fi
     20839    fi
     20840    LAPACK_DATA=`sed -n -e 's/datadir=//gp' ../ThirdParty/Lapack/coinlapack-uninstalled.pc`
     20841
     20842
     20843
     20844
     20845
     20846    coin_has_lapack=yes
     20847  fi
     20848fi
     20849
     20850#if user did not disable setting of makefile conditional, do it
     20851
     20852
     20853echo "$as_me:$LINENO: result: $coin_has_lapack" >&5
     20854echo "${ECHO_T}$coin_has_lapack" >&6
     20855fi
     20856
     20857fi
     20858
     20859if test x$coin_has_coinutils != "xyes" ; then
    2074720860echo "$as_me:$LINENO: checking for COIN-OR module CoinUtils (fallback)" >&5
    2074820861echo $ECHO_N "checking for COIN-OR module CoinUtils (fallback)... $ECHO_C" >&6
     
    2078320896
    2078420897    ADDLIBS="$ADDLIBS $COINUTILS_LIBS"
    20785 
    20786     REQUIREDPACKAGES="$REQUIREDPACKAGES coinutils"
     20898       REQUIREDPACKAGES="$REQUIREDPACKAGES coinutils"
     20899
    2078720900
    2078820901
     
    2082020933   { (exit 1); exit 1; }; }
    2082120934fi
     20935#so if we had to do find Blas and Lapack separately, then add their linker flags to the CoinUtils flags
     20936#actually the libs may already be included in libCoinUtils, but we may still need the fortran library flags
     20937COINUTILS_LIBS="$COINUTILS_LIBS $BLAS_LIBS $LAPACK_LIBS"
    2082220938
    2082320939
     
    2100621122
    2100721123
    21008 if test $coin_has_osi != "yes" ; then
     21124if test x$coin_has_osi != "xyes" ; then
    2100921125echo "$as_me:$LINENO: checking for COIN-OR module Osi (fallback)" >&5
    2101021126echo $ECHO_N "checking for COIN-OR module Osi (fallback)... $ECHO_C" >&6
     
    2104421160    OSI_DATA=`sed -n -e 's/datadir=//gp' ../Osi/osi-uninstalled.pc`
    2104521161
    21046     ADDLIBS="$ADDLIBS $OSI_LIBS"
    21047 
    2104821162
    2104921163
     
    2126121375
    2126221376
    21263 
    21264 if test $coin_has_ositests != "yes" ; then
     21377if test $coin_has_ositests != yes ; then
     21378
     21379if test x$coin_has_ositests != "xyes" ; then
    2126521380echo "$as_me:$LINENO: checking for COIN-OR module OsiTests (fallback)" >&5
    2126621381echo $ECHO_N "checking for COIN-OR module OsiTests (fallback)... $ECHO_C" >&6
     
    2130021415    OSITESTS_DATA=`sed -n -e 's/datadir=//gp' ../Osi/osi-unittests-uninstalled.pc`
    2130121416
    21302     ADDLIBS="$ADDLIBS $OSITESTS_LIBS"
    21303 
    2130421417
    2130521418
     
    2133321446fi
    2133421447
     21448fi
    2133521449
    2133621450
     
    2151921633
    2152021634
    21521 if test $coin_has_sample != "yes" ; then
     21635if test x$coin_has_sample != "xyes" ; then
    2152221636echo "$as_me:$LINENO: checking for COIN-OR module Sample (fallback)" >&5
    2152321637echo $ECHO_N "checking for COIN-OR module Sample (fallback)... $ECHO_C" >&6
     
    2155721671    SAMPLE_DATA=`sed -n -e 's/datadir=//gp' ../Data/Sample/coindatasample-uninstalled.pc`
    2155821672
    21559     ADDLIBS="$ADDLIBS $SAMPLE_LIBS"
    21560 
    2156121673
    2156221674
     
    2177621888
    2177721889
    21778 if test $coin_has_netlib != "yes" ; then
     21890if test x$coin_has_netlib != "xyes" ; then
    2177921891echo "$as_me:$LINENO: checking for COIN-OR module Netlib (fallback)" >&5
    2178021892echo $ECHO_N "checking for COIN-OR module Netlib (fallback)... $ECHO_C" >&6
     
    2181321925    fi
    2181421926    NETLIB_DATA=`sed -n -e 's/datadir=//gp' ../Data/Netlib/coindatanetlib-uninstalled.pc`
    21815 
    21816     ADDLIBS="$ADDLIBS $NETLIB_LIBS"
    2181721927
    2181821928
  • branches/split/Clp/configure.ac

    r1542 r1543  
    5858
    5959AC_COIN_HAS_MODULE(CoinUtils,          [coinutils = split])
     60if test $coin_has_coinutils != yes ; then
     61  #if we have to use the fallback routines, then obviously it will not find CoinUtils dependencies
     62  #thus, we check whether ThirdParty/Blas and ThirdParty/Lapack have been setup and
     63  #assume that if present then they are dependencies of CoinUtils
     64  AC_COIN_HAS_MODULE_FALLBACK(Blas,   [coinblas],   [../ThirdParty/Blas],   [required=0 dodefine=0 doconditional=0])
     65  AC_COIN_HAS_MODULE_FALLBACK(Lapack, [coinlapack], [../ThirdParty/Lapack], [required=0 dodefine=0 doconditional=0])
     66fi
    6067AC_COIN_HAS_MODULE_FALLBACK(CoinUtils, [coinutils], [../CoinUtils])
    6168if test $coin_has_coinutils != yes ; then
    6269  AC_MSG_ERROR([Required package CoinUtils not available.])
    6370fi
     71#so if we had to do find Blas and Lapack separately, then add their linker flags to the CoinUtils flags
     72#actually the libs may already be included in libCoinUtils, but we may still need the fortran library flags
     73COINUTILS_LIBS="$COINUTILS_LIBS $BLAS_LIBS $LAPACK_LIBS"
    6474
    6575AC_COIN_HAS_MODULE(Osi,               [osi],                     [required=0])
    6676AC_COIN_HAS_MODULE_FALLBACK(Osi,      [osi],           [../Osi], [required=0])
    6777AC_COIN_HAS_MODULE(OsiTests,          [osi-unittests],           [required=0])
    68 AC_COIN_HAS_MODULE_FALLBACK(OsiTests, [osi-unittests], [../Osi], [required=0])
     78if test $coin_has_ositests != yes ; then
     79  AC_COIN_HAS_MODULE_FALLBACK(OsiTests, [osi-unittests], [../Osi], [required=0])
     80fi
    6981
    7082AC_COIN_HAS_MODULE(Sample,          [coindatasample],                   [required=0])
Note: See TracChangeset for help on using the changeset viewer.