void-packages/srcpkgs/cgminer/template
2013-12-25 10:39:21 +01:00

47 lines
1.5 KiB
Text

# Template file for 'cgminer'
pkgname=cgminer
version=3.9.0
revision=1
build_style=gnu-configure
configure_args="
--enable-bflsc --enable-bitforce --enable-icarus --enable-modminer
--enable-avalon --enable-klondike --enable-bitfury --enable-hashfast
--enable-bab --with-system-libusb"
hostmakedepends="pkg-config automake libtool yasm"
makedepends="libcurl-devel libusb-devel jansson-devel libudev-devel ncurses-devel"
short_desc="Multi-threaded multi-pool CPU and GPU miner for bitcoin"
maintainer="Juan RP <xtraeme@gmail.com>"
license="GPL-3"
homepage="https://github.com/ckolivas/cgminer"
distfiles="http://ck.kolivas.org/apps/cgminer/cgminer-${version}.tar.bz2"
checksum=f4a9af3e5e08919cfc9ca26628d63e7a3f8e986ebfa358b7316a79b1e8621790
pre_configure() {
# We have latest jansson and libusb - just use them
sed -e 's|^AC_CONFIG_SUBDIRS.*compat/jansson-2\.5.*||' \
-e 's|JANSSON_LIBS="compat/jansson-2\.5/src/\.libs/libjansson\.a"|JANSSON_LIBS=-ljansson|' \
-e 's|compat/Makefile||' \
-i configure.ac
sed -e 's|^JANSSON_CPPFLAGS= .*||' \
-e "s|^USBUTILS_CPPFLAGS = .*|USBUTILS_CPPFLAGS = -I${XBPS_CROSS_BASE}/usr/include/libusb-1.0|" \
-e 's|^SUBDIRS.*|SUBDIRS = lib ccan|' \
-i Makefile.am
rm -r compat
autoreconf -fi
}
post_install() {
vinstall example.conf 644 etc cgminer.conf
sed -i -e 's#/usr/local/bin#/usr/bin#g' ${DESTDIR}/etc/cgminer.conf
vinstall ${FILESDIR}/cgminer.service 644 usr/lib/systemd/system
}
cgminer_package() {
conf_files="/etc/cgminer.conf"
pkg_install() {
vmove all
}
}