summaryrefslogtreecommitdiff
path: root/pcr/icestorm-git/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'pcr/icestorm-git/PKGBUILD')
-rw-r--r--pcr/icestorm-git/PKGBUILD49
1 files changed, 49 insertions, 0 deletions
diff --git a/pcr/icestorm-git/PKGBUILD b/pcr/icestorm-git/PKGBUILD
new file mode 100644
index 000000000..7339c9c9d
--- /dev/null
+++ b/pcr/icestorm-git/PKGBUILD
@@ -0,0 +1,49 @@
+# Maintainer (AUR): Sebastian Bøe <sebastianbooe@gmail.com>
+# Maintainer: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
+# parabola changes and rationale:
+# - Added armv7h and i686 architectures support
+pkgname=icestorm-git
+pkgver=r726.9594931
+pkgrel=1
+pkgdesc="Lattice iCE40 FPGAs Bitstream Documentation (Reverse Engineered)"
+arch=('armv7h' 'i686' 'x86_64')
+url="http://www.clifford.at/icestorm/"
+license=('custom:ISC')
+depends=('python' 'libftdi-compat')
+makedepends=('git')
+provides=("${pkgname%-git}")
+conflicts=("${pkgname%-git}")
+source=('git+https://github.com/cliffordwolf/icestorm.git')
+md5sums=('SKIP')
+_prefix="/usr"
+
+pkgver() {
+ cd "$srcdir/${pkgname%-git}"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+build() {
+ cd "$srcdir/${pkgname%-git}"
+
+ # Icestorm defaults to clang. We prefer to use gcc because it is
+ # more widespread on Arch (gcc is in base-devel).
+ CXX=gcc
+
+ make \
+ CXX=$CXX \
+ PREFIX=$_prefix
+}
+
+package() {
+ cd "$srcdir/${pkgname%-git}"
+
+ # Move the license file into place
+ install -dm 755 "$pkgdir/usr/share/licenses/$pkgname"
+ install -m 644 README "$pkgdir/usr/share/licenses/$pkgname"
+
+ # Install the package
+ make \
+ DESTDIR="$pkgdir" \
+ PREFIX=$_prefix \
+ install
+}