void-packages/srcpkgs/lpsolve/template
Jürgen Buchmüller 990bc8b60c lpsolve: unbreak build
-DNOISNAN results in errors for x86_64 and i686
2016-02-28 16:39:01 +01:00

46 lines
1 KiB
Bash

# Template file for 'lpsolve'
pkgname=lpsolve
version=5.5.2.0
revision=3
wrksrc=lp_solve_${version%.*.*}
short_desc="Mixed Integer Linear Programming (MILP) solver"
maintainer="Enno Boland <gottox@voidlinux.eu>"
license="GPL"
homepage="http://sourceforge.net/projects/lpsolve"
distfiles="${SOURCEFORGE_SITE}/$pkgname/lp_solve_${version}_source.tar.gz"
checksum=5827a30b143105283f398a09419ea608719a2d7699ecea165a66d521803bcc9c
do_configure() {
sed -i \
-e 's/^c=cc/c="$CC"/' \
-e 's/^opts=.*/opts="$CFLAGS"/' \
-e 's/^PLATFORM=.*/PLATFORM=/' \
-e 's/-DNOISNAN//' \
lp_solve/ccc lpsolve55/ccc
}
do_build() {
cd lpsolve55
sh -x ccc
cd ../lp_solve
sh -x ccc
cd ..
}
do_install() {
vmkdir usr/bin
vmkdir usr/lib
vmkdir usr/include/lpsolve
vinstall lp_solve/bin/lp_solve 755 usr/bin/
vinstall lpsolve55/bin/liblpsolve55.so 755 usr/lib/
vcopy lp*.h usr/include/lpsolve/
}
lpsolve-devel_package() {
depends="lpsolve>=${version}_${revision}"
short_desc+=" - development files"
pkg_install() {
vmove usr/include
}
}