arma3-unix-launcher: 413-unstable-2025-02-10 -> 420

This commit is contained in:
DrymarchonShaun 2025-05-01 13:34:20 -07:00
parent 4fc0d1aceb
commit ef5267ea61
No known key found for this signature in database
4 changed files with 55 additions and 34 deletions

View file

@ -1,18 +0,0 @@
diff --git a/src/arma3-unix-launcher/main.cpp b/src/arma3-unix-launcher/main.cpp
index 10f6ed9..c706734 100644
--- a/src/arma3-unix-launcher/main.cpp
+++ b/src/arma3-unix-launcher/main.cpp
@@ -216,3 +216,3 @@ int main(int argc, char *argv[])
- MainWindow w(std::move(client), config_file, parser.get<bool>("--disable-steam-integration"));
+ MainWindow w(std::move(client), config_file, !parser.get<bool>("--disable-steam-integration"));
w.show();
diff --git a/src/dayz-linux-launcher/main.cpp b/src/dayz-linux-launcher/main.cpp
index f30bf8a..e0cef66 100644
--- a/src/dayz-linux-launcher/main.cpp
+++ b/src/dayz-linux-launcher/main.cpp
@@ -216,3 +216,3 @@ int main(int argc, char *argv[])
- MainWindow w(std::move(client), config_file, parser.get<bool>("--disable-steam-integration"));
+ MainWindow w(std::move(client), config_file, !parser.get<bool>("--disable-steam-integration"));
w.show();

View file

@ -1,19 +1,19 @@
diff --git a/cmake/external_dependencies.cmake b/cmake/external_dependencies.cmake
index 2eb6ec5..9f1d67e 100644
index 76648b2..145e978 100644
--- a/cmake/external_dependencies.cmake
+++ b/cmake/external_dependencies.cmake
@@ -4,7 +4,7 @@ include(FetchContent)
@@ -3,7 +3,7 @@ include(FetchContent)
function(setup_library SOURCE_TO_TEST)
set(boolArgs HEADER_ONLY)
- set(oneValueArgs NAME CXX_FLAGS GIT_REPOSITORY GIT_TAG TEST_DEFINITIONS TEST_LINK_LIBS)
+ set(oneValueArgs NAME CXX_FLAGS URL GIT_TAG TEST_DEFINITIONS TEST_LINK_LIBS)
set(multiValueArgs WHEN)
cmake_parse_arguments(LIB_SETUP "${boolArgs}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN})
@@ -27,12 +27,11 @@ function(setup_library SOURCE_TO_TEST)
@@ -26,12 +26,11 @@ function(setup_library SOURCE_TO_TEST)
endif()
FetchContent_Declare(${LIB_SETUP_NAME}
- GIT_REPOSITORY ${LIB_SETUP_GIT_REPOSITORY}
- GIT_TAG ${LIB_SETUP_GIT_TAG})
@ -26,7 +26,7 @@ index 2eb6ec5..9f1d67e 100644
FetchContent_Populate(${LIB_SETUP_NAME})
set(SRCDIR "${LIB_SETUP_NAME}_SOURCE_DIR")
set(BINDIR "${LIB_SETUP_NAME}_BINARY_DIR")
@@ -51,8 +50,7 @@ function(setup_argparse)
@@ -50,8 +49,7 @@ function(setup_argparse)
}")
setup_library("${CHECK_SOURCE}"
NAME argparse
@ -36,7 +36,7 @@ index 2eb6ec5..9f1d67e 100644
HEADER_ONLY
)
if (NOT TARGET argparse::argparse)
@@ -64,7 +62,7 @@ function(setup_curlpp)
@@ -63,7 +61,7 @@ function(setup_curlpp)
set(CHECK_SOURCE "#error unimplemented}")
setup_library("${CHECK_SOURCE}"
NAME curlpp
@ -63,7 +63,7 @@ index 2eb6ec5..9f1d67e 100644
+ URL @fmt_src@
TEST_LINK_LIBS fmt
)
@@ -126,7 +123,7 @@ function(setup_nlohmann_json)
add_library(nlohmann_json INTERFACE)
else()
@ -84,7 +84,7 @@ index 2eb6ec5..9f1d67e 100644
)
get_target_property(TARGET_TYPE pugixml TYPE)
@@ -188,8 +184,7 @@ function(setup_spdlog)
setup_library("${CHECK_SOURCE}"
NAME spdlog
- GIT_REPOSITORY https://github.com/gabime/spdlog.git
@ -94,7 +94,7 @@ index 2eb6ec5..9f1d67e 100644
TEST_LINK_LIBS ${FMT_TARGET_NAME}
CXX_FLAGS "-Wno-attributes -Wno-reorder -Wno-redundant-move"
@@ -198,8 +193,7 @@ endfunction()
function(setup_steamworkssdk)
FetchContent_Declare(steamworkssdk
- URL https://github.com/julianxhokaxhiu/SteamworksSDKCI/releases/download/1.53/SteamworksSDK-v1.53.0_x64.zip

View file

@ -11,18 +11,19 @@
nlohmann_json,
qt5,
spdlog,
steam-run,
replaceVars,
buildDayZLauncher ? false,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "arma3-unix-launcher";
version = "413-unstable-2025-02-10";
version = "420";
src = fetchFromGitHub {
owner = "muttleyxd";
repo = "arma3-unix-launcher";
rev = "7d4bcb166da3bb64ef10af421619d0b00136ebd5";
hash = "sha256-so7fjxESUAkQfO4hO5aQTzU5lHpeJlOOfEGp0Pb89sQ=";
tag = "commit-${finalAttrs.version}";
hash = "sha256-QY3zDtfZt2ifF69Jzp0Ls1SpDCliKdkwLaGFXneT79o=";
};
patches = [
@ -52,8 +53,11 @@ stdenv.mkDerivation (finalAttrs: {
doctest_src = null;
trompeloeil_src = null;
})
# game won't launch with steam integration anyways, disable it
./disable_steam_integration.patch
# use steam-run when running the game directly
(replaceVars ./steam-run.patch {
steamRun = lib.getExe steam-run;
})
];
nativeBuildInputs = [

View file

@ -0,0 +1,35 @@
diff --git a/src/arma3-unix-launcher-library/arma3client.cpp b/src/arma3-unix-launcher-library/arma3client.cpp
index dbb17d0..ee8853c 100644
--- a/src/arma3-unix-launcher-library/arma3client.cpp
+++ b/src/arma3-unix-launcher-library/arma3client.cpp
@@ -63,7 +63,7 @@ namespace
disable_esync);
if (!is_proton)
{
- StdUtils::StartBackgroundProcess(fmt::format("env {} {} {}", user_environment_variables, executable_path, arguments),
+ StdUtils::StartBackgroundProcess(fmt::format("@steamRun@ env {} {} {}", user_environment_variables, executable_path, arguments),
arma_path.string());
return;
}
@@ -83,7 +83,7 @@ namespace
auto const environment = fmt::format(R"env({} SteamGameId={} LD_PRELOAD={} STEAM_COMPAT_DATA_PATH="{}")env",
get_esync_prefix(disable_esync), arma3_id, ld_preload_path, steam_compat_data_path.string());
- auto const command = fmt::format(R"command(env {} {} {} {} {} "{}" {})command", environment, user_environment_variables,
+ auto const command = fmt::format(R"command(@steamRun@ env {} {} {} {} {} "{}" {})command", environment, user_environment_variables,
optional_steam_runtime(steam_utils), compatibility_tool.first,
get_verb(compatibility_tool.second), executable_path.string(), arguments);
spdlog::info("Running Arma:\n{}\n", command);
diff --git a/src/dayz-linux-launcher-library/dayzclient.cpp b/src/dayz-linux-launcher-library/dayzclient.cpp
index 5fc9027..d2b9e92 100644
--- a/src/dayz-linux-launcher-library/dayzclient.cpp
+++ b/src/dayz-linux-launcher-library/dayzclient.cpp
@@ -76,7 +76,7 @@ namespace
auto const environment = fmt::format(R"env({} SteamGameId={} LD_PRELOAD={} STEAM_COMPAT_DATA_PATH="{}")env",
get_esync_prefix(disable_esync), dayz_id, ld_preload_path, steam_compat_data_path.string());
- auto const command = fmt::format(R"command(env {} {} {} {} {} "{}" {})command", environment, user_environment_variables,
+ auto const command = fmt::format(R"command(@steamRun@ env {} {} {} {} {} "{}" {})command", environment, user_environment_variables,
optional_steam_runtime(steam_utils), compatibility_tool.first,
get_verb(compatibility_tool.second), executable_path.string(), arguments);
spdlog::info("Running DayZ:\n{}\n", command);