From 0cb9094852092722bfd559935c1b4e95a94efb53 Mon Sep 17 00:00:00 2001 From: sergio Date: Thu, 25 Jun 2026 22:06:01 -0400 Subject: [PATCH] =?UTF-8?q?Etapa=20G:=20cola=20C=20=E2=80=94=20tig=20+=20w?= =?UTF-8?q?get=20est=C3=A1ticos=20(corpus=20279=E2=86=92281)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit tig 2.6.1 (ncurses+pcre2; -Wno-int-conversion por gcc15), wget 1.25.0 (openssl+zlib+pcre2). Ambos static-musl verificados (sin INTERP). GOTCHAS de la cola C (reusables): - NO pasar LDFLAGS=-L/usr/lib pelado: clobbea el LDFLAGS=-static del lab → binario dinámico. Usar LDFLAGS="-static -L/usr/lib". - nuestra zlib.a es non-PIC ⇒ linkear contra ella en un PIE falla (R_X86_64_32S vs zcalloc) ⇒ agregar -no-pie (estático no-pie es válido). [fix sistémico opcional: rebuildar zlib con -fPIC para toda la cola C] Co-Authored-By: Claude Opus 4.8 --- recipes/incoming/tig.toml | 47 -------------------------------------- recipes/incoming/wget.toml | 47 -------------------------------------- recipes/tig.toml | 17 ++++++++++++++ recipes/wget.toml | 22 ++++++++++++++++++ 4 files changed, 39 insertions(+), 94 deletions(-) delete mode 100644 recipes/incoming/tig.toml delete mode 100644 recipes/incoming/wget.toml create mode 100644 recipes/tig.toml create mode 100644 recipes/wget.toml diff --git a/recipes/incoming/tig.toml b/recipes/incoming/tig.toml deleted file mode 100644 index c412b783..00000000 --- a/recipes/incoming/tig.toml +++ /dev/null @@ -1,47 +0,0 @@ -# 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 = "tig" -version = "2.6.1" - -[source] -tarball = "https://github.com/jonas/tig/releases/download/tig-2.6.1/tig-2.6.1.tar.gz" -# FIXME sha256: el wrapper lo calcula (Alpine publica sha512). sha512 de Alpine: -# sha512 = "685fe0a5b6db87c3bab7914e47b43ad1c677f84ca1e86a0f9c9e6a86b5b338a9195901d2e07d9031f7cd6da241a238b000447e5e864d816a228847db63534c3e" -sha256 = "5adeabdcd93aa0423d618da8b878b53482bef6e0e9e1fe224acc0f18031fe91e" - -[build] -compiler = "zig-cc" -target = "x86_64-linux-musl" -link = "static" -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() { -CFLAGS="${CFLAGS//-Os/-O2} -flto=auto" \ - CXXFLAGS="${CXXFLAGS//-Os/-O2} -flto=auto" \ - ./configure \ - --build=$CBUILD \ - --host=$CHOST \ - --prefix=/usr \ - --sysconfdir=/etc \ - --mandir=/usr/share/man \ - --localstatedir=/var - make all -} -_abuild_phase -''' -# de package() de Alpine (traducido $pkgdir→/out): -install = ''' -_abuild_phase() { -make DESTDIR="/out" install install-doc-man -} -_abuild_phase -''' - -# depends de runtime de Alpine (NO build-deps): git - -[deps] -build = ["ncurses", "pcre2"] diff --git a/recipes/incoming/wget.toml b/recipes/incoming/wget.toml deleted file mode 100644 index 460bf5d5..00000000 --- a/recipes/incoming/wget.toml +++ /dev/null @@ -1,47 +0,0 @@ -# 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 = "wget" -version = "1.25.0" - -[source] -tarball = "https://ftp.gnu.org/gnu/wget/wget-1.25.0.tar.gz" -# FIXME sha256: el wrapper lo calcula (Alpine publica sha512). sha512 de Alpine: -# sha512 = "a7ce33c07a1a206a8574b6e9ea7cc5292315df0914edbcf05a014d35ae9e3d24699a46818b409b884ada57428cf30502f4bbb3767cae2c6934e4e7fb2d0c5036" -sha256 = "766e48423e79359ea31e41db9e5c289675947a7fcf2efdcedb726ac9d0da3784" - -[build] -compiler = "zig-cc" -target = "x86_64-linux-musl" -link = "static" -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() { -CFLAGS="$CFLAGS -flto=auto" \ - ./configure \ - --build=$CBUILD \ - --host=$CHOST \ - --prefix=/usr \ - --sysconfdir=/etc \ - --mandir=/usr/share/man \ - --infodir=/usr/share/info \ - --with-libidn \ - --with-ssl=openssl \ - --disable-nls - make -} -_abuild_phase -''' -# de package() de Alpine (traducido $pkgdir→/out): -install = ''' -_abuild_phase() { -make DESTDIR="/out" install -} -_abuild_phase -''' - -[deps] -build = ["libidn2", "openssl", "pcre2", "perl", "zlib"] diff --git a/recipes/tig.toml b/recipes/tig.toml new file mode 100644 index 00000000..c96d008f --- /dev/null +++ b/recipes/tig.toml @@ -0,0 +1,17 @@ +# tig 2.6.1 — interfaz ncurses para git (C). De-Alpinizada: gcc, configure-split, ncurses+pcre2. +name = "tig" +version = "2.6.1" +[source] +tarball = "https://github.com/jonas/tig/releases/download/tig-2.6.1/tig-2.6.1.tar.gz" +sha256 = "5adeabdcd93aa0423d618da8b878b53482bef6e0e9e1fe224acc0f18031fe91e" +[build] +compiler = "gcc" +target = "x86_64-linux-musl" +link = "static" +flags = [] +[build.phases] +configure = './configure --build=$CBUILD --host=$CHOST --prefix=/usr --sysconfdir=/etc CFLAGS="-O2 -Wno-int-conversion" CPPFLAGS=-I/usr/include LDFLAGS="-static -L/usr/lib"' +compile = 'make' +install = 'make DESTDIR=/out install' +[deps] +build = ["ncurses", "pcre2"] diff --git a/recipes/wget.toml b/recipes/wget.toml new file mode 100644 index 00000000..0b846a6d --- /dev/null +++ b/recipes/wget.toml @@ -0,0 +1,22 @@ +# wget 1.25.0 — descargador HTTP/FTP (C). De-Alpinizada: gcc, configure-split, TLS openssl + zlib, +# sin libidn (no en corpus). pcre2 para --regex. +name = "wget" +version = "1.25.0" +[source] +tarball = "https://ftp.gnu.org/gnu/wget/wget-1.25.0.tar.gz" +sha256 = "766e48423e79359ea31e41db9e5c289675947a7fcf2efdcedb726ac9d0da3784" +[build] +compiler = "gcc" +target = "x86_64-linux-musl" +link = "static" +flags = [] +[build.phases] +configure = ''' +./configure --build=$CBUILD --host=$CHOST --prefix=/usr --sysconfdir=/etc \ + --with-ssl=openssl --with-zlib --without-libidn --without-libpsl --disable-nls \ + CPPFLAGS=-I/usr/include LDFLAGS="-static -no-pie -L/usr/lib" +''' +compile = 'make' +install = 'make DESTDIR=/out install' +[deps] +build = ["openssl", "zlib", "pcre2"]