%global lockver 1 %global pkgvers 0 %global scdate0 20221121 %global schash0 1929dc28685a3dd31944f759514cd0b6d7bc0654 %global branch0 master %global source0 https://github.com/scipopt/scip %global sshort0 %{expand:%%{lua:print(('%{schash0}'):sub(1,8))}} Name: scip Version: 802 Release: %{scdate0}.%{pkgvers}.git%{sshort0}%{?dist} Summary: Solving Constraint Integer Programs License: Apache v2.0 URL: https://scipopt.org BuildRequires: git gcc-c++ cmake BuildRequires: zlib-devel readline-devel gmp-devel BuildRequires: bliss-devel coin-or-Clp-devel %if 0%{?fedora} BuildRequires: coin-or-Ipopt-devel %endif %global __cmake_in_source_build 1 %description One of the fastest academically developed solvers for mixed integer programming (MIP) and mixed integer nonlinear programming (MINLP). %package devel Summary: Development files for %{name} Requires: %{name} = %{version}-%{release} %description devel This package contains development files for %{name} %prep %setup -T -c -n %{name} git clone --depth 1 -n -b %{branch0} %{source0} . git fetch --depth 1 origin %{schash0} git reset --hard %{schash0} git log --format=fuller # fix install path sed -i 's|DESTINATION lib|DESTINATION %{_lib}|g' src/CMakeLists.txt # external bliss rm -rf src/bliss/* echo "" > src/bliss/CMakeLists.txt sed -i 's| libbliss| bliss|' CMakeLists.txt sed -i 's|export(TARGETS scip libscip ${BLISS_TARGET}|export(TARGETS scip libscip|' src/CMakeLists.txt %build mkdir build pushd build %global optflags %(echo "%{optflags}" -fPIC) %cmake .. \ -DCMAKE_SKIP_RPATH=ON \ -DCMAKE_VERBOSE_MAKEFILE=OFF \ -DCMAKE_BUILD_TYPE=RelWithDebInfo \ -DAUTOBUILD=ON \ -DTPI=tny \ -DLPS=clp \ -DSYM=bliss %cmake_build popd %install pushd build %cmake_install popd %files %license LICENSE %doc README.md %doc doc examples %{_bindir}/* %{_libdir}/*.so.* %files devel %{_includedir}/* %{_libdir}/*.so %{_libdir}/cmake/* %changelog * Sat Jul 25 2020 Cristian Balint - github upstream releases