mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2026-04-08 15:21:51 +02:00
79 lines
2.4 KiB
Plaintext
79 lines
2.4 KiB
Plaintext
# Maintainer: Hoang Nguyen <folliekazetani@protonmail.com>
|
|
pkgname=please-build
|
|
pkgver=17.3.1
|
|
pkgrel=0
|
|
pkgdesc="High-performance, extensible build system for reproducible multi-language builds"
|
|
url="https://please.build/"
|
|
# The only architectures supported upstream
|
|
arch="x86_64 aarch64"
|
|
license="Apache-2.0"
|
|
makedepends="go bash"
|
|
subpackages="
|
|
$pkgname-tools
|
|
$pkgname-bash-completion
|
|
$pkgname-zsh-completion
|
|
"
|
|
source="
|
|
$pkgname-$pkgver.tar.gz::https://github.com/thought-machine/please/archive/refs/tags/v$pkgver.tar.gz
|
|
fix-test.patch
|
|
"
|
|
builddir="$srcdir/please-$pkgver"
|
|
|
|
export GOCACHE="${GOCACHE:-"$srcdir/go-cache"}"
|
|
export GOTMPDIR="${GOTMPDIR:-"$srcdir"}"
|
|
export GOMODCACHE="${GOMODCACHE:-"$srcdir/go"}"
|
|
|
|
build() {
|
|
local _buildargs="--plain_output --noupdate --profile=alpine"
|
|
go run src/please.go build $_buildargs //src:please
|
|
|
|
./plz-out/bin/src/please build $_buildargs \
|
|
//tools/sandbox:please_sandbox \
|
|
//tools/please_shim:please_shim \
|
|
//tools/build_langserver:build_langserver
|
|
|
|
./plz-out/bin/src/please --completion_script > plz.bash
|
|
}
|
|
|
|
check() {
|
|
# The test has an input only for x86_64 target.
|
|
rm -r test/config_rules
|
|
|
|
# python3: vendored 'please_pex' binary doesn't run on musl.
|
|
# Also, it can't be built from source due to dependency cycling.
|
|
# clang:
|
|
# - 16: hardcode -fmodules-ts in cc-rules plugin
|
|
# - 15: undefined reference to 'initializer for module q1'
|
|
./plz-out/bin/src/please test \
|
|
--plain_output --noupdate --profile=alpine \
|
|
--exclude=python3 --exclude=clang --exclude=e2e
|
|
}
|
|
|
|
package() {
|
|
install -Dm755 plz-out/bin/src/please "$pkgdir"/usr/bin/plz
|
|
|
|
install -Dm755 -t "$pkgdir"/usr/bin/ \
|
|
plz-out/bin/tools/build_langserver/build_langserver \
|
|
plz-out/bin/tools/sandbox/please_sandbox \
|
|
plz-out/bin/tools/please_shim/please_shim
|
|
|
|
install -Dm644 plz.bash \
|
|
"$pkgdir"/usr/share/bash-completion/completions/plz
|
|
install -Dm644 plz.bash \
|
|
"$pkgdir"/usr/share/zsh/site-functions/_plz
|
|
}
|
|
|
|
tools() {
|
|
pkgdesc="External utilities for Please build system"
|
|
|
|
amove \
|
|
usr/bin/build_langserver \
|
|
usr/bin/please_sandbox \
|
|
usr/bin/please_shim
|
|
}
|
|
|
|
sha512sums="
|
|
9d94dbc65f17c29456444308706faa394ec7608f8237f09f4ca556934bbd18e820f0916aa3fdc5845f9da7780142a55df4308c998e5e70e480a93e597d56140f please-build-17.3.1.tar.gz
|
|
e628c001a45daacfa19eacb99b79b51bc2d8ba4957a1fa56da6d524c553bfef9422fe54c0551403b675c761367627312579cafdaf0944c7122d3b2ba9edc3719 fix-test.patch
|
|
"
|