summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorDimitris Kiziridis2020-05-20 11:37:31 +0300
committerDimitris Kiziridis2020-05-20 11:37:31 +0300
commitd5cfa2485beffd0fc8e69e3c59ead499899753ae (patch)
tree262f61ffc2471cdd579ae9284b2d72a1e459a34e
parentcd850fef5a1aef8ebacba095ad2089f78cdcd46d (diff)
downloadaur-d5cfa2485beffd0fc8e69e3c59ead499899753ae.tar.gz
update pkgbuild, go-pie replaced
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD20
2 files changed, 11 insertions, 11 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 8e66f482b470..084172f47274 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -5,7 +5,7 @@ pkgbase = simplehttp-git
url = https://github.com/snwfdhmp/simplehttp
arch = x86_64
license = Apache
- makedepends = go-pie
+ makedepends = go
makedepends = git
depends = glibc
provides = simplehttp
diff --git a/PKGBUILD b/PKGBUILD
index ea8bc0fddc27..b50fd5b5e7e7 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -9,7 +9,7 @@ url='https://github.com/snwfdhmp/simplehttp'
license=('Apache')
provides=('simplehttp')
depends=('glibc')
-makedepends=('go-pie' 'git')
+makedepends=('go' 'git')
source=("git+${url}")
sha256sums=('SKIP')
@@ -20,21 +20,21 @@ pkgver() {
prepare() {
cd "${srcdir}/simplehttp"
- mkdir -p $srcdir/go
- export GOPATH="${srcdir}"/go
- export PATH=$PATH:$GOPATH/bin
- go get -d -v ./...
+ mkdir -p build/
}
build() {
- export GOPATH="${srcdir}"/go
- export PATH=$PATH:$GOPATH/bin
cd "${srcdir}/simplehttp"
- go build -v -o "${srcdir}/simplehttp-bin"
+ export CGO_LDFLAGS="${LDFLAGS}"
+ export CGO_CFLAGS="${CFLAGS}"
+ export CGO_CPPFLAGS="${CPPFLAGS}"
+ export CGO_CXXFLAGS="${CXXFLAGS}"
+ export GOFLAGS="-buildmode=pie -trimpath -modcacherw"
+ go get -d -v ./...
+ go build -o build ./...
}
package() {
cd "${srcdir}/simplehttp"
- install -Dm755 "${srcdir}"/simplehttp-bin "${pkgdir}/usr/bin/simplehttp"
- go clean -modcache #Remove go libraries
+ install -Dm755 build/simplehttp "${pkgdir}/usr/bin/simplehttp"
} \ No newline at end of file