Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 18 May 2018 17:37:21 +0000 (UTC)
From:      Steve Wills <swills@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r470314 - head/net/google-cloud-sdk
Message-ID:  <201805181737.w4IHbLjw097553@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: swills
Date: Fri May 18 17:37:21 2018
New Revision: 470314
URL: https://svnweb.freebsd.org/changeset/ports/470314

Log:
  net/google-cloud-sdk: pre-compile python files
  
  Avoids issues after uninstall if apps have been run as root. While here,
  auto-generate most of plist since it's quite large and changes a lot between
  releases.
  
  PR:		227431
  Reported by:	SBB <samorders@gmail.com>

Deleted:
  head/net/google-cloud-sdk/pkg-plist
Modified:
  head/net/google-cloud-sdk/Makefile   (contents, props changed)

Modified: head/net/google-cloud-sdk/Makefile
==============================================================================
--- head/net/google-cloud-sdk/Makefile	Fri May 18 17:31:21 2018	(r470313)
+++ head/net/google-cloud-sdk/Makefile	Fri May 18 17:37:21 2018	(r470314)
@@ -3,6 +3,7 @@
 
 PORTNAME=	google-cloud-sdk
 PORTVERSION=	200.0.0
+PORTREVISION=	1
 CATEGORIES=	net
 MASTER_SITES=	https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/
 DISTNAME=	google-cloud-sdk-${PORTVERSION}-linux-x86_64
@@ -11,10 +12,10 @@ MAINTAINER=	swills@FreeBSD.org
 COMMENT=	Google Cloud SDK for Google Cloud Platform
 
 USES=		python:2.7
-NO_ARCH=	yes
-NO_BUILD=	yes
 WRKSRC=		${WRKDIR}/google-cloud-sdk
 
+PLIST_FILES=	bin/bq bin/gcloud bin/git-credential-gcloud.sh bin/gsutil
+
 RUN_DEPENDS=	python:lang/python \
 		${PYTHON_PKGNAMEPREFIX}sqlite3>0:databases/py-sqlite3
 
@@ -27,6 +28,10 @@ post-extract:
 		${WRKSRC}/deb \
 		${WRKSRC}/lib/third_party/grpc/_cython/cygrpc.so
 
+do-build:
+	@cd ${WRKSRC} ; \
+		${PYTHON_CMD} -m compileall -q -x python3 .
+
 do-install:
 	${RM} -r ${WRKSRC}/help ${WRKSRC}/.install/.download
 	( cd ${WRKSRC} ; ${COPYTREE_SHARE} . ${STAGEDIR}${PREFIX}/google-cloud-sdk )
@@ -35,5 +40,9 @@ do-install:
 	${RLN} ${STAGEDIR}${PREFIX}/google-cloud-sdk/bin/${x} \
 		${STAGEDIR}${PREFIX}/bin/${x}
 .endfor
+
+post-install:
+	@(cd ${STAGEDIR}${PREFIX} && \
+                ${FIND} -s google-cloud-sdk -type f -o -type l >> ${TMPPLIST})
 
 .include <bsd.port.mk>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201805181737.w4IHbLjw097553>