diff options
author | Yuri Victorovich <yuri@FreeBSD.org> | 2021-02-22 08:11:07 +0000 |
---|---|---|
committer | Yuri Victorovich <yuri@FreeBSD.org> | 2021-02-22 08:11:07 +0000 |
commit | dd5f7a57021bf8d6d79ff717d82d8a94cce48258 (patch) | |
tree | c484d99df850f2829effe6d1fafb228d6cb7800e /science/py-veusz | |
parent | 00ec803b347d3fc54b4c312b2e0c7e3819e7ac0f (diff) | |
download | ports-dd5f7a57021bf8d6d79ff717d82d8a94cce48258.tar.gz ports-dd5f7a57021bf8d6d79ff717d82d8a94cce48258.zip |
Notes
Diffstat (limited to 'science/py-veusz')
-rw-r--r-- | science/py-veusz/Makefile | 9 | ||||
-rw-r--r-- | science/py-veusz/distinfo | 6 | ||||
-rw-r--r-- | science/py-veusz/files/patch-pyqtdistutils.py | 83 |
3 files changed, 10 insertions, 88 deletions
diff --git a/science/py-veusz/Makefile b/science/py-veusz/Makefile index 1a1d9edcdd9f..0632ce35a4e8 100644 --- a/science/py-veusz/Makefile +++ b/science/py-veusz/Makefile @@ -3,8 +3,7 @@ PORTNAME= veusz DISTVERSIONPREFIX= ${PORTNAME}- -DISTVERSION= 3.2.1 -PORTREVISION= 5 +DISTVERSION= 3.3.1 CATEGORIES= science PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} @@ -26,4 +25,10 @@ SHEBANG_FILES= examples/embedexample.py MAKE_ENV= SIP_DIR=${LOCALBASE}/share/PyQt5/${PYTHON_VER}/sip +post-install: + # strip + ${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/veusz/helpers/*.so + # workaround for https://github.com/veusz/veusz/issues/475 + ${REINPLACE_CMD} -i '' -e 's|PyQt5||' ${STAGEDIR}${PYTHON_SITELIBDIR}/*/requires.txt + .include <bsd.port.mk> diff --git a/science/py-veusz/distinfo b/science/py-veusz/distinfo index 69b14960a3cd..1321f687a6b8 100644 --- a/science/py-veusz/distinfo +++ b/science/py-veusz/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1585035752 -SHA256 (veusz-veusz-veusz-3.2.1_GH0.tar.gz) = 8128e47bbaffff99298d5ab3ec3296c84ce1b5976dce319527acbbe6125e433e -SIZE (veusz-veusz-veusz-3.2.1_GH0.tar.gz) = 1712860 +TIMESTAMP = 1613978246 +SHA256 (veusz-veusz-veusz-3.3.1_GH0.tar.gz) = 308d32c85d334553019a6e7b6847a625c700a85570f4ac2d2de37466563d0cb8 +SIZE (veusz-veusz-veusz-3.3.1_GH0.tar.gz) = 2443328 diff --git a/science/py-veusz/files/patch-pyqtdistutils.py b/science/py-veusz/files/patch-pyqtdistutils.py deleted file mode 100644 index 792e4d24cbd5..000000000000 --- a/science/py-veusz/files/patch-pyqtdistutils.py +++ /dev/null @@ -1,83 +0,0 @@ -Patch from https://github.com/veusz/veusz/pull/433 - ---- pyqtdistutils.py.orig 2020-10-11 07:18:07 UTC -+++ pyqtdistutils.py -@@ -10,9 +10,8 @@ import sys - import sysconfig - import subprocess - --from distutils.sysconfig import customize_compiler -+from distutils.sysconfig import customize_compiler, get_python_lib - import distutils.command.build_ext --from distutils.dep_util import newer, newer_group - - import PyQt5.QtCore - -@@ -97,20 +96,6 @@ class build_ext(distutils.command.build_ext.build_ext) - self.qt_library_dir = None - self.qt_libinfix = None - -- def _get_sip_output_list(self, sbf): -- ''' -- Parse the sbf file specified to extract the name of the generated source -- files. Make them absolute assuming they reside in the temp directory. -- ''' -- for line in open(sbf): -- key, value = line.split('=', 1) -- if key.strip() == 'sources': -- out = [] -- for o in value.split(): -- out.append(os.path.join(self.build_temp, o)) -- return out -- raise RuntimeError('cannot parse SIP-generated "%s"' % sbf) -- - def _get_sip_exe(self, build_cmd): - """Get exe for sip. Sources are: - --sip-exe option, environment, DEF_SIP_BIN, search on path.""" -@@ -289,26 +274,35 @@ class build_ext(distutils.command.build_ext.build_ext) - generated_sources = [] - - for sip in sip_sources: -- # Use the sbf file as dependency check -- sipbasename = os.path.basename(sip) -- sbf = os.path.join(self.build_temp, -- replace_suffix(sipbasename, '.sbf')) -- if newer_group([sip]+depends, sbf) or self.force: -- self._sip_compile(sip_exe, sip_dir, sip, sbf) -- out = self._get_sip_output_list(sbf) -+ sip_basename = os.path.basename(sip)[:-4] -+ sip_builddir = os.path.join(self.build_temp, 'sip-' + sip_basename) -+ if not os.path.exists(sip_builddir) or self.force: -+ os.makedirs(sip_builddir, exist_ok=True) -+ self._sip_compile(sip_exe, sip_dir, sip, sip_builddir) -+ out = [ -+ os.path.join(sip_builddir, fn) -+ for fn in os.listdir(sip_builddir) -+ if fn.endswith(".cpp") -+ ] - generated_sources.extend(out) - - return generated_sources + other_sources - -- def _sip_compile(self, sip_exe, sip_dir, source, sbf): -+ def _sip_compile(self, sip_exe, sip_dir, source, sip_builddir): - """Compile sip file to sources.""" -+ if 'sip5' in sip_exe: -+ pyqt5_include_dir = os.path.join(get_python_lib(plat_specific=1), -+ 'PyQt5', 'bindings') -+ self.spawn(['sip-module', '--target-dir', sip_builddir, -+ '--sip-h', 'PyQt5.sip']) -+ else: -+ pyqt5_include_dir = os.path.join(sip_dir, 'PyQt5') - self.spawn( - [ - sip_exe, -- '-c', self.build_temp -+ '-c', sip_builddir - ] + SIP_FLAGS.split() + [ -- '-I', os.path.join(sip_dir, 'PyQt5'), -- '-b', sbf, -+ '-I', pyqt5_include_dir, - source - ] - ) |