diff options
author | araujo <araujo@FreeBSD.org> | 2017-03-22 20:10:26 +0800 |
---|---|---|
committer | Koop Mast <kwm@rainbow-runner.nl> | 2017-04-09 20:54:04 +0800 |
commit | 6594b559ae308f3a2a3f891bb8c91bd565464d07 (patch) | |
tree | c0d84669a798c99da7a71bfe181012a4f7be7d30 | |
parent | 65e62de35e02831baec84838975d7e69e8abaa46 (diff) | |
download | freebsd-ports-gnome-6594b559ae308f3a2a3f891bb8c91bd565464d07.tar.gz freebsd-ports-gnome-6594b559ae308f3a2a3f891bb8c91bd565464d07.tar.zst freebsd-ports-gnome-6594b559ae308f3a2a3f891bb8c91bd565464d07.zip |
This port currently installs as minio-client, which is a bit long.
Also, most examples of usage show mc. I intentionally used minio-client
to avoid a naming collision with mc (midnight commander).
I would like to give users the option to install as mc if desired.
PR: ports/217858
Submitted by: John Hixson <jhixson@gmail.com> (maintainer)
-rw-r--r-- | www/minio-client/Makefile | 21 |
1 files changed, 17 insertions, 4 deletions
diff --git a/www/minio-client/Makefile b/www/minio-client/Makefile index a978cebea770..cf12815dbb40 100644 --- a/www/minio-client/Makefile +++ b/www/minio-client/Makefile @@ -2,6 +2,7 @@ PORTNAME= minio-client PORTVERSION= ${GH_TAGNAME:S/RELEASE.//:S/Z//:S/T/-/:S/-/./g} +PORTREVISION= 1 CATEGORIES= www MAINTAINER= jhixson@gmail.com @@ -12,6 +13,18 @@ LICENSE= APACHE20 BUILD_DEPENDS= go>=1.7:lang/go \ bash:shells/bash +OPTIONS_DEFINE= MC + +MC_DESC= Install as mc + +.include <bsd.port.options.mk> + +.if ${PORT_OPTIONS:MMC} +MC= mc +.else +MC= ${PORTNAME} +.endif + USE_GITHUB= yes GH_ACCOUNT= minio GH_PROJECT= mc @@ -20,15 +33,15 @@ GH_SUBDIR= src/github.com/${GH_ACCOUNT}/${GH_PROJECT} MAKE_ENV= GOPATH=${WRKSRC} GOROOT=${LOCALBASE}/go STRIP= # stripping can break go binaries -PLIST_FILES= bin/${PORTNAME} +PLIST_FILES= bin/${MC} do-build: @cd ${WRKSRC}/src/github.com/${GH_ACCOUNT}/${GH_PROJECT}; \ ${SETENV} ${BUILD_ENV} GOPATH=${WRKSRC} go build -v -x \ - -ldflags "-X main.GitDescribe=v${PORTVERSION}" -o bin/${PORTNAME} + -ldflags "-X main.GitDescribe=v${PORTVERSION}" -o bin/${MC} do-install: - ${INSTALL_PROGRAM} ${WRKSRC}/src/github.com/${GH_ACCOUNT}/${GH_PROJECT}/bin/${PORTNAME} \ - ${STAGEDIR}${PREFIX}/bin/${PORTNAME} + ${INSTALL_PROGRAM} ${WRKSRC}/src/github.com/${GH_ACCOUNT}/${GH_PROJECT}/bin/${MC} \ + ${STAGEDIR}${PREFIX}/bin/${MC} .include <bsd.port.mk> |