Unverified Commit fd4b8f2b authored by Cosima Neidahl's avatar Cosima Neidahl Committed by GitHub
Browse files

openxray: 2188-november-2023-rc1 -> 2921-january-2025-rc1 (#375925)

parents 250bc427 925e96bb
Loading
Loading
Loading
Loading
+20 −3
Original line number Diff line number Diff line
@@ -18,16 +18,23 @@

stdenv.mkDerivation (finalAttrs: {
  pname = "openxray";
  version = "2188-november-2023-rc1";
  version = "2921-january-2025-rc1";

  src = fetchFromGitHub {
    owner = "OpenXRay";
    repo = "xray-16";
    rev = finalAttrs.version;
    tag = finalAttrs.version;
    fetchSubmodules = true;
    hash = "sha256-rRxw/uThACmT2qI8NUwJU+WbJ3BWUss6CH13R5aaHco=";
    hash = "sha256-PYRC1t4gjT2d41ZZOZJF4u3vc0Pq7DpivEnnfbcSQYk=";
  };

  # Don't force-override these please
  postPatch = ''
    substituteInPlace Externals/LuaJIT-proj/CMakeLists.txt \
      --replace-fail 'set(CMAKE_OSX_SYSROOT' '#set(CMAKE_OSX_SYSROOT' \
      --replace-fail 'set(ENV{SDKROOT}' '#set(ENV{SDKROOT}'
  '';

  strictDeps = true;

  nativeBuildInputs = [
@@ -47,6 +54,16 @@ stdenv.mkDerivation (finalAttrs: {
    pcre
  ];

  cmakeFlags =
    [
      # Breaks on Darwin
      (lib.cmakeBool "USE_LTO" (!stdenv.hostPlatform.isDarwin))
    ]
    ++ lib.optionals stdenv.hostPlatform.isDarwin [
      # This seemingly only gets set properly by CMake when using the XCode generator
      (lib.cmakeFeature "CMAKE_OSX_DEPLOYMENT_TARGET" "${stdenv.hostPlatform.darwinMinVersion}")
    ];

  # Crashes can happen, we'd like them to be reasonably debuggable
  cmakeBuildType = "RelWithDebInfo";
  dontStrip = true;