- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The most recent version of the shell script compilervars.sh added a section to
remove duplicate paths. Its fine for bash, but breaks zsh (whis no default in MacOS.
"echo $(!arg) " is incorrect syntax in the zshell scripting.
I found the fix below , It might be useful for anyone using zhell on macos.
Broken script
------------------function remove_duplicate_paths----------------------------
remove_duplicate_paths() {
local arg=$1
if [ "${INTEL_HOST_PLATFORM}" = "Darwin" ]; then
local arr=(`echo ${!arg} | sed 's/:/\'$'\n/g'`)
else
local arr=(`echo ${!arg} | sed 's/:/\n/g'`)
fi
fixed script below
# ------------------function remove_duplicate_paths----------------------------
remove_duplicate_paths() {
local arg=$1
eval "value=\"\${$arg}\""
if [ "${INTEL_HOST_PLATFORM}" = "Darwin" ]; then
local arr=(`echo ${value} | sed 's/:/\'$'\n/g'`)
else
local arr=(`echo ${!arg} | sed 's/:/\n/g'`)
fi
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Thanks for reporting this issue and providing the workaround.
We will forward this thread to the concerned internal team to verify and get it fixed accordingly if possible.
Have a Good day!
Thanks & Regards
Goutham
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I've reported this to our Developer.
Thanks,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks, I confirm this worked for me on 10.15.7 with zsh. Now onto the next problems with updating macos+intel+openmpi...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you so much for your more beneficial advice so that I could work around the same as problem in my case.
$ source .zshrc (return)
After this command, there is nothing such as error messages at all.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Thanks for the confirmation.
As your issue has been resolved, we are closing this thread. We will no longer respond to this thread. If you require additional assistance from Intel, please start a new thread. Any further interaction in this thread will be considered community only
Regards
Prasanth
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page