void-packages/srcpkgs/picosat/template

51 lines
1.2 KiB
Bash

# Template file for 'picosat'
pkgname=picosat
version=965
revision=2
build_style=configure
configure_script="./configure.sh"
configure_args="--shared --static"
short_desc="Satisfiability (SAT) solver for boolean variables"
maintainer="Duncaen <duncaen@voidlinux.org>"
license="MIT"
homepage="http://fmv.jku.at/picosat/"
changelog="http://fmv.jku.at/picosat/NEWS"
distfiles="http://fmv.jku.at/picosat/picosat-${version}.tar.gz"
checksum=15169b4f28ba8f628f353f6f75a100845cdef4a2244f101a02b6e5a26e46a754
CFLAGS=-DTRACE
post_extract() {
# fix parallel builds
vsed -i -e 's/-l\(picosat\)/-l:lib\1.a/g' makefile.in
# include breaks musl build and is not necessary for getrusage(2)
vsed -i -e '/sys\/unistd.h/d' picosat.c
}
do_install() {
vbin picogcnf
vbin picomcs
vbin picomus
vbin picosat
vinstall libpicosat.a 644 /usr/lib
vinstall libpicosat.so 755 /usr/lib
vinstall picosat.h 644 /usr/include
vlicense LICENSE
}
libpicosat_package() {
short_desc+=" - runtime library"
pkg_install() {
vmove "usr/lib/*.so"
}
}
picosat-devel_package() {
short_desc+=" - development files"
depends="libpicosat>=${version}_${revision}"
pkg_install() {
vmove usr/include
vmove "usr/lib/*.a"
}
}