diff mbox series

[1/2] package/python-sip: bump to version 4.19.25

Message ID 20220523224646.2151739-1-aduskett@gmail.com
State Accepted
Headers show
Series [1/2] package/python-sip: bump to version 4.19.25 | expand

Commit Message

Adam Duskett May 23, 2022, 10:46 p.m. UTC
This version is the minimum version needed to support newer versions of PyQT.

Changes:
  - Update the URL as this version is not hosted on sourceforge.
  - Add --no-stubs to prevent the error: No such file or directory: sip.pyi
  - Add 0001-remove-join-from-sip-h-files-string.patch to prevent python-sip
    from attempting to copy the entire hosts /usr directory when installing.
Signed-off-by: Adam Duskett <aduskett@gmail.com>
---
 ...-remove-join-from-sip-h-files-string.patch | 33 +++++++++++++++++++
 package/python-sip/python-sip.hash            | 10 +++---
 package/python-sip/python-sip.mk              |  6 ++--
 3 files changed, 40 insertions(+), 9 deletions(-)
 create mode 100644 package/python-sip/0001-remove-join-from-sip-h-files-string.patch

Comments

Thomas Petazzoni June 2, 2022, 1:48 p.m. UTC | #1
On Mon, 23 May 2022 15:46:45 -0700
Adam Duskett <aduskett@gmail.com> wrote:

> This version is the minimum version needed to support newer versions of PyQT.
> 
> Changes:
>   - Update the URL as this version is not hosted on sourceforge.
>   - Add --no-stubs to prevent the error: No such file or directory: sip.pyi
>   - Add 0001-remove-join-from-sip-h-files-string.patch to prevent python-sip
>     from attempting to copy the entire hosts /usr directory when installing.
> Signed-off-by: Adam Duskett <aduskett@gmail.com>
> ---
>  ...-remove-join-from-sip-h-files-string.patch | 33 +++++++++++++++++++
>  package/python-sip/python-sip.hash            | 10 +++---
>  package/python-sip/python-sip.mk              |  6 ++--
>  3 files changed, 40 insertions(+), 9 deletions(-)
>  create mode 100644 package/python-sip/0001-remove-join-from-sip-h-files-string.patch

Applied to next, thanks. However, I would really like the patch
0001-remove-join-from-sip-h-files-string.patch to be submitted
upstream. Of course, it probably can't be accepted upstream as-is, but
this can create the discussion that will hopefully lead to an
upstream-acceptable solution.

Thanks!

Thomas
diff mbox series

Patch

diff --git a/package/python-sip/0001-remove-join-from-sip-h-files-string.patch b/package/python-sip/0001-remove-join-from-sip-h-files-string.patch
new file mode 100644
index 0000000000..e7a0d606e9
--- /dev/null
+++ b/package/python-sip/0001-remove-join-from-sip-h-files-string.patch
@@ -0,0 +1,33 @@ 
+From 009e5cf0750134ed5403aae23ef53a177764ca04 Mon Sep 17 00:00:00 2001
+From: Adam Duskett <aduskett@gmail.com>
+Date: Wed, 29 Dec 2021 13:49:15 -0800
+Subject: [PATCH] remove join from sip_h.files string
+
+When cross compiling, the configure system appends the hosts /usr/ directory 
+to the path of which to find files that python-sip will install. This leads to
+python-sip attempting to install everything under the hosts /usr directory into
+the targets /usr/include/python directory.
+
+Remove the .join() in the sip_h.files string to prevent the above issue.
+
+Signed-off-by: Adam Duskett <aduskett@gmail.com>
+---
+ configure.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.py b/configure.py
+index 25bcaa7..fc8f2dc 100644
+--- a/configure.py
++++ b/configure.py
+@@ -408,7 +408,7 @@ def create_makefiles(macros):
+             # There will only be one element.
+             files, path = gen_installs[0]
+             pro.write("\n")
+-            pro.write("sip_h.files = %s\n" % " ".join(files))
++            pro.write("sip_h.files = %s\n" % files)
+             pro.write("sip_h.path = %s\n" % quote(path))
+             pro.write("INSTALLS += sip_h\n")
+ 
+-- 
+2.33.1
+
diff --git a/package/python-sip/python-sip.hash b/package/python-sip/python-sip.hash
index 6adf44d410..0108924cdc 100644
--- a/package/python-sip/python-sip.hash
+++ b/package/python-sip/python-sip.hash
@@ -1,7 +1,5 @@ 
-# From https://sourceforge.net/projects/pyqt/files/sip/sip-4.18/
-md5 78724bf2a79878201c3bc81a1d8248ea	sip-4.18.tar.gz
 # Locally calculated:
-sha256 f1dc5c81c07a9ad97edcd4a0af964a41e420024ba7ca165afd2b351efd249cb6	 sip-4.18.tar.gz
-sha256 accecbfda71ad4497bce0d451796706e734e405e5ecf3b3f9ee0cc68300a3d9c  LICENSE
-sha256 7ebb61006e46b9e9340dd135d5f4afbbcb1d1d6c6709f74473b35929007b9aeb  LICENSE-GPL2
-sha256 63cb5f5c1ea39b732c495f354f971e40f6db84c567ca5573a68bb65af07741f8  LICENSE-GPL3
+sha256  b39d93e937647807bac23579edbff25fe46d16213f708370072574ab1f1b4211  sip-4.19.25.tar.gz
+sha256  accecbfda71ad4497bce0d451796706e734e405e5ecf3b3f9ee0cc68300a3d9c  LICENSE
+sha256  7ebb61006e46b9e9340dd135d5f4afbbcb1d1d6c6709f74473b35929007b9aeb  LICENSE-GPL2
+sha256  63cb5f5c1ea39b732c495f354f971e40f6db84c567ca5573a68bb65af07741f8  LICENSE-GPL3
diff --git a/package/python-sip/python-sip.mk b/package/python-sip/python-sip.mk
index 01ccb1ddd5..3e015fa16c 100644
--- a/package/python-sip/python-sip.mk
+++ b/package/python-sip/python-sip.mk
@@ -4,12 +4,11 @@ 
 #
 ################################################################################
 
-PYTHON_SIP_VERSION = 4.18
+PYTHON_SIP_VERSION = 4.19.25
 PYTHON_SIP_SOURCE = sip-$(PYTHON_SIP_VERSION).tar.gz
-PYTHON_SIP_SITE = http://downloads.sourceforge.net/project/pyqt/sip/sip-$(PYTHON_SIP_VERSION)
+PYTHON_SIP_SITE = https://www.riverbankcomputing.com/static/Downloads/sip/$(PYTHON_SIP_VERSION)
 PYTHON_SIP_LICENSE = SIP license or GPL-2.0 or GPL-3.0
 PYTHON_SIP_LICENSE_FILES = LICENSE LICENSE-GPL2 LICENSE-GPL3
-
 PYTHON_SIP_DEPENDENCIES = python3 qt5base
 HOST_PYTHON_SIP_DEPENDENCIES = host-python3
 
@@ -34,6 +33,7 @@  define PYTHON_SIP_CONFIGURE_CMDS
 			--incdir $(STAGING_DIR)/usr/include/python$(PYTHON3_VERSION_MAJOR) \
 			--sipdir $(TARGET_DIR)/usr/share/sip \
 			--sysroot $(STAGING_DIR)/usr \
+			--no-stubs \
 			--use-qmake && \
 		$(HOST_DIR)/bin/qmake)
 endef