diff options
Diffstat (limited to 'pkgs/games')
-rw-r--r-- | pkgs/games/minetest/default.nix | 6 | ||||
-rw-r--r-- | pkgs/games/openmw/tes3mp.nix | 6 | ||||
-rw-r--r-- | pkgs/games/openmw/tes3mp.patch | 13 | ||||
-rw-r--r-- | pkgs/games/terraria-server/default.nix | 26 |
4 files changed, 32 insertions, 19 deletions
diff --git a/pkgs/games/minetest/default.nix b/pkgs/games/minetest/default.nix index b2d958c5e090..db36b43ea299 100644 --- a/pkgs/games/minetest/default.nix +++ b/pkgs/games/minetest/default.nix @@ -76,9 +76,9 @@ let }; v5 = { - version = "5.1.1"; - sha256 = "0cjj63333b7j4ydfq0h9yc6d2jvmyjd7n7zbd08yrf0rcibrj2k0"; - dataSha256 = "1r9fxz2j24q74a9injvbxbf2xk67fzabv616i676zw2cvgv9hn39"; + version = "5.2.0"; + sha256 = "0pj9hkxwc1vzng2khbixi79557sbawf6mqkzl589jciyqa7jqkv1"; + dataSha256 = "1kjz7x3xiqqnpyrd6339a139pbdxx31c4qpg8pmns410hsm8i358"; }; in { diff --git a/pkgs/games/openmw/tes3mp.nix b/pkgs/games/openmw/tes3mp.nix index 222aa68dba24..59bdc6901078 100644 --- a/pkgs/games/openmw/tes3mp.nix +++ b/pkgs/games/openmw/tes3mp.nix @@ -50,6 +50,12 @@ in openmw.overrideAttrs (oldAttrs: rec { "-DRakNet_LIBRARY_DEBUG=${rakNetLibrary}/lib/libRakNetLibStatic.a" ]; + # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95175 + patches = [ + ./tes3mp.patch + ]; + NIX_CFLAGS_COMPILE = "-fpermissive"; + preConfigure = '' substituteInPlace files/version.in \ --subst-var-by OPENMW_VERSION_COMMITHASH ${compatHash} diff --git a/pkgs/games/openmw/tes3mp.patch b/pkgs/games/openmw/tes3mp.patch new file mode 100644 index 000000000000..c2a78f9db9b0 --- /dev/null +++ b/pkgs/games/openmw/tes3mp.patch @@ -0,0 +1,13 @@ +diff --git a/apps/openmw-mp/Script/Types.hpp b/apps/openmw-mp/Script/Types.hpp +index be365cfb8..204dcdc7b 100644 +--- a/apps/openmw-mp/Script/Types.hpp ++++ b/apps/openmw-mp/Script/Types.hpp +@@ -105,7 +105,7 @@ struct ScriptFunctionPointer : public ScriptIdentity + void *addr; + #if (!defined(__clang__) && defined(__GNUC__)) + template<typename R, typename... Types> +- constexpr ScriptFunctionPointer(Function<R, Types...> addr) : ScriptIdentity(addr), addr((void*)(addr)) {} ++ constexpr ScriptFunctionPointer(Function<R, Types...> addr) : ScriptIdentity(addr), addr(addr) {} + #else + template<typename R, typename... Types> + constexpr ScriptFunctionPointer(Function<R, Types...> addr) : ScriptIdentity(addr), addr(addr) {} diff --git a/pkgs/games/terraria-server/default.nix b/pkgs/games/terraria-server/default.nix index dab0b653ee9c..c61d2733c06c 100644 --- a/pkgs/games/terraria-server/default.nix +++ b/pkgs/games/terraria-server/default.nix @@ -1,36 +1,30 @@ -{ stdenv, lib, file, fetchurl, unzip }: +{ stdenv, lib, file, fetchurl, autoPatchelfHook, unzip }: stdenv.mkDerivation rec { pname = "terraria-server"; - version = "1.3.5.3"; - urlVersion = lib.replaceChars ["."] [""] version; + version = "1.4.0.3"; + urlVersion = lib.replaceChars [ "." ] [ "" ] version; src = fetchurl { - url = "https://terraria.org/server/terraria-server-${urlVersion}.zip"; - sha256 = "0l7j2n6ip4hxph7dfal7kzdm3dqnm1wba6zc94gafkh97wr35ck3"; + url = "https://terraria.org/system/dedicated_servers/archives/000/000/037/original/terraria-server-${urlVersion}.zip"; + sha256 = "1g9rd0a40gsljk8xp3bkvwy8ngywjzk8chf2x9l43s2kf40ib0p8"; }; buildInputs = [ file unzip ]; + nativeBuildInputs = [ autoPatchelfHook ]; installPhase = '' mkdir -p $out/bin cp -r Linux $out/ chmod +x "$out/Linux/TerrariaServer.bin.x86_64" ln -s "$out/Linux/TerrariaServer.bin.x86_64" $out/bin/TerrariaServer - # Fix "/lib64/ld-linux-x86-64.so.2" like references in ELF executables. - find "$out" | while read filepath; do - if file "$filepath" | grep -q "ELF.*executable"; then - echo "setting interpreter $(cat "$NIX_CC"/nix-support/dynamic-linker) in $filepath" - patchelf --set-interpreter "$(cat "$NIX_CC"/nix-support/dynamic-linker)" "$filepath" - test $? -eq 0 || { echo "patchelf failed to process $filepath"; exit 1; } - fi - done ''; meta = with lib; { - homepage = "http://terraria.org"; - description = "Dedicated server for Terraria, a 2D action-adventure sandbox"; - platforms = ["x86_64-linux"]; + homepage = "https://terraria.org"; + description = + "Dedicated server for Terraria, a 2D action-adventure sandbox"; + platforms = [ "x86_64-linux" ]; license = licenses.unfree; }; } |