mirror of
https://github.com/protocolbuffers/protobuf
synced 2026-08-26 02:23:14 -04:00
Remove javaopts requiring java8 in non-release builds.
Adding java8 tests as a presubmit test to ensure no regression on java8 compatibility since the option will no longer apply to tests. PiperOrigin-RevId: 681615348
This commit is contained in:
parent
578148d50f
commit
59e469d5b0
2 changed files with 3 additions and 5 deletions
1
.github/workflows/test_java.yml
vendored
1
.github/workflows/test_java.yml
vendored
|
|
@ -34,7 +34,6 @@ jobs:
|
|||
# TODO: b/318555165 - enable the layering check. Currently it does
|
||||
# not work correctly with the toolchain in this Docker image.
|
||||
targets: //java/... //java/internal:java_version //compatibility/... --features=-layering_check
|
||||
continuous-only: true
|
||||
- name: OpenJDK 11
|
||||
cache_key: '11'
|
||||
image: us-docker.pkg.dev/protobuf-build/containers/test/linux/java:6.4.0-11-27cf7b86212020d7e552bc13b1e084abb971da75
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ load("@rules_jvm_external//:defs.bzl", "java_export")
|
|||
load("//:protobuf_version.bzl", "PROTOBUF_JAVA_VERSION")
|
||||
load("//java/osgi:osgi.bzl", "osgi_java_library")
|
||||
|
||||
JAVA_OPTS = [
|
||||
JAVA_RELEASE_OPTS = [
|
||||
"-source 8",
|
||||
"-target 8",
|
||||
"-Xep:Java8ApiChecker:ERROR",
|
||||
|
|
@ -16,7 +16,7 @@ BUNDLE_LICENSE = "https://opensource.org/licenses/BSD-3-Clause"
|
|||
|
||||
def protobuf_java_export(**kwargs):
|
||||
java_export(
|
||||
javacopts = JAVA_OPTS,
|
||||
javacopts = JAVA_RELEASE_OPTS,
|
||||
# https://github.com/bazelbuild/rules_jvm_external/issues/1245
|
||||
javadocopts = [
|
||||
"-notimestamp",
|
||||
|
|
@ -31,7 +31,6 @@ def protobuf_java_export(**kwargs):
|
|||
|
||||
def protobuf_java_library(**kwargs):
|
||||
java_library(
|
||||
javacopts = JAVA_OPTS,
|
||||
**kwargs
|
||||
)
|
||||
|
||||
|
|
@ -77,7 +76,7 @@ def protobuf_versioned_java_library(
|
|||
java_library target.
|
||||
"""
|
||||
osgi_java_library(
|
||||
javacopts = JAVA_OPTS,
|
||||
javacopts = JAVA_RELEASE_OPTS,
|
||||
automatic_module_name = automatic_module_name,
|
||||
bundle_doc_url = BUNDLE_DOC_URL,
|
||||
bundle_license = BUNDLE_LICENSE,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue