summaryrefslogtreecommitdiff
path: root/dev-python/coloredlogs/files
diff options
context:
space:
mode:
authorroot <root@alpha.trunkmasters.com>2026-06-12 19:09:37 -0500
committerroot <root@alpha.trunkmasters.com>2026-06-12 19:09:37 -0500
commitb590c8d7572b727d565cc0b8ff660d43569845de (patch)
tree06f7a4102ea4e845df8b66660f252920d52952f9 /dev-python/coloredlogs/files
parent24f9cbfc4c34fdb6a6e03311674414e881ceab47 (diff)
downloadbaldeagleos-repo-b590c8d7572b727d565cc0b8ff660d43569845de.tar.gz
baldeagleos-repo-b590c8d7572b727d565cc0b8ff660d43569845de.tar.xz
baldeagleos-repo-b590c8d7572b727d565cc0b8ff660d43569845de.zip
Adding metadata
Diffstat (limited to 'dev-python/coloredlogs/files')
-rw-r--r--dev-python/coloredlogs/files/coloredlogs-14.0-fix-install-prefix.patch35
-rw-r--r--dev-python/coloredlogs/files/coloredlogs-15.0.1-py3.13.patch43
2 files changed, 78 insertions, 0 deletions
diff --git a/dev-python/coloredlogs/files/coloredlogs-14.0-fix-install-prefix.patch b/dev-python/coloredlogs/files/coloredlogs-14.0-fix-install-prefix.patch
new file mode 100644
index 000000000000..d6b60c3bdf57
--- /dev/null
+++ b/dev-python/coloredlogs/files/coloredlogs-14.0-fix-install-prefix.patch
@@ -0,0 +1,35 @@
+commit 6f566c799323feb3b8dc2b82e62953040a6a5129
+Author: Louis Sautier <sautier.louis@gmail.com>
+Date: Sat Sep 26 10:30:37 2020 +0200
+
+ setup.py: use absolute paths for pth files
+
+ On some systems (such as PyPy3 on Gentoo), distutils' `data` path is not
+ `sys.prefix`, which means that we cannot rely on relative paths.
+
+diff --git a/setup.py b/setup.py
+index 057dd80..7674adc 100755
+--- a/setup.py
++++ b/setup.py
+@@ -66,9 +66,9 @@ def find_pth_directory():
+ Determine the correct directory pathname for installing ``*.pth`` files.
+
+ To install a ``*.pth`` file using a source distribution archive (created
+- when ``python setup.py sdist`` is called) the relative directory pathname
+- ``lib/pythonX.Y/site-packages`` needs to be passed to the ``data_files``
+- option to ``setup()``.
++ when ``python setup.py sdist`` is called) the directory pathname
++ ``/usr/lib/pythonX.Y/site-packages`` needs to be passed to the ``data_files``
++ option of ``setup()``.
+
+ Unfortunately this breaks universal wheel archives (created when ``python
+ setup.py bdist_wheel --universal`` is called) because a specific Python
+@@ -81,7 +81,7 @@ def find_pth_directory():
+ directory without hard coding its location.
+ """
+ return ('/' if 'bdist_wheel' in sys.argv
+- else os.path.relpath(distutils.sysconfig.get_python_lib(), sys.prefix))
++ else distutils.sysconfig.get_python_lib())
+
+
+ setup(name='coloredlogs',
diff --git a/dev-python/coloredlogs/files/coloredlogs-15.0.1-py3.13.patch b/dev-python/coloredlogs/files/coloredlogs-15.0.1-py3.13.patch
new file mode 100644
index 000000000000..649683b4944e
--- /dev/null
+++ b/dev-python/coloredlogs/files/coloredlogs-15.0.1-py3.13.patch
@@ -0,0 +1,43 @@
+From 9d4f4020897fcf48d381de8e099dc29b53fc9531 Mon Sep 17 00:00:00 2001
+From: "Benjamin A. Beasley" <code@musicinmybrain.net>
+Date: Wed, 12 Jun 2024 14:00:28 -0400
+Subject: [PATCH] Replace pipes.quote with shlex.quote on Python 3
+
+The shlex.quote() API is available from Python 3.3 on; pipes.quote() was
+never documented, and is removed in Python 3.13.
+
+Fixes #119.
+
+Upstream-PR: https://github.com/xolox/python-coloredlogs/pull/120
+Upstream-Issue: https://github.com/xolox/python-coloredlogs/issues/119
+
+diff --git a/coloredlogs/converter/__init__.py b/coloredlogs/converter/__init__.py
+index a424469..96817a0 100644
+--- a/coloredlogs/converter/__init__.py
++++ b/coloredlogs/converter/__init__.py
+@@ -9,11 +9,15 @@
+ # Standard library modules.
+ import codecs
+ import os
+-import pipes
+ import re
+ import subprocess
+ import tempfile
+
++try:
++ from shlex import quote # Python 3
++except ImportError:
++ from pipes import quote # Python 2 (removed in 3.13)
++
+ # External dependencies.
+ from humanfriendly.terminal import (
+ ANSI_CSI,
+@@ -75,7 +79,7 @@ def capture(command, encoding='UTF-8'):
+ #
+ # [1] http://man7.org/linux/man-pages/man1/script.1.html
+ # [2] https://developer.apple.com/legacy/library/documentation/Darwin/Reference/ManPages/man1/script.1.html
+- command_line = ['script', '-qc', ' '.join(map(pipes.quote, command)), '/dev/null']
++ command_line = ['script', '-qc', ' '.join(map(quote, command)), '/dev/null']
+ script = subprocess.Popen(command_line, stdout=subprocess.PIPE, stderr=dev_null)
+ stdout, stderr = script.communicate()
+ if script.returncode == 0: