Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 17 Aug 2017 21:34:56 +0000 (UTC)
From:      Richard Gallamore <ultima@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-branches@freebsd.org
Subject:   svn commit: r448196 - in branches/2017Q3/devel/bazel: . files
Message-ID:  <201708172134.v7HLYuRA052794@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ultima
Date: Thu Aug 17 21:34:56 2017
New Revision: 448196
URL: https://svnweb.freebsd.org/changeset/ports/448196

Log:
  MFH: r445987 r446868 r447714
  
  * Update to 0.5.3
  * Fix build on i386
  * Cleanup Makefile
  
  PR:		221114
  Submitted by:	Klaus Aehlig (maintainer)
  Reviewed by:	matthew (mentor)
  Approved by:	matthew (mentor)
  Differential Revision:	https://reviews.freebsd.org/D11937
  
  Approved by:	ports-secteam (feld)

Added:
  branches/2017Q3/devel/bazel/files/extra-i386_src_BUILD
     - copied unchanged from r447714, head/devel/bazel/files/extra-i386_src_BUILD
  branches/2017Q3/devel/bazel/files/patch-src_main_java_com_google_devtools_build_lib_bazel_rules_python_python__stub__template.txt
     - copied unchanged from r446868, head/devel/bazel/files/patch-src_main_java_com_google_devtools_build_lib_bazel_rules_python_python__stub__template.txt
Deleted:
  branches/2017Q3/devel/bazel/files/patch-src_main_java_com_google_devtools_build_lib_bazel_rules_python_stub__template.txt
Modified:
  branches/2017Q3/devel/bazel/Makefile
  branches/2017Q3/devel/bazel/distinfo
Directory Properties:
  branches/2017Q3/   (props changed)

Modified: branches/2017Q3/devel/bazel/Makefile
==============================================================================
--- branches/2017Q3/devel/bazel/Makefile	Thu Aug 17 21:27:45 2017	(r448195)
+++ branches/2017Q3/devel/bazel/Makefile	Thu Aug 17 21:34:56 2017	(r448196)
@@ -2,28 +2,27 @@
 # $FreeBSD$
 
 PORTNAME=		bazel
-PORTVERSION=		0.5.0
+PORTVERSION=		0.5.3
 CATEGORIES=		devel java
 MASTER_SITES=		https://storage.googleapis.com/bazel/${PORTVERSION}/rc${FINALRC}/
 DISTNAME=		bazel-${PORTVERSION}rc${FINALRC}-dist
 
-MAINTAINER=		aehlig@linta.de
+MAINTAINER?=		aehlig@linta.de
 COMMENT=		Fast and correct build system
 
 LICENSE=		APACHE20
 LICENSE_FILE=		${WRKSRC}/LICENSE
 
+BROKEN_armv6=		fails to package: cp: bazel: No such file or directory
+
 BUILD_DEPENDS=		bash:shells/bash \
 			zip:archivers/zip
 
-BROKEN_armv6=		fails to package: cp: bazel: No such file or directory
-
 # In bazel, a release is always code-wise identical to the final release candidate.
 # Hence we can also download that one and so have a simple way to also test earlier release
 # candidates.
-FINALRC=		9
+FINALRC=		4
 
-NO_WRKSUBDIR=		YES
 USES=			shebangfix zip
 SHEBANG_REGEX=		.*(sh|txt|_stub|stub_.*|bazel|get_workspace_status|protobuf_support|_so)
 USE_JAVA=		yes
@@ -32,6 +31,21 @@ JAVA_VERSION=		1.8
 JAVA_BUILD=		yes
 JAVA_RUN=		yes
 
+NO_WRKSUBDIR=		YES
+
+CONFLICTS_INSTALL?=	bazel-clang38
+
+OPTIONS_DEFINE=	CLANG38
+CLANG38_DESC=	Use clang38 as default crosstool
+CLANG38_BUILD_DEPENDS=	clang38:devel/llvm38
+CLANG38_RUN_DEPENDS=	clang38:devel/llvm38
+
+.include <bsd.port.pre.mk>
+
+.if ${ARCH} == "i386"
+EXTRA_PATCHES=	${FILESDIR}/extra-i386_src_BUILD
+.endif
+
 # Have the location of the system-wide rc file reside ${ETCDIR}.
 # Also adapt the sample file to disable persistent java workers as they
 # do not work reliably on FreeBSD.
@@ -41,6 +55,10 @@ post-patch:
 	${WRKSRC}/src/main/cpp/blaze_util_posix.cc
 	@${ECHO_CMD} build --strategy=Javac=standalone >> ${WRKSRC}/scripts/packages/debian/bazel.bazelrc
 
+post-patch-CLANG38-on:
+	@${REINPLACE_CMD} -e 's=/usr/lib/clang=${LOCALBASE}/llvm38/lib/clang=' \
+	-e 's=/usr/bin/clang=${LOCALBASE}/bin/clang38=' ${WRKSRC}/tools/cpp/CROSSTOOL
+
 do-build:
 	@${MKDIR} ${WRKDIR}/bazel_tmp
 	(if [ -z "$${SOURCE_DATE_EPOCH}" ] ; \
@@ -60,4 +78,4 @@ do-install:
 	@${MKDIR} ${STAGEDIR}${ETCDIR}
 	${INSTALL_DATA} ${WRKSRC}/scripts/packages/debian/bazel.bazelrc ${STAGEDIR}${ETCDIR}/bazel.bazelrc.sample
 
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>

Modified: branches/2017Q3/devel/bazel/distinfo
==============================================================================
--- branches/2017Q3/devel/bazel/distinfo	Thu Aug 17 21:27:45 2017	(r448195)
+++ branches/2017Q3/devel/bazel/distinfo	Thu Aug 17 21:34:56 2017	(r448196)
@@ -1,3 +1,3 @@
-TIMESTAMP = 1495581096
-SHA256 (bazel-0.5.0rc9-dist.zip) = b2b2f2e399cd341d91d27f3df0f9862ef0c4c51cc256fd2bda6ca93c0f00e27f
-SIZE (bazel-0.5.0rc9-dist.zip) = 98166774
+TIMESTAMP = 1501141783
+SHA256 (bazel-0.5.3rc4-dist.zip) = 41d70a98366256a20ddf0b0f2aab826913cd332d90c4f245b2c2e83a66f3d846
+SIZE (bazel-0.5.3rc4-dist.zip) = 100445883

Copied: branches/2017Q3/devel/bazel/files/extra-i386_src_BUILD (from r447714, head/devel/bazel/files/extra-i386_src_BUILD)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2017Q3/devel/bazel/files/extra-i386_src_BUILD	Thu Aug 17 21:34:56 2017	(r448196, copy of r447714, head/devel/bazel/files/extra-i386_src_BUILD)
@@ -0,0 +1,32 @@
+--- src/BUILD.orig	2017-07-31 10:06:21.426927000 +0200
++++ src/BUILD	2017-07-31 10:06:44.279345000 +0200
+@@ -179,7 +179,7 @@
+             "//src/java_tools/singlejar:SingleJar_deploy.jar",
+         ],
+         "//conditions:default": [
+-            "//src/tools/singlejar:singlejar",
++            "//src/java_tools/singlejar:SingleJar_deploy.jar",
+         ],
+     }) + select({
+         "//tools/jdk:jdk7": [],
+--- src/main/cpp/blaze_util_posix.cc.orig
++++ src/main/cpp/blaze_util_posix.cc
+@@ -29,6 +29,7 @@
+ #include <sys/resource.h>
+ #include <sys/wait.h>
+ #include <unistd.h>
++#include <time.h>
+ 
+ #include <cassert>
+ #include <cinttypes>
+@@ -648,8 +649,8 @@
+ }
+ 
+ void TrySleep(unsigned int milliseconds) {
+-  unsigned int seconds_part = milliseconds / 1000;
+-  unsigned int nanoseconds_part = (milliseconds % 1000) * 1000 * 1000;
++  time_t seconds_part = (time_t) (milliseconds / 1000);
++  long nanoseconds_part = ((long)(milliseconds % 1000)) * 1000 * 1000;
+   struct timespec sleeptime = {seconds_part, nanoseconds_part};
+   nanosleep(&sleeptime, NULL);
+ }

Copied: branches/2017Q3/devel/bazel/files/patch-src_main_java_com_google_devtools_build_lib_bazel_rules_python_python__stub__template.txt (from r446868, head/devel/bazel/files/patch-src_main_java_com_google_devtools_build_lib_bazel_rules_python_python__stub__template.txt)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2017Q3/devel/bazel/files/patch-src_main_java_com_google_devtools_build_lib_bazel_rules_python_python__stub__template.txt	Thu Aug 17 21:34:56 2017	(r448196, copy of r446868, head/devel/bazel/files/patch-src_main_java_com_google_devtools_build_lib_bazel_rules_python_python__stub__template.txt)
@@ -0,0 +1,11 @@
+--- src/main/java/com/google/devtools/build/lib/bazel/rules/python/python_stub_template.txt.orig	2017-07-25 04:58:01 UTC
++++ src/main/java/com/google/devtools/build/lib/bazel/rules/python/python_stub_template.txt
+@@ -38,7 +38,7 @@ if IsWindows() and not PYTHON_BINARY.end
+ 
+ # Find a file in a given search path.
+ def SearchPath(name):
+-  search_path = os.getenv('PATH', os.defpath).split(os.pathsep)
++  search_path = os.getenv('PATH', os.defpath + ":/usr/local/bin").split(os.pathsep)
+   for directory in search_path:
+     if directory == '': continue
+     path = os.path.join(directory, name)



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