diff options
author | rm <rm@FreeBSD.org> | 2015-11-19 06:13:53 +0800 |
---|---|---|
committer | rm <rm@FreeBSD.org> | 2015-11-19 06:13:53 +0800 |
commit | bbee0e4fe8e66d074b9436ffd9aacb4a7ecea500 (patch) | |
tree | ec1bdc7c9faebdb932da5779d45f74e9a3eeb407 /graphics | |
parent | 8e9566a7b08aaa3f286467c75dc81bd607e2dc08 (diff) | |
download | freebsd-ports-gnome-bbee0e4fe8e66d074b9436ffd9aacb4a7ecea500.tar.gz freebsd-ports-gnome-bbee0e4fe8e66d074b9436ffd9aacb4a7ecea500.tar.zst freebsd-ports-gnome-bbee0e4fe8e66d074b9436ffd9aacb4a7ecea500.zip |
Let gnome3 stack be built with python 3.5
This mostly fixing packaging for python3.5, but there is
also py35 waf fix for py3-cairo, that was obtained from Ubuntu
repository.
PR: 204075
Approved by: maintainer timeout (22 days)
Diffstat (limited to 'graphics')
-rw-r--r-- | graphics/eog-plugins/Makefile | 12 | ||||
-rw-r--r-- | graphics/eog-plugins/pkg-plist | 14 | ||||
-rw-r--r-- | graphics/py3-cairo/Makefile | 16 | ||||
-rw-r--r-- | graphics/py3-cairo/files/pycairo-1.10.0-waf-py3_5.patch | 10 | ||||
-rw-r--r-- | graphics/py3-cairo/pkg-plist | 2 |
5 files changed, 42 insertions, 12 deletions
diff --git a/graphics/eog-plugins/Makefile b/graphics/eog-plugins/Makefile index f20682e75089..337a250159ff 100644 --- a/graphics/eog-plugins/Makefile +++ b/graphics/eog-plugins/Makefile @@ -63,4 +63,14 @@ post-patch: ${WRKSRC}/configure .endif -.include <bsd.port.mk> +.include <bsd.port.pre.mk> + +.if ${PYTHON_REL} < 3500 +PYOEXTENSION= pyo +.else +PYOEXTENSION= opt-1.pyc +.endif + +PLIST_SUB+= PYOEXTENSION=${PYOEXTENSION} + +.include <bsd.port.post.mk> diff --git a/graphics/eog-plugins/pkg-plist b/graphics/eog-plugins/pkg-plist index ba39eda38006..3a7668908ba2 100644 --- a/graphics/eog-plugins/pkg-plist +++ b/graphics/eog-plugins/pkg-plist @@ -2,14 +2,14 @@ lib/eog/plugins/exif-display.plugin %%PYTHON%%lib/eog/plugins/export-to-folder.plugin %%PYTHON%%lib/eog/plugins/export-to-folder.py %%PYTHON%%lib/eog/plugins/__pycache__/export-to-folder.cpython-%%PYVER%%.pyc -%%PYTHON%%lib/eog/plugins/__pycache__/export-to-folder.cpython-%%PYVER%%.pyo +%%PYTHON%%lib/eog/plugins/__pycache__/export-to-folder.cpython-%%PYVER%%.%%PYOEXTENSION%% %%PYTHON%%lib/eog/plugins/__pycache__/maximize-windows.cpython-%%PYVER%%.pyc -%%PYTHON%%lib/eog/plugins/__pycache__/maximize-windows.cpython-%%PYVER%%.pyo +%%PYTHON%%lib/eog/plugins/__pycache__/maximize-windows.cpython-%%PYVER%%.%%PYOEXTENSION%% lib/eog/plugins/fit-to-width.plugin %%PYTHON%%lib/eog/plugins/fullscreenbg.plugin %%PYTHON%%lib/eog/plugins/fullscreenbg.py %%PYTHON%%lib/eog/plugins/__pycache__/fullscreenbg.cpython-%%PYVER%%.pyc -%%PYTHON%%lib/eog/plugins/__pycache__/fullscreenbg.cpython-%%PYVER%%.pyo +%%PYTHON%%lib/eog/plugins/__pycache__/fullscreenbg.cpython-%%PYVER%%.%%PYOEXTENSION%% lib/eog/plugins/hide-titlebar.plugin lib/eog/plugins/libexif-display.so lib/eog/plugins/libfit-to-width.so @@ -26,18 +26,18 @@ lib/eog/plugins/postasa.plugin %%PYTHON%%lib/eog/plugins/pythonconsole.plugin %%PYTHON%%lib/eog/plugins/pythonconsole/__init__.py %%PYTHON%%lib/eog/plugins/pythonconsole/__pycache__/__init__.cpython-%%PYVER%%.pyc -%%PYTHON%%lib/eog/plugins/pythonconsole/__pycache__/__init__.cpython-%%PYVER%%.pyo +%%PYTHON%%lib/eog/plugins/pythonconsole/__pycache__/__init__.cpython-%%PYVER%%.%%PYOEXTENSION%% %%PYTHON%%lib/eog/plugins/pythonconsole/__pycache__/config.cpython-%%PYVER%%.pyc -%%PYTHON%%lib/eog/plugins/pythonconsole/__pycache__/config.cpython-%%PYVER%%.pyo +%%PYTHON%%lib/eog/plugins/pythonconsole/__pycache__/config.cpython-%%PYVER%%.%%PYOEXTENSION%% %%PYTHON%%lib/eog/plugins/pythonconsole/__pycache__/console.cpython-%%PYVER%%.pyc -%%PYTHON%%lib/eog/plugins/pythonconsole/__pycache__/console.cpython-%%PYVER%%.pyo +%%PYTHON%%lib/eog/plugins/pythonconsole/__pycache__/console.cpython-%%PYVER%%.%%PYOEXTENSION%% %%PYTHON%%lib/eog/plugins/pythonconsole/config.py %%PYTHON%%lib/eog/plugins/pythonconsole/console.py lib/eog/plugins/send-by-mail.plugin %%PYTHON%%lib/eog/plugins/slideshowshuffle.plugin %%PYTHON%%lib/eog/plugins/slideshowshuffle.py %%PYTHON%%lib/eog/plugins/__pycache__/slideshowshuffle.cpython-%%PYVER%%.pyc -%%PYTHON%%lib/eog/plugins/__pycache__/slideshowshuffle.cpython-%%PYVER%%.pyo +%%PYTHON%%lib/eog/plugins/__pycache__/slideshowshuffle.cpython-%%PYVER%%.%%PYOEXTENSION%% share/appdata/eog-exif-display.metainfo.xml %%PYTHON%%share/appdata/eog-export-to-folder.metainfo.xml share/appdata/eog-fit-to-width.metainfo.xml diff --git a/graphics/py3-cairo/Makefile b/graphics/py3-cairo/Makefile index 34c4b3e61fdd..9fa022fdf211 100644 --- a/graphics/py3-cairo/Makefile +++ b/graphics/py3-cairo/Makefile @@ -20,7 +20,16 @@ LDFLAGS+= -L${LOCALBASE}/lib SHEBANG_FILES= examples/*.py examples/*/*.py test/*.py -PLIST_SUB+= PYTVER=${PYTHON_VER:S/.//} +.include <bsd.port.pre.mk> + +.if ${PYTHON_REL} < 3500 +PYOEXTENSION= pyo +.else +PYOEXTENSION= opt-1.pyc +.endif + +PLIST_SUB+= PYTVER=${PYTHON_VER:S/.//} \ + PYOEXTENSION=${PYOEXTENSION} post-patch: @${REINPLACE_CMD} -e 's|python %s|${PYTHON_CMD} %s|g' \ @@ -30,7 +39,8 @@ pre-configure: # Run waf configure twice, once to extract waflib and patch and then actual configure @cd ${WRKSRC} && ${SETENV} ${CONFIGURE_ENV} ${CONFIGURE_CMD} || : @cd ${WRKSRC}/.waf3-1.6.4-e3c1e08604b18a10567cfcd2d02eb6e6/ && \ - ${PATCH} -p1 < ${FILESDIR}/pycairo-1.10.0-waf-py3_4.patch + ${PATCH} -p1 < ${FILESDIR}/pycairo-1.10.0-waf-py3_4.patch && \ + ${PATCH} -p1 < ${FILESDIR}/pycairo-1.10.0-waf-py3_5.patch post-install: @${RM} ${STAGEDIR}${PYTHON_SITELIBDIR}/cairo/__init__.py[co] @@ -40,4 +50,4 @@ post-install: -d ${PYTHONPREFIX_SITELIBDIR} -f ${PYTHONPREFIX_SITELIBDIR:S;${PREFIX}/;;} @${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/cairo/_cairo.so -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/graphics/py3-cairo/files/pycairo-1.10.0-waf-py3_5.patch b/graphics/py3-cairo/files/pycairo-1.10.0-waf-py3_5.patch new file mode 100644 index 000000000000..dcfdbea2fbdc --- /dev/null +++ b/graphics/py3-cairo/files/pycairo-1.10.0-waf-py3_5.patch @@ -0,0 +1,10 @@ +--- a/waflib/Build.py ++++ b/waflib/Build.py +@@ -151,6 +151,7 @@ class BuildContext(Context.Context): + f.close() + self.init_dirs() + def store(self): ++ return + data={} + for x in SAVED_ATTRS: + data[x]=getattr(self,x) diff --git a/graphics/py3-cairo/pkg-plist b/graphics/py3-cairo/pkg-plist index 433916acfb52..b720e36e0691 100644 --- a/graphics/py3-cairo/pkg-plist +++ b/graphics/py3-cairo/pkg-plist @@ -1,6 +1,6 @@ include/pycairo/py3cairo.h %%PYTHON_SITELIBDIR%%/cairo/__pycache__/__init__.cpython-%%PYTVER%%.pyc -%%PYTHON_SITELIBDIR%%/cairo/__pycache__/__init__.cpython-%%PYTVER%%.pyo +%%PYTHON_SITELIBDIR%%/cairo/__pycache__/__init__.cpython-%%PYTVER%%.%%PYOEXTENSION%% %%PYTHON_SITELIBDIR%%/cairo/__init__.py %%PYTHON_SITELIBDIR%%/cairo/_cairo.so libdata/pkgconfig/py3cairo.pc |