Skip to content
Merged
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
13 changes: 12 additions & 1 deletion etc/DependencyInstaller.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,10 @@ _versionCompare() {
}

_installORDependencies() {
./tools/OpenROAD/etc/DependencyInstaller.sh ${OR_INSTALLER_ARGS}
if [[ ${YOSYS_VER} == "" ]]; then
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}"
}

_installPipCommon() {
Expand Down Expand Up @@ -306,6 +309,10 @@ Usage: $0 [-all|-base|-common] [-<ARGS>]
# sudo or with root access.
$0 -ci
# Installs CI tools
$0 -yosys-ver=VERSION
# Installs specified version of Yosys.
# By default, the Yosys version is
# obtained from tools/yosys/docs/source/conf.py
$0 -constant-build-dir
# Use constant build directory, instead of
# random one.
Expand All @@ -315,6 +322,7 @@ EOF

# default args
OR_INSTALLER_ARGS="-eqy"
YOSYS_VER=""
# default prefix
PREFIX=""
# default option
Expand Down Expand Up @@ -355,6 +363,9 @@ while [ "$#" -gt 0 ]; do
CI="yes"
OR_INSTALLER_ARGS="${OR_INSTALLER_ARGS} -save-deps-prefixes=/etc/openroad_deps_prefixes.txt"
;;
-yosys-ver=*)
YOSYS_VER=${1#*=}
;;
-prefix=*)
OR_INSTALLER_ARGS="${OR_INSTALLER_ARGS} $1"
PREFIX=${1#*=}
Expand Down
13 changes: 8 additions & 5 deletions etc/DockerHelper.sh
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,10 @@ _setup() {
fromImage="${FROM_IMAGE_OVERRIDE:-$osBaseImage}"
cp tools/OpenROAD/etc/DependencyInstaller.sh etc/InstallerOpenROAD.sh
context="etc"
buildArgs="--build-arg options=${options} ${noConstantBuildDir}"
local yosys_ver
yosys_ver=v$(grep 'yosys_ver =' tools/yosys/docs/source/conf.py | awk -F'"' '{print $2}')
options+=" -yosys-ver=${yosys_ver}"
buildArgs="--build-arg \"options=${options}\" ${noConstantBuildDir}"
;;
*)
echo "Target ${target} not found" >&2
Expand All @@ -87,20 +90,20 @@ _setup() {

_create() {
echo "Create docker image ${imagePath} using ${file}"
${DOCKER_CMD} buildx build \
eval ${DOCKER_CMD} buildx build \
--file "${file}" \
--tag "${imagePath}" \
${buildArgs} \
"${buildArgs}" \
"${context}"
rm -f etc/InstallerOpenROAD.sh
}

_push() {
if [[ -z ${username+x} ]]; then
if [[ -z ${username+x} ]] && [[ ${dryRun} != 1 ]]; then
echo "Missing required -username=<USER> argument"
_help
fi
if [[ -z ${password+x} ]]; then
if [[ -z ${password+x} ]] && [[ ${dryRun} != 1 ]]; then
echo "Missing required -password=<PASS> argument"
_help
fi
Expand Down
2 changes: 1 addition & 1 deletion tools/OpenROAD
Submodule OpenROAD updated 166 files