aboutsummaryrefslogtreecommitdiffstats
path: root/news/pyne
diff options
context:
space:
mode:
authordaichi <daichi@FreeBSD.org>2003-07-02 20:58:39 +0800
committerdaichi <daichi@FreeBSD.org>2003-07-02 20:58:39 +0800
commitbb6f776547e76593186ec913b3bf7b04808c699a (patch)
treebbe5040fb79c600477c1f1bc9f5173a1d8ceaf30 /news/pyne
parent27e6bdf874e9cb35eb4186d16f4982817e14cbc8 (diff)
downloadfreebsd-ports-gnome-bb6f776547e76593186ec913b3bf7b04808c699a.tar.gz
freebsd-ports-gnome-bb6f776547e76593186ec913b3bf7b04808c699a.tar.zst
freebsd-ports-gnome-bb6f776547e76593186ec913b3bf7b04808c699a.zip
fix news/pyne:
- pyne configure fails to find some python modules. - pyne cannot be installed/packaged without a valid ${DISPLAY} variable. PR: 53489 Submitted by: Clement Laforet <sheepkiller@cultdeadsheep.org>
Diffstat (limited to 'news/pyne')
-rw-r--r--news/pyne/Makefile27
1 files changed, 27 insertions, 0 deletions
diff --git a/news/pyne/Makefile b/news/pyne/Makefile
index 202461b59c0d..f31801bf11f6 100644
--- a/news/pyne/Makefile
+++ b/news/pyne/Makefile
@@ -8,6 +8,7 @@
PORTNAME= pyne
PORTVERSION= 0.6.9
+PORTREVISION= 1
CATEGORIES= news python mail
MASTER_SITES= http://www.soul-less.pwp.blueyonder.co.uk/pyne/
@@ -19,6 +20,12 @@ BUILD_DEPENDS= ${PYTHON_SITELIBDIR}/gtk-1.2/GTK.py:${PORTSDIR}/x11-toolkits/py-g
RUN_DEPENDS= ${PYTHON_SITELIBDIR}/gtk-1.2/GTK.py:${PORTSDIR}/x11-toolkits/py-gtk \
${PYTHON_SITELIBDIR}/gtkextra/__init__.py:${PORTSDIR}/x11-toolkits/py-gtkextra
+# ugly hack imported from openoffice.
+.if !defined(DISPLAY)
+BUILD_DEPENDS+= Xvfb:${PORTSDIR}/x11-servers/XFree86-4-VirtualFramebufferServer
+DISPLAYHACK=localhost:1001
+.endif
+
USE_REINPLACE= yes
USE_PYTHON= yes
GNU_CONFIGURE= yes
@@ -27,5 +34,25 @@ MAKE_ENV= PYTHON_SITELIBDIR="${PYTHON_SITELIBDIR}"
post-patch:
@${REINPLACE_CMD} -e "s@[(]PREFIX[)]\/lib@(PYTHON_SITELIBDIR)@g" ${WRKSRC}/Makefile.in
+ @${REINPLACE_CMD} -e "s@pybins=\(.*\)@pybins=\${PYTHON_VERSION}@" ${WRKSRC}/configure
+
+pre-install:
+.if !defined(DISPLAY)
+.if exists(${WRKDIR}/.Xvfb.pid)
+ @-${CAT} ${WRKDIR}/.Xvfb.pid | ${XARGS} kill
+ @${RM} -f ${WRKDIR}/.Xvfb.pid
+.endif
+
+ ${X11BASE}/bin/Xvfb :1001 -screen 0 800x600x24 > /dev/null 2>&1 & ${ECHO} $$! > \
+ ${WRKDIR}/.Xvfb.pid
+ @${REINPLACE_CMD} -e "s@--compile@--compile --display ${DISPLAYHACK}@" \
+ ${WRKSRC}/Makefile
+.endif
+
+post-install:
+.if !defined(DISPLAY)
+ @${CAT} ${WRKDIR}/.Xvfb.pid | ${XARGS} kill
+ @${RM} ${WRKDIR}/.Xvfb.pid
+.endif
.include <bsd.port.mk>