# This file is part of BlackArch Linux ( https://www.blackarch.org/ ). # See COPYING for license details. pkgname=amass _pkgname=Amass pkgver=2025.72765f05 pkgrel=1 epoch=2 pkgdesc='In-depth subdomain enumeration written in Go.' arch=('x86_64' 'aarch64') groups=('blackarch' 'blackarch-scanner' 'blackarch-recon') url='https://github.com/OWASP/Amass' license=('Apache') makedepends=('git' 'go') source=('git+https://github.com/OWASP/Amass.git') sha512sums=('SKIP') pkgver() { cd $_pkgname echo $(git rev-list --count HEAD).$(git rev-parse --short HEAD) } build() { cd $_pkgname GOPATH="$srcdir" go mod download GOPATH="$srcdir" go build \ -trimpath \ -buildmode=pie \ -mod=readonly \ -modcacherw \ -ldflags "-s -w" \ -o $pkgname ./cmd/... } package() { cd $_pkgname install -dm 755 "$pkgdir/usr/share/$pkgname" install -Dm 755 $pkgname "$pkgdir/usr/bin/$pkgname" cp -a --no-preserve=ownership examples "$pkgdir/usr/share/$pkgname" mv "$pkgdir/usr/share/$pkgname/examples/wordlists" "$pkgdir/usr/share/$pkgname" chmod 644 "$pkgdir/usr/share/$pkgname/"{wordlists/*,examples/*} }