Date: Tuesday, February 21, 2023 @ 19:11:53
Author: jelle
Revision: 1403287
archrelease: copy trunk to community-x86_64
Added:
esbuild/repos/community-x86_64/
esbuild/repos/community-x86_64/PKGBUILD
(from rev 1403286, esbuild/trunk/PKGBUILD)
----------+
PKGBUILD | 38 ++++++++++++++++++++++++++++++++++++++
1 file changed, 38 insertions(+)
Copied: esbuild/repos/community-x86_64/PKGBUILD (from rev 1403286,
esbuild/trunk/PKGBUILD)
===================================================================
--- community-x86_64/PKGBUILD (rev 0)
+++ community-x86_64/PKGBUILD 2023-02-21 19:11:53 UTC (rev 1403287)
@@ -0,0 +1,38 @@
+# Maintainer: Jelle van der Waa <[email protected]>
+# Contributor: Daniel Milde <[email protected]>
+# Contributor: George Rawlinson <[email protected]>
+
+pkgname=esbuild
+pkgver=0.17.10
+pkgrel=1
+pkgdesc="An extremely fast JavaScript and CSS bundler and minifier."
+arch=('x86_64')
+url="https://esbuild.github.io/"
+license=('MIT')
+depends=(glibc)
+makedepends=(go)
+source=("${pkgname}-${pkgver}.tar.gz::https://github.com/evanw/${pkgname}/archive/v${pkgver}.tar.gz")
+sha512sums=('84780215c3839d6ac9bcf88a1f90b603b33f89543c058b4318725790742da9ea8921336d8f58ce6dfc29dec674d4c953332f5a37c158f91ce8ad4a694b44a1da')
+
+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"
+
+build() {
+ cd "${pkgname}-${pkgver}"
+ go build \
+ -trimpath \
+ -buildmode=pie \
+ -mod=readonly \
+ -modcacherw \
+ -ldflags "-linkmode external -extldflags \"${LDFLAGS}\"" \
+ ./cmd/esbuild
+}
+
+package() {
+ cd "${pkgname}-${pkgver}"
+ install -Dm755 "${pkgname}" "${pkgdir}/usr/bin/${pkgname}"
+ install -Dm644 -t "${pkgdir}/usr/share/licenses/${pkgname}" "LICENSE.md"
+}