# Maintainer: Max Meyer pkgname=local_pac pkgver=0.0.1 pkgrel=1 pkgdesc="local pacfile serving server" arch=(i686 x86_64) url="https://github.com/dg-vrnetze/${pkgname}" license=('MIT') depends=(ruby) makedepends=(rubygems filegen) source=(http://gems.rubyforge.org/gems/$pkgname-$pkgver.gem) noextract=($pkgname-$pkgver.gem) md5sums=() package() { cd "$srcdir" _library_dir=/usr/lib/${pkgname} _share_dir="${_library_dir}/gems/${pkgname}-${pkgver}/share" _systemd_dir=/usr/lib/systemd/system _bin_dir=/usr/bin install -d ${srcdir}/$_library_dir gem install --env-shebang --wrappers --no-ri --no-rdoc --install-dir ${srcdir}/${_library_dir} $pkgname SOFTWARE_BINARY=$_library_dir/gems/${pkgname}-${pkgver}/bin/${pkgname} SOFTWARE_LIB=/usr/lib/local_pac filegen ${_share_dir}/archlinux/startup.erb > ${srcdir}/${_bin_dir}/${pkgname} chmod a+x ${srcdir}/${_bin_dir}/${pkgname} rm -r ${srcdir}/${_library_dir}/cache install ${srcdir}/$_share_dir/systemd/${pkgname}.service ${srcdir}/$_systemd_dir install ${srcdir}/$_share_dir/systemd/${pkgname}.socket ${srcdir}/$_systemd_dir } # vim:set ts=2 sw=2 et: