Merge pull request #311725 from lheckemann/openclonk

openclonk: 8.1 -> unstable-2023-10-30
This commit is contained in:
lassulus 2024-05-15 12:04:21 +02:00 committed by GitHub
commit 05789ac113
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,5 +1,6 @@
{ lib, stdenv, fetchurl, fetchDebianPatch, fetchpatch, cmake, pkg-config { lib, stdenv, fetchurl, fetchFromGitHub, fetchDebianPatch, fetchpatch, cmake, pkg-config
, SDL2, libvorbis, libogg, libjpeg, libpng, freetype, glew, tinyxml, openal , SDL2, libvorbis, libogg, libjpeg, libpng, freetype, glew, tinyxml, openal, libepoxy
, curl
, freealut, readline, libb2, gcc-unwrapped , freealut, readline, libb2, gcc-unwrapped
, enableSoundtrack ? false # Enable the "Open Clonk Soundtrack - Explorers Journey" by David Oerther , enableSoundtrack ? false # Enable the "Open Clonk Soundtrack - Explorers Journey" by David Oerther
}: }:
@ -10,12 +11,14 @@ let
sha256 = "1ckj0dlpp5zsnkbb5qxxfxpkiq76jj2fgj91fyf3ll7n0gbwcgw5"; sha256 = "1ckj0dlpp5zsnkbb5qxxfxpkiq76jj2fgj91fyf3ll7n0gbwcgw5";
}; };
in stdenv.mkDerivation rec { in stdenv.mkDerivation rec {
version = "8.1"; version = "unstable-2023-10-30";
pname = "openclonk"; pname = "openclonk";
src = fetchurl { src = fetchFromGitHub {
url = "https://www.openclonk.org/builds/release/8.1/openclonk-${version}-src.tar.bz2"; owner = "openclonk";
sha256 = "0imkqjp8lww5p0cnqf4k4mb2v682mnsas63qmiz17rspakr7fxik"; repo = "openclonk";
rev = "5275334a11ef7c23ce809f35d6b443abd91b415f";
sha256 = "14x5b2rh739156l4072rbsnv9n862jz1zafi6ng158ja5fwl16l2";
}; };
patches = [ patches = [
@ -26,15 +29,11 @@ in stdenv.mkDerivation rec {
patch = "system-libb2.patch"; patch = "system-libb2.patch";
hash = "sha256-zuH6zxSQXRhnt75092Xwb6XYv8UG391E5Arbnr7ApiI="; hash = "sha256-zuH6zxSQXRhnt75092Xwb6XYv8UG391E5Arbnr7ApiI=";
}) })
(fetchpatch {
name = "fix-gcc-11-build.patch";
url = "https://github.com/openclonk/openclonk/commit/e304efde2c8643bbc0fc1ad5e85024982744b233.patch";
hash = "sha256-jfVCgeZuYo4x53zhljKcnMDMIBECTRsUSxkl6JaL6HA=";
})
]; ];
enableParallelInstalling = false;
postInstall = '' postInstall = ''
mv -v $out/games/openclonk $out/bin/
'' + lib.optionalString enableSoundtrack '' '' + lib.optionalString enableSoundtrack ''
ln -sv ${soundtrack_src} $out/share/games/openclonk/Music.ocg ln -sv ${soundtrack_src} $out/share/games/openclonk/Music.ocg
''; '';
@ -43,6 +42,7 @@ in stdenv.mkDerivation rec {
buildInputs = [ buildInputs = [
SDL2 libvorbis libogg libjpeg libpng freetype glew tinyxml openal freealut SDL2 libvorbis libogg libjpeg libpng freetype glew tinyxml openal freealut
libepoxy curl
readline libb2 readline libb2
]; ];