Skip to content

Commit c8ee4fb

Browse files
authored
Merge pull request #7 from JuliaParallel/initial
Fix AMDGPU preference set up
2 parents cdfcc9a + cdd1fcf commit c8ee4fb

File tree

1 file changed

+21
-1
lines changed

1 file changed

+21
-1
lines changed

juhpc

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,20 @@
1212

1313
export JUHPC="\e[1;34m[\e[0m \e[1;35mJ\e[0m\e[1;32mU\e[0m\e[1;31mH\e[0m\e[1;31mP\e[0m\e[1;31mC\e[0m\e[1;34m:\e[0m"
1414

15+
export JUHPC_LOGO=$(cat <<'EOF'
16+
\e[1;35m ██╗\e[0m \e[1;32m██╗ ██╗\e[0m \e[1;31m██╗ ██╗██████╗ ██████╗\e[0m
17+
\e[1;35m ██║\e[0m \e[1;32m██║ ██║\e[0m \e[1;31m██║ ██║██╔══██╗██╔════╝\e[0m
18+
\e[1;35m ██║\e[0m \e[1;32m██║ ██║\e[0m \e[1;31m███████║██████╔╝██║ \e[0m
19+
\e[1;35m██╗ ██║\e[0m \e[1;32m██║ ██║\e[0m \e[1;31m██╔══██║██╔═══╝ ██║ \e[0m
20+
\e[1;35m╚█████╔╝\e[0m \e[1;32m╚██████╔╝\e[0m \e[1;31m██║ ██║██║ ╚██████╗\e[0m
21+
\e[1;35m ╚════╝ \e[0m \e[1;32m ╚═════╝ \e[0m \e[1;31m╚═╝ ╚═╝╚═╝ ╚═════╝\e[0m
22+
EOF
23+
)
24+
25+
print_logo() {
26+
echo -e "$JUHPC_LOGO" >&2
27+
}
28+
1529
info() {
1630
local message="$1"
1731
echo -e "$JUHPC $message" >&2
@@ -62,6 +76,7 @@ export TMP_JULIAUP_ROOTDIR=$TMP/juliaup
6276

6377
# Start installation
6478

79+
print_logo
6580
info "Starting installation of HPC setup for juliaup, julia and HPC key packages requiring system libraries..."
6681
check_var "JULIAUP_INSTALLDIR" "JUHPC_SETUP_INSTALLDIR"
6782
check_dir "$JUHPC_SETUP_INSTALLDIR"
@@ -121,7 +136,7 @@ if [ -n "${JUHPC_CUDA_HOME}" ]; then # Set preference for using the local CUDA
121136
fi
122137

123138
if [ -n "${JUHPC_ROCM_HOME}" ]; then # Set preference for using the local ROCm runtime in a more stable way (in case the previous would not be valid anymore)
124-
julia --project=$JULIA_PREFDIR -e 'using ROCM; ROCM.AMDGPU.ROCmDiscovery.use_artifacts!(false)'
139+
julia --project=$JULIA_PREFDIR -e 'using AMDGPU; AMDGPU.ROCmDiscovery.use_artifacts!(false)'
125140
fi
126141

127142
if [ -n "${JUHPC_MPI_VENDOR}" ]; then
@@ -150,12 +165,17 @@ mkdir -p "$JULIAUP_WRAPPER_BINDIR" || { error "failed to create directory: $JULI
150165
julia -e '
151166
println("""#!/bin/bash
152167
168+
print_logo() {
169+
echo -e "$(ENV["JUHPC_LOGO"])" >&2
170+
}
171+
153172
info() {
154173
local message="\$1"
155174
echo -e "$(ENV["JUHPC"]) \$message" >&2
156175
}
157176
158177
if [ ! -f $(ENV["JULIAUP_BINDIR"])/juliaup ]; then
178+
print_logo
159179
info "This is the first call to juliaup; juliaup and the latest julia will now be installed. After that, you can use juliaup and julia normally. Installing in $(ENV["JULIAUP_INSTALLDIR"])..."
160180
PATH_OLD=\$PATH
161181
export PATH=\$(echo \$PATH | perl -pe "s|[^:]*juliaup(?:_wrapper)?[^:]*:?||g") # Remove all juliaup paths from PATH

0 commit comments

Comments
 (0)