View | Details | Raw Unified | Return to bug 245427
Collapse All | Expand All

(-)bazel/Makefile (-3 / +3 lines)
Lines 2-8 Link Here
2
# $FreeBSD: head/devel/bazel/Makefile 525657 2020-02-09 13:48:19Z riggs $
2
# $FreeBSD: head/devel/bazel/Makefile 525657 2020-02-09 13:48:19Z riggs $
3
3
4
PORTNAME=	bazel
4
PORTNAME=	bazel
5
DISTVERSION=	2.1.0
5
DISTVERSION=	3.0.0
6
CATEGORIES=	devel java
6
CATEGORIES=	devel java
7
MASTER_SITES=	https://storage.googleapis.com/bazel/${PORTVERSION}/rc${FINALRC}/
7
MASTER_SITES=	https://storage.googleapis.com/bazel/${PORTVERSION}/rc${FINALRC}/
8
DISTNAME=	bazel-${PORTVERSION}rc${FINALRC}-dist
8
DISTNAME=	bazel-${PORTVERSION}rc${FINALRC}-dist
Lines 29-35 Link Here
29
# In bazel, a release is always code-wise identical to the final release candidate.
29
# In bazel, a release is always code-wise identical to the final release candidate.
30
# Hence we can also download that one and so have a simple way to also test earlier release
30
# Hence we can also download that one and so have a simple way to also test earlier release
31
# candidates.
31
# candidates.
32
FINALRC=	4
32
FINALRC=	2
33
33
34
SHEBANG_REGEX=	.*(sh|txt|_stub|stub_.*|bazel|get_workspace_status|protobuf_support|_so)
34
SHEBANG_REGEX=	.*(sh|txt|_stub|stub_.*|bazel|get_workspace_status|protobuf_support|_so)
35
USE_JAVA=	yes
35
USE_JAVA=	yes
Lines 64-70 Link Here
64
	-e 's|^\(PYTHON_BIN=.*\)|if [ "%VERSION%" = "3" ] ; then PYTHON_BIN=${PYTHON_CMD}; else \1 ; fi|' \
64
	-e 's|^\(PYTHON_BIN=.*\)|if [ "%VERSION%" = "3" ] ; then PYTHON_BIN=${PYTHON_CMD}; else \1 ; fi|' \
65
	${WRKSRC}/tools/python/pywrapper_template.txt
65
	${WRKSRC}/tools/python/pywrapper_template.txt
66
	@${REINPLACE_CMD} \
66
	@${REINPLACE_CMD} \
67
	-e 's|/usr/bin/env python|${PYTHON_CMD}|' \
67
	-e 's|%%PYTHON_CMD%%|${PYTHON_CMD}|' \
68
	${WRKSRC}/src/main/java/com/google/devtools/build/lib/bazel/rules/python/BazelPythonSemantics.java
68
	${WRKSRC}/src/main/java/com/google/devtools/build/lib/bazel/rules/python/BazelPythonSemantics.java
69
69
70
do-build:
70
do-build:
(-)bazel/distinfo (-3 / +3 lines)
Lines 1-3 Link Here
1
TIMESTAMP = 1580457560
1
TIMESTAMP = 1584210642
2
SHA256 (bazel-2.1.0rc4-dist.zip) = ac1d9a6189d717ba5aafcbc0745809155d24044df1a69e8de254c5b9182e894b
2
SHA256 (bazel-3.0.0rc2-dist.zip) = 6431e745e304bb77e54386b577554c076a7b6e918e5f494bb7b8e77c6ecdc5ec
3
SIZE (bazel-2.1.0rc4-dist.zip) = 259805171
3
SIZE (bazel-3.0.0rc2-dist.zip) = 269096438
(-)bazel/files/patch-src_main_java_com_google_devtools_build_lib_bazel_rules_python_BazelPythonSemantics.java (+21 lines)
Line 0 Link Here
1
--- src/main/java/com/google/devtools/build/lib/bazel/rules/python/BazelPythonSemantics.java.orig	2020-03-03 17:09:23 UTC
2
+++ src/main/java/com/google/devtools/build/lib/bazel/rules/python/BazelPythonSemantics.java
3
@@ -237,15 +237,15 @@ public class BazelPythonSemantics implem
4
         PathFragment shExecutable = ShToolchain.getPathOrError(ruleContext);
5
         // TODO(#8685): Remove this special-case handling as part of making the proper shebang a
6
         // property of the Python toolchain configuration.
7
-        String pythonExecutableName = OS.getCurrent() == OS.OPENBSD ? "python3" : "python";
8
+        String pythonExecutable = "%%PYTHON_CMD%%";
9
         ruleContext.registerAction(
10
             new SpawnAction.Builder()
11
                 .addInput(zipFile)
12
                 .addOutput(executable)
13
                 .setShellCommand(
14
                     shExecutable,
15
-                    "echo '#!/usr/bin/env "
16
-                        + pythonExecutableName
17
+                    "echo '#!"
18
+                        + pythonExecutable
19
                         + "' | cat - "
20
                         + zipFile.getExecPathString()
21
                         + " > "
(-)bazel/files/patch-third_party__BUILD (-11 lines)
Lines 1-11 Link Here
1
--- third_party/BUILD.orig	2019-07-11 08:41:05.213918000 +0000
2
+++ third_party/BUILD	2019-07-11 08:41:40.502181000 +0000
3
@@ -536,7 +536,7 @@
4
     name = "filter_netty_dynamic_libs",
5
     srcs = ["netty_tcnative/netty-tcnative-boringssl-static-2.0.24.Final.jar"],
6
     outs = ["netty_tcnative/netty-tcnative-filtered.jar"],
7
-    cmd = "cp $< $@ && zip -qd $@ " + UNNECESSARY_DYNAMIC_LIBRARIES,
8
+    cmd = "cp $< $@ && (zip -qd $@ " + UNNECESSARY_DYNAMIC_LIBRARIES + " || : )",
9
 )
10
 
11
 java_import(
(-)bazel/files/patch-tools__jdk__default_java_toolchain.bzl (-9 / +9 lines)
Lines 1-6 Link Here
1
--- tools/jdk/default_java_toolchain.bzl.orig	2019-08-06 08:09:07.930962000 +0000
1
--- tools/jdk/default_java_toolchain.bzl.orig	2020-02-14 20:56:31.911758000 +0100
2
+++ tools/jdk/default_java_toolchain.bzl	2019-08-06 08:16:15.674960000 +0000
2
+++ tools/jdk/default_java_toolchain.bzl	2020-02-14 20:57:09.531875000 +0100
3
@@ -19,25 +19,6 @@
3
@@ -21,25 +21,6 @@
4
 ]
4
 ]
5
 
5
 
6
 JDK9_JVM_OPTS = [
6
 JDK9_JVM_OPTS = [
Lines 26-37 Link Here
26
 ]
26
 ]
27
 
27
 
28
 DEFAULT_JAVACOPTS = [
28
 DEFAULT_JAVACOPTS = [
29
@@ -70,7 +51,7 @@
29
@@ -63,7 +44,7 @@
30
         "@bazel_tools//tools/jdk:jdk_compiler_jar",
31
     ],
32
     "javac_supports_workers": 1,
30
     "javac_supports_workers": 1,
33
-    "jvm_opts": JDK9_JVM_OPTS,
31
     "jvm_opts": select({
34
+    "jvm_opts": JDK8_JVM_OPTS,
32
         "@bazel_tools//src/conditions:openbsd": JDK8_JVM_OPTS,
33
-        "//conditions:default": JDK9_JVM_OPTS,
34
+        "//conditions:default": JDK8_JVM_OPTS,
35
     }),
35
     "misc": DEFAULT_JAVACOPTS,
36
     "misc": DEFAULT_JAVACOPTS,
36
     "compatible_javacopts": COMPATIBLE_JAVACOPTS,
37
     "singlejar": ["@bazel_tools//tools/jdk:singlejar"],
37
     "singlejar": ["@bazel_tools//tools/jdk:singlejar"],

Return to bug 245427