-
-
Save sukanka/e343a4dfcf5f3347861ae40a2ba28d9a to your computer and use it in GitHub Desktop.
# Maintainer: Michael Schubert <mschu.dev at gmail> | |
# Contributor: sukanka <su975853527 at gmail> | |
pkgname=augustus | |
_pkgname=Augustus | |
pkgver=3.5.0 | |
pkgrel=1 | |
pkgdesc="A eucaryotic gene prediction program" | |
arch=('i686' 'x86_64') | |
url="http://augustus.gobics.de/" | |
license=('custom:Artistic-2.0') | |
depends=('bamtools' 'boost-libs' 'gsl' 'mysql++' 'sqlite' 'python' 'lpsolve' 'perl' 'htslib') | |
makedepends=('boost' 'suitesparse' 'samtools' ) | |
source=($pkgname-$pkgver.tar.gz::https://github.com/Gaius-Augustus/Augustus/archive/v$pkgver.tar.gz) | |
sha256sums=('5ed6ce6106303b800c5e91d37a250baff43b20824657b853ae04d11ad8bdd686') | |
prepare() { | |
cd $_pkgname-$pkgver | |
sed -i "s|/usr/local/bin|/usr/bin|" Makefile | |
} | |
build() { | |
cd $_pkgname-$pkgver | |
make SAMTOOLS=/usr/include/bam PREFIX="$pkgdir"/usr INSTALLDIR=${pkgdir}/opt/augustus | |
} | |
package() { | |
cd $_pkgname-$pkgver | |
install -d ${pkgdir}/usr/bin | |
make DESTDIR="$pkgdir" PREFIX="$pkgdir"/usr INSTALLDIR=${pkgdir}/opt/augustus install | |
# fix broken links | |
for bin in {augustus,etraining,prepareAlign,fastBlockSearch} | |
do | |
ln -sf /opt/augustus/bin/${bin} "$pkgdir"/usr/bin/${bin} | |
done | |
rm "$pkgdir"/usr/bin/{load2db,getSeq} | |
# link utils, note: load2db,getSeq are prefixed with augustus in /usr/bin | |
for bin in {aln2wig,bam2hints,bam2wig,compileSpliceCands,filterBam,homGeneMapping,joingenes,load2sqlitedb,pp_simScore,load2db,getSeq} | |
do | |
ln -sf /opt/augustus/bin/${bin} "$pkgdir"/usr/bin/augustus-${bin} | |
done | |
install -Dm644 src/LICENSE.TXT "$pkgdir"/usr/share/licenses/augustus/LICENSE | |
} |
hi, thanks a lot for your efforts. this PKGBUILD was able to compile the package successfully. however, while integrating with braker pipeline following options creates issues
# link utils, note: load2db,getSeq are prefixed with augustus in /usr/bin for bin in {aln2wig,bam2hints,bam2wig,compileSpliceCands,filterBam,homGeneMapping,joingenes,load2sqlitedb,pp_simScore,load2db,getSeq} do ln -sf /opt/augustus/bin/${bin} "$pkgdir"/usr/bin/augustus-${bin} done
braker pipeline expects these tools without "augustus-" prefix. even if i alias them to upstream names in ~/.bashrc the braker scripts wouldn't work. right now i have to manually edit every script in braker pipeline to replace all instances aforementioned utils with "augustus-" prefix.
Is it possible to build packages without this?
Surely you can. I added this prefix as the names like load2db,getSeq
are too general.
You can remove the prefix in pkgbuild, but I recommend make scripts in braker use /opt/augustus/bin/
instead of /usr/bin
so you can call the excutables directly without prefix.
A workaround is to add
export PATH=/opt/augustus/bin:$PATH
in the scripts.
hi, thanks a lot for your efforts. this PKGBUILD was able to compile the package successfully. however, while integrating with braker pipeline following options creates issues
braker pipeline expects these tools without "augustus-" prefix. even if i alias them to upstream names in ~/.bashrc the braker scripts wouldn't work. right now i have to manually edit every script in braker pipeline to replace all instances aforementioned utils with "augustus-" prefix.
Is it possible to build packages without this?