Skip to content
This repository was archived by the owner on Jan 26, 2022. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions .bazelrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Avoid downloading protobuf twice:
build --proto_toolchain_for_java="@com_google_protobuf//:java_toolchain"
# Run with a persistent scalac worker. See: https://github.com/bazelbuild/rules_scala#getting-started
build --strategy=Scalac=worker
test --strategy=Scalac=worker

# Build with as much future compatibility as possible
# See https://docs.bazel.build/versions/master/skylark/backward-compatibility.html
# TODO We have protobuf 3.6.1 in the WORKSPACE but an older protobuf is causing the errors below. Why?
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do you know what external dependency it's getting picked up from?

build --incompatible_bzl_disallow_load_after_statement
build --incompatible_depset_is_not_iterable
build --incompatible_depset_union
build --incompatible_disable_deprecated_attr_params=false # Fixed in protobuf 3.6.1
build --incompatible_disable_objc_provider_resources
build --incompatible_disallow_conflicting_providers
build --incompatible_disallow_data_transition
build --incompatible_disallow_dict_plus
build --incompatible_disallow_filetype
build --incompatible_disallow_legacy_javainfo=false # See: https://github.com/bazelbuild/rules_scala/issues/513
build --incompatible_disallow_old_style_args_add
build --incompatible_disallow_slash_operator
build --incompatible_expand_directories
build --incompatible_generate_javacommon_source_jar
build --incompatible_new_actions_api
build --incompatible_no_support_tools_in_action_inputs=false # See: https://github.com/bazelbuild/rules_scala/issues/596
build --incompatible_no_transitive_loads
build --incompatible_package_name_is_a_function=false # Fixed in protobuf 3.6.1
build --incompatible_range_type
build --incompatible_remove_native_git_repository
build --incompatible_remove_native_http_archive
build --incompatible_static_name_resolution
build --incompatible_string_is_not_iterable

3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -45,3 +45,6 @@ hs_err_pid*
*.DS_STORE
# Ignore bazel-deps resolverCache. See: https://github.com/johnynek/bazel-deps#options
target/local-repo

# Ignore IntelliJ library files
.ijwb
16 changes: 9 additions & 7 deletions WORKSPACE
Original file line number Diff line number Diff line change
@@ -1,16 +1,18 @@
load("//thirdparty:workspace.bzl", "maven_dependencies")
load("//tools/bazel_defs:declare_maven.bzl", "declare_maven")
maven_dependencies(declare_maven)
maven_dependencies()

# Provide dependencies for proto_library and java_proto_library rules.
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")

# LICENSE: The Apache Software License, Version 2.0
# proto_library rules implicitly depend on @com_google_protobuf//:protoc
http_archive(
name = "com_google_protobuf",
sha256 = "091e1aa2b64ea6d512ff9294ecc9da95132c3b961a8fb39a3bab3929e5122f50",
strip_prefix = "protobuf-3.4.1",
urls = ["https://github.com/google/protobuf/releases/download/v3.4.1/protobuf-java-3.4.1.zip"],
sha256 = "d7a221b3d4fb4f05b7473795ccea9e05dab3b8721f6286a95fffbffc2d926f8b",
strip_prefix = "protobuf-3.6.1",
urls = ["https://github.com/google/protobuf/archive/v3.6.1.zip"],
)

rules_scala_version = "5874a2441596fe9a0bf80e167a4d7edd945c221e" # update this as needed
rules_scala_version = "4be50865a332aef46c46c94b345c320c3353e9e1" # HEAD on 11-1-2018. update this as needed.

http_archive(
name = "io_bazel_rules_scala",
Expand Down
2 changes: 1 addition & 1 deletion dev-scripts/dependencies/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ SCRIPT_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
ROOT_DIR=$(cd "${SCRIPT_DIR}/../.." && pwd)
BAZEL_DEPS_DIR="$ROOT_DIR/../bazel-deps"
# Pin a specific version of bazel-deps; change this to upgrade:
BAZEL_DEPS_VERSION="aad33e40cd2ce2400347e5db28b767e5d512a4fd"
BAZEL_DEPS_VERSION="1af8921d52f053fad575f26762533a3823b4a847"

if [ -d "$BAZEL_DEPS_DIR" ]
then
Expand Down
6 changes: 0 additions & 6 deletions tools/bazel.rc

This file was deleted.

63 changes: 0 additions & 63 deletions tools/bazel_defs/declare_maven.bzl

This file was deleted.

96 changes: 0 additions & 96 deletions tools/bazel_defs/scala.bzl

This file was deleted.

16 changes: 0 additions & 16 deletions tools/bazel_defs/scala_maven_jar.bzl

This file was deleted.