David Ostrovsky | 28fe85f | 2023-11-18 22:13:31 +0100 | [diff] [blame] | 1 | # TODO(davido): Migrate all dependencies from WORKSPACE to MODULE.bazel |
| 2 | # https://issues.gerritcodereview.com/issues/303819949 |
| 3 | common --noenable_bzlmod |
David Ostrovsky | 231e698 | 2024-05-28 19:49:03 +0200 | [diff] [blame] | 4 | common --incompatible_enable_proto_toolchain_resolution |
David Ostrovsky | 28fe85f | 2023-11-18 22:13:31 +0100 | [diff] [blame] | 5 | |
David Ostrovsky | 2b5fe09 | 2021-03-03 11:52:30 +0100 | [diff] [blame] | 6 | build --workspace_status_command="python3 ./tools/workspace_status.py" |
David Ostrovsky | 2bf355d | 2018-05-30 08:58:22 +0200 | [diff] [blame] | 7 | build --repository_cache=~/.gerritcodereview/bazel-cache/repository |
Wyatt Allen | 370962b | 2018-06-08 15:45:02 -0700 | [diff] [blame] | 8 | build --action_env=PATH |
Han-Wen Nienhuys | 9c15e2b | 2019-05-16 16:59:33 +0200 | [diff] [blame] | 9 | build --disk_cache=~/.gerritcodereview/bazel-cache/cas |
David Ostrovsky | 21a891c | 2020-12-19 12:57:06 +0100 | [diff] [blame] | 10 | |
David Ostrovsky | c47854e | 2023-11-25 13:27:00 +0100 | [diff] [blame] | 11 | # Define configuration using remotejdk_17, executes using remotejdk_17 or local_jdk |
| 12 | build:build_shared --java_language_version=17 |
| 13 | build:build_shared --java_runtime_version=remotejdk_17 |
| 14 | build:build_shared --tool_java_language_version=17 |
| 15 | build:build_shared --tool_java_runtime_version=remotejdk_17 |
David Ostrovsky | 21a891c | 2020-12-19 12:57:06 +0100 | [diff] [blame] | 16 | |
| 17 | # Builds using remotejdk_17, executes using remotejdk_17 or local_jdk |
David Ostrovsky | c47854e | 2023-11-25 13:27:00 +0100 | [diff] [blame] | 18 | # Avoid warnings for non default configurations: |
| 19 | # build --config=build_shared |
David Ostrovsky | 0250833 | 2022-01-08 20:12:10 +0100 | [diff] [blame] | 20 | build --java_language_version=17 |
| 21 | build --java_runtime_version=remotejdk_17 |
| 22 | build --tool_java_language_version=17 |
| 23 | build --tool_java_runtime_version=remotejdk_17 |
David Ostrovsky | 21a891c | 2020-12-19 12:57:06 +0100 | [diff] [blame] | 24 | |
Alvaro Vilaplana Garcia | 0491f5e | 2023-11-25 09:12:44 +0000 | [diff] [blame] | 25 | # Builds and executes on Google GCP RBE using remotejdk_17 |
| 26 | build:remote --config=config_gcp |
David Ostrovsky | c47854e | 2023-11-25 13:27:00 +0100 | [diff] [blame] | 27 | build:remote --config=build_shared |
| 28 | |
Alvaro Vilaplana Garcia | 0491f5e | 2023-11-25 09:12:44 +0000 | [diff] [blame] | 29 | # Define remote configuration alias |
| 30 | build:remote_gcp --config=remote |
| 31 | |
Alvaro Vilaplana Garcia | d0908c9 | 2023-11-15 15:59:25 +0000 | [diff] [blame] | 32 | # Builds and executes on BuildBuddy RBE using remotejdk_17 |
| 33 | build:remote_bb --config=config_bb |
| 34 | build:remote_bb --config=build_shared |
| 35 | |
David Ostrovsky | c47854e | 2023-11-25 13:27:00 +0100 | [diff] [blame] | 36 | # Builds using remotejdk_21, executes using remotejdk_21 or local_jdk |
| 37 | build:build_java21_shared --java_language_version=21 |
| 38 | build:build_java21_shared --java_runtime_version=remotejdk_21 |
| 39 | build:build_java21_shared --tool_java_language_version=21 |
| 40 | build:build_java21_shared --tool_java_runtime_version=remotejdk_21 |
| 41 | |
| 42 | build:java21 --config=build_java21_shared |
| 43 | |
| 44 | # Builds and executes on RBE using remotejdk_21 |
Alvaro Vilaplana Garcia | 0491f5e | 2023-11-25 09:12:44 +0000 | [diff] [blame] | 45 | build:remote21 --config=config_gcp |
David Ostrovsky | c47854e | 2023-11-25 13:27:00 +0100 | [diff] [blame] | 46 | build:remote21 --config=build_java21_shared |
Han-Wen Nienhuys | 9c15e2b | 2019-05-16 16:59:33 +0200 | [diff] [blame] | 47 | |
Alvaro Vilaplana Garcia | 0491f5e | 2023-11-25 09:12:44 +0000 | [diff] [blame] | 48 | # Define remote21 configuration alias |
| 49 | build:remote21_gcp --config=remote21 |
| 50 | |
Alvaro Vilaplana Garcia | d0908c9 | 2023-11-15 15:59:25 +0000 | [diff] [blame] | 51 | # Builds and executes on BuildBuddy RBE using remotejdk_11 |
| 52 | build:remote21_bb --config=config_bb |
| 53 | build:remote21_bb --config=build_java21_shared |
| 54 | |
Gert van Dijk | a5c5489 | 2019-09-19 11:57:16 +0200 | [diff] [blame] | 55 | # Enable strict_action_env flag to. For more information on this feature see |
| 56 | # https://groups.google.com/forum/#!topic/bazel-discuss/_VmRfMyyHBk. |
| 57 | # This will be the new default behavior at some point (and the flag was flipped |
| 58 | # shortly in 0.21.0 - https://github.com/bazelbuild/bazel/issues/7026). Remove |
| 59 | # this flag here once flipped in Bazel again. |
| 60 | build --incompatible_strict_action_env |
| 61 | |
David Ostrovsky | 2a3b282 | 2021-02-19 12:58:35 +0100 | [diff] [blame] | 62 | build --announce_rc |
| 63 | |
Thomas Draebing | 3ccc4cf | 2019-05-20 15:11:07 +0200 | [diff] [blame] | 64 | test --build_tests_only |
Nasser Grainawi | 84dbcef | 2023-02-22 15:59:32 -0700 | [diff] [blame] | 65 | test --test_output=errors |
Thomas Draebing | 3ccc4cf | 2019-05-20 15:11:07 +0200 | [diff] [blame] | 66 | |
David Ostrovsky | adb2f75 | 2019-10-10 03:47:27 +0200 | [diff] [blame] | 67 | import %workspace%/tools/remote-bazelrc |
David Ostrovsky | 96d18ce | 2023-12-19 01:14:59 +0100 | [diff] [blame] | 68 | |
| 69 | # User-specific .bazelrc |
| 70 | try-import %workspace%/user.bazelrc |