Skip to content

Commit

Permalink
net/trippy: Provide an optional man page
Browse files Browse the repository at this point in the history
  • Loading branch information
ehaupt committed Apr 4, 2024
1 parent 3d89d48 commit 0c470ad
Showing 1 changed file with 19 additions and 4 deletions.
23 changes: 19 additions & 4 deletions net/trippy/Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
PORTNAME= trippy
DISTVERSION= 0.10.0
PORTREVISION= 1
CATEGORIES= net

MAINTAINER= ehaupt@FreeBSD.org
Expand All @@ -13,16 +14,30 @@ USES= cargo
USE_GITHUB= yes
GH_ACCOUNT= fujiapple852

OPTIONS_DEFINE= SUID
OPTIONS_DEFAULT= SUID
SUID_DESC= Use suid to allow execution as non root
PORTSCOUT= skipv:1.0.0

OPTIONS_DEFINE= MANPAGES SUID
OPTIONS_DEFAULT= MANPAGES SUID
OPTIONS_SUB= yes

MANPAGES_DESC= Build and install auto-generated manpages
SUID_DESC= Use suid to allow execution as non root

MANPAGES_BUILD_DEPENDS= help2man:misc/help2man
MANPAGES_PLIST_FILES= share/man/man1/trip.1.gz
SUID_PLIST_FILES= "@(,,4110) bin/trip"
SUID_PLIST_FILES_OFF= "@(,,0100) bin/trip"

PORTSCOUT= skipv:1.0.0
post-build-MANPAGES-on:
help2man -s 1 -Nn "${COMMENT}" \
${CARGO_TARGET_DIR}/${CARGO_BUILD_TARGET}/*/trip \
-o ${WRKSRC}/trip.1

post-install:
${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/trip

post-install-MANPAGES-on:
${INSTALL_MAN} ${WRKSRC}/trip.1 \
${STAGEDIR}${PREFIX}/share/man/man1

.include <bsd.port.mk>

0 comments on commit 0c470ad

Please sign in to comment.