2022-05-12 18:34:54 +01:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchFromGitHub
|
|
|
|
, cmake
|
|
|
|
, glew
|
|
|
|
, freeimage
|
|
|
|
, liblockfile
|
|
|
|
, openal
|
|
|
|
, libtheora
|
|
|
|
, SDL2
|
|
|
|
, lzo
|
|
|
|
, libjpeg
|
|
|
|
, libogg
|
|
|
|
, pcre
|
|
|
|
, makeWrapper
|
|
|
|
}:
|
2019-10-03 20:19:00 +01:00
|
|
|
|
2022-07-30 00:31:37 +01:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "openxray";
|
2022-05-12 18:34:54 +01:00
|
|
|
version = "1144-december-2021-rc1";
|
2019-10-03 20:19:00 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "OpenXRay";
|
|
|
|
repo = "xray-16";
|
|
|
|
rev = version;
|
|
|
|
fetchSubmodules = true;
|
2022-05-12 18:34:54 +01:00
|
|
|
sha256 = "07qj1lpp21g4p583gvz5h66y2q71ymbsz4g5nr6dcys0vm7ph88v";
|
2019-10-03 20:19:00 +01:00
|
|
|
};
|
|
|
|
|
2022-05-12 18:34:54 +01:00
|
|
|
nativeBuildInputs = [
|
|
|
|
cmake
|
|
|
|
makeWrapper
|
2020-11-29 09:47:58 +00:00
|
|
|
];
|
|
|
|
|
2019-10-03 20:19:00 +01:00
|
|
|
buildInputs = [
|
2022-05-12 18:34:54 +01:00
|
|
|
glew
|
|
|
|
freeimage
|
|
|
|
liblockfile
|
|
|
|
openal
|
|
|
|
libtheora
|
|
|
|
SDL2
|
|
|
|
lzo
|
|
|
|
libjpeg
|
|
|
|
libogg
|
|
|
|
pcre
|
2019-10-03 20:19:00 +01:00
|
|
|
];
|
2021-05-07 08:19:32 +01:00
|
|
|
|
2022-05-12 18:34:54 +01:00
|
|
|
# Crashes can happen, we'd like them to be reasonably debuggable
|
|
|
|
cmakeBuildType = "RelWithDebInfo";
|
|
|
|
dontStrip = true;
|
2019-10-03 20:19:00 +01:00
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
# needed because of SDL_LoadObject library loading code
|
|
|
|
wrapProgram $out/bin/xr_3da \
|
|
|
|
--prefix LD_LIBRARY_PATH : $out/lib
|
|
|
|
'';
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2022-05-12 18:34:54 +01:00
|
|
|
mainProgram = "xray-16";
|
2020-12-09 11:58:04 +00:00
|
|
|
description = "Improved version of the X-Ray Engine, the game engine used in the world-famous S.T.A.L.K.E.R. game series by GSC Game World";
|
2022-05-12 18:34:54 +01:00
|
|
|
homepage = "https://github.com/OpenXRay/xray-16/";
|
2019-10-03 20:19:00 +01:00
|
|
|
license = licenses.unfree // {
|
2022-07-30 00:31:37 +01:00
|
|
|
url = "https://github.com/OpenXRay/xray-16/blob/${version}/License.txt";
|
2019-10-03 20:19:00 +01:00
|
|
|
};
|
2021-05-07 08:19:32 +01:00
|
|
|
maintainers = with maintainers; [ OPNA2608 ];
|
2019-11-19 14:32:11 +00:00
|
|
|
platforms = [ "x86_64-linux" "i686-linux" ];
|
2019-10-03 20:19:00 +01:00
|
|
|
};
|
|
|
|
}
|