Changes between Version 33 and Version 34 of WikiStart


Ignore:
Timestamp:
Jun 16, 2012 5:14:22 AM (9 years ago)
Author:
chm.duquesne
Comment:

Added informations about lazylpsolverlibs

Legend:

Unmodified
Added
Removed
Modified
  • WikiStart

    v33 v34  
    5252----------
    5353
     54== Easily adding support for commercial solvers ==
     55
     56=== At build time ===
     57
     58It is possible to create an osi build that supports cplex, gurobi and xpress even if you don't have (yet) any of these solvers on your machine using [https://code.google.com/p/lazylpsolverlibs/ lazylpsolverlibs]. To do so, follow these steps:
     59
     60 1. Install lazylpsolverlibs (follow the instructions of the [https://code.google.com/p/lazylpsolverlibs/wiki/HowToSetup lazylpsolverlibs wiki])
     61 2. Use the following command line to configure Osi:
     62{{{
     63./configure --with-cplex-incdir="$(pkg-config --variable=includedir lazycplex)/lazylpsolverlibs/ilcplex" \
     64            --with-cplex-lib="$(pkg-config --libs lazycplex)" \
     65            --with-gurobi-incdir="$(pkg-config --variable=includedir lazygurobi)/lazylpsolverlibs" \
     66            --with-gurobi-lib="$(pkg-config --libs lazygurobi)" \
     67            --with-xpress-incdir="$(pkg-config --variable=includedir lazyxprs)/lazylpsolverlibs" \
     68            --with-xpress-lib="$(pkg-config --libs lazyxprs)"
     69}}}
     70 3. Then follow the normal installation process (make, make install)
     71
     72=== At run time ===
     73
     74Your build should now support cplex, gurobi and xpress, which means that if you install one of these solvers, osi will be able to use it. At run time, you just need to point one of the environment variables LAZYLPSOLVERLIBS_GUROBI_LIB, LAZYLPSOLVERLIBS_CPLEX_LIB or LAZYLPSOLVERLIBS_XPRS_LIB to the full path of the corresponding solver library. For example:
     75{{{
     76export LAZYLPSOLVERLIBS_CPLEX_LIB=/usr/ilog/cplex121/bin/x86_debian4.0_4.1/libcplex121.so
     77}}}
     78
     79=== Troubleshooting ===
     80
     81If pkg-config reports errors during the configure step, try modifying the PKG_CONFIG_PATH variable. Most likely, you need to do:
     82{{{
     83export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
     84}}}
     85
     86----------
     87
    5488== Included Projects ==
    5589