From 09da768d39f451c1c9db2e859864f3e4585190ab Mon Sep 17 00:00:00 2001 From: Eryk Szpotanski Date: Tue, 3 Sep 2024 14:59:40 +0200 Subject: [PATCH] etc: DependencyInstaller: Add option for constant build path to increase build reproducibility Signed-off-by: Eryk Szpotanski --- etc/DependencyInstaller.sh | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/etc/DependencyInstaller.sh b/etc/DependencyInstaller.sh index 47756712023..a559aa4fa0a 100755 --- a/etc/DependencyInstaller.sh +++ b/etc/DependencyInstaller.sh @@ -721,6 +721,9 @@ Usage: $0 # Installs dependencies required to run CI $0 -nocert # Disable certificate checks + $0 -constant-build-dir + # Use constant build directory, instead of + # random one. EOF exit "${1:-1}" @@ -776,6 +779,14 @@ while [ "$#" -gt 0 ]; do export PREFIX="${HOME}/.local" export isLocal="true" ;; + -constant-build-dir) + baseDir="/tmp/DependencyInstaller-OpenROAD" + if [[ -d "$baseDir" ]]; then + echo "INFO: removing old building directory $baseDir" + rm -r "$baseDir" + fi + mkdir -p "$baseDir" + ;; -prefix=*) if [[ ! -z ${PREFIX} ]]; then echo "WARNING: previous argument -local will be overwritten with -prefix"