From 34f9116c5868f81ac83daae291c67a16a002605c Mon Sep 17 00:00:00 2001 From: Weijia Wang <9713184+wegank@users.noreply.github.com> Date: Thu, 20 Jul 2023 10:53:13 +0300 Subject: [PATCH 1/3] cegui: 0.8.7 -> unstable-2023-03-18 --- pkgs/development/libraries/cegui/default.nix | 54 ++++++++++++++++---- pkgs/top-level/all-packages.nix | 4 +- 2 files changed, 45 insertions(+), 13 deletions(-) diff --git a/pkgs/development/libraries/cegui/default.nix b/pkgs/development/libraries/cegui/default.nix index cb302f3381c..c56c59d02ad 100644 --- a/pkgs/development/libraries/cegui/default.nix +++ b/pkgs/development/libraries/cegui/default.nix @@ -1,19 +1,53 @@ -{ lib, stdenv, fetchurl, cmake, ogre, freetype, boost, expat, libiconv }: +{ lib +, stdenv +, fetchFromGitHub +, cmake +, ogre +, freetype +, boost +, expat +, darwin +, libiconv +, unstableGitUpdater +}: -stdenv.mkDerivation rec { +stdenv.mkDerivation { pname = "cegui"; - version = "0.8.7"; + version = "unstable-2023-03-18"; - src = fetchurl { - url = "mirror://sourceforge/crayzedsgui/${pname}-${version}.tar.bz2"; - sha256 = "067562s71kfsnbp2zb2bmq8zj3jk96g5a4rcc5qc3n8nfyayhldk"; + src = fetchFromGitHub { + owner = "paroj"; + repo = "cegui"; + rev = "186ce900e293b98f2721c11930248a8de54aa338"; + hash = "sha256-RJ4MnxklcuxC+ZYEbfma5RDc2aeJ95LuTwNk+FnEhdo="; }; - nativeBuildInputs = [ cmake ]; - buildInputs = [ ogre freetype boost expat ] - ++ lib.optionals stdenv.isDarwin [ libiconv ]; + strictDeps = true; - cmakeFlags = lib.optional (stdenv.isDarwin && stdenv.isAarch64) "-DCMAKE_OSX_ARCHITECTURES=arm64"; + nativeBuildInputs = [ + cmake + ]; + + buildInputs = [ + ogre + freetype + boost + expat + ] ++ lib.optionals stdenv.isDarwin [ + darwin.apple_sdk.frameworks.Cocoa + darwin.apple_sdk.frameworks.Foundation + libiconv + ]; + + cmakeFlags = [ + "-DCEGUI_OPTION_DEFAULT_IMAGECODEC=OgreRenderer-0" + ] ++ lib.optionals (stdenv.hostPlatform.isDarwin) [ + "-DCMAKE_OSX_ARCHITECTURES=${stdenv.hostPlatform.darwinArch}" + ]; + + passthru.updateScript = unstableGitUpdater { + branch = "v0"; + }; meta = with lib; { homepage = "http://cegui.org.uk/"; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 4492c01918a..ccc2d26e53e 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -20391,9 +20391,7 @@ with pkgs; celt_0_7 = callPackage ../development/libraries/celt/0.7.nix { }; celt_0_5_1 = callPackage ../development/libraries/celt/0.5.1.nix { }; - cegui = callPackage ../development/libraries/cegui { - ogre = ogre1_10; - }; + cegui = callPackage ../development/libraries/cegui { }; certbot = python3.pkgs.toPythonApplication python3.pkgs.certbot; From 73c36c646a5579b2abdb86ba5f943233df07ed14 Mon Sep 17 00:00:00 2001 From: Weijia Wang <9713184+wegank@users.noreply.github.com> Date: Thu, 20 Jul 2023 11:07:17 +0300 Subject: [PATCH 2/3] opendungeons: unstable-2021-11-06 -> unstable-2023-03-18 --- pkgs/games/opendungeons/default.nix | 54 ++++++++++++++++++++++++----- pkgs/top-level/all-packages.nix | 4 +-- 2 files changed, 47 insertions(+), 11 deletions(-) diff --git a/pkgs/games/opendungeons/default.nix b/pkgs/games/opendungeons/default.nix index 61f8aad304c..a5fdb5cd9a8 100644 --- a/pkgs/games/opendungeons/default.nix +++ b/pkgs/games/opendungeons/default.nix @@ -1,14 +1,35 @@ -{ lib, stdenv, fetchFromGitHub, ogre, cegui, boost, sfml, openal, cmake, ois, pkg-config }: +{ lib +, stdenv +, fetchFromGitHub +, cmake +, pkg-config +, ogre +, cegui +, boost +, sfml +, openal +, ois +}: -stdenv.mkDerivation rec { +let + ogre' = ogre.overrideAttrs (old: { + cmakeFlags = old.cmakeFlags ++ [ + "-DOGRE_RESOURCEMANAGER_STRICT=0" + ]; + }); + cegui' = cegui.override { + ogre = ogre'; + }; +in +stdenv.mkDerivation { pname = "opendungeons"; - version = "unstable-2021-11-06"; + version = "unstable-2023-03-18"; src = fetchFromGitHub { - owner = "OpenDungeons"; + owner = "paroj"; repo = "OpenDungeons"; - rev = "c180ed1864eab5fbe847d1dd5c5c936c4e45444e"; - sha256 = "0xf7gkpy8ll1h59wyaljf0hr8prg7p4ixz80mxqwcnm9cglpgn63"; + rev = "974378d75591214dccbe0fb26e6ec8a40c2156e0"; + hash = "sha256-vz9cT+rNcyKT3W9I9VRKcFol2SH1FhOhOALALjgKfIE="; }; patches = [ @@ -21,8 +42,25 @@ stdenv.mkDerivation rec { cp source/utils/StackTrace{Stub,Unix}.cpp ''; - nativeBuildInputs = [ cmake pkg-config ]; - buildInputs = [ ogre cegui boost sfml openal ois ]; + strictDeps = true; + + nativeBuildInputs = [ + cmake + pkg-config + ]; + + buildInputs = [ + ogre' + cegui' + boost + sfml + openal + ois + ]; + + cmakeFlags = [ + "-DOD_TREAT_WARNINGS_AS_ERRORS=FALSE" + ]; meta = with lib; { description = "An open source, real time strategy game sharing game elements with the Dungeon Keeper series and Evil Genius"; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index ccc2d26e53e..bdb8fe45aca 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -37462,9 +37462,7 @@ with pkgs; openarena = callPackage ../games/openarena { }; - opendungeons = callPackage ../games/opendungeons { - ogre = ogre1_10; - }; + opendungeons = callPackage ../games/opendungeons { }; openlierox = callPackage ../games/openlierox { }; From 98e07b5b2dab24a16312733bcbffc66d0815f738 Mon Sep 17 00:00:00 2001 From: Weijia Wang <9713184+wegank@users.noreply.github.com> Date: Thu, 20 Jul 2023 11:08:50 +0300 Subject: [PATCH 3/3] ogre1_10: remove --- pkgs/development/libraries/ogre/1.10.x.nix | 110 --------------------- pkgs/top-level/aliases.nix | 1 + pkgs/top-level/all-packages.nix | 1 - 3 files changed, 1 insertion(+), 111 deletions(-) delete mode 100644 pkgs/development/libraries/ogre/1.10.x.nix diff --git a/pkgs/development/libraries/ogre/1.10.x.nix b/pkgs/development/libraries/ogre/1.10.x.nix deleted file mode 100644 index 73f15b744bf..00000000000 --- a/pkgs/development/libraries/ogre/1.10.x.nix +++ /dev/null @@ -1,110 +0,0 @@ -{ lib -, stdenv -, fetchurl -, fetchpatch -, cmake -, pkg-config -, boost -, freeimage -, freetype -, libpng -, ois -, zziplib -, freeglut -, libGL -, libGLU -, libICE -, libSM -, libX11 -, libXaw -, libXmu -, libXrandr -, libXrender -, libXt -, libXxf86vm -, xorgproto -, darwin -, withNvidiaCg ? false -, nvidia_cg_toolkit -, withSamples ? false -}: - -let - inherit (darwin.apple_sdk.frameworks) AGL Cocoa; -in -stdenv.mkDerivation rec { - pname = "ogre"; - version = "1.10.11"; - - src = fetchurl { - url = "https://bitbucket.org/sinbad/ogre/get/v${lib.replaceStrings ["."] ["-"] version}.tar.gz"; - sha256 = "1zwvlx5dz9nwjazhnrhzb0w8ilpa84r0hrxrmmy69pgr1p1yif5a"; - }; - - patches = [ - # aarch64-darwin support - (fetchpatch { - url = "https://github.com/OGRECave/ogre/commit/bd5fbe3482c56e58c6c3b3bf439b1eab8c1be258.patch"; - includes = [ "OgreMain/include/OgrePlatform*.h" ]; - sha256 = "sha256-ELeCklQkltz7DeDaGl78Jk1H3Wdfu8fMUiMZaJM4s/Y="; - }) - (fetchpatch { - url = "https://github.com/OGRECave/ogre/commit/0873244cc06b613ca2afbcb5522fe9ef89f111c5.patch"; - sha256 = "sha256-xGvlMB55B2rdthxNMIM5iFf9p/6zuE8bGL9P04qtweQ="; - }) - # aarch64-linux support - (fetchpatch { - name = "fix-build-on-aarch64-linux.patch"; - url = "https://github.com/OGRECave/ogre/commit/8ec086e9bc2e24fab373b514c572483b69071d69.patch"; - sha256 = "sha256-22wlJPZ7lRIPAMqvpI/2YI0neQjGi1UXt8y5zNSpxCw="; - }) - ]; - - nativeBuildInputs = [ - cmake - pkg-config - ]; - - buildInputs = [ - boost - freeimage - freetype - libpng - ois - zziplib - ] ++ lib.optionals stdenv.isLinux [ - freeglut - libGL - libGLU - libICE - libSM - libX11 - libXaw - libXmu - libXrandr - libXrender - libXt - libXxf86vm - xorgproto - ] ++ lib.optionals stdenv.isDarwin [ - AGL - Cocoa - ] ++ lib.optionals withNvidiaCg [ - nvidia_cg_toolkit - ]; - - cmakeFlags = [ - "-DOGRE_BUILD_COMPONENT_OVERLAY_IMGUI=FALSE" - "-DOGRE_BUILD_SAMPLES=${toString withSamples}" - ] ++ lib.optionals stdenv.isDarwin [ - "-DOGRE_BUILD_LIBS_AS_FRAMEWORKS=FALSE" - ]; - - meta = { - description = "3D Object-Oriented Graphics Rendering Engine"; - homepage = "https://www.ogre3d.org/"; - maintainers = with lib.maintainers; [ raskin wegank ]; - platforms = lib.platforms.unix; - license = lib.licenses.mit; - }; -} diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix index 4dfcec2635d..673189ff6b0 100644 --- a/pkgs/top-level/aliases.nix +++ b/pkgs/top-level/aliases.nix @@ -1207,6 +1207,7 @@ mapAliases ({ odpdown = throw "odpdown has been removed because it lacks python3 support"; # Added 2022-04-25 ofp = throw "ofp is not compatible with odp-dpdk"; ogre1_9 = throw "ogre1_9 has been removed, use ogre instead"; # Added 2023-03-22 + ogre1_10 = throw "ogre1_10 has been removed, use ogre instead"; # Added 2023-07-20 olifant = throw "olifant has been removed from nixpkgs, as it was unmaintained"; # Added 2021-08-05 opa = throw "opa has been removed from nixpkgs as upstream has abandoned the project"; # Added 2023-03-21 opam_1_2 = throw "'opam_1_2' has been renamed to/replaced by 'opam'"; # Added 2023-03-08 diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index bdb8fe45aca..7c9345c1b07 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -23785,7 +23785,6 @@ with pkgs; ogre = callPackage ../development/libraries/ogre { inherit (darwin.apple_sdk.frameworks) Cocoa; }; - ogre1_10 = callPackage ../development/libraries/ogre/1.10.x.nix { }; olm = callPackage ../development/libraries/olm { };