pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

py-tables: Clean up macOS patch



Module Name:	pkgsrc-wip
Committed By:	Jason W. Bacon <bacon%NetBSD.org@localhost>
Pushed By:	outpaddling
Date:		Mon Dec 2 07:33:45 2024 -0600
Changeset:	c42801775880a8e3ea94399ccc97106162cb4500

Modified Files:
	py-tables/distinfo
	py-tables/patches/patch-setup.py

Log Message:
py-tables: Clean up macOS patch

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=c42801775880a8e3ea94399ccc97106162cb4500

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 py-tables/distinfo               |  2 +-
 py-tables/patches/patch-setup.py | 43 +++++++++++++++++++---------------------
 2 files changed, 21 insertions(+), 24 deletions(-)

diffs:
diff --git a/py-tables/distinfo b/py-tables/distinfo
index 3ff0dc4e15..79161bac4d 100644
--- a/py-tables/distinfo
+++ b/py-tables/distinfo
@@ -3,4 +3,4 @@ $NetBSD: distinfo,v 1.9 2024/10/23 22:55:52 wiz Exp $
 BLAKE2s (tables-3.10.1.tar.gz) = 1150b460680ad8bad06e7fbf137cb576e80de0de2d0d5b1d3175df9ec3a7db2b
 SHA512 (tables-3.10.1.tar.gz) = 7590dccefdd718d170ac288d391173ed540760a911f53fd39e37dd74237dc554f9363c8d9d4d518f067da299d71a1d8cb4a40134b1afaf79daa0a17de248caf5
 Size (tables-3.10.1.tar.gz) = 4762413 bytes
-SHA1 (patch-setup.py) = 82e32fd4f0d6aea42b3e01afa464150c8823c82a
+SHA1 (patch-setup.py) = 08a24f0d3e26c41d94493cc7e977d1dd49c36143
diff --git a/py-tables/patches/patch-setup.py b/py-tables/patches/patch-setup.py
index 3924a6516e..100c8b1d21 100644
--- a/py-tables/patches/patch-setup.py
+++ b/py-tables/patches/patch-setup.py
@@ -1,18 +1,10 @@
 $NetBSD$
 
-# Hack for macOS, where setup.py thinks it didn't find blosc
+# Hack to fix PLIST issue on macOS
 
 --- setup.py.orig	2024-08-17 08:56:33.000000000 +0000
 +++ setup.py
-@@ -418,6 +418,7 @@ class BasePackage:
-             ]
- 
-         if use_pkgconfig:
-+            print("find_directories() using pkgconfig...")
-             # header
-             pkgconfig_header_dirs = [
-                 Path(d[2:])
-@@ -455,6 +456,10 @@ class BasePackage:
+@@ -455,6 +455,10 @@ class BasePackage:
  
          hook_dirs = hook() if hook is not None else [None, None, None]
  
@@ -23,7 +15,7 @@ $NetBSD$
          directories = [None, None, None]  # headers, libraries, runtime
          for idx, (name, find_path, default_dirs) in enumerate(dirdata):
              use_locations = (
-@@ -463,6 +468,7 @@ class BasePackage:
+@@ -463,6 +467,7 @@ class BasePackage:
                  or hook_dirs[idx]
                  or default_dirs
              )
@@ -31,7 +23,7 @@ $NetBSD$
              # pkgconfig does not list bin/ as the runtime dir
              if (
                  name == "blosc"  # blosc
-@@ -475,8 +481,12 @@ class BasePackage:
+@@ -475,8 +480,12 @@ class BasePackage:
                  use_locations = list(use_locations)
                  use_locations[0] = use_locations[0].parent / "bin"
                  print(f"Patching runtime dir: {str(use_locations[0])}")
@@ -44,19 +36,24 @@ $NetBSD$
                  if path is True:
                      directories[idx] = True
                      continue
-@@ -497,6 +507,15 @@ class BasePackage:
+@@ -496,7 +505,19 @@ class BasePackage:
+                     directories[idx] = Path(path[: path.rfind(name)])
                  else:
                      directories[idx] = Path(path).parent
- 
-+        if name == "blosc" or name == "blosc2":
-+            print("directories = ", directories)
-+            print("rundir (should be 'True') = ", directories[2])
-+            # sys.exit(1)
-+            # FIXME: Forcing rundir to True for macOS.  This is a hack,
-+            # but it's the value it should have, since the headers and libs
-+            # are found.  This prevents setup.py from copying libblosc
-+            # into the py-tables installation, breaking PLIST.
-+            directories[2] = True
+-
++            else:
++                print("path is not set!!  This is a problem.")
++                if name == "blosc" or name == "blosc2":
++                    print("directories = ", directories)
++                    print("rundir (should be 'True') = ", directories[2])
++                    sys.exit(1)
++                    # FIXME: tables-3.10.1 hack
++                    # Forcing rundir to True for macOS.  This is a
++                    # hack, but it's the value it should have, since the
++                    # headers and libs are found.  When rundir is None,
++                    # setup.py copyies libblosc into the py-tables
++                    # installation, breaking PLIST.
++                    directories[2] = True
          return tuple(directories)
  
  


Home | Main Index | Thread Index | Old Index