From ba42575f78d39fbbf16a2b68cc9b30d5425bbab7 Mon Sep 17 00:00:00 2001 From: Vitor Bandeira Date: Wed, 30 Sep 2026 14:33:13 -0300 Subject: [PATCH 1/3] feat(installer): make -bazel the default and add -cmake The installer always gave -bazel to the OpenROAD installer with -base or -all. There was no flag to skip it. Users who build OpenROAD with CMake (build_openroad.sh --openroad-args -cmake-build) do not need bazelisk and its runtime libraries. -bazel is the default, so current callers get the same result. -cmake skips Bazel. If both flags are given, the last one wins. Signed-off-by: Vitor Bandeira --- etc/DependencyInstaller.sh | 33 ++++++++++++++++++++++++++------- 1 file changed, 26 insertions(+), 7 deletions(-) diff --git a/etc/DependencyInstaller.sh b/etc/DependencyInstaller.sh index 1303b663b5..1341e4e86b 100755 --- a/etc/DependencyInstaller.sh +++ b/etc/DependencyInstaller.sh @@ -337,13 +337,23 @@ Usage: $0 [-all|-base|-common] [-] # $0 -base # Installs OpenROAD's dependencies using - # package managers, including Bazel - # (bazelisk). -common must be executed - # in another command. + # package managers. -common must be + # executed in another command. $0 -common # Installs OpenROAD's common dependencies # (-base must be executed in another # command). + $0 -bazel + # Default. Installs Bazel (bazelisk) and + # its runtime libraries with -base or + # -all. build_openroad.sh builds + # OpenROAD with Bazel. + $0 -cmake + # Skips Bazel and installs only the CMake + # dependencies. Use it to build + # OpenROAD with CMake, e.g. + # build_openroad.sh --openroad-args + # -cmake-build (deprecated upstream). $0 -prefix=DIR # Installs common dependencies in an existing # user-specified directory. Only used @@ -378,6 +388,8 @@ option="none" isLocal="false" constantBuildDir="false" CI="no" +# OpenROAD build system to install dependencies for: bazel or cmake +buildSystem="bazel" # default values, can be overwritten by cmdline args while [ "$#" -gt 0 ]; do @@ -403,6 +415,12 @@ while [ "$#" -gt 0 ]; do fi option="common" ;; + -bazel) + buildSystem="bazel" + ;; + -cmake) + buildSystem="cmake" + ;; -local) OR_INSTALLER_ARGS="${OR_INSTALLER_ARGS} -local" ;; @@ -442,10 +460,11 @@ if [[ "${option}" == "none" ]]; then fi OR_INSTALLER_ARGS="${OR_INSTALLER_ARGS} -${option}" -# build_openroad.sh builds OpenROAD with Bazel, so bazelisk and its runtime -# libraries are base dependencies. They need root, and -common may run -# unprivileged, so they ride along with -base only. -if [[ "${option}" == "base" || "${option}" == "all" ]]; then +# build_openroad.sh builds OpenROAD with Bazel by default, so bazelisk and +# its runtime libraries are base dependencies unless -cmake is given. They +# need root, and -common may run unprivileged, so they ride along with -base +# only. +if [[ "${buildSystem}" == "bazel" ]] && [[ "${option}" == "base" || "${option}" == "all" ]]; then OR_INSTALLER_ARGS="${OR_INSTALLER_ARGS} -bazel" fi From 8c38ddb16e3b2bb361f65a73e5fdee044cd59193 Mon Sep 17 00:00:00 2001 From: Vitor Bandeira Date: Mon, 5 Oct 2026 11:00:07 -0300 Subject: [PATCH 2/3] fix(installer): pass -cmake to the OpenROAD installer The OpenROAD installer now defaults to the Bazel set. Its -base and -common install the CMake set only with -cmake. Yosys, EQY and kepler-formal need the CMake set for both build systems, so always pass -cmake. With -bazel, -base now installs only the Bazel runtime libraries, and -common installs bazelisk into the -common prefix. That prefix is not on PATH. A separate bare -bazel call in the privileged step keeps bazelisk in /usr/local. The installed parts stay the same for -base, -common and -all, with or without -ci. This needs the OpenROAD submodule at a version with the -cmake option. Signed-off-by: Vitor Bandeira --- etc/DependencyInstaller.sh | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/etc/DependencyInstaller.sh b/etc/DependencyInstaller.sh index 1341e4e86b..af335f2437 100755 --- a/etc/DependencyInstaller.sh +++ b/etc/DependencyInstaller.sh @@ -31,6 +31,12 @@ _installORDependencies() { YOSYS_VER=v$(grep 'yosys_ver =' tools/yosys/docs/source/conf.py | awk -F'"' '{print $2}') fi ./tools/OpenROAD/etc/DependencyInstaller.sh ${OR_INSTALLER_ARGS} -yosys-ver="${YOSYS_VER}" + # bazelisk goes to /usr/local in the privileged step, because the -common + # prefix is not on PATH. A bare -bazel installs it and its runtime + # libraries. + if [[ "${buildSystem}" == "bazel" ]] && [[ "${option}" == "base" || "${option}" == "all" ]]; then + ./tools/OpenROAD/etc/DependencyInstaller.sh -bazel + fi } _installPipCommon() { @@ -459,14 +465,10 @@ if [[ "${option}" == "none" ]]; then _help fi -OR_INSTALLER_ARGS="${OR_INSTALLER_ARGS} -${option}" -# build_openroad.sh builds OpenROAD with Bazel by default, so bazelisk and -# its runtime libraries are base dependencies unless -cmake is given. They -# need root, and -common may run unprivileged, so they ride along with -base -# only. -if [[ "${buildSystem}" == "bazel" ]] && [[ "${option}" == "base" || "${option}" == "all" ]]; then - OR_INSTALLER_ARGS="${OR_INSTALLER_ARGS} -bazel" -fi +# Yosys, EQY and kepler-formal need the OpenROAD CMake dependency set for +# both build systems. build_openroad.sh builds OpenROAD with Bazel by default, +# so _installORDependencies also installs the Bazel set unless -cmake is given. +OR_INSTALLER_ARGS="${OR_INSTALLER_ARGS} -cmake -${option}" platform="$(uname -s)" case "${platform}" in From 30bd13d25352073c747d01794998ce48048143b8 Mon Sep 17 00:00:00 2001 From: Vitor Bandeira Date: Thu, 15 Oct 2026 13:47:49 -0300 Subject: [PATCH 3/3] bump OR to the Bazel-default installer Move tools/OpenROAD to 61470341f3. It includes the OpenROAD installer that defaults to Bazel and takes -cmake, and the Build.sh that builds with Bazel by default. The ORFS installer passes -cmake, so it needs this version. Signed-off-by: Vitor Bandeira --- tools/OpenROAD | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/OpenROAD b/tools/OpenROAD index 91e5f5ff2f..61470341f3 160000 --- a/tools/OpenROAD +++ b/tools/OpenROAD @@ -1 +1 @@ -Subproject commit 91e5f5ff2f198fd130e8915c8ad4408b56987fa4 +Subproject commit 61470341f3d2062514af36de09ab7590ddae06a4