diff options
| author | Adrian Fiergolski <adrian.fiergolski@fastree3d.com> | 2020-02-05 12:36:30 +0100 |
|---|---|---|
| committer | Martin Jansa <Martin.Jansa@gmail.com> | 2020-02-06 14:01:49 +0100 |
| commit | caf09cd53cc2a4eb10a1d1124dadd2a34fb6b116 (patch) | |
| tree | b75706bbf09038bab26eda637da6c6568c893cc2 /recipes-python | |
| parent | f18d5948bb9d53e07241ef7f2b399e485e170d07 (diff) | |
| download | meta-qt5-caf09cd53cc2a4eb10a1d1124dadd2a34fb6b116.tar.gz | |
Add PyQtChart.
Signed-off-by: Adrian Fiergolski <adrian.fiergolski@fastree3d.com>
Diffstat (limited to 'recipes-python')
| -rw-r--r-- | recipes-python/pyqtchart/python-pyqtchart.inc | 66 | ||||
| -rw-r--r-- | recipes-python/pyqtchart/python3-pyqtchart_5.13.1.bb | 7 |
2 files changed, 73 insertions, 0 deletions
diff --git a/recipes-python/pyqtchart/python-pyqtchart.inc b/recipes-python/pyqtchart/python-pyqtchart.inc new file mode 100644 index 00000000..e8dba18a --- /dev/null +++ b/recipes-python/pyqtchart/python-pyqtchart.inc | |||
| @@ -0,0 +1,66 @@ | |||
| 1 | SUMMARY = "Python Qt Chart Bindings" | ||
| 2 | AUTHOR = "Adrian.Fiergolski@fastree3d.com" | ||
| 3 | SECTION = "devel/python" | ||
| 4 | LICENSE = "GPLv3" | ||
| 5 | LIC_FILES_CHKSUM = "\ | ||
| 6 | file://LICENSE;md5=d32239bcb673463ab874e80d47fae504 \ | ||
| 7 | " | ||
| 8 | SRC_URI = "\ | ||
| 9 | https://www.riverbankcomputing.com/static/Downloads/PyQtChart/${PV}/PyQtChart-${PV}.tar.gz \ | ||
| 10 | " | ||
| 11 | SRC_URI[md5sum] = "d5d37bff46b690d6318e5e5f25dd5213" | ||
| 12 | SRC_URI[sha256sum] = "49960a1483527857b38c1527f9b6328d30bdcc84521f579c0a561a892f54130e" | ||
| 13 | |||
| 14 | S = "${WORKDIR}/PyQtChart-${PV}" | ||
| 15 | |||
| 16 | inherit qmake5 | ||
| 17 | DEPENDS = "qtbase qtdeclarative qtquickcontrols2" | ||
| 18 | |||
| 19 | export BUILD_SYS | ||
| 20 | export HOST_SYS | ||
| 21 | export STAGING_INCDIR | ||
| 22 | export STAGING_LIBDIR | ||
| 23 | |||
| 24 | PARALLEL_MAKEINST = "" | ||
| 25 | |||
| 26 | DISABLED_FEATURES = "PyQt_Desktop_OpenGL PyQt_Accessibility PyQt_SessionManager" | ||
| 27 | |||
| 28 | DISABLED_FEATURES_append_arm = " PyQt_qreal_double" | ||
| 29 | |||
| 30 | do_configure_prepend() { | ||
| 31 | cd ${S} | ||
| 32 | echo "[PyQt 5]" > pyqt.cfg | ||
| 33 | echo "py_platform = linux" >> pyqt.cfg | ||
| 34 | echo "py_inc_dir = %(sysroot)/$includedir/python%(py_major).%(py_minor)${PYTHON_ABI}" >> pyqt.cfg | ||
| 35 | echo "py_pylib_dir = %(sysroot)/${libdir}/python%(py_major).%(py_minor)" >> pyqt.cfg | ||
| 36 | echo "pyqt_module_dir = ${D}/${libdir}/python%(py_major).%(py_minor)/site-packages" >> pyqt.cfg | ||
| 37 | echo "py_sip_dir = ${STAGING_EXECPREFIXDIR}/share/sip" >> pyqt.cfg | ||
| 38 | echo "sip_module = PyQt5.sip" >> pyqt.cfg | ||
| 39 | echo "pyqt_disabled_features = ${DISABLED_FEATURES}" >> pyqt.cfg | ||
| 40 | echo yes | ${PYTHON} configure.py --verbose --qmake ${STAGING_BINDIR_NATIVE}/${QT_DIR_NAME}/qmake --configuration pyqt.cfg --sysroot ${STAGING_DIR_HOST} | ||
| 41 | } | ||
| 42 | |||
| 43 | do_configure_append() { | ||
| 44 | #Fix installation paths | ||
| 45 | sed -i -e s:'$(INSTALL_ROOT)'${STAGING_EXECPREFIXDIR}:'$(INSTALL_ROOT)'${D}${exec_prefix}:g ${S}/Makefile | ||
| 46 | sed -i -e s:'$(INSTALL_ROOT)'${STAGING_EXECPREFIXDIR}:'$(INSTALL_ROOT)'${D}${exec_prefix}:g ${S}/QtChart/Makefile | ||
| 47 | #Skip installed.txt creation | ||
| 48 | sed -i -e s:" install_distinfo ":" ": ${S}/Makefile | ||
| 49 | } | ||
| 50 | |||
| 51 | do_compile() { | ||
| 52 | cd ${S} | ||
| 53 | oe_runmake | ||
| 54 | } | ||
| 55 | |||
| 56 | do_install() { | ||
| 57 | cd ${S} | ||
| 58 | oe_runmake MAKEFLAGS='-j 1' install | ||
| 59 | } | ||
| 60 | |||
| 61 | |||
| 62 | FILES_${PN} += "${libdir}/${PYTHON_DIR}/site-packages ${datadir}/" | ||
| 63 | |||
| 64 | DEPENDS = "qtcharts" | ||
| 65 | |||
| 66 | RDEPENDS_${PN} = "qtbase qtdeclarative qtquickcontrols2 qtquickcontrols2-mkspecs qtcharts" | ||
diff --git a/recipes-python/pyqtchart/python3-pyqtchart_5.13.1.bb b/recipes-python/pyqtchart/python3-pyqtchart_5.13.1.bb new file mode 100644 index 00000000..899f9691 --- /dev/null +++ b/recipes-python/pyqtchart/python3-pyqtchart_5.13.1.bb | |||
| @@ -0,0 +1,7 @@ | |||
| 1 | require python-pyqtchart.inc | ||
| 2 | |||
| 3 | inherit python3native python3-dir | ||
| 4 | |||
| 5 | DEPENDS += "sip3 sip3-native python3 python3-pyqt5" | ||
| 6 | |||
| 7 | RDEPENDS_${PN} += "python3-core python3-sip3 python3-pyqt5" | ||
