scipopt / scip

SCIP - Solving Constraint Integer Programs
Other
369 stars 63 forks source link

Successful Compiling ARM64 Android via Termux #28

Closed defencedog closed 1 year ago

defencedog commented 1 year ago

Well I couldn't install ipopt as Android lacks fortran compilers & workarounds are beyond me. All were installed in /usr/local What i can install successfully are papilo. A bug is resolved as well

git clone https://github.com/scipopt/papilo.git
cd papilo 
https://github.com/scipopt/papilo/issues/20
export LDFLAGS="-llog" && cmake -DCMAKE_INSTALL_PREFIX=$PREFIX/local .. && make -j8 && make install

soplex was as well installed

git clone https://github.com/scipopt/soplex.git
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=$PREFIX/local -DPAPILO=on ..

zimpl was as well installed (very good small language). Its source was in the scioptsuite I couldn't find its separate git. On Android will throw error so link libm.so as following

cd scipoptsuite-8.0.1/zimpl/build
ln -s /apex/com.android.runtime/lib64/bionic/libm.so $PREFIX/lib/
cmake -DCMAKE_INSTALL_PREFIX=$PREFIX/local  .. && make -j8 && make install

Finally build scip (I didnt use scioptsuite tar ball except for zimpl)

cd scip-8.0.1
mkdir build && cd build
cmake -DCMAKE_INSTALL_PREFIX=$PREFIX/local -DIPOPT=off  ..
make -j8 && make install

Further notes while configuring scip, I had COIN-OR cpl installed in my system but still following gets reported, the documentation doesnt refer how to force-enable it -- Support CLP: OFF

scip -v
SCIP version 8.0.1 [precision: 8 byte] [memory: block] [mode: debug] [LP solver: Soplex 6.0.1.3] [GitHash: c84ee4283e]
Copyright (C) 2002-2022 Konrad-Zuse-Zentrum fuer Informationstechnik Berlin (ZIB)

External libraries:
  Readline 8.1         GNU library for command line editing (gnu.org/s/readline)
  Soplex 6.0.1.3       Linear Programming Solver developed at Zuse Institute Berlin (soplex.zib.de) [GitHash: 713be0fe]
  CppAD 20180000.0     Algorithmic Differentiation of C++ algorithms developed by B. Bell (github.com/coin-or/CppAD)
  ZLIB 1.2.12          General purpose compression library by J. Gailly and M. Adler (zlib.net)
  GMP 6.2.1            GNU Multiple Precision Arithmetic Library developed by T. Granlund (gmplib.org)
  ZIMPL 3.5.2          Zuse Institute Mathematical Programming Language developed by T. Koch (zimpl.zib.de)
  AMPL/MP 4e2d45c4     AMPL .nl file reader library (github.com/ampl/mp)
  PaPILO 2.1.1         parallel presolve for integer and linear optimization (github.com/scipopt/papilo) [GitHash: dea16d4]
  bliss 0.77           Computing Graph Automorphism Groups by T. Junttila and P. Kaski (www.tcs.hut.fi/Software/bliss/)

Compiler: clang 14.0.6

Build options:
 ARCH=aarch64
 OSTYPE=Android-4.19.113-24856341
 COMP=Clang 14.0.6
 BUILD=RelWithDebInfo
 DEBUGSOL=OFF
 EXPRINT=cppad
 SYM=bliss
 GMP=ON
 IPOPT=off
 WORHP=OFF
 LPS=spx
 LPSCHECK=OFF
 NOBLKBUFMEM=OFF
 NOBLKMEM=OFF
 NOBUFMEM=OFF
 THREADSAFE=ON
 READLINE=ON
 SANITIZE_ADDRESS=OFF
 SANITIZE_MEMORY=OFF
 SANITIZE_UNDEFINED=OFF
 SANITIZE_THREAD=OFF
 SHARED=ON
 VERSION=8.0.1.0
 API_VERSION=104
 ZIMPL=ON
 ZLIB=ON
fschloesser commented 1 year ago

SCIP can use several different lp solvers, by default, soplex is used. If you want to use clp as an lp solver, you have to set -DLPS=clp as option to the cmake call: https://scipopt.org/doc/html/md_INSTALL.php#CMAKE

defencedog commented 1 year ago

@fschloesser Can you tell which is superior?

svigerske commented 1 year ago

No one is superior :), but SCIP is better tested with SoPlex than with Clp.