summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorp4block2017-07-01 16:21:02 +0200
committerp4block2017-07-01 16:21:02 +0200
commitc2e2afb70b01aa0032714f3d4051b6890f0fcee3 (patch)
tree3f72a76a2cb15b82dcccdc321de3a5dc58d4468f /PKGBUILD
downloadaur-c2e2afb70b01aa0032714f3d4051b6890f0fcee3.tar.gz
initial commit
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD77
1 files changed, 77 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..6e78d0ac3485
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,77 @@
+# Maintainer: p4block
+# Contributor: Rowan Decker <rdecker@scu.edu>
+# Contributor: Eric Toombs <ee double you toombs at you waterloo dot see eh?>
+# Contributor: Afri 5chdn <aur@cach.co>
+# Contributor: Andy Weidenbaum <archbaum@gmail.com>
+
+pkgname=ethminer-ocl-git
+pkgver=0.11.0.0.20170701.7b678d8a4
+pkgrel=1
+pkgdesc="Ethereum GPU miner, with roots in Genoil's cpp-ethereum fork. Pure OpenCl version."
+arch=('i686' 'x86_64')
+depends=(
+ 'crypto++'
+ 'leveldb'
+ 'ocl-icd'
+)
+makedepends=(
+ 'gcc'
+ 'cmake'
+ 'git'
+ 'opencl-headers'
+)
+optdepends=(
+ 'solidity: The Solidity Contract-Oriented Programming Language'
+)
+groups=('ethereum')
+url="https://github.com/ethereum-mining/ethminer"
+license=('GPL')
+source=(
+ "$pkgname::git+https://github.com/ethereum-mining/ethminer.git"
+)
+sha256sums=('SKIP')
+provides=(
+ 'ethminer'
+)
+conflicts=(
+ 'ethereum'
+ 'cpp-ethereum'
+)
+replaces=(
+ 'ethereum-genoil-ocl-git'
+)
+
+pkgver() {
+ cd $pkgname
+ echo "`grep -m1 "PROJECT_VERSION" CMakeLists.txt | tr -cd '[[:digit:]].'`.`date +%Y%m%d`.`git log --pretty=format:%h -n 1`"
+}
+
+build() {
+ msg 'Updating...'
+ cd $pkgname
+ git submodule update --init --recursive
+
+ mkdir -p hunter
+
+ export HUNTER_ROOT=hunter
+
+ unset CFLAGS #march=native can break the build if set in makepkg.conf
+ unset CXXFLAGS
+
+ msg 'Building...'
+ mkdir -p build && pushd build
+ cmake .. -DCMAKE_INSTALL_PREFIX=/usr
+ cmake --build .
+ popd
+}
+
+package() {
+ cd $pkgname
+
+ msg 'Installing...'
+ make DESTDIR="$pkgdir" install -C build
+
+ msg 'Cleaning up pkgdir...'
+ find "$pkgdir" -type d -name .git -exec rm -r '{}' +
+ find "$pkgdir" -type f -name .gitignore -exec rm -r '{}' +
+}