summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD37
1 files changed, 37 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..17fb55892713
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,37 @@
+# Maintainer: Caltlgin Stsodaat <contact@fossdaily.xyz>
+
+pkgname='subjs'
+pkgver=1.0.1
+pkgrel=1
+pkgdesc='Fetches javascript file from a list of URLS or subdomains'
+arch=('x86_64')
+url='https://github.com/lc/subjs'
+license=('MIT')
+makedepends=('go')
+source=("${pkgname}-${pkgver}.tar.gz::${url}/archive/v${pkgver}.tar.gz")
+sha256sums=('a1772a7cc9a46befd4465616041ff52b3375033f0ec13c48212b776fea37aa24')
+
+prepare() {
+ export GOPATH="${srcdir}/gopath"
+ go clean -modcache
+}
+
+build() {
+ export CGO_CPPFLAGS="${CPPFLAGS}"
+ export CGO_CFLAGS="${CFLAGS}"
+ export CGO_CXXFLAGS="${CXXFLAGS}"
+ export CGO_LDFLAGS="${LDFLAGS}"
+ export GOFLAGS="-buildmode=pie -trimpath -ldflags=-linkmode=external -mod=readonly -modcacherw"
+
+ cd "${pkgname}-${pkgver}"
+ go build -v -o "${pkgname}" .
+}
+
+package() {
+ cd "${pkgname}-${pkgver}"
+ install -Dvm755 "${pkgname}" -t "${pkgdir}/usr/bin"
+ install -Dvm644 'README.md' -t "${pkgdir}/usr/share/doc/${pkgname}"
+ install -Dvm644 'LICENSE' -t "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+}
+
+# vim: ts=2 sw=2 et: