summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorMatthew Pickering <matthewtpickering@gmail.com>2018-04-17 20:39:50 +0100
committerMatthew Pickering <matthewtpickering@gmail.com>2018-08-11 22:37:59 +0100
commit7262b88b0a9033e3b000ac6b80582551245a6fa7 (patch)
tree005d2a0fce5101f9b41c5f341f671835d3d5fc6d /pkgs
parentcce0fc8fe5c5991b2fc36455b4b0353fff6cc2cf (diff)
downloadnixlib-7262b88b0a9033e3b000ac6b80582551245a6fa7.tar
nixlib-7262b88b0a9033e3b000ac6b80582551245a6fa7.tar.gz
nixlib-7262b88b0a9033e3b000ac6b80582551245a6fa7.tar.bz2
nixlib-7262b88b0a9033e3b000ac6b80582551245a6fa7.tar.lz
nixlib-7262b88b0a9033e3b000ac6b80582551245a6fa7.tar.xz
nixlib-7262b88b0a9033e3b000ac6b80582551245a6fa7.tar.zst
nixlib-7262b88b0a9033e3b000ac6b80582551245a6fa7.zip
saga_2_3_2: Init at 2.3.2
This is the lts branch of SAGA which is currently used by QGIS 2.18.x
series.
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/applications/gis/saga/clang_patch.patch19
-rw-r--r--pkgs/applications/gis/saga/lts.nix33
-rw-r--r--pkgs/top-level/all-packages.nix4
3 files changed, 56 insertions, 0 deletions
diff --git a/pkgs/applications/gis/saga/clang_patch.patch b/pkgs/applications/gis/saga/clang_patch.patch
new file mode 100644
index 000000000000..e6af8d130514
--- /dev/null
+++ b/pkgs/applications/gis/saga/clang_patch.patch
@@ -0,0 +1,19 @@
+commit e92b250968e9656084ab5984689747ca615ff6e7
+Author: Volker Wichmann <wichmann@laserdata.at>
+Date:   Sun Mar 5 13:49:53 2017 +0100
+
+    saga_api, CSG_Table::Del_Records(): bug fix, check record count correctly
+
+diff --git a/src/saga_core/saga_api/table.cpp b/src/saga_core/saga_api/table.cpp
+index 76a1d8d..fa1a66f 100644
+--- a/src/saga_core/saga_api/table.cpp
++++ b/src/saga_core/saga_api/table.cpp
+@@ -901,7 +901,7 @@ bool CSG_Table::Del_Record(int iRecord)
+ //---------------------------------------------------------
+ bool CSG_Table::Del_Records(void)
+ {
+-	if( m_Records > 0 )
++	if( m_nRecords > 0 )
+ 	{
+ 		_Index_Destroy();
+
diff --git a/pkgs/applications/gis/saga/lts.nix b/pkgs/applications/gis/saga/lts.nix
new file mode 100644
index 000000000000..a0e9d64ac8e8
--- /dev/null
+++ b/pkgs/applications/gis/saga/lts.nix
@@ -0,0 +1,33 @@
+{ stdenv, fetchgit, gdal, wxGTK30, proj, libiodbc, lzma, jasper,
+  libharu, opencv, vigra, postgresql, autoreconfHook, Cocoa
+  , unixODBC , poppler, hdf4, hdf5, netcdf, sqlite }:
+
+stdenv.mkDerivation rec {
+  name = "saga-2.3.2";
+
+  # See https://groups.google.com/forum/#!topic/nix-devel/h_vSzEJAPXs
+  # for why the have additional buildInputs on darwin
+  buildInputs = [ autoreconfHook gdal wxGTK30 proj libharu opencv vigra
+                  postgresql libiodbc lzma jasper
+                  Cocoa unixODBC poppler hdf4.out hdf5 netcdf sqlite ];
+
+  enableParallelBuilding = true;
+
+  sourceRoot = "code-b6f474f/saga-gis";
+
+  patches = [ ./clang_patch.patch ];
+
+  src = fetchgit {
+    url = "https://git.code.sf.net/p/saga-gis/code.git";
+    rev = "b6f474f8af4af7f0ff82548cc6f88c53547d91f5";
+    sha256 = "0iakynai8mhcwj6wxvafkqhd7b417ss7hyhbcp9wf6092l6vc2zd";
+  };
+
+  meta = with stdenv.lib; {
+    description = "System for Automated Geoscientific Analyses";
+    homepage = http://www.saga-gis.org;
+    license = licenses.gpl2Plus;
+    maintainers = [ maintainers.mpickering ];
+    platforms = with platforms; unix;
+  };
+}
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index 7e124de83a48..56088c77e847 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -19882,6 +19882,10 @@ with pkgs;
     inherit (darwin.apple_sdk.frameworks) Cocoa;
   };
 
+  saga_2_3_2 = callPackage ../applications/gis/saga/lts.nix {
+    inherit (darwin.apple_sdk.frameworks) Cocoa;
+  };
+
   samplv1 = callPackage ../applications/audio/samplv1 { };
 
   sauerbraten = callPackage ../games/sauerbraten {};