Merge branch 'poudriere_build_static'

This commit is contained in:
Tom Alexander 2023-09-01 11:16:59 -04:00
commit 0f054f819f
Signed by: talexander
GPG Key ID: D3A179C9A53C0EDE
3 changed files with 29 additions and 8 deletions

View File

@ -1,3 +0,0 @@
KERNCONF=CUSTOM
BUILD_STATIC=YES

View File

@ -1,15 +1,29 @@
{% if cpu_opt is defined and cpu_opt %}
CPUTYPE?={{ cpu_opt }}
{% endif %}
OPTIMIZED_CFLAGS=YES
BUILD_OPTIMIZED=YES
WITH_CPUFLAGS=YES
KERNCONF=CUSTOM
WITH_MALLOC_PRODUCTION=YES
WITHOUT_LLVM_ASSERTIONS=YES
WITH_REPRODUCIBLE_BUILD=YES
PORTS_MODULES+=graphics/drm-510-kmod
NO_SHARED=YES
# Would be fun to experiment with:
# WITHOUT_SOURCELESS=YES
# WITHOUT_SHARED_TOOLCHAIN=YES
# WITHOUT_GAMES=YES
# WITHOUT_KERBEROS=YES
# WITHOUT_LEGACY_CONSOLE=YES
# WITHOUT_LIB32=YES
# WITHOUT_LOADER_GELI=YES
# WITHOUT_MLX5TOOL=YES
# WITHOUT_NDIS=YES
# WITHOUT_OFED=YES
# WITHOUT_PPP=YES
# WITH_SORT_THREADS=YES
# WITHOUT_TALK=YES
# WITHOUT_TCSH=YES
# Questionable Optimizations
WITHOUT_FLOPPY=YES
@ -19,4 +33,3 @@ WITHOUT_IPFILTER=YES
WITHOUT_LLVM_TARGET_ALL=YES
# Commented out because maybe I want email alerts for failing disks
# WITHOUT_MAIL=YES
# WITHOUT_SENDMAIL=YES

View File

@ -10,4 +10,15 @@ CPUTYPE?=tigerlake
OPTIMIZED_CFLAGS=YES
BUILD_OPTIMIZED=YES
WITH_CPUFLAGS=YES
BUILD_STATIC=YES
# Disable static for subversion because /usr/local/lib/libutf8proc.a not found despite utf8proc being installed
#
# Disable static for netpbm because "ld: error: undefined symbol: libdeflate_free_compressor" which is "referenced by tif_zip.o:(ZIPVSetField) in archive /usr/local/lib/libtiff.a"
#
# Disable static for libsndfile because pulseaudio and libsamplerate fails to find libsndfile.so
#
# Disable static for firefox because "ld: error: /wrkdirs/usr/ports/www/firefox/work/.build/x86_64-unknown-freebsd/release/libgkrust.a(gkrust_shared-8ce2324940b7b6ec.gkrust_shared.45f3776c712ef4bb-cgu.0.rcgu.o): Unknown attribute kind (86) (Producer: 'LLVM16.0.5-rust-1.71.0-stable' Reader: 'LLVM 13.0.1')"
#
# Disable static for zsh because histdb is throwing "failed to load module: zsh/regex" and "-regex-match not available for regex"
.if ${.CURDIR:N*/devel/subversion*} && ${.CURDIR:N*/graphics/netpbm*} && ${.CURDIR:N*/audio/libsndfile*} && ${.CURDIR:N*/www/firefox*} && ${.CURDIR:N*/shells/zsh*}
OPTIONS_SET+=STATIC LTO
.endif