OpenFOAMing-Sea/pkgs/openfoam/0001-etc-bashrc-add-placeholder-for-FOAM_INST_DIR.patch
2025-04-22 16:57:29 +02:00

35 lines
988 B
Diff

From 8043842ab7feceae999addf2725d44ab0f65071a Mon Sep 17 00:00:00 2001
From: Sebastian Woetzel <wose@zuendmasse.de>
Date: Sun, 20 Apr 2025 18:00:41 +0200
Subject: [PATCH] etc/bashrc: add placeholder for FOAM_INST_DIR
---
etc/bashrc | 11 ++---------
1 file changed, 2 insertions(+), 9 deletions(-)
diff --git a/etc/bashrc b/etc/bashrc
index 1ead5cc1c7..59d0bdb2ad 100644
--- a/etc/bashrc
+++ b/etc/bashrc
@@ -42,15 +42,8 @@ export WM_PROJECT_VERSION=12
# the directory two levels below this file, or $HOME/$WM_PROJECT if that
# directory cannot be determined.
#
-[ "$BASH" ] && bashrcFile=${BASH_SOURCE}
-[ "$ZSH_NAME" ] && bashrcFile=$0
-if [ -n "$bashrcFile" ]
-then
- export FOAM_INST_DIR=$(cd $(dirname $bashrcFile)/../.. && pwd -P)
-else
- export FOAM_INST_DIR=$HOME/$WM_PROJECT
-fi
-unset bashrcFile
+# FOAM_INST_DIR is set in postPatch phase
+# __inst_dir_placeholder__
#
# Please set to the appropriate path if the above default is not correct. E.g.,
#
--
2.49.0