summary refs log tree commit diff
path: root/pkgs/development/libraries/fltk
diff options
context:
space:
mode:
authorJulien Dehos <dehos@lisic.univ-littoral.fr>2016-05-22 16:50:31 +0200
committerJulien Dehos <dehos@lisic.univ-littoral.fr>2016-05-23 08:37:19 +0200
commit2607b53e9d7b66d7e016f00338502194c70cbc50 (patch)
treeab3463f32ec9f9725522e86ab6dcc28e8308dc84 /pkgs/development/libraries/fltk
parente591789b04420c65592fc4889e336bfadf951b1d (diff)
downloadnixpkgs-2607b53e9d7b66d7e016f00338502194c70cbc50.tar
nixpkgs-2607b53e9d7b66d7e016f00338502194c70cbc50.tar.gz
nixpkgs-2607b53e9d7b66d7e016f00338502194c70cbc50.tar.bz2
nixpkgs-2607b53e9d7b66d7e016f00338502194c70cbc50.tar.lz
nixpkgs-2607b53e9d7b66d7e016f00338502194c70cbc50.tar.xz
nixpkgs-2607b53e9d7b66d7e016f00338502194c70cbc50.tar.zst
nixpkgs-2607b53e9d7b66d7e016f00338502194c70cbc50.zip
fltk: 2-alpha -> 1.3.3
Diffstat (limited to 'pkgs/development/libraries/fltk')
-rw-r--r--pkgs/development/libraries/fltk/default.nix37
-rw-r--r--pkgs/development/libraries/fltk/fltk13.nix66
2 files changed, 28 insertions, 75 deletions
diff --git a/pkgs/development/libraries/fltk/default.nix b/pkgs/development/libraries/fltk/default.nix
index 6398e5542ac..242f1cb00a7 100644
--- a/pkgs/development/libraries/fltk/default.nix
+++ b/pkgs/development/libraries/fltk/default.nix
@@ -1,19 +1,34 @@
-{ composableDerivation, fetchurl, pkgconfig, xlibsWrapper, inputproto, libXi
-, freeglut, mesa, libjpeg, zlib, libXinerama, libXft, libpng }:
+{ stdenv, composableDerivation, fetchurl, pkgconfig, xlibsWrapper, inputproto, libXi
+, freeglut, mesa, libjpeg, zlib, libXinerama, libXft, libpng
+, cfg ? {}
+, automake, autoconf, libtool
+}:
 
 let inherit (composableDerivation) edf; in
 
-composableDerivation.composableDerivation {} rec {
-  name = "fltk-2.0.x-alpha-r9296";
+let version = "1.3.3"; in
+composableDerivation.composableDerivation {} {
+  name = "fltk-${version}";
 
   src = fetchurl {
-    url = "ftp://ftp.easysw.com/pub/fltk/snapshots/${name}.tar.bz2";
-    sha256 = "0353ngb7gpyklc9mdz8629big2na3c73akfwhis8fhqp7jkbs9ih";
+    url = "http://fltk.org/pub/fltk/${version}/fltk-${version}-source.tar.gz";
+    sha256 = "15qd7lkz5d5ynz70xhxhigpz3wns39v9xcf7ggkl0792syc8sfgq";
   };
 
+  # http://www.fltk.org/str.php?L3156
+  patchPhase = ''
+    substituteInPlace FL/x.H \
+      --replace 'class Fl_XFont_On_Demand' 'class FL_EXPORT Fl_XFont_On_Demand'
+  '';
+
   propagatedBuildInputs = [ xlibsWrapper inputproto libXi freeglut ];
 
-  buildInputs = [ pkgconfig ];
+  enableParallelBilding = true;
+
+  nativeBuildInputs = [
+    pkgconfig
+    automake autoconf libtool # only required because of patch
+  ];
 
   flags =
     # this could be tidied up (?).. eg why does it require freeglut without glSupport?
@@ -39,10 +54,14 @@ composableDerivation.composableDerivation {} rec {
     localpngSupport = false;
     sharedSupport = true;
     threadsSupport = true;
-  };
+  } // cfg;
 
   meta = {
-    description = "a C++ cross platform lightweight gui library binding";
+    description = "A C++ cross-platform lightweight GUI library";
     homepage = http://www.fltk.org;
+    platforms = stdenv.lib.platforms.linux;
+    license = stdenv.lib.licenses.gpl2;
   };
+
 }
+
diff --git a/pkgs/development/libraries/fltk/fltk13.nix b/pkgs/development/libraries/fltk/fltk13.nix
deleted file mode 100644
index cb71724a360..00000000000
--- a/pkgs/development/libraries/fltk/fltk13.nix
+++ /dev/null
@@ -1,66 +0,0 @@
-{ composableDerivation, fetchurl, pkgconfig, xlibsWrapper, inputproto, libXi
-, freeglut, mesa, libjpeg, zlib, libXinerama, libXft, libpng
-, cfg ? {}
-, automake, autoconf, libtool
-}:
-
-let inherit (composableDerivation) edf; in
-
-let version = "1.3.3"; in
-composableDerivation.composableDerivation {} {
-  name = "fltk-${version}";
-
-  src = fetchurl {
-    url = "http://fltk.org/pub/fltk/${version}/fltk-${version}-source.tar.gz";
-    sha256 = "15qd7lkz5d5ynz70xhxhigpz3wns39v9xcf7ggkl0792syc8sfgq";
-  };
-
-  # http://www.fltk.org/str.php?L3156
-  postPatch = ''
-    substituteInPlace FL/x.H \
-      --replace 'class Fl_XFont_On_Demand' 'class FL_EXPORT Fl_XFont_On_Demand'
-  '';
-
-  propagatedBuildInputs = [ xlibsWrapper inputproto libXi freeglut ];
-
-  enableParallelBilding = true;
-
-  nativeBuildInputs = [
-    pkgconfig
-    automake autoconf libtool # only required because of patch
-  ];
-
-  flags =
-    # this could be tidied up (?).. eg why does it require freeglut without glSupport?
-    edf { name = "cygwin"; }  #         use the CygWin libraries default=no
-    // edf { name = "debug"; }  #          turn on debugging default=no
-    // edf { name = "gl"; enable = { buildInputs = [ mesa ]; }; }  #             turn on OpenGL support default=yes
-    // edf { name = "shared"; }  #         turn on shared libraries default=no
-    // edf { name = "threads"; }  #        enable multi-threading support
-    // edf { name = "quartz"; enable = { buildInputs = "quartz"; }; }  # don't konw yet what quartz is #         use Quartz instead of Quickdraw (default=no)
-    // edf { name = "largefile"; } #     omit support for large files
-    // edf { name = "localjpeg"; disable = { buildInputs = [libjpeg]; }; } #       use local JPEG library, default=auto
-    // edf { name = "localzlib"; disable = { buildInputs = [zlib]; }; } #       use local ZLIB library, default=auto
-    // edf { name = "localpng"; disable = { buildInputs = [libpng]; }; } #       use local PNG library, default=auto
-    // edf { name = "xinerama"; enable = { buildInputs = [libXinerama]; }; } #       turn on Xinerama support default=no
-    // edf { name = "xft"; enable = { buildInputs=[libXft]; }; } #            turn on Xft support default=no
-    // edf { name = "xdbe"; };  #           turn on Xdbe support default=no
-
-  cfg = {
-    largefileSupport = true; # is default
-    glSupport = true; # doesn't build without it. Why?
-    localjpegSupport = false;
-    localzlibSupport = false;
-    localpngSupport = false;
-    sharedSupport = true;
-    threadsSupport = true;
-  } // cfg;
-
-  meta = {
-    description = "A C++ cross-platform light-weight GUI library binding";
-    homepage = http://www.fltk.org;
-  };
-
-  patches = [
-     ];
-}