mirror of
https://git.freebsd.org/ports.git
synced 2025-07-18 01:39:16 -04:00
math/py-matplotlib: Add uniquefiles:dirs for version specific files [1]
- Convert to OPTIONSNG - Convert patch files to be 'make makepatch' compatible - Depreciate bsd.port.options.mk - Add STRIP_CMD for shared objects PR: 202205 [1] Submitted by: mazhe@alkumuna.eu [1]
This commit is contained in:
parent
dafc3395c8
commit
a2b4ecec50
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=396886
2 changed files with 42 additions and 63 deletions
|
@ -20,78 +20,44 @@ RUN_DEPENDS= ${PYNUMPY} \
|
||||||
${PYTHON_PKGNAMEPREFIX}pytz>=0:${PORTSDIR}/devel/py-pytz \
|
${PYTHON_PKGNAMEPREFIX}pytz>=0:${PORTSDIR}/devel/py-pytz \
|
||||||
${PYTHON_PKGNAMEPREFIX}parsing>=0:${PORTSDIR}/devel/py-parsing
|
${PYTHON_PKGNAMEPREFIX}parsing>=0:${PORTSDIR}/devel/py-parsing
|
||||||
|
|
||||||
USES= pkgconfig shebangfix python
|
USES= pkgconfig python shebangfix uniquefiles:dirs
|
||||||
USE_PYTHON= distutils autoplist
|
USE_PYTHON= autoplist distutils
|
||||||
CFLAGS+= -I${LOCALBASE}/include
|
CFLAGS+= -I${LOCALBASE}/include
|
||||||
|
|
||||||
OPTIONS_DEFINE= EXAMPLES GTKBACKEND GTKAGGBACKEND TKAGGBACKEND WXAGGBACKEND
|
OPTIONS_DEFINE= EXAMPLES GTKBACKEND GTKAGGBACKEND TKAGGBACKEND WXAGGBACKEND
|
||||||
OPTIONS_DEFAULT= GTKBACKEND GTKAGGBACKEND TKAGGBACKEND
|
OPTIONS_DEFAULT= GTKBACKEND GTKAGGBACKEND TKAGGBACKEND
|
||||||
|
OPTIONS_SUB= yes
|
||||||
GTKBACKEND_DESC= GTK backend support
|
GTKBACKEND_DESC= GTK backend support
|
||||||
|
GTKBACKEND_VARS= GTK_BACKEND=True
|
||||||
|
GTKBACKEND_VARS_OFF= GTK_BACKEND=False
|
||||||
|
GTKBACKEND_USE= GNOME=gtk20,pygtk2
|
||||||
GTKAGGBACKEND_DESC= GTKAgg backend support
|
GTKAGGBACKEND_DESC= GTKAgg backend support
|
||||||
|
GTKAGGBACKEND_USE= GNOME=gtk20,pygtk2
|
||||||
|
GTKAGGBACKEND_VARS= GTKAGG_BACKEND=True
|
||||||
|
GTKAGGBACKEND_VARS_OFF= GTKAGG_BACKEND=False
|
||||||
TKAGGBACKEND_DESC= TKAgg backend support
|
TKAGGBACKEND_DESC= TKAgg backend support
|
||||||
|
TKAGGBACKEND_BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}tkinter>0:${PORTSDIR}/x11-toolkits/py-tkinter
|
||||||
|
TKAGGBACKEND_RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}tkinter>0:${PORTSDIR}/x11-toolkits/py-tkinter
|
||||||
|
TKAGGBACKEND_USES= tk:run
|
||||||
|
TKAGGBACKEND_VARS= TKAGG_BACKEND=True
|
||||||
|
TKAGGBACKEND_VARS_OFF= TKAGG_BACKEND=False
|
||||||
WXAGGBACKEND_DESC= WXAgg backend support
|
WXAGGBACKEND_DESC= WXAgg backend support
|
||||||
|
WXAGGBACKEND_USE= WX=2.8+
|
||||||
|
WXAGGBACKEND_VARS= WX_COMPS=python:lib,WX_UNICODE=yes
|
||||||
|
WXAGGBACKEND_CONFIGURE_ENV= WX_CONFIG="${WX_CONFIG}"
|
||||||
|
WXAGGBACKEND_VARS= WXAGG_BACKEND=True
|
||||||
|
WXAGGBACKEND_VARS_OFF= WXAGG_BACKEND=False
|
||||||
|
|
||||||
PORTEXAMPLES= *
|
PORTEXAMPLES= *
|
||||||
|
UNIQUENAME= ${PORTNAME}
|
||||||
|
|
||||||
.include <bsd.port.options.mk>
|
.if defined(PACKAGE_BUILDING)
|
||||||
|
GTKBACKEND_BUILD_DEPENDS= Xvfb:${PORTSDIR}/x11-servers/xorg-vfbserver
|
||||||
.if defined(PACKAGE_BUILDING) && \
|
GTKAGGBACKEND_BUILD_DEPENDS= Xvfb:${PORTSDIR}/x11-servers/xorg-vfbserver
|
||||||
( ${PORT_OPTIONS:MGTKBACKEND} || ${PORT_OPTIONS:MGTKAGGBACKEND} || \
|
TKAGGBACKEND_BUILD_DEPENDS= Xvfb:${PORTSDIR}/x11-servers/xorg-vfbserver
|
||||||
${PORT_OPTIONS:MTKAGGBACKEND} || ${PORT_OPTIONS:MWXAGGBACKEND} )
|
WXAGGBACKEND_BUILD_DEPENDS= Xvfb:${PORTSDIR}/x11-servers/xorg-vfbserver
|
||||||
BUILD_DEPENDS+= Xvfb:${PORTSDIR}/x11-servers/xorg-vfbserver
|
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if ${PORT_OPTIONS:MGTKBACKEND} || ${PORT_OPTIONS:MGTKAGGBACKEND}
|
|
||||||
USE_GNOME= gtk20 pygtk2
|
|
||||||
.endif
|
|
||||||
|
|
||||||
.if ${PORT_OPTIONS:MGTKBACKEND}
|
|
||||||
GTK_BACKEND= True
|
|
||||||
|
|
||||||
PLIST_SUB+= GTKBACKEND=""
|
|
||||||
.else
|
|
||||||
GTK_BACKEND= False
|
|
||||||
|
|
||||||
PLIST_SUB+= GTKBACKEND="@comment "
|
|
||||||
.endif
|
|
||||||
|
|
||||||
.if ${PORT_OPTIONS:MGTKAGGBACKEND}
|
|
||||||
GTKAGG_BACKEND= True
|
|
||||||
|
|
||||||
PLIST_SUB+= GTKAGGBACKEND=""
|
|
||||||
.else
|
|
||||||
GTKAGG_BACKEND= False
|
|
||||||
|
|
||||||
PLIST_SUB+= GTKAGGBACKEND="@comment "
|
|
||||||
.endif
|
|
||||||
|
|
||||||
.if ${PORT_OPTIONS:MTKAGGBACKEND}
|
|
||||||
BUILD_DEPENDS+= ${PYTHON_PKGNAMEPREFIX}tkinter>0:${PORTSDIR}/x11-toolkits/py-tkinter
|
|
||||||
RUN_DEPENDS+= ${PYTHON_PKGNAMEPREFIX}tkinter>0:${PORTSDIR}/x11-toolkits/py-tkinter
|
|
||||||
|
|
||||||
USES+= tk:run
|
|
||||||
|
|
||||||
TKAGG_BACKEND= True
|
|
||||||
|
|
||||||
PLIST_SUB+= TKAGGBACKEND=""
|
|
||||||
.else
|
|
||||||
TKAGG_BACKEND= False
|
|
||||||
|
|
||||||
PLIST_SUB+= TKAGGBACKEND="@comment "
|
|
||||||
.endif
|
|
||||||
|
|
||||||
.if ${PORT_OPTIONS:MWXAGGBACKEND}
|
|
||||||
USE_WX= 2.8+
|
|
||||||
WX_COMPS= python:lib
|
|
||||||
WX_UNICODE= yes
|
|
||||||
CONFIGURE_ENV+= WX_CONFIG="${WX_CONFIG}"
|
|
||||||
|
|
||||||
WXAGG_BACKEND= True
|
|
||||||
.else
|
|
||||||
WXAGG_BACKEND= False
|
|
||||||
.endif
|
|
||||||
|
|
||||||
EXAMPLESDIR= ${PREFIX}/share/examples/py-${PORTNAME}
|
|
||||||
post-extract:
|
post-extract:
|
||||||
${CHMOD} -R ga+r ${WRKDIR}
|
${CHMOD} -R ga+r ${WRKDIR}
|
||||||
|
|
||||||
|
@ -110,10 +76,23 @@ post-patch:
|
||||||
-e 's|%%WXAGG_BACKEND%%|${WXAGG_BACKEND}|g' \
|
-e 's|%%WXAGG_BACKEND%%|${WXAGG_BACKEND}|g' \
|
||||||
${WRKSRC}/setup.cfg
|
${WRKSRC}/setup.cfg
|
||||||
|
|
||||||
.if ${PORT_OPTIONS:MEXAMPLES}
|
|
||||||
post-install:
|
post-install:
|
||||||
|
${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/matplotlib/_image.so
|
||||||
|
${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/matplotlib/backends/_backend_agg.so
|
||||||
|
${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/matplotlib/backends/_gtkagg.so
|
||||||
|
${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/matplotlib/backends/_tkagg.so
|
||||||
|
${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/matplotlib/backends/_backend_gdk.so
|
||||||
|
${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/matplotlib/_qhull.so
|
||||||
|
${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/matplotlib/ttconv.so
|
||||||
|
${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/matplotlib/_delaunay.so
|
||||||
|
${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/matplotlib/_png.so
|
||||||
|
${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/matplotlib/_tri.so
|
||||||
|
${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/matplotlib/_path.so
|
||||||
|
${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/matplotlib/_cntr.so
|
||||||
|
${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/matplotlib/ft2font.so
|
||||||
|
|
||||||
|
post-install-EXAMPLES-on:
|
||||||
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
|
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
|
||||||
${CP} -R ${WRKSRC}/examples/ ${STAGEDIR}${EXAMPLESDIR}
|
${CP} -R ${WRKSRC}/examples/ ${STAGEDIR}${EXAMPLESDIR}
|
||||||
.endif
|
|
||||||
|
|
||||||
.include <bsd.port.mk>
|
.include <bsd.port.mk>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
--- setup.cfg 1969-12-31 19:00:00.000000000 -0500
|
--- setup.cfg.orig 2015-09-05 07:46:40 UTC
|
||||||
+++ setup.cfg 2010-07-06 10:44:15.000000000 -0400
|
+++ setup.cfg
|
||||||
@@ -0,0 +1,83 @@
|
@@ -0,0 +1,83 @@
|
||||||
+# Rename this file to setup.cfg to modify matplotlib's
|
+# Rename this file to setup.cfg to modify matplotlib's
|
||||||
+# build options.
|
+# build options.
|
||||||
|
|
Loading…
Add table
Reference in a new issue