Package Details: pyqt4-common 4.12.3-8

Git Clone URL: https://aur.archlinux.org/pyqt4.git (read-only, click to copy)
Package Base: pyqt4
Description: Common PyQt files shared between python-pyqt4 and python2-pyqt4
Upstream URL: https://riverbankcomputing.com/software/pyqt/intro
Licenses: GPL
Conflicts: pyqt-common
Provides: pyqt-common
Replaces: pyqt-common
Submitter: arojas
Maintainer: LaughingMan
Last Packager: LaughingMan
Votes: 20
Popularity: 0.000000
First Submitted: 2018-08-24 08:49 (UTC)
Last Updated: 2025-12-10 23:06 (UTC)

Latest Comments

1 2 3 4 5 6 .. 11 Next › Last »

LaughingMan commented on 2025-12-10 23:11 (UTC)

Ah, I had misunderstood how dependency declarations within package work and assumed it would be available at build time as well. Fixed.

micwoj92 commented on 2025-12-10 19:49 (UTC)

qt4 is not in dependency tree for makedeps, I only need to install (from aur): python2 python2-dbus python2-opengl python2-sip-pyqt4 sip4.

qt4 only is declared as dependency in package_pyqt4-common step.

LaughingMan commented on 2025-12-10 17:26 (UTC)

@micwoj92: Can't reproduce. Builds fine both on my live system as well as in a clean chroot. Are you missing qmake-qt4 entirely or did your permissions just get messed up?

micwoj92 commented on 2025-12-09 16:49 (UTC)

Build fails:

==> Starting build()...
Usage: python configure-ng.py [opts] [name=value] [name+=value]

configure-ng.py: error: '/usr/bin/qmake-qt4' is not an executable
==> ERROR: A failure occurred in build().
    Aborting...

zer0def commented on 2025-04-25 17:04 (UTC) (edited on 2025-04-26 03:57 (UTC) by zer0def)

Or if you'd like to push your luck, you can try this patch, on the basis of https://github.com/python/cpython/blob/v3.8.20/Objects/abstract.c#L292-L316

diff --git a/qpy/QtCore/qpycore_pyqtsignal.cpp b/qpy/QtCore/qpycore_pyqtsignal.cpp
--- a/qpy/QtCore/qpycore_pyqtsignal.cpp 2025-04-25 17:45:13.313875991 +0200
+++ b/qpy/QtCore/qpycore_pyqtsignal.cpp 2025-04-25 17:46:22.604618384 +0200
@@ -658,7 +658,11 @@ PyObject *qpycore_call_signal_overload(q
     if (!func)
         return 0;

+#if PY_MAJOR_VERSION >= 3
+    PyObject *result = PyObject_Call(func, args, kw);
+#else
     PyObject *result = PyCFunction_Call(func, args, kw);
+#endif

     Py_DECREF(func);

diff --git a/qpy/QtCore/qpycore_qtlib.cpp b/qpy/QtCore/qpycore_qtlib.cpp
--- a/qpy/QtCore/qpycore_qtlib.cpp  2025-04-25 17:45:13.314191046 +0200
+++ b/qpy/QtCore/qpycore_qtlib.cpp  2025-04-25 17:45:40.204713167 +0200
@@ -127,7 +127,11 @@ PyObject *qtlib_invoke_slot(const sipSlo

     for (;;)
     {
+#if PY_MAJOR_VERSION >= 3
+        PyObject *resobj = PyObject_CallObject(sfunc, sa);
+#else
         PyObject *resobj = PyEval_CallObject(sfunc, sa);
+#endif

         if (resobj)
         {
diff --git a/qpy/QtCore/qpycore_qstring.cpp b/qpy/QtCore/qpycore_qstring.cpp
--- a/qpy/QtCore/qpycore_qstring.cpp     2018-08-31 09:37:06.000000000 +0200
+++ b/qpy/QtCore/qpycore_qstring.cpp 2025-04-25 18:14:38.746056092 +0200
@@ -246,6 +246,9 @@ const char *qpycore_encode(PyObject **s,
     PyObject *obj = *s;
     const char *es = 0;
     SIP_SSIZE_T sz;
+#if PY_MAJOR_VERSION >= 3
+    Py_buffer view;
+#endif

     if (PyUnicode_Check(obj))
     {
@@ -291,17 +294,22 @@ const char *qpycore_encode(PyObject **s,
         es = PyBytes_AS_STRING(obj);
         Py_INCREF(obj);
     }
+    else if (PyObject_GetBuffer(obj, &view, PyBUF_SIMPLE) >= 0)
 #else
     else if (PyString_Check(obj))
     {
         es = PyString_AS_STRING(obj);
         Py_INCREF(obj);
     }
-#endif
     else if (PyObject_AsCharBuffer(obj, &es, &sz) >= 0)
+#endif
     {
         Py_INCREF(obj);
     }
+#if PY_MAJOR_VERSION >= 3
+    es = (const char*)view.buf;
+    PyBuffer_Release(&view);
+#endif

     if (es)
     {

LaughingMan commented on 2025-01-07 12:18 (UTC)

Python 3.13 removed PyObject_AsCharBuffer. Since there really is no point in maintaining the Python 3 side, python-pyqt4 has been dropped. Only python2-pyqt4 is kept for the legacy applications. (Also dropped the phonon-qt4 optional dependency. Thanks for mentioning it, MarsSeed.)

Shoxx98 commented on 2025-01-06 20:19 (UTC)

building fails for me

../qpy/QtCore/qpycore_qstring.cpp:301:14: error: ‘PyObject_AsCharBuffer’ was not declared in this scope; did you mean ‘PyObject_CheckBuffer’?
  301 |     else if (PyObject_AsCharBuffer(obj, &es, &sz) >= 0)
      |              ^~~~~~~~~~~~~~~~~~~~~
      |              PyObject_CheckBuffer
make[1]: *** [Makefile:1320: qpycore_qstring.o] Error 1
make[1]: Leaving directory '/home/jonas/.cache/yay/pyqt4/src/PyQt4_gpl_x11-4.12.3/QtCore'
make: *** [Makefile:60: sub-QtCore-make_default-ordered] Error 2
==> ERROR: A failure occurred in build().
    Aborting...

LaughingMan commented on 2024-05-15 02:30 (UTC)

Package builds fine for me with Python 3.12. IIRC it did indeed not build around the time you posted, but now it does. An update to some dependency must have fixed it.

MarsSeed commented on 2024-04-30 10:38 (UTC) (edited on 2024-04-30 10:57 (UTC) by MarsSeed)

Also I think phonon-qt4 is safe to drop from make/opt depends, as none of the existing applications that use python2-pyqt4 seem to require multimedia playback capability via phonon.

MarsSeed commented on 2024-04-26 11:54 (UTC) (edited on 2024-04-30 09:22 (UTC) by MarsSeed)

The build of python-pyqt4 is broken on Python 3.12.

It is likely that they can be fixed, but actually you can safely drop the Python3 package of pyqt4. As all its reverse dependencies are already broken, EOL, unmaintained, and pending deletion.