diff options
author | Francesco Colista <fcolista@alpinelinux.org> | 2019-02-13 15:35:39 +0000 |
---|---|---|
committer | Francesco Colista <fcolista@alpinelinux.org> | 2019-02-13 15:35:44 +0000 |
commit | 7ff2a006e31b607cccc22ab293186296037a9f33 (patch) | |
tree | 0f9c7871fbfe6fb4b462698e29116e3c4ed2861f /community/gns3-gui | |
parent | ee9ea42e8072a9c11dc6fd9995296ff649bcb86a (diff) | |
download | aports-7ff2a006e31b607cccc22ab293186296037a9f33.tar.bz2 aports-7ff2a006e31b607cccc22ab293186296037a9f33.tar.xz |
community/gns3-gui: fix sip dependency
Diffstat (limited to 'community/gns3-gui')
-rw-r--r-- | community/gns3-gui/APKBUILD | 12 | ||||
-rw-r--r-- | community/gns3-gui/fix-qt5-sip.patch | 200 |
2 files changed, 207 insertions, 5 deletions
diff --git a/community/gns3-gui/APKBUILD b/community/gns3-gui/APKBUILD index 23c974d247..669f1d63d0 100644 --- a/community/gns3-gui/APKBUILD +++ b/community/gns3-gui/APKBUILD @@ -2,16 +2,17 @@ # Maintainer: Francesco Colista <fcolista@alpinelinux.org> pkgname=gns3-gui pkgver=2.1.12 -pkgrel=0 +pkgrel=1 pkgdesc="GNS3 network simulator. Graphical user interface package." url="https://github.com/GNS3/gns3-gui" arch="noarch" license="GPL-3.0" -depends="python3 py3-paramiko gns3-converter py3-psutil py3-jsonschema - py3-raven py3-qt5 qt5-qtsvg" +depends="python3 py3-paramiko py3-psutil py3-jsonschema + py3-raven py3-qt5 qt5-qtsvg py3-sip" makedepends="python3-dev py-setuptools" subpackages="$pkgname-doc" -source="${pkgname}-${pkgver}.tar.gz::https://github.com/GNS3/${pkgname}/archive/v${pkgver}.tar.gz" +source="${pkgname}-${pkgver}.tar.gz::https://github.com/GNS3/${pkgname}/archive/v${pkgver}.tar.gz +fix-qt5-sip.patch" builddir="$srcdir"/$pkgname-$pkgver build() { @@ -31,4 +32,5 @@ package() { install -Dm644 ${srcdir}/${pkgname}-${pkgver}/LICENSE ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE } -sha512sums="8846a26982a167d5c645f6127a29ec76a1d30e28ff4e256f3bb45e14833887779c1346554b590366a4f51d71925b262152cded2a7e8de9313d4bd6af97c7d943 gns3-gui-2.1.12.tar.gz" +sha512sums="8846a26982a167d5c645f6127a29ec76a1d30e28ff4e256f3bb45e14833887779c1346554b590366a4f51d71925b262152cded2a7e8de9313d4bd6af97c7d943 gns3-gui-2.1.12.tar.gz +a38f3b2c6864ccc3fe78422a92b9a83ea1fa04c15e26131d74e6303dcc6671148d2860dc129483bac53f699dd25cbdfae20ac63ab170891fd4640c739d4bfc6c fix-qt5-sip.patch" diff --git a/community/gns3-gui/fix-qt5-sip.patch b/community/gns3-gui/fix-qt5-sip.patch new file mode 100644 index 0000000000..0712fc4497 --- /dev/null +++ b/community/gns3-gui/fix-qt5-sip.patch @@ -0,0 +1,200 @@ +diff --git a/gns3/console_cmd.py b/gns3/console_cmd.py +index 5e630f43..b1d0673a 100644 +--- a/gns3/console_cmd.py ++++ b/gns3/console_cmd.py +@@ -22,7 +22,7 @@ Handles commands typed in the GNS3 console. + import sys + import cmd + import struct +-import sip ++from .qt import sip + import json + + from .node import Node +diff --git a/gns3/console_view.py b/gns3/console_view.py +index 10edb860..365f7bc1 100644 +--- a/gns3/console_view.py ++++ b/gns3/console_view.py +@@ -16,7 +16,7 @@ + # along with this program. If not, see <http://www.gnu.org/licenses/>. + + import sys +-import sip ++from .qt import sip + import struct + import inspect + import datetime +diff --git a/gns3/crash_report.py b/gns3/crash_report.py +index bc37d061..a9379e16 100644 +--- a/gns3/crash_report.py ++++ b/gns3/crash_report.py +@@ -132,7 +132,7 @@ class CrashReport: + def _add_qt_information(self, context): + try: + from .qt import QtCore +- import sip ++ from .qt import sip + except ImportError: + return context + context["psutil:version"] = psutil.__version__ +diff --git a/gns3/dialogs/appliance_wizard.py b/gns3/dialogs/appliance_wizard.py +index 06f2bf2a..8ab386b4 100644 +--- a/gns3/dialogs/appliance_wizard.py ++++ b/gns3/dialogs/appliance_wizard.py +@@ -16,7 +16,7 @@ + # along with this program. If not, see <http://www.gnu.org/licenses/>. + + import os +-import sip ++from ..qt import sip + import shutil + + from ..qt import QtWidgets, QtCore, QtGui, qpartial, qslot +diff --git a/gns3/graphics_view.py b/gns3/graphics_view.py +index 517bfaaf..da058385 100644 +--- a/gns3/graphics_view.py ++++ b/gns3/graphics_view.py +@@ -21,7 +21,7 @@ Graphical view on the scene where items are drawn. + + import logging + import os +-import sip ++from .qt import sip + import sys + + from .qt import QtCore, QtGui, QtNetwork, QtWidgets, qpartial, qslot +diff --git a/gns3/http_client.py b/gns3/http_client.py +index c0ceca69..6993bf58 100644 +--- a/gns3/http_client.py ++++ b/gns3/http_client.py +@@ -15,7 +15,7 @@ + # You should have received a copy of the GNU General Public License + # along with this program. If not, see <http://www.gnu.org/licenses/>. + +-import sip ++from .qt import sip + import json + import copy + import http +diff --git a/gns3/items/node_item.py b/gns3/items/node_item.py +index cac82e70..b4ec7930 100644 +--- a/gns3/items/node_item.py ++++ b/gns3/items/node_item.py +@@ -19,7 +19,7 @@ + Graphical representation of a node on the QGraphicsScene. + """ + +-import sip ++from ..qt import sip + + from ..qt import QtCore, QtGui, QtWidgets, QtSvg, qslot + from ..qt.qimage_svg_renderer import QImageSvgRenderer +diff --git a/gns3/link.py b/gns3/link.py +index 1cd634c0..323823b1 100644 +--- a/gns3/link.py ++++ b/gns3/link.py +@@ -21,7 +21,7 @@ Manages and stores everything needed for a connection between 2 devices. + + import os + import re +-import sip ++from .qt import sip + import uuid + + from .qt import QtCore, QtWidgets +diff --git a/gns3/nodes_view.py b/gns3/nodes_view.py +index 463a63fe..16f51ed4 100644 +--- a/gns3/nodes_view.py ++++ b/gns3/nodes_view.py +@@ -22,7 +22,7 @@ on the QGraphics scene. + + import tempfile + import json +-import sip ++from .qt import sip + + from .qt import QtCore, QtGui, QtWidgets, qpartial + from .modules import MODULES +diff --git a/gns3/ports/port.py b/gns3/ports/port.py +index 66776a33..3425df0a 100644 +--- a/gns3/ports/port.py ++++ b/gns3/ports/port.py +@@ -19,7 +19,7 @@ + Base class for port objects. + """ + +-import sip ++from ..qt import sip + + from ..qt import qslot + +diff --git a/gns3/progress.py b/gns3/progress.py +index 4f167bbd..33135513 100644 +--- a/gns3/progress.py ++++ b/gns3/progress.py +@@ -15,7 +15,7 @@ + # You should have received a copy of the GNU General Public License + # along with this program. If not, see <http://www.gnu.org/licenses/>. + +-import sip ++from .qt import sip + import time + from contextlib import contextmanager + +diff --git a/gns3/qt/__init__.py b/gns3/qt/__init__.py +index b8d9550e..ae88c4bf 100644 +--- a/gns3/qt/__init__.py ++++ b/gns3/qt/__init__.py +@@ -24,7 +24,6 @@ Compatibility layer for Qt bindings, so it is easier to switch to PySide if need + + + import sys +-import sip + import os + import re + import inspect +@@ -33,12 +32,17 @@ import functools + import logging + log = logging.getLogger("qt/__init__.py") + ++try: ++ import sip ++except ImportError: ++ from PyQt5 import sip + from PyQt5 import QtCore, QtGui, QtNetwork, QtWidgets, Qt + sys.modules[__name__ + '.QtCore'] = QtCore + sys.modules[__name__ + '.QtGui'] = QtGui + sys.modules[__name__ + '.QtNetwork'] = QtNetwork + sys.modules[__name__ + '.QtWidgets'] = QtWidgets + sys.modules[__name__ + '.Qt'] = Qt ++sys.modules[__name__ + '.sip'] = sip + + try: + from PyQt5 import QtSvg +diff --git a/gns3/utils/progress_dialog.py b/gns3/utils/progress_dialog.py +index b6a84af9..9742e1b3 100644 +--- a/gns3/utils/progress_dialog.py ++++ b/gns3/utils/progress_dialog.py +@@ -19,7 +19,7 @@ + Progress dialog that blocking tasks (file operations, network connections etc.) + """ + +-import sip ++from ..qt import sip + from gns3.version import __version__ + from ..qt import QtWidgets, QtCore, qslot + +diff --git a/gns3/utils/wait_for_lambda_worker.py b/gns3/utils/wait_for_lambda_worker.py +index 78a5207a..d24a3cb0 100644 +--- a/gns3/utils/wait_for_lambda_worker.py ++++ b/gns3/utils/wait_for_lambda_worker.py +@@ -19,7 +19,7 @@ + Thread showing a progress dialog and running the code from a lambda + """ + +-import sip ++from ..qt import sip + + from ..qt import QtCore + + |