From 8f2084a6d0857e2d69b2bb6bc5eaa4abf5f47966 Mon Sep 17 00:00:00 2001 From: Peter Kling <1018801+pitkling@users.noreply.github.com> Date: Thu, 9 Jan 2025 14:25:07 +0100 Subject: [PATCH] python312Packages.macfsevents: do not include unnecessary files `data_files` installs into Python's installation prefix (not into the directory of the python module), potentially causing collisions if other packages do the same (with such general files). --- .../python-modules/macfsevents/default.nix | 2 ++ .../macfsevents/fix-packaging.patch | 16 ++++++++++++++++ 2 files changed, 18 insertions(+) create mode 100644 pkgs/development/python-modules/macfsevents/fix-packaging.patch diff --git a/pkgs/development/python-modules/macfsevents/default.nix b/pkgs/development/python-modules/macfsevents/default.nix index 77e82746e77d..e240f96929d1 100644 --- a/pkgs/development/python-modules/macfsevents/default.nix +++ b/pkgs/development/python-modules/macfsevents/default.nix @@ -16,6 +16,8 @@ buildPythonPackage rec { hash = "sha256-v3KD8dUXdkzNyBlbIWMdu6wcUGuSC/mo6ilWsxJ2Ucs="; }; + patches = [ ./fix-packaging.patch ]; + buildInputs = [ CoreFoundation CoreServices diff --git a/pkgs/development/python-modules/macfsevents/fix-packaging.patch b/pkgs/development/python-modules/macfsevents/fix-packaging.patch new file mode 100644 index 000000000000..21569c63ade5 --- /dev/null +++ b/pkgs/development/python-modules/macfsevents/fix-packaging.patch @@ -0,0 +1,16 @@ +diff --git a/setup.py b/setup.py +index d7f9bb0..7707e38 100644 +--- a/setup.py ++++ b/setup.py +@@ -21,11 +21,6 @@ def read(fname): + description = "Thread-based interface to file system observation primitives.", + long_description = "\n\n".join((read('README.rst'), read('CHANGES.rst'))), + license = "BSD", +- data_files = [("", [ +- "compat.h", +- "LICENSE.txt", +- "CHANGES.rst" +- ])], + author = "Malthe Borch", + author_email = "mborch@gmail.com", + url = 'https://github.com/malthe/macfsevents',