33 lines
1.3 KiB
TOML
33 lines
1.3 KiB
TOML
# DIFERIDA (frontera): go.mod `go 1.16`; bumpear a 1.17+ activa module-graph-pruning ⇒ exige `go mod tidy` (red, no offline). Fix real: en fetch `go mod edit -go=1.17 && go mod tidy && vendor` (cuidado reproducibilidad).
|
|
# Importada de nixpkgs por `hammer import-nix` (Etapa G). PUNTO DE PARTIDA, no final:
|
|
# - el build usa el lab de hammer (zig-cc / musl estático), NO el stdenv de nix ⇒ revisá
|
|
# compiler/link/phases y adaptá hasta que compile.
|
|
# - las deps van con su nombre NIX; remapealas a las recetas del corpus si difieren.
|
|
name = "gotop"
|
|
version = "4.2.0"
|
|
|
|
[source]
|
|
repo = "https://github.com/xxxserxxx/gotop"
|
|
commit = "f590a56842e30e61949c23fab30fb10bf76e1410"
|
|
|
|
[build]
|
|
compiler = "zig-cc"
|
|
target = "x86_64-linux-musl"
|
|
link = "static"
|
|
flags = []
|
|
|
|
# buildInputs de nix (no usados con CGO off): go
|
|
[deps]
|
|
build = ["go"]
|
|
|
|
[build.phases]
|
|
# go.mod declara `go 1.16` pero x/sys vendoreado usa unsafe.Slice (go1.17). Bump del lang in-situ
|
|
# (no toca deps) antes del compile estándar del lab.
|
|
compile = '''
|
|
go mod edit -go=1.21
|
|
export GOCACHE=/src/.gocache GOTMPDIR=/src/.gotmp GOPATH=/tmp/gopath GOTOOLCHAIN=local CGO_ENABLED=0 GOFLAGS=-mod=vendor GOPROXY=off GOBIN=/out/usr/bin
|
|
mkdir -p /src/.gotmp
|
|
go install -trimpath -ldflags=-buildid= .
|
|
'''
|
|
install = "true"
|