summary refs log tree commit diff
path: root/pkgs/development
diff options
context:
space:
mode:
authorDanylo Hlynskyi <abcz2.uprola@gmail.com>2019-01-26 21:15:43 +0200
committerGitHub <noreply@github.com>2019-01-26 21:15:43 +0200
commit4fb8bc8238aa0366d78bae6095676ef7e08c17b2 (patch)
tree47b20a1e7a6186479bbed3dfc79505817fed5cd7 /pkgs/development
parent18f23748dc6d8be05520e9259e679aa71b57a9c7 (diff)
downloadnixpkgs-4fb8bc8238aa0366d78bae6095676ef7e08c17b2.tar
nixpkgs-4fb8bc8238aa0366d78bae6095676ef7e08c17b2.tar.gz
nixpkgs-4fb8bc8238aa0366d78bae6095676ef7e08c17b2.tar.bz2
nixpkgs-4fb8bc8238aa0366d78bae6095676ef7e08c17b2.tar.lz
nixpkgs-4fb8bc8238aa0366d78bae6095676ef7e08c17b2.tar.xz
nixpkgs-4fb8bc8238aa0366d78bae6095676ef7e08c17b2.tar.zst
nixpkgs-4fb8bc8238aa0366d78bae6095676ef7e08c17b2.zip
postgresql: cleanup postgis (#54396)
postgis: cleanup

Another part of https://github.com/NixOS/nixpkgs/pull/38698, though I did cleanup even more.
Moving docs to separate output should save another 30MB.

I did pin poppler to 0.61 just to be sure GDAL doesn't break again next
time poppler changes internal APIs.
Diffstat (limited to 'pkgs/development')
-rw-r--r--pkgs/development/libraries/postgis/default.nix105
1 files changed, 0 insertions, 105 deletions
diff --git a/pkgs/development/libraries/postgis/default.nix b/pkgs/development/libraries/postgis/default.nix
deleted file mode 100644
index be7fc6f8c17..00000000000
--- a/pkgs/development/libraries/postgis/default.nix
+++ /dev/null
@@ -1,105 +0,0 @@
-{ fetchurl
-, stdenv
-, perl
-, libxml2
-, postgresql
-, geos
-, proj
-, gdal
-, json_c
-, pkgconfig
-, file
-}:
-
-  /*
-
-  ### NixOS - usage:
-  ==================
-
-    services.postgresql.extraPlugins = [ (pkgs.postgis.override { postgresql = pkgs.postgresql_9_5; }) ];
-
-
-  ### important Postgis implementation details:
-  =============================================
-
-    Postgis provides a shared library implementing many operations. They are
-    exposed to the Postgres SQL interpreter by special SQL queries eg:
-
-      CREATE FUNCTION [...]
-              AS '[..]liblwgeom', 'lwhistogram2d_in' LANGUAGE 'C' IMMUTABLE STRICT; -- WITH (isstrict);
-
-   where liblwgeom is the shared library.
-   Postgis < 1.5 used absolute paths, in NixOS $libdir is always used.
-
-   Thus if you want to use postgresql dumps which were created by non NixOS
-   systems you have to adopt the library path.
-
-
-   ### TODO:
-   =========
-   the bin commands to have gtk gui:
-  */
-
-
-let
-  version = "2.5.1";
-  sha256 = "14bsh4kflp4bxilypkpmhrpldknc9s9vgiax8yfhxbisyib704zv";
-in stdenv.mkDerivation rec {
-  name = "postgis-${version}";
-
-  src = fetchurl {
-    url = "https://download.osgeo.org/postgis/source/postgis-${builtins.toString version}.tar.gz";
-    inherit sha256;
-  };
-
-  # don't pass these vars to the builder
-  removeAttrs = ["sql_comments" "sql_srcs"];
-
-  preInstall = ''
-    mkdir -p $out/bin
-  '';
-
-  # create aliases for all commands adding version information
-  postInstall = ''
-    sql_srcs=$(for sql in ${builtins.toString sql_srcs}; do echo -n "$(find $out -iname "$sql") "; done )
-
-    for prog in $out/bin/*; do # */
-      ln -s $prog $prog-${version}
-    done
-
-    cp -r doc $out
-  '';
-
-  buildInputs = [ libxml2 postgresql geos proj perl gdal json_c pkgconfig ];
-
-  sql_comments = "postgis_comments.sql";
-
-  sql_srcs = ["postgis.sql" "spatial_ref_sys.sql"];
-
-  # postgis config directory assumes /include /lib from the same root for json-c library
-  NIX_LDFLAGS = "-L${stdenv.lib.getLib json_c}/lib";
-
-  dontDisableStatic = true;
-  preConfigure = ''
-    sed -i 's@/usr/bin/file@${file}/bin/file@' configure
-    configureFlags="--datadir=$out/share --datarootdir=$out/share --bindir=$out/bin --with-gdalconfig=${gdal}/bin/gdal-config --with-jsondir=${json_c.dev}"
-    makeFlags="PERL=${perl}/bin/perl datadir=$out/share pkglibdir=$out/lib bindir=$out/bin"
-  '';
-  postConfigure = ''
-    sed -i "s|@mkdir -p \$(DESTDIR)\$(PGSQL_BINDIR)||g ;
-            s|\$(DESTDIR)\$(PGSQL_BINDIR)|$prefix/bin|g
-            " \
-        "raster/loader/Makefile";
-    sed -i "s|\$(DESTDIR)\$(PGSQL_BINDIR)|$prefix/bin|g
-            " \
-        "raster/scripts/python/Makefile";
-  '';
-
-  meta = with stdenv.lib; {
-    description = "Geographic Objects for PostgreSQL";
-    homepage = http://postgis.refractions.net;
-    license = licenses.gpl2;
-    maintainers = [ maintainers.marcweber ];
-    platforms = platforms.linux;
-  };
-}