3.5 KiB
3.5 KiB
How the Butt package is built
Unlike a simple repack, Butt is compiled from source. This document explains the build process to guarantee transparency and reproducibility.
- Docker-First Environment (Recommended): To guarantee a perfect, reproducible build, the standard method is running the script inside a Docker container. The script is designed to automatically detect your host OS. If you are not on the exact target Ubuntu release (e.g., Ubuntu 22.04), it will automatically spawn a Docker container to perform the build. This ensures that
dpkg-shlibdepsgenerates the correct, expected dependencies without relying on your host's configuration. - Source Verification: The script downloads the official
.tar.gzfromdanielnoethen.de. - Compilation & Linking: The script runs
./configureandmake. It explicitly forces dynamic linking (LIBS=... -lporttime -lasound) so the resulting binary uses the system's shared libraries rather than bundling them. - AAC Exclusion: The script actively checks if
libfdk-aac-devis installed and aborts if it is, to prevent accidental inclusion. It also runsobjdump -pon the final binary to ensure nofdklibraries are linked. - Dependencies:
dpkg-shlibdepsis used inside the Docker container to generate the exactDepends:list required by the compiled binary for the target Ubuntu version. - Packaging & Checksums: Finally,
dpkg-debcreates the.debfile. Separate SHA256 checksums are generated for the source code (upstream_sha256_X.txt) and for the resulting package (SHA256SUMS_X.deb) to maintain a transparent verification chain.
Hogyan készül a Butt csomag (Magyar)
A Betterbirddel ellentétben a Butt forráskódból kerül lefordításra. Ez a dokumentum elmagyarázza a build folyamatot az átláthatóság és a reprodukálhatóság érdekében.
- Docker-alapú környezet (Javasolt): A tökéletes, reprodukálható build garantálása érdekében a szabványos módszer a script Docker konténerben való futtatása. A script felismeri a hoszt operációs rendszert. Ha nem a pontos cél Ubuntu kiadáson vagy (pl. Ubuntu 22.04), automatikusan indít egy Docker konténert a build elvégzéséhez. Ez biztosítja, hogy a
dpkg-shlibdepsa helyes, elvárt függőségeket generálja anélkül, hogy a hoszt beállításaira támaszkodna. - Forrás ellenőrzése: A script letölti a hivatalos
.tar.gzfájlt adanielnoethen.deoldalról. - Fordítás és linkelés: A script lefuttatja a
./configureés amakeparancsokat. Kifejezetten kikényszeríti a dinamikus linkelést (LIBS=... -lporttime -lasound), így a létrejövő bináris a rendszer megosztott könyvtárait használja, nem pedig beágyazza azokat. - AAC kizárása: A script aktívan ellenőrzi, hogy a
libfdk-aac-devtelepítve van-e, és ha igen, leáll, hogy megakadályozza a véletlen bekerülését. A végleges binárison lefuttatja azobjdump -pparancsot is, hogy megbizonyosodjon róla, nincsfdkkönyvtárhoz linkelve. - Függőségek: A
dpkg-shlibdepsa Docker konténeren belül generálja le a lefordított bináris által igényelt pontosDepends:listát a cél Ubuntu verzióhoz. - Csomagolás és ellenőrzőösszegek: Végül a
dpkg-deblétrehozza a.debfájlt. Külön SHA256 ellenőrzőösszegek generálódnak a forráskódhoz (upstream_sha256_X.txt) és a létrejött csomaghoz (SHA256SUMS_X.deb), hogy megmaradjon az átlátható ellenőrzési lánc.