about summary refs log tree commit diff
path: root/nixpkgs/pkgs/by-name/ki
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2023-12-15 19:32:38 +0100
committerAlyssa Ross <hi@alyssa.is>2023-12-15 19:32:38 +0100
commit6b8e2555ef013b579cda57025b17d662e0f1fe1f (patch)
tree5a83c673af26c9976acd5a5dfa20e09e06898047 /nixpkgs/pkgs/by-name/ki
parent66ca7a150b5c051f0728f13134e6265cc46f370c (diff)
parent02357adddd0889782362d999628de9d309d202dc (diff)
downloadnixlib-6b8e2555ef013b579cda57025b17d662e0f1fe1f.tar
nixlib-6b8e2555ef013b579cda57025b17d662e0f1fe1f.tar.gz
nixlib-6b8e2555ef013b579cda57025b17d662e0f1fe1f.tar.bz2
nixlib-6b8e2555ef013b579cda57025b17d662e0f1fe1f.tar.lz
nixlib-6b8e2555ef013b579cda57025b17d662e0f1fe1f.tar.xz
nixlib-6b8e2555ef013b579cda57025b17d662e0f1fe1f.tar.zst
nixlib-6b8e2555ef013b579cda57025b17d662e0f1fe1f.zip
Merge branch 'nixos-unstable-small' of https://github.com/NixOS/nixpkgs
Diffstat (limited to 'nixpkgs/pkgs/by-name/ki')
-rw-r--r--nixpkgs/pkgs/by-name/ki/kikit/default.nix8
-rw-r--r--nixpkgs/pkgs/by-name/ki/kikit/shapely/default.nix71
-rw-r--r--nixpkgs/pkgs/by-name/ki/kikit/shapely/library-paths.patch31
3 files changed, 3 insertions, 107 deletions
diff --git a/nixpkgs/pkgs/by-name/ki/kikit/default.nix b/nixpkgs/pkgs/by-name/ki/kikit/default.nix
index 45209545aa3d..886cca973837 100644
--- a/nixpkgs/pkgs/by-name/ki/kikit/default.nix
+++ b/nixpkgs/pkgs/by-name/ki/kikit/default.nix
@@ -16,13 +16,10 @@
 , pcbnew-transition
 , pybars3
 , versioneer
+, shapely_1_8
 }:
 let
   solidpython = callPackage ./solidpython { };
-
-  # https://github.com/yaqwsx/KiKit/issues/574
-  # copy-pasted from nixpkgs#8d8e62e74f511160a599471549a98bc9e4f4818d
-  shapely = callPackage ./shapely { };
 in
 buildPythonApplication rec {
   pname = "kikit";
@@ -48,7 +45,8 @@ buildPythonApplication rec {
     wxPython_4_2
     pcbnew-transition
     pybars3
-    shapely
+    # https://github.com/yaqwsx/KiKit/issues/574
+    shapely_1_8
     # https://github.com/yaqwsx/KiKit/issues/576
     solidpython
   ];
diff --git a/nixpkgs/pkgs/by-name/ki/kikit/shapely/default.nix b/nixpkgs/pkgs/by-name/ki/kikit/shapely/default.nix
deleted file mode 100644
index 7f136a1338ad..000000000000
--- a/nixpkgs/pkgs/by-name/ki/kikit/shapely/default.nix
+++ /dev/null
@@ -1,71 +0,0 @@
-{ lib
-, stdenv
-, buildPythonPackage
-, fetchPypi
-, substituteAll
-, pythonOlder
-, geos
-, pytestCheckHook
-, cython
-, numpy
-}:
-
-buildPythonPackage rec {
-  pname = "Shapely";
-  version = "1.8.4";
-  disabled = pythonOlder "3.6";
-
-  src = fetchPypi {
-    inherit pname version;
-    sha256 = "sha256-oZXlHKr6IYKR8suqP+9p/TNTyT7EtlsqRyLEz0DDGYw=";
-  };
-
-  nativeBuildInputs = [
-    geos # for geos-config
-    cython
-  ];
-
-  propagatedBuildInputs = [
-    numpy
-  ];
-
-  checkInputs = [
-    pytestCheckHook
-  ];
-
-  # Environment variable used in shapely/_buildcfg.py
-  GEOS_LIBRARY_PATH = "${geos}/lib/libgeos_c${stdenv.hostPlatform.extensions.sharedLibrary}";
-
-  patches = [
-    # Patch to search form GOES .so/.dylib files in a Nix-aware way
-    (substituteAll {
-      src = ./library-paths.patch;
-      libgeos_c = GEOS_LIBRARY_PATH;
-      libc = lib.optionalString (!stdenv.isDarwin) "${stdenv.cc.libc}/lib/libc${stdenv.hostPlatform.extensions.sharedLibrary}.6";
-    })
-  ];
-
-  preCheck = ''
-    rm -r shapely # prevent import of local shapely
-  '';
-
-  disabledTests = lib.optionals (stdenv.isDarwin && stdenv.isAarch64) [
-    # FIXME(lf-): these logging tests are broken, which is definitely our
-    # fault. I've tried figuring out the cause and failed.
-    #
-    # It is apparently some sandbox or no-sandbox related thing on macOS only
-    # though.
-    "test_error_handler_exception"
-    "test_error_handler"
-    "test_info_handler"
-  ];
-
-  pythonImportsCheck = [ "shapely" ];
-
-  meta = with lib; {
-    description = "Geometric objects, predicates, and operations";
-    homepage = "https://pypi.python.org/pypi/Shapely/";
-    license = with licenses; [ bsd3 ];
-    maintainers = with maintainers; [ knedlsepp ];
-  };
-}
diff --git a/nixpkgs/pkgs/by-name/ki/kikit/shapely/library-paths.patch b/nixpkgs/pkgs/by-name/ki/kikit/shapely/library-paths.patch
deleted file mode 100644
index 12f93e757f9a..000000000000
--- a/nixpkgs/pkgs/by-name/ki/kikit/shapely/library-paths.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-diff --git a/shapely/geos.py b/shapely/geos.py
-index 88c5f53..1ccd6e4 100644
---- a/shapely/geos.py
-+++ b/shapely/geos.py
-@@ -96,6 +96,7 @@ if sys.platform.startswith('linux'):
-         alt_paths = [
-             'libgeos_c.so.1',
-             'libgeos_c.so',
-+            '@libgeos_c@',
-         ]
-         _lgeos = load_dll('geos_c', fallbacks=alt_paths)
-
-@@ -160,6 +161,7 @@ elif sys.platform == 'darwin':
-             "/usr/local/lib/libgeos_c.dylib",
-             # homebrew Apple Silicon
-             "/opt/homebrew/lib/libgeos_c.dylib",
-+            "@libgeos_c@",
-         ]
-         _lgeos = load_dll('geos_c', fallbacks=alt_paths)
-
-diff --git a/tests/test_dlls.py b/tests/test_dlls.py
-index c71da8e..c36262c 100644
---- a/tests/test_dlls.py
-+++ b/tests/test_dlls.py
-@@ -18,4 +18,5 @@ class LoadingTestCase(unittest.TestCase):
-             '/opt/homebrew/lib/libgeos_c.dylib',  # homebrew (macOS)
-             os.path.join(sys.prefix, "lib", "libgeos_c.so"), # anaconda (Linux)
-             'libgeos_c.so.1',
--            'libgeos_c.so'])
-+            'libgeos_c.so',
-+            '@libgeos_c@'])