From d5047b721d7fad32e6a2be1e13fef5067303c68a Mon Sep 17 00:00:00 2001 From: Steve Wills Date: Mon, 3 Oct 2011 14:37:41 +0000 Subject: - fix plist when rst2man is in PATH - respect PREFIX for system-wide config file PR: ports/160668 Submitted by: h h Approved by: Quentin Stievenart (maintainer) --- graphics/zathura/Makefile | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/graphics/zathura/Makefile b/graphics/zathura/Makefile index 944f65671aa4..a706e443dacd 100644 --- a/graphics/zathura/Makefile +++ b/graphics/zathura/Makefile @@ -26,8 +26,13 @@ PLIST_FILES= bin/zathura \ share/applications/zathura.desktop PLIST_DIRSTRY= share/applications +.if !defined(NOPORTDOCS) +BUILD_DEPENDS+= rst2html:${PORTSDIR}/textproc/py-docutils +MAN5+= zathurarc.5 +.endif + post-patch: .SILENT - ${REINPLACE_CMD} -e 's|man1|man/man1|g' \ + ${REINPLACE_CMD} -e 's|man[15]|man/&|g' \ -e '/CC/s/$${SFLAGS}/${STRIP} /' \ -e '/CFLAGS/!s/$${LDFLAGS}/$${CFLAGS} &/' \ -e 's/{DFLAGS/{DEBUG_FLAGS/g' \ @@ -39,10 +44,16 @@ post-patch: .SILENT -e 's/cp[[:space:]]$$/' \ -e 's/\(include\)[[:space:]]\(.*\)/.\1 "\2"/' \ ${WRKSRC}/Makefile +.if defined(NOPORTDOCS) + ${REINPLACE_CMD} 's|which rst2man|${FALSE}|' ${WRKSRC}/Makefile +.endif ${REINPLACE_CMD} -e 's|/usr/include|${LOCALBASE}/include|' \ -e 's/-lpthread/${PTHREAD_LIBS}/' \ -e 's/-lc//' \ -e 's/$$(shell[[:space:]]\(.*\))/`\1`/' \ ${WRKSRC}/config.mk + ${REINPLACE_CMD} -e 's|/etc|${PREFIX}&|g' \ + ${WRKSRC}/config.def.h \ + ${WRKSRC}/zathurarc.5.rst .include -- cgit v1.2.3