aboutsummaryrefslogtreecommitdiffstats
path: root/textproc/gxditview/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'textproc/gxditview/Makefile')
-rw-r--r--textproc/gxditview/Makefile36
1 files changed, 20 insertions, 16 deletions
diff --git a/textproc/gxditview/Makefile b/textproc/gxditview/Makefile
index deb34b2f1cd8..a0a84913f02f 100644
--- a/textproc/gxditview/Makefile
+++ b/textproc/gxditview/Makefile
@@ -12,30 +12,34 @@ DISTFILES= # none
MAINTAINER= ru@FreeBSD.org
COMMENT= An X11 based previewer for groff output
-WRKSRC= ${WRKDIR}/${DISTNAME}
-
-USE_IMAKE= yes
MAN1= gxditview.1
+PLIST_FILES= bin/gxditview lib/X11/app-defaults/GXditview
+
+.if !exists(/usr/src/contrib/groff/src)
+IGNORE= requires /usr/src/contrib/groff/src to build
+PORTVERSION= 1.16.1
+.endif
-.if exists(/usr/src/contrib/groff/src/xditview)
-GXDVSRC= /usr/src/contrib/groff/src/xditview
GXDVVERSION!= cat /usr/src/contrib/groff/VERSION
GXDVREVISION!= sed -e 's/^0$$//' -e 's/^[1-9].*$$/.&/' /usr/src/contrib/groff/REVISION
PORTVERSION= ${GXDVVERSION}${GXDVREVISION}
-.else
-GXDVSRC= /usr/src/contrib/groff/xditview
-PORTVERSION= 1.16.1
-.endif
+
+.if exists(/usr/src/contrib/groff/src/devices/xditview) && \
+ exists(/usr/src/gnu/usr.bin/groff/src/devices/xditview)
+USE_X_PREFIX= yes
+MANCOMPRESSED= maybe
+WRKSRC= /usr/src/gnu/usr.bin/groff/src/devices/xditview
+MAKE_ENV= MAKEOBJDIR=${WRKDIR}
+
+pre-configure-script:
+ @${DO_NADA}
+.elif exists(/usr/src/contrib/groff/src/xditview)
+USE_IMAKE= yes
do-extract:
- @if [ ! -d ${GXDVSRC} ]; then \
- ${ECHO} "You need the gxditview source in"; \
- ${ECHO} "${GXDVSRC}"; \
- ${ECHO} "to build this port."; \
- exit 1; \
- fi
@${RM} -rf ${WRKDIR}
@${MKDIR} ${WRKSRC}
- ${CP} -rp ${GXDVSRC}/* ${WRKSRC}
+ ${CP} -rp /usr/src/contrib/groff/src/xditview/* ${WRKSRC}
+.endif
.include <bsd.port.mk>