<div dir="ltr"><div>Hi Stefan,</div><div><br></div><div>Please see below the output of `./configure`. I'll try building against cplex directly as suggested. <br></div><div>Is there any official documentation on how to build against cplex (under Ubuntu)?</div><div><br></div><div>Thanks a lot,<br></div><div><br></div><div><br></div><div dir="ltr">$ ./configure --with-cplex-incdir="$(pkg-config --variable=includedir lazycplex)/lazylpsolverlibs/ilcplex" \<br>>             --with-cplex-lib="$(pkg-config --libs lazycplex)" \<br>>             --with-gurobi-incdir="$(pkg-config --variable=includedir lazygurobi)/lazylpsolverlibs" \<br>>             --with-gurobi-lib="$(pkg-config --libs lazygurobi)" \<br>>             --with-xpress-incdir="$(pkg-config --variable=includedir lazyxprs)/lazylpsolverlibs" \<br>>             --with-xpress-lib="$(pkg-config --libs lazyxprs)"<br>checking build system type... x86_64-unknown-linux-gnu<br>checking whether we want to compile in debug mode... no<br>checking for gcc... gcc<br>checking for C compiler default output file name... a.out<br>checking whether the C compiler works... yes<br>checking whether we are cross compiling... no<br>checking for suffix of executables... <br>checking for suffix of object files... o<br>checking whether we are using the GNU C compiler... yes<br>checking whether gcc accepts -g... yes<br>checking for gcc option to accept ANSI C... none needed<br>configure: C compiler options are: -O3 -pipe -DNDEBUG -Wimplicit -Wparentheses -Wsequence-point -Wreturn-type -Wcast-qual -Wall -Wno-unknown-pragmas -Wno-long-long  <br>checking for g++... g++<br>checking whether we are using the GNU C++ compiler... yes<br>checking whether g++ accepts -g... yes<br>checking whether C++ compiler g++ works... yes<br>configure: C++ compiler options are: -O3 -pipe -DNDEBUG -Wparentheses -Wreturn-type -Wcast-qual -Wall -Wpointer-arith -Wwrite-strings -Wconversion -Wno-unknown-pragmas -Wno-long-long  <br>configure: Trying to determine Fortran compiler name<br>checking for gfortran... gfortran<br>checking whether we are using the GNU Fortran 77 compiler... yes<br>checking whether gfortran accepts -g... yes<br>configure: Fortran compiler options are: -O3 -pipe  <br>checking for egrep... grep -E<br>checking whether ln -s works... yes<br>checking for a BSD-compatible install... /usr/bin/install -c<br>checking whether build environment is sane... yes<br>checking for gawk... no<br>checking for mawk... mawk<br>checking whether make sets $(MAKE)... yes<br>checking for style of include used by make... GNU<br>checking dependency style of gcc... gcc3<br>checking dependency style of g++... gcc3<br>checking whether to enable maintainer-specific portions of Makefiles... no<br>checking host system type... x86_64-unknown-linux-gnu<br>checking for a sed that does not truncate output... /bin/sed<br>checking for ld used by gcc... /usr/bin/ld<br>checking if the linker (/usr/bin/ld) is GNU ld... yes<br>checking for /usr/bin/ld option to reload object files... -r<br>checking for BSD-compatible nm... /usr/bin/nm -B<br>checking how to recognise dependent libraries... pass_all<br>checking how to run the C preprocessor... gcc -E<br>checking for ANSI C header files... yes<br>checking for sys/types.h... yes<br>checking for sys/stat.h... yes<br>checking for stdlib.h... yes<br>checking for string.h... yes<br>checking for memory.h... yes<br>checking for strings.h... yes<br>checking for inttypes.h... yes<br>checking for stdint.h... yes<br>checking for unistd.h... yes<br>checking dlfcn.h usability... yes<br>checking dlfcn.h presence... yes<br>checking for dlfcn.h... yes<br>checking how to run the C++ preprocessor... g++ -E<br>checking the maximum length of command line arguments... 32768<br>checking command to parse /usr/bin/nm -B output from gcc object... ok<br>checking for objdir... .libs<br>checking for ar... ar<br>checking for ranlib... ranlib<br>checking for strip... strip<br>checking if gcc supports -fno-rtti -fno-exceptions... no<br>checking for gcc option to produce PIC... -fPIC<br>checking if gcc PIC flag -fPIC works... yes<br>checking if gcc static flag -static works... yes<br>checking if gcc supports -c -o file.o... yes<br>checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes<br>checking whether -lc should be explicitly linked in... no<br>checking dynamic linker characteristics... cat: /etc/ld.so.conf.d/opl.conf: Permission denied<br>GNU/Linux ld.so<br>checking how to hardcode library paths into programs... immediate<br>checking whether stripping libraries is possible... yes<br>checking if libtool supports shared libraries... yes<br>checking whether to build shared libraries... yes<br>checking whether to build static libraries... no<br>configure: creating libtool<br>appending configuration tag "CXX" to libtool<br>checking for ld used by g++... /usr/bin/ld -m elf_x86_64<br>checking if the linker (/usr/bin/ld -m elf_x86_64) is GNU ld... yes<br>checking whether the g++ linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes<br>checking for g++ option to produce PIC... -fPIC<br>checking if g++ PIC flag -fPIC works... yes<br>checking if g++ static flag -static works... yes<br>checking if g++ supports -c -o file.o... yes<br>checking whether the g++ linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes<br>checking dynamic linker characteristics... cat: /etc/ld.so.conf.d/opl.conf: Permission denied<br>GNU/Linux ld.so<br>checking how to hardcode library paths into programs... immediate<br>appending configuration tag "F77" to libtool<br>checking if libtool supports shared libraries... yes<br>checking whether to build shared libraries... yes<br>checking whether to build static libraries... no<br>checking for gfortran option to produce PIC... -fPIC<br>checking if gfortran PIC flag -fPIC works... yes<br>checking if gfortran static flag -static works... yes<br>checking if gfortran supports -c -o file.o... yes<br>checking whether the gfortran linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes<br>checking dynamic linker characteristics... cat: /etc/ld.so.conf.d/opl.conf: Permission denied<br>GNU/Linux ld.so<br>checking how to hardcode library paths into programs... immediate<br>configure: Build is "x86_64-unknown-linux-gnu".<br>checking if library version is set... no<br>checking whether source of project Glpk is available and should be compiled... no<br>checking whether source of project SoPlex is available and should be compiled... no<br>checking whether source of project Blas is available and should be compiled... no<br>checking whether source of project Lapack is available and should be compiled... no<br>checking whether source of project Sample is available and should be compiled... no<br>checking whether source of project Netlib is available and should be compiled... no<br>checking whether source of project CoinUtils is available and should be compiled... no<br>checking whether source of project Osi is available and should be compiled... yes, source in Osi<br>configure: configuring doxygen documentation options<br>checking for doxygen... no<br>checking for latex... no<br>checking for dot... NO<br>checking for doxygen doc'n for CoinUtils ... NONE/share/coin/doc/CoinUtils/doxydoc (tag)<br>checking for doxygen doc'n for Cgl ... NONE/share/coin/doc/Cgl/doxydoc (tag)<br>checking for doxygen doc'n for Clp ... NONE/share/coin/doc/Clp/doxydoc (tag)<br>checking for doxygen doc'n for DyLP ... NONE/share/coin/doc/DyLP/doxydoc (tag)<br>checking for doxygen doc'n for Vol ... NONE/share/coin/doc/Vol/doxydoc (tag)<br>checking for doxygen doc'n for SYMPHONY ... NONE/share/coin/doc/SYMPHONY/doxydoc (tag)<br>checking which command should be used to link input files... ln -s<br>configure: creating ./config.status<br>config.status: creating Makefile<br>config.status: creating doxydoc/doxygen.conf<br>config.status: executing depfiles commands<br>configure: configuring in Osi<br>configure: running /bin/bash './configure' --prefix=/home/user/myosi/Osi  '--with-cplex-incdir=/usr/local/include/lazylpsolverlibs/ilcplex' '--with-cplex-lib=-L/usr/local/lib -llazycplex -pthread -Wl,--export-dynamic -lgmodule-2.0 -pthread -lglib-2.0' '--with-gurobi-incdir=/usr/local/include/lazylpsolverlibs' '--with-gurobi-lib=-L/usr/local/lib -llazygurobi -Wl,--export-dynamic -lgmodule-2.0 -pthread -lglib-2.0' '--with-xpress-incdir=/usr/local/include/lazylpsolverlibs' '--with-xpress-lib=-L/usr/local/lib -llazyxprs -Wl,--export-dynamic -lgmodule-2.0 -pthread -lglib-2.0' --cache-file=/dev/null --srcdir=.<br>checking build system type... x86_64-unknown-linux-gnu<br>checking for svnversion... no<br>checking whether we want to compile in debug mode... no<br>checking for gcc... gcc<br>checking for C compiler default output file name... a.out<br>checking whether the C compiler works... yes<br>checking whether we are cross compiling... no<br>checking for suffix of executables... <br>checking for suffix of object files... o<br>checking whether we are using the GNU C compiler... yes<br>checking whether gcc accepts -g... yes<br>checking for gcc option to accept ANSI C... none needed<br>configure: C compiler options are: -O3 -pipe -DNDEBUG -Wimplicit -Wparentheses -Wsequence-point -Wreturn-type -Wcast-qual -Wall -Wno-unknown-pragmas -Wno-long-long   -DOSI_BUILD<br>checking for g++... g++<br>checking whether we are using the GNU C++ compiler... yes<br>checking whether g++ accepts -g... yes<br>checking whether C++ compiler g++ works... yes<br>configure: C++ compiler options are: -O3 -pipe -DNDEBUG -Wparentheses -Wreturn-type -Wcast-qual -Wall -Wpointer-arith -Wwrite-strings -Wconversion -Wno-unknown-pragmas -Wno-long-long   -DOSI_BUILD<br>checking for egrep... grep -E<br>checking whether ln -s works... yes<br>checking for a BSD-compatible install... /usr/bin/install -c<br>checking whether build environment is sane... yes<br>checking for gawk... no<br>checking for mawk... mawk<br>checking whether make sets $(MAKE)... yes<br>checking for style of include used by make... GNU<br>checking dependency style of gcc... gcc3<br>checking dependency style of g++... gcc3<br>checking whether to enable maintainer-specific portions of Makefiles... no<br>configure: Using libtool script in directory ..<br>checking if library version is set... no<br>checking for pkg-config... pkg-config<br>checking pkg-config is at least version 0.16.0... yes<br>checking for COIN-OR package CoinUtils... yes: 2.10.14 <br>checking for COIN-OR package Glpk... not given: No package 'coinglpk' found<br>checking for COIN-OR package SoPlex... not given: No package 'coinsoplex' found<br>checking for COIN-OR package Sample... yes: 1.2.10 <br>checking for COIN-OR package Netlib... not given: No package 'coindatanetlib' found<br>checking if user provides library for Cplex... yes<br>checking whether symbol CPXgetstat is available with CPX... yes<br>checking if user provides library for Mosek... no<br>checking if user provides library for Xpress... yes<br>checking whether symbol XPRSinit is available with XPR... yes<br>checking if user provides library for Gurobi... yes<br>checking whether symbol GRBloadenv is available with GRB... yes<br>configure: configuring doxygen documentation options<br>checking for doxygen... no<br>checking for latex... no<br>checking for dot... NO<br>checking for doxygen doc'n for CoinUtils ... /home/user/myosi/Osi/share/coin/doc/CoinUtils/doxydoc (tag)<br>checking cmath usability... yes<br>checking cmath presence... yes<br>checking for cmath... yes<br>checking cfloat usability... yes<br>checking cfloat presence... yes<br>checking for cfloat... yes<br>checking cieeefp usability... no<br>checking cieeefp presence... no<br>checking for cieeefp... no<br>checking ieeefp.h usability... no<br>checking ieeefp.h presence... no<br>checking for ieeefp.h... no<br>checking which command should be used to link input files... ln -s<br>configure: creating ./config.status<br>config.status: creating Makefile<br>config.status: creating examples/Makefile<br>config.status: creating src/Osi/Makefile<br>config.status: creating src/OsiCpx/Makefile<br>config.status: creating src/OsiGlpk/Makefile<br>config.status: creating src/OsiMsk/Makefile<br>config.status: creating src/OsiXpr/Makefile<br>config.status: creating src/OsiGrb/Makefile<br>config.status: creating src/OsiSpx/Makefile<br>config.status: creating src/OsiCommonTest/Makefile<br>config.status: creating test/Makefile<br>config.status: creating osi.pc<br>config.status: creating osi-uninstalled.pc<br>config.status: creating osi-unittests.pc<br>config.status: creating osi-unittests-uninstalled.pc<br>config.status: creating osi-cplex.pc<br>config.status: creating osi-cplex-uninstalled.pc<br>config.status: creating osi-gurobi.pc<br>config.status: creating osi-gurobi-uninstalled.pc<br>config.status: creating osi-xpress.pc<br>config.status: creating osi-xpress-uninstalled.pc<br>config.status: creating doxydoc/doxygen.conf<br>config.status: creating src/Osi/config.h<br>config.status: src/Osi/config.h is unchanged<br>config.status: creating src/Osi/config_osi.h<br>config.status: src/Osi/config_osi.h is unchanged<br>config.status: executing depfiles commands<br>configure: In case of trouble, first consult the troubleshooting page at <a href="https://projects.coin-or.org/BuildTools/wiki/user-troubleshooting">https://projects.coin-or.org/BuildTools/wiki/user-troubleshooting</a><br>configure: Configuration of Osi successful<br>configure: In case of trouble, first consult the troubleshooting page at <a href="https://projects.coin-or.org/BuildTools/wiki/user-troubleshooting">https://projects.coin-or.org/BuildTools/wiki/user-troubleshooting</a><br>configure: Main configuration of Osi successful<br><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, Feb 16, 2019 at 7:24 AM Stefan Vigerske <<a href="mailto:stefan@math.hu-berlin.de">stefan@math.hu-berlin.de</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi,<br>
<br>
it looks like configure didn't see the flags to build against Cplex and <br>
then didn't build OsiCpx.<br>
<br>
Are you sure that you actually have the lazylpsolverlibs package installed?<br>
<br>
Have a look into the output of configure.<br>
<br>
It should be easier to first try building against CPLEX, etc, directly, <br>
without the lazylpsolverlibs in between.<br>
<br>
Stefan<br>
<br>
<br>
On 2/16/19 8:08 AM, T L wrote:<br>
>   Hi List members,<br>
> <br>
> I have a quick question about installing the coin-or OSI interface for<br>
> CPLEX.<br>
> <br>
> Following the OSI website <<a href="https://projects.coin-or.org/Osi" rel="noreferrer" target="_blank">https://projects.coin-or.org/Osi</a>>, I compiled it<br>
> from source (under Ubuntu 18.04) as follows:<br>
> <br>
> ./configure --with-cplex-incdir="$(pkg-config --variable=includedir<br>
> lazycplex)/lazylpsolverlibs/ilcplex" \<br>
>              --with-cplex-lib="$(pkg-config --libs lazycplex)" \<br>
>              --with-gurobi-incdir="$(pkg-config --variable=includedir<br>
> lazygurobi)/lazylpsolverlibs" \<br>
>              --with-gurobi-lib="$(pkg-config --libs lazygurobi)" \<br>
>              --with-xpress-incdir="$(pkg-config --variable=includedir<br>
> lazyxprs)/lazylpsolverlibs" \<br>
>              --with-xpress-lib="$(pkg-config --libs lazyxprs)"<br>
> make<br>
> make test<br>
> sudo make install<br>
> <br>
> But I cannot find the header file for CPLEX OsiCplexSolverInterface.hpp in<br>
> /usr/inclde/coin/, while other files such as<br>
> /usr/include/coin/OsiClpSolverInterface.hpp are present.<br>
> <br>
> However, it is inside the build folder as<br>
> include/coin/OsiCpxSolverInterface.hpp.<br>
> <br>
> Then when I try to compile example code for cplex, it gives an error about<br>
> missing OsiCpxSolverInterface.hpp<br>
> <br>
> Do I need to add options to ./configure to let make install it to system<br>
> folder?<br>
> <br>
> (I prefer to install in system folder, rather than individual users' home<br>
> folder; I've asked a question on StackOverflow:<br>
> <a href="https://stackoverflow.com/questions/54614995" rel="noreferrer" target="_blank">https://stackoverflow.com/questions/54614995</a>  but haven't got any answer so<br>
> far.)<br>
> <br>
> Thanks in advance,<br>
> <br>
> <br>
> _______________________________________________<br>
> Osi mailing list<br>
> <a href="mailto:Osi@list.coin-or.org" target="_blank">Osi@list.coin-or.org</a><br>
> <a href="https://list.coin-or.org/mailman/listinfo/osi" rel="noreferrer" target="_blank">https://list.coin-or.org/mailman/listinfo/osi</a><br>
> <br>
<br>
</blockquote></div>