diff options
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/irrlicht/default.nix')
-rw-r--r-- | nixpkgs/pkgs/development/libraries/irrlicht/default.nix | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/libraries/irrlicht/default.nix b/nixpkgs/pkgs/development/libraries/irrlicht/default.nix new file mode 100644 index 000000000000..e283a2909474 --- /dev/null +++ b/nixpkgs/pkgs/development/libraries/irrlicht/default.nix @@ -0,0 +1,38 @@ +{ lib, stdenv, fetchzip, libGLU, libGL, unzip, libXrandr, libX11, libXxf86vm }: + +let + common = import ./common.nix { inherit fetchzip; }; +in + +stdenv.mkDerivation rec { + pname = common.pname; + version = common.version; + + src = common.src; + + postPatch = '' + sed -ie '/sys\/sysctl.h/d' source/Irrlicht/COSOperator.cpp + ''; + + preConfigure = '' + cd source/Irrlicht + ''; + + buildPhase = '' + make sharedlib NDEBUG=1 "LDFLAGS=-lX11 -lGL -lXxf86vm" + ''; + + preInstall = '' + sed -i s,/usr/local/lib,$out/lib, Makefile + mkdir -p $out/lib + ''; + + buildInputs = [ unzip libGLU libGL libXrandr libX11 libXxf86vm ]; + + meta = { + homepage = "http://irrlicht.sourceforge.net/"; + license = lib.licenses.zlib; + description = "Open source high performance realtime 3D engine written in C++"; + platforms = lib.platforms.linux ++ lib.platforms.darwin; + }; +} |