From e3acf8917ba56eb4c398fffe8c5b41b0a87d3e35 Mon Sep 17 00:00:00 2001 From: Augustin Cavalier Date: Fri, 27 Aug 2021 13:50:07 -0400 Subject: [PATCH] Fix usage of Zstd build feature. We do not actually need a SetupFeatureObjcetsDir here, as this build feature is used unconditionally if it is available (unlike OpenSSL which is not, and which needs a feature objects directory.) It appears FeatureObjectsDir expects to be called unconditionally, i.e. in an "else" as well as "if", so this actually caused some build oddities. Additionally, since it is built unconditionally if available, we have to put it outside the "regular" checks in the PackageInfo so that it will be included in the images. This fixes booting @minimum images, which was apparently broken at some point when "zstd" was inadvertently removed. --- src/data/package_infos/generic/haiku | 6 +++--- src/kits/support/Jamfile | 1 - 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/data/package_infos/generic/haiku b/src/data/package_infos/generic/haiku index 8483512444..5dde375e2d 100644 --- a/src/data/package_infos/generic/haiku +++ b/src/data/package_infos/generic/haiku @@ -96,6 +96,9 @@ requires { #ifdef HAIKU_BUILD_FEATURE_%HAIKU_PACKAGING_ARCH%_zlib_ENABLED lib:libz #endif +#ifdef HAIKU_BUILD_FEATURE_%HAIKU_PACKAGING_ARCH%_zstd_ENABLED + lib:libzstd >= 1 +#endif #ifdef HAIKU_REGULAR_BUILD #ifdef HAIKU_BUILD_FEATURE_%HAIKU_PACKAGING_ARCH%_ffmpeg_ENABLED @@ -137,8 +140,5 @@ requires { #ifdef HAIKU_BUILD_FEATURE_%HAIKU_PACKAGING_ARCH%_libwebp_ENABLED lib:libwebp #endif -#ifdef HAIKU_BUILD_FEATURE_%HAIKU_PACKAGING_ARCH%_zstd_ENABLED - lib:libzstd >= 1 -#endif #endif } diff --git a/src/kits/support/Jamfile b/src/kits/support/Jamfile index afc40985da..4413a33645 100644 --- a/src/kits/support/Jamfile +++ b/src/kits/support/Jamfile @@ -19,7 +19,6 @@ for architectureObject in [ MultiArchSubDirSetup ] { UseBuildFeatureHeaders zstd ; Includes [ FGristFiles ZstdCompressionAlgorithm.cpp ] : [ BuildFeatureAttribute zstd : headers ] ; - SetupFeatureObjectsDir zstd ; } # BUrl uses ICU to perform IDNA conversions (unicode domain names)