made openssl use dynamic libraries on fedora

This commit is contained in:
Jerom Venneker
2025-05-22 22:58:28 +02:00
parent 513684d9a2
commit 0fa178ee40
3 changed files with 9 additions and 6 deletions

View File

@@ -303,7 +303,14 @@ if (BUILD_REMOTE_CONTROL)
set(SDL2-NET-INCLUDE ${SDL_NET_INCLUDE_DIRS})
endif()
set(OPENSSL_USE_STATIC_LIBS TRUE)
file(STRINGS /etc/os-release distro REGEX "^NAME=")
string(REGEX REPLACE "NAME=\"(.*)\"" "\\1" distro "${distro}")
if(${distro} MATCHES "Fedora Linux")
set(OPENSSL_USE_STATIC_LIBS OFF)
else()
set(OPENSSL_USE_STATIC_LIBS ON)
endif()
find_package(OpenSSL)
if(NOT OPENSSL_FOUND)
message(STATUS "OpenSSL not found (it's possible the version installed is too old). Disabling BUILD_REMOTE_CONTROL.")

View File

@@ -487,7 +487,7 @@ void Context::ParseArchipelagoItemsLocations(const std::vector<ArchipelagoClient
const std::string SlotName = ArchipelagoClient::GetInstance().GetSlotName();
// init the item table with regular items first
for(int rc = 1; rc <= RC_MAX; rc++) {
for(int rc = 1; rc < RC_MAX; rc++) {
// This may not even be needed
const RandomizerGet vanillaItem = StaticData::GetLocation(static_cast<RandomizerCheck>(rc))->GetVanillaItem();
itemLocationTable[rc].SetPlacedItem(vanillaItem);

View File

@@ -78,10 +78,6 @@ class StaticData {
static std::unordered_map<u32, RandomizerHint> grottoChestParamsToHint;
static std::array<HintText, RHT_MAX> hintTextTable;
static std::unordered_map<std::string_view, RandomizerGet> APitemToSoh;
static std::unordered_map<std::string_view, RandomizerCheck> APcheckToSoh;
static std::unordered_map<RandomizerCheck, std::string_view> SohCheckToAP;
static std::unordered_map<std::string_view, std::string_view> APsettingToHoSsetting;
StaticData();
~StaticData();
};