python-pyqt: fix PyQt_qreal_double enabling/disabling
authorGwenhael Goavec-Merou <gwenhael.goavec-merou@trabucayre.com>
Sat, 25 Apr 2015 10:41:16 +0000 (12:41 +0200)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Sun, 26 Apr 2015 10:13:19 +0000 (12:13 +0200)
fix :
http://autobuild.buildroot.net/results/6a2/6a28855c11b321ce8ceaf0acdd5395738af931fd/
http://autobuild.buildroot.net/results/91a/91a3641d1e4126475bbca0d3c779582832f6db91/
http://autobuild.buildroot.net/results/b10/b10fa70c199fc2de405068fea1eac80c29577747/
http://autobuild.buildroot.net/results/b53/b5334ac80afb58a19bd40b7c0b18378d75bc8fc7/
http://autobuild.buildroot.net/results/01f/01fa1319e467c3c2410fd462dc40c18b82dc8246/
http://autobuild.buildroot.net/results/2e6/2e6cae93ab860175c405e440bc7e24334b5b14e8/

According to configure-ng.py, PyQt_qreal_double must be disabled on
ARM target and when QT_NO_FPU is set.

[Thomas: refactor code using a hidden Config.in boolean.]

Signed-off-by: Gwenhael Goavec-Merou <gwenhael.goavec-merou@trabucayre.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
package/python-pyqt/Config.in
package/python-pyqt/python-pyqt.mk

index d4544fa2265df1e904aab612e8927ca3682fb908..a50cb74a43d0f4ac29b14a25af7342b1065d39b6 100644 (file)
@@ -13,3 +13,13 @@ config BR2_PACKAGE_PYTHON_PYQT
          PyQt4 for Qt Embedded 4 bindings.
 
          http://www.riverbankcomputing.com/software/pyqt/
+
+if BR2_PACKAGE_PYTHON_PYQT
+
+config BR2_PACKAGE_PYTHON_PYQT_ARCH_USES_QREAL_FLOAT
+       bool
+       default y if BR2_arm || BR2_armeb
+       default y if BR2_sh4 || BR2_sh4eb || BR2_sh4a || BR2_sh4aeb
+       default y if (BR2_mipsel || BR2_mips) && BR2_PACKAGE_QT_EMBEDDED
+
+endif
index 2363f7d062b24483eb45bced3c4efc3d4217a489..24455677002a0fcd03e92948830d452b35eeeaeb 100644 (file)
@@ -33,13 +33,19 @@ endif
 # Turn off features that aren't available in QWS and current qt
 # configuration.
 PYTHON_PYQT_QTDETAIL_DISABLE_FEATURES = \
-       PyQt_Accessibility PyQt_SessionManager PyQt_qreal_double \
+       PyQt_Accessibility PyQt_SessionManager \
        PyQt_Shortcut PyQt_RawFont
 
 ifeq ($(BR2_PACKAGE_QT_OPENSSL),)
 PYTHON_PYQT_QTDETAIL_DISABLE_FEATURES += PyQt_OpenSSL
 endif
 
+# PyQt_qreal_double must be disabled on a number of architectures that
+# use float for qreal.
+ifeq ($(BR2_PACKAGE_PYTHON_PYQT_ARCH_USES_QREAL_FLOAT),y)
+PYTHON_PYQT_QTDETAIL_DISABLE_FEATURES += PyQt_qreal_double
+endif
+
 define PYTHON_PYQT_QTDETAIL
        echo $(1) >> $(2)/qtdetail.out
 endef