internal/rosa/package: migrate ninja
All checks were successful
Test / Create distribution (push) Successful in 1m5s
Test / Sandbox (push) Successful in 2m45s
Test / ShareFS (push) Successful in 3m44s
Test / Hakurei (push) Successful in 3m53s
Test / Sandbox (race detector) (push) Successful in 5m22s
Test / Hakurei (race detector) (push) Successful in 6m33s
Test / Flake checks (push) Successful in 1m22s
All checks were successful
Test / Create distribution (push) Successful in 1m5s
Test / Sandbox (push) Successful in 2m45s
Test / ShareFS (push) Successful in 3m44s
Test / Hakurei (push) Successful in 3m53s
Test / Sandbox (race detector) (push) Successful in 5m22s
Test / Hakurei (race detector) (push) Successful in 6m33s
Test / Flake checks (push) Successful in 1m22s
The ninja package predates all abstractions currently available. This migration causes rebuilds due to the old package being nonreproducible. Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
@@ -6,7 +6,10 @@ import (
|
|||||||
"strings"
|
"strings"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _cmake = H("cmake")
|
var (
|
||||||
|
_cmake = H("cmake")
|
||||||
|
_ninja = H("ninja")
|
||||||
|
)
|
||||||
|
|
||||||
// CMakeHelper is the [CMake] build system helper.
|
// CMakeHelper is the [CMake] build system helper.
|
||||||
type CMakeHelper struct {
|
type CMakeHelper struct {
|
||||||
|
|||||||
@@ -1,52 +0,0 @@
|
|||||||
package rosa
|
|
||||||
|
|
||||||
import "hakurei.app/internal/pkg"
|
|
||||||
|
|
||||||
var _ninja = H("ninja")
|
|
||||||
|
|
||||||
func init() {
|
|
||||||
const (
|
|
||||||
version = "1.13.2"
|
|
||||||
checksum = "ygKWMa0YV2lWKiFro5hnL-vcKbc_-RACZuPu0Io8qDvgQlZ0dxv7hPNSFkt4214v"
|
|
||||||
)
|
|
||||||
meta := Metadata{
|
|
||||||
Name: "ninja",
|
|
||||||
Description: "a small build system with a focus on speed",
|
|
||||||
Website: "https://ninja-build.org",
|
|
||||||
Version: version,
|
|
||||||
|
|
||||||
ID: 2089,
|
|
||||||
}
|
|
||||||
native.MustRegister(meta.Name, func(t Toolchain) (*Metadata, pkg.Artifact) {
|
|
||||||
_, python := t.Load(_python)
|
|
||||||
_, bash := t.Load(_bash)
|
|
||||||
return &meta, t.New(meta.Name+"-"+version, 0, []pkg.Artifact{
|
|
||||||
python,
|
|
||||||
bash,
|
|
||||||
}, nil, nil, `
|
|
||||||
cd "$(mktemp -d)"
|
|
||||||
python3 /usr/src/ninja/configure.py \
|
|
||||||
--verbose \
|
|
||||||
--bootstrap \
|
|
||||||
--gtest-source-dir=/usr/src/googletest
|
|
||||||
./ninja `+jobsFlagE+` all
|
|
||||||
./ninja_test
|
|
||||||
|
|
||||||
mkdir -p /work/system/bin/
|
|
||||||
cp ninja /work/system/bin/
|
|
||||||
`, pkg.Path(AbsUsrSrc.Append("googletest"), false,
|
|
||||||
newFromGitHubRelease(
|
|
||||||
"google/googletest",
|
|
||||||
"v1.16.0",
|
|
||||||
"googletest-1.16.0.tar.gz",
|
|
||||||
"NjLGvSbgPy_B-y-o1hdanlzEzaYeStFcvFGxpYV3KYlhrWWFRcugYhM3ZMzOA9B_",
|
|
||||||
pkg.TarGzip,
|
|
||||||
)), pkg.Path(AbsUsrSrc.Append("ninja"), true, t.NewPatchedSource(
|
|
||||||
meta.Name+"-"+version, newFromGitHub(
|
|
||||||
"ninja-build/ninja",
|
|
||||||
"v"+version,
|
|
||||||
checksum,
|
|
||||||
), false,
|
|
||||||
)))
|
|
||||||
})
|
|
||||||
}
|
|
||||||
14
internal/rosa/package/googletest.az
Normal file
14
internal/rosa/package/googletest.az
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
package googletest {
|
||||||
|
description = "Google Testing and Mocking Framework";
|
||||||
|
exclude = true;
|
||||||
|
anitya = 18290;
|
||||||
|
|
||||||
|
version* = "1.16.0";
|
||||||
|
output = remoteGitHubRelease {
|
||||||
|
suffix = "google/googletest";
|
||||||
|
tag = "v"+version;
|
||||||
|
name = "googletest-"+version+".tar.gz";
|
||||||
|
checksum = "NjLGvSbgPy_B-y-o1hdanlzEzaYeStFcvFGxpYV3KYlhrWWFRcugYhM3ZMzOA9B_";
|
||||||
|
compress = gzip;
|
||||||
|
};
|
||||||
|
}
|
||||||
34
internal/rosa/package/ninja.az
Normal file
34
internal/rosa/package/ninja.az
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
package ninja {
|
||||||
|
description = "a small build system with a focus on speed";
|
||||||
|
website = "https://ninja-build.org";
|
||||||
|
anitya = 2089;
|
||||||
|
|
||||||
|
version* = "1.13.2";
|
||||||
|
source = remoteGitHub {
|
||||||
|
suffix = "ninja-build/ninja";
|
||||||
|
tag = "v"+version;
|
||||||
|
checksum = "ygKWMa0YV2lWKiFro5hnL-vcKbc_-RACZuPu0Io8qDvgQlZ0dxv7hPNSFkt4214v";
|
||||||
|
};
|
||||||
|
extra = [ googletest ];
|
||||||
|
|
||||||
|
exec = generic {
|
||||||
|
build = `
|
||||||
|
python3 /usr/src/ninja/configure.py \
|
||||||
|
--verbose \
|
||||||
|
--bootstrap
|
||||||
|
python3 /usr/src/ninja/configure.py \
|
||||||
|
--gtest-source-dir=/usr/src/extra/googletest
|
||||||
|
./ninja ` + jobsFlagE + ` all`;
|
||||||
|
|
||||||
|
check = "\n./ninja_test";
|
||||||
|
|
||||||
|
install = `
|
||||||
|
mkdir -p /work/system/bin/
|
||||||
|
cp ninja /work/system/bin/`;
|
||||||
|
};
|
||||||
|
|
||||||
|
inputs = [
|
||||||
|
python,
|
||||||
|
bash,
|
||||||
|
];
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user