git: c9c021742730 - main - x11-toolkits/pango: Add MANPAGES option

From: Emmanuel Vadot <manu_at_FreeBSD.org>
Date: Tue, 09 Nov 2021 13:51:15 UTC
The branch main has been updated by manu:

URL: https://cgit.FreeBSD.org/ports/commit/?id=c9c021742730b2b0ffe05f5b44903ee978130269

commit c9c021742730b2b0ffe05f5b44903ee978130269
Author:     Emmanuel Vadot <manu@FreeBSD.org>
AuthorDate: 2021-10-21 16:15:38 +0000
Commit:     Emmanuel Vadot <manu@FreeBSD.org>
CommitDate: 2021-11-09 13:50:27 +0000

    x11-toolkits/pango: Add MANPAGES option
    
    And only install manpages if it's selected.
    
    Reviewed by:     desktop (tcberner@)
    Differential Revision:    https://reviews.freebsd.org/D32904
    Sponsored by:   Beckhoff Automation GmbH & Co. KG
---
 x11-toolkits/pango/Makefile  | 7 ++++---
 x11-toolkits/pango/pkg-plist | 2 +-
 2 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/x11-toolkits/pango/Makefile b/x11-toolkits/pango/Makefile
index 27fbd6b5d24b..14326b47e08c 100644
--- a/x11-toolkits/pango/Makefile
+++ b/x11-toolkits/pango/Makefile
@@ -12,7 +12,6 @@ COMMENT=	Open-source framework for the layout and rendering of i18n text
 LICENSE=	LGPL20
 LICENSE_FILE=	${WRKSRC}/COPYING
 
-BUILD_DEPENDS=	help2man:misc/help2man
 LIB_DEPENDS=	libfreetype.so:print/freetype2 \
 		libharfbuzz.so:print/harfbuzz \
 		libfontconfig.so:x11-fonts/fontconfig \
@@ -36,12 +35,14 @@ FONTSCALE=	${LOCALBASE}/share/fonts/TTF/luximb.ttf
 FONTENCOD=	${LOCALBASE}/share/fonts/encodings/encodings.dir
 
 OPTIONS_SUB=	yes
-OPTIONS_DEFINE=	X11 DOCS
-OPTIONS_DEFAULT=X11
+OPTIONS_DEFINE=	X11 DOCS MANPAGES
+OPTIONS_DEFAULT=X11 MANPAGES
 
 DOCS_MESON_TRUE=	gtk_doc
 DOCS_BUILD_DEPENDS=	${PYTHON_PKGNAMEPREFIX}gi-docgen>=0:textproc/py-gi-docgen
 
+MANPAGES_BUILD_DEPENDS=	help2man:misc/help2man
+
 X11_MESON_ENABLED=	xft
 X11_USES=	xorg
 X11_USE=	XORG=x11,xft,xrender
diff --git a/x11-toolkits/pango/pkg-plist b/x11-toolkits/pango/pkg-plist
index bc5db9b130f2..23845c33beec 100644
--- a/x11-toolkits/pango/pkg-plist
+++ b/x11-toolkits/pango/pkg-plist
@@ -66,7 +66,7 @@ share/gir-1.0/PangoFT2-1.0.gir
 share/gir-1.0/PangoFc-1.0.gir
 share/gir-1.0/PangoOT-1.0.gir
 %%X11%%share/gir-1.0/PangoXft-1.0.gir
-share/man/man1/pango-view.1.gz
+%%MANPAGES%%share/man/man1/pango-view.1.gz
 %%PORTDOCS%%%%DOCSDIR%%/reference/Pango/Pango.devhelp2
 %%PORTDOCS%%%%DOCSDIR%%/reference/Pango/RedHatDisplay-Black.woff
 %%PORTDOCS%%%%DOCSDIR%%/reference/Pango/RedHatDisplay-Black.woff2