mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2026-03-24 06:51:37 +01:00
59 lines
2.0 KiB
Plaintext
59 lines
2.0 KiB
Plaintext
# Maintainer: Leon White <badfunkstripe@gmail.com>
|
|
pkgname=bazel8
|
|
pkgver=8.1.1
|
|
pkgrel=0
|
|
pkgdesc="Bazel is an open-source build and test tool"
|
|
url="https://bazel.build/"
|
|
arch="x86_64 aarch64"
|
|
license="Apache-2.0"
|
|
depends="bash openjdk21-jdk"
|
|
makedepends="linux-headers python3 unzip zip"
|
|
# Bazel binary is thin C++ client with zip file embedded into the binary,
|
|
# stripping breaks that: https://github.com/bazelbuild/bazel/issues/11842
|
|
options="!strip"
|
|
provides="bazel=$pkgver-r$pkgrel"
|
|
source="
|
|
https://github.com/bazelbuild/bazel/releases/download/$pkgver/bazel-$pkgver-dist.zip
|
|
bazel-$pkgver-archive.tar.gz::https://github.com/bazelbuild/bazel/archive/refs/tags/$pkgver.tar.gz
|
|
0001-off64t-fix.patch
|
|
"
|
|
builddir="$srcdir/"
|
|
|
|
build() {
|
|
EMBED_LABEL=$pkgver-$pkgrel \
|
|
EXTRA_BAZEL_ARGS=--tool_java_runtime_version=local_jdk \
|
|
./compile.sh
|
|
|
|
./output/bazel clean --expunge
|
|
}
|
|
|
|
check() {
|
|
ln -s bazel-$pkgver/examples examples
|
|
# shellcheck disable=SC2046
|
|
./output/bazel build $(\
|
|
./output/bazel query --noshow_progress '//examples/...' \
|
|
| grep -vF \
|
|
-e /android/ \
|
|
-e /windows/ \
|
|
-e :hello-error-prone \
|
|
)
|
|
./output/bazel test \
|
|
//examples/cpp:hello-success_test \
|
|
//examples/java-native/src/test/java/com/example/myproject:custom \
|
|
//examples/java-native/src/test/java/com/example/myproject:hello \
|
|
//examples/java-starlark/src/test/java/com/example/myproject:pass \
|
|
//examples/shell:test
|
|
|
|
./output/bazel clean --expunge
|
|
}
|
|
|
|
package() {
|
|
install -Dm 755 -t "$pkgdir/usr/bin" output/bazel
|
|
}
|
|
|
|
sha512sums="
|
|
a39d783ae402a3368b15d1380940414b81b710005f2fe4fef4d6cd0899f72096cd28772cb7bb7b400ca8bf108a56bc066d8a82a9d79b2db6f9d683ff04007c8a bazel-8.1.1-archive.tar.gz
|
|
5afb65531129f76abb8bec3928220918726325fa4f2f4b9972fc12b0b096eb937c2b4511ebcdbef5f8ded16c9fe6d0c7a73934fb7acd6b2192cfc1aa056b4366 bazel-8.1.1-dist.zip
|
|
48d1abf9366ae94208868838e129cc79b9f6d8395d2759a74fa2827155112f79545c0897a2b1289c7f081561089fe7f0e7660c14a877d936c5e9f5c39ecc1649 0001-off64t-fix.patch
|
|
"
|