From 79d1927d637812b91bfc5ac45b5459fdaec1c10d Mon Sep 17 00:00:00 2001 From: xbzk Date: Sat, 26 Sep 2026 11:06:52 -0300 Subject: [PATCH] [loader] external zbic + code tweaks --- cpmfile.json | 5 +++++ externals/CMakeLists.txt | 6 +++--- src/common/CMakeLists.txt | 2 +- src/common/zbic_compression.cpp | 2 +- 4 files changed, 10 insertions(+), 5 deletions(-) diff --git a/cpmfile.json b/cpmfile.json index 2ab195d60b..b6dd5771be 100644 --- a/cpmfile.json +++ b/cpmfile.json @@ -338,6 +338,11 @@ "repo": "herumi/xbyak", "version": "v7.40.1" }, + "zbic": { + "hash": "fbe2f37986377d7f0d96ae3224c80b5971df6e8b6961f68061f1975ebb2e8cb78f07b90f014b007be4023dbf5513581504e7f7d61a5237cb2a8a7a61ae11e482", + "repo": "kinnay/zbic", + "version": "11b08f2712264bbed731545085cbd9702096ceb7" + }, "zlib": { "hash": "16fea4df307a68cf0035858abe2fd550250618a97590e202037acd18a666f57afc10f8836cbbd472d54a0e76539d0e558cb26f059d53de52ff90634bbf4f47d4", "min_version": "1.2", diff --git a/externals/CMakeLists.txt b/externals/CMakeLists.txt index 1c88a86c4d..cb1deceb96 100644 --- a/externals/CMakeLists.txt +++ b/externals/CMakeLists.txt @@ -48,9 +48,9 @@ if (NOT TARGET stb::headers) add_library(stb::headers ALIAS stb) endif() -AddJsonPackage(NAME atmosphere_zstd_bic DOWNLOAD_ONLY) -set(ATMOSPHERE_ZSTD_BIC_INCLUDE_DIR - "${atmosphere_zstd_bic_SOURCE_DIR}/libraries/libstratosphere/source/util" +AddJsonPackage(NAME zbic DOWNLOAD_ONLY) +set(ZBIC_INCLUDE_DIR + "${zbic_SOURCE_DIR}/src" PARENT_SCOPE) # ItaniumDemangle (Windows only) diff --git a/src/common/CMakeLists.txt b/src/common/CMakeLists.txt index c1bc77ed62..ff2bd3e504 100644 --- a/src/common/CMakeLists.txt +++ b/src/common/CMakeLists.txt @@ -150,7 +150,7 @@ add_library( container/unordered_map.h container/unordered_set.h) set_source_files_properties(zbic_compression.cpp PROPERTIES - INCLUDE_DIRECTORIES "${ATMOSPHERE_ZSTD_BIC_INCLUDE_DIR}" + INCLUDE_DIRECTORIES "${ZBIC_INCLUDE_DIR}" COMPILE_OPTIONS "$<$:-Wno-unused-function>") if(WIN32) diff --git a/src/common/zbic_compression.cpp b/src/common/zbic_compression.cpp index 3155c00f44..0ce7594d44 100644 --- a/src/common/zbic_compression.cpp +++ b/src/common/zbic_compression.cpp @@ -13,7 +13,7 @@ #undef ZSTD_MULTITHREAD #include "zstd.h" -#include "zstd.inc" +#include "zstd.c" namespace Common::Compression {