-
Notifications
You must be signed in to change notification settings - Fork 143
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #137 from swt2c/sip5
Add support for building with sip 5
- Loading branch information
Showing
3 changed files
with
44 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
"""The build configuration file for QHexEdit, used by sip.""" | ||
|
||
import os | ||
from os.path import abspath, join | ||
from sipbuild import Option | ||
from pyqtbuild import PyQtBindings, PyQtProject | ||
import PyQt5 | ||
|
||
|
||
class QHexEditProject(PyQtProject): | ||
"""The QHexEdit Project class.""" | ||
|
||
def __init__(self): | ||
super().__init__() | ||
self.bindings_factories = [QHexEditBindings] | ||
|
||
def update(self, tool): | ||
"""Allows SIP to find PyQt5 .sip files.""" | ||
super().update(tool) | ||
self.sip_include_dirs.append(join(PyQt5.__path__[0], 'bindings')) | ||
|
||
|
||
class QHexEditBindings(PyQtBindings): | ||
"""The QHexEdit Bindings class.""" | ||
|
||
def __init__(self, project): | ||
super().__init__(project, name='QHexEdit', | ||
sip_file='qhexedit.sip', | ||
qmake_QT=['widgets']) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
[build-system] | ||
requires = ["sip >=5", "PyQt-builder", "PyQt5"] | ||
build-backend = "sipbuild.api" | ||
|
||
[tool.sip.metadata] | ||
name = "QHexEdit" | ||
version = "0.8.9" | ||
|
||
[tools.sip] | ||
abi-version = "12.8" | ||
project-factory = "pyqtbuild:PyQtProject" | ||
|
||
[tool.sip.project] | ||
sip-files-dir = "src" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters