2016-04-11 15:48:01 +02:00
|
|
|
{ fetchurl, stdenv, lib
|
2019-11-10 17:44:34 +01:00
|
|
|
, cmake, libGLU, libGL
|
2018-12-31 04:40:47 +01:00
|
|
|
, freetype, freeimage, zziplib, xorgproto, libXrandr
|
2012-04-06 11:07:23 +02:00
|
|
|
, libXaw, freeglut, libXt, libpng, boost, ois
|
2018-12-31 04:40:47 +01:00
|
|
|
, libX11, libXmu, libSM, pkgconfig
|
|
|
|
, libXxf86vm, libICE
|
2019-02-24 21:39:20 +01:00
|
|
|
, unzip
|
2018-12-31 04:40:47 +01:00
|
|
|
, libXrender
|
2016-04-11 15:48:01 +02:00
|
|
|
, withNvidiaCg ? false, nvidia_cg_toolkit
|
|
|
|
, withSamples ? false }:
|
2010-12-22 15:50:13 +01:00
|
|
|
|
2019-02-24 21:39:20 +01:00
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 14:41:18 +02:00
|
|
|
pname = "ogre";
|
2019-07-02 06:24:16 +02:00
|
|
|
version = "1.12.1";
|
2010-12-22 15:50:13 +01:00
|
|
|
|
2015-09-26 20:49:54 +02:00
|
|
|
src = fetchurl {
|
2019-02-24 21:39:20 +01:00
|
|
|
url = "https://github.com/OGRECave/ogre/archive/v${version}.zip";
|
2019-07-02 06:24:16 +02:00
|
|
|
sha256 = "1iv6k0dwdzg5nnzw2mcgcl663q4f7p2kj7nhs8afnsikrzxxgsi4";
|
2012-04-06 11:07:23 +02:00
|
|
|
};
|
2010-12-22 15:50:13 +01:00
|
|
|
|
2016-04-11 15:48:01 +02:00
|
|
|
cmakeFlags = [ "-DOGRE_BUILD_SAMPLES=${toString withSamples}" ]
|
|
|
|
++ map (x: "-DOGRE_BUILD_PLUGIN_${x}=on")
|
|
|
|
([ "BSP" "OCTREE" "PCZ" "PFX" ] ++ lib.optional withNvidiaCg "CG")
|
|
|
|
++ map (x: "-DOGRE_BUILD_RENDERSYSTEM_${x}=on") [ "GL" ];
|
2011-03-31 00:08:33 +02:00
|
|
|
|
2012-04-06 11:07:23 +02:00
|
|
|
enableParallelBuilding = true;
|
2010-12-22 15:50:13 +01:00
|
|
|
|
2012-04-06 11:07:23 +02:00
|
|
|
buildInputs =
|
2019-11-10 17:44:34 +01:00
|
|
|
[ cmake libGLU libGL
|
2018-12-31 04:40:47 +01:00
|
|
|
freetype freeimage zziplib xorgproto libXrandr
|
2012-04-06 11:07:23 +02:00
|
|
|
libXaw freeglut libXt libpng boost ois
|
2018-12-31 04:40:47 +01:00
|
|
|
libX11 libXmu libSM pkgconfig
|
|
|
|
libXxf86vm libICE
|
|
|
|
libXrender
|
2016-04-11 15:48:01 +02:00
|
|
|
] ++ lib.optional withNvidiaCg nvidia_cg_toolkit;
|
2011-04-09 17:51:00 +02:00
|
|
|
|
2019-02-24 21:39:20 +01:00
|
|
|
nativeBuildInputs = [ unzip ];
|
|
|
|
|
2010-12-22 15:50:13 +01:00
|
|
|
meta = {
|
|
|
|
description = "A 3D engine";
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "https://www.ogre3d.org/";
|
2012-04-06 11:07:23 +02:00
|
|
|
maintainers = [ stdenv.lib.maintainers.raskin ];
|
|
|
|
platforms = stdenv.lib.platforms.linux;
|
2014-06-19 06:19:00 +02:00
|
|
|
license = stdenv.lib.licenses.mit;
|
2010-12-22 15:50:13 +01:00
|
|
|
};
|
2012-04-06 11:07:23 +02:00
|
|
|
}
|