void-packages/srcpkgs/kaitai-struct-compiler/template

27 lines
804 B
Bash

# Template file for 'kaitai-struct-compiler'
pkgname=kaitai-struct-compiler
version=0.8
revision=1
archs=noarch
hostmakedepends="unzip"
depends="virtual?java-environment"
short_desc="Compiler for the Kaitai declarative binary format parsing language"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
license="GPL-3"
homepage="http://kaitai.io"
distfiles="https://bintray.com/kaitai-io/universal/download_file?file_path=${version}%2F${pkgname}-${version}.zip"
checksum=545fc10e134db2901cad8817be1b440fca6f2bad8b92b2948ebe0647f3ffa2c9
pre_install() {
# patch libdir
sed -i 's|lib_dir=.*|lib_dir="/usr/share/java/kaitai-struct-compiler"|g' bin/$pkgname
}
do_install() {
for lib in lib/*.jar; do
vinstall $lib 644 usr/share/java/$pkgname
done
vbin bin/$pkgname
ln -s $pkgname $DESTDIR/usr/bin/ksc
}