# Importada de Alpine aports por `hammer import-alpine` (Etapa G). PUNTO DE PARTIDA — pero # YA trae los parches de musl de Alpine (lo que un import de nix pierde). Pendiente: el # sha256 del tarball (el wrapper lo calcula), y adaptar build/install del shell de abuild. name = "iproute2" version = "7.1.0" license = "GPL-2.0-or-later" [source] tarball = "https://kernel.org/pub/linux/utils/net/iproute2/iproute2-7.1.0.tar.xz" # FIXME sha256: el wrapper lo calcula (Alpine publica sha512). sha512 de Alpine: # sha512 = "17052405c4d220da7a93a52b9c9ea01c9fa4a8889b5d4758cae86c8c97c78ed4011d74ea3153ea44c0dd632215961e6cd6e5f9e369acb19bec0a822d2eb844b8" sha256 = "fd9fa1b95809417157ca83dd72957e3261bdbce896353cb936f80af0b33a4b5c" [build] compiler = "zig-cc" target = "x86_64-linux-musl" link = "static" # Split de la info de depuración (SDD 23 etapa 4, tanda de HOJAS). Entra en `hash_inputs`. strip_debug = true flags = [] [build.phases] # de build() de Alpine (traducido; el lab provee $CBUILD/$CHOST — Etapa G Fase 3; revisá --shared para estático): compile = ''' _abuild_phase() { # iproute2 usa ./configure propio; autodetecta libmnl/libelf/libcap y las # desactiva si faltan. Sin netfilter/xtables (iptables no está en catálogo). ./configure || true make V=1 HAVE_MNL=n HAVE_ELF=n HAVE_CAP=n HAVE_SELINUX=n } _abuild_phase ''' # de package() de Alpine (traducido $pkgdir→/out): install = ''' _abuild_phase() { make DESTDIR="/out" install install -D -m644 include/libnetlink.h "/out"/usr/include/libnetlink.h install -D -m644 lib/libnetlink.a "/out"/usr/lib/libnetlink.a } _abuild_phase ''' [deps] build = ["binutils", "linux-headers", "bison", "flex", "make", "pkgconf"]