bazel: remove --experimental_sibling_repository_layout

one experimental option less and it looks like we won't get native compilation issues like:
https://github.com/bazelbuild/bazel/issues/26361

GitOrigin-RevId: 9baceb40e32b600ce8c9e04d95067027a1184a52
This commit is contained in:
Leonid Shalupov
2025-06-24 21:39:09 +00:00
committed by intellij-monorepo-bot
parent be5adcdb35
commit 55bbdd4d37
3 changed files with 12 additions and 7 deletions
+6 -1
View File
@@ -6,6 +6,10 @@
### --- ###
### NOTE on --experimental_sibling_repository_layout
### The option was removed due to https://github.com/bazelbuild/bazel/issues/26361
### One experimental option less and also it looks like it won't enabled by default in the future
common --@rules_jvm//:jvm-builder=@community//:monorepo-jvm-builder
common --@rules_jvm//:default-kotlinc-opts=@community//:k17
common --@rules_jvm//:resource-packager=@rules_jvm//src/misc:worker-jvm
@@ -30,7 +34,7 @@ common:windows --lockfile_mode=off # todo: https://youtrack.jetbrains.com/issue
common --noenable_workspace
common --nolegacy_external_runfiles --experimental_sibling_repository_layout
common --nolegacy_external_runfiles
# https://bazel.build/docs/bazel-and-java#config-build-tools-java
# A second pair of JDK and JVM used to build and execute tools, which are used in the build process, but are not in the build results.
@@ -41,6 +45,7 @@ common --tool_java_runtime_version=remotejdk_17
# make sure you don't need to open file to read compilation errors
common --experimental_ui_max_stdouterr_bytes=-1
common --experimental_ui_max_stdouterr_bytes=-1
# IDEA do not handle symlinks efficiently (freeze due to modal non-cancellable dialog) and no way to exclude directories by pattern bazel-
common --symlink_prefix=out/bazel-
+1 -1
View File
@@ -1,5 +1,5 @@
build --nobuild_runfile_links
common --nolegacy_external_runfiles --experimental_sibling_repository_layout
common --nolegacy_external_runfiles
# Without it it fails in Windows Sandbox with:
# ERROR: C:/users/wdagutilityaccount/desktop/bazel/BUILD.bazel:24:15: JdepsMerge //:jps_to_bazel-lib { jdeps: 1 } failed: Worker process did not return a WorkResponse:
@@ -51,11 +51,11 @@ internal data class CustomModuleDescription(
internal val customModules: Map<String, CustomModuleDescription> = listOf(
CustomModuleDescription(moduleName = "intellij.idea.community.build.zip", bazelPackage = "@rules_jvm//zip", bazelTargetName = "zip",
outputDirectory = "out/bazel-out/rules_jvm+/\${CONF}/bin/zip"),
outputDirectory = "out/bazel-bin/external/rules_jvm+/zip"),
CustomModuleDescription(moduleName = "intellij.platform.jps.build.dependencyGraph", bazelPackage = "@rules_jvm//dependency-graph", bazelTargetName = "dependency-graph",
outputDirectory = "out/bazel-out/rules_jvm+/\${CONF}/bin/dependency-graph"),
outputDirectory = "out/bazel-bin/external/rules_jvm+/dependency-graph"),
CustomModuleDescription(moduleName = "intellij.platform.jps.build.javac.rt", bazelPackage = "@rules_jvm//jps-builders-6", bazelTargetName = "build-javac-rt",
outputDirectory = "out/bazel-out/rules_jvm+/\${CONF}/bin/jps-builders-6"),
outputDirectory = "out/bazel-bin/external/rules_jvm+/jps-builders-6"),
).associateBy { it.moduleName }
@Suppress("ReplaceGetOrSet")
@@ -520,7 +520,7 @@ internal class BazelBuildFileGenerator(
val jarOutputDirectory = when {
customModule != null -> customModule.outputDirectory
moduleDescriptor.isCommunity -> "out/bazel-out/community+/\${CONF}/bin/$bazelModuleRelativePath"
moduleDescriptor.isCommunity -> "out/bazel-bin/external/community+/$bazelModuleRelativePath"
else -> "out/bazel-bin/$bazelModuleRelativePath"
}
@@ -531,7 +531,7 @@ internal class BazelBuildFileGenerator(
// full target name instead of just jar for intellij.dotenv.*
// like @community//plugins/env-files-support:dotenv-go_resources
jarName.startsWith("@community//") ->
"out/bazel-out/community+/\${CONF}/bin/${jarName.substringAfter("@community//").replace(':', '/')}.jar"
"out/bazel-bin/external/community+/${jarName.substringAfter("@community//").replace(':', '/')}.jar"
else -> "$jarOutputDirectory/$jarName.jar"
}