about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/mygui
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/mygui')
-rw-r--r--nixpkgs/pkgs/development/libraries/mygui/default.nix32
1 files changed, 32 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/libraries/mygui/default.nix b/nixpkgs/pkgs/development/libraries/mygui/default.nix
new file mode 100644
index 000000000000..894d35eb3d8a
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/mygui/default.nix
@@ -0,0 +1,32 @@
+{  stdenv, fetchFromGitHub, libX11, unzip, cmake, ois, freetype, libuuid,
+   boost, pkgconfig, withOgre ? false, ogre ? null, libGL, libGLU ? null } :
+
+let
+  renderSystem = if withOgre then "3" else "4";
+in stdenv.mkDerivation rec {
+  pname = "mygui";
+  version = "3.4.0";
+
+  src = fetchFromGitHub {
+    owner = "MyGUI";
+    repo = "mygui";
+    rev = "MyGUI${version}";
+    sha256 = "0a4zi8w18pjj813n7kmxldl1d9r1jp0iyhkw7pbqgl8f7qaq994w";
+  };
+
+  enableParallelBuilding = true;
+
+  nativeBuildInputs = [ pkgconfig ];
+  buildInputs = [ libX11 unzip cmake ois freetype libuuid boost ]
+    ++ (if withOgre then [ ogre ] else [libGL libGLU]);
+
+  # Tools are disabled due to compilation failures.
+  cmakeFlags = [ "-DMYGUI_BUILD_TOOLS=OFF" "-DMYGUI_BUILD_DEMOS=OFF" "-DMYGUI_RENDERSYSTEM=${renderSystem}" ];
+
+  meta = with stdenv.lib; {
+    homepage = "http://mygui.info/";
+    description = "Library for creating GUIs for games and 3D applications";
+    license = licenses.lgpl3Plus;
+    platforms = platforms.linux;
+  };
+}