Skip to content

Commit

Permalink
modified the init/eessi_environment_variables
Browse files Browse the repository at this point in the history
  • Loading branch information
Richard Top committed Jan 11, 2024
1 parent dff5274 commit baf0cc7
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions init/eessi_environment_variables
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ function error() {
false
}

# set up minimal environment: $EESSI_PREFIX, $EESSI_PILOT_VERSION, $EESSI_OS_TYPE, $EESSI_CPU_FAMILY, $EPREFIX
# set up minimal environment: $EESSI_PREFIX, $EESSI_VERSION, $EESSI_OS_TYPE, $EESSI_CPU_FAMILY, $EPREFIX
source $EESSI_INIT_DIR_PATH/minimal_eessi_env

if [ -d $EESSI_PREFIX ]; then
echo "Found EESSI pilot repo @ $EESSI_PREFIX!" >> $output
echo "Found EESSI repo @ $EESSI_PREFIX!" >> $output

export EESSI_EPREFIX=$EPREFIX
if [ -d $EESSI_EPREFIX ]; then
Expand All @@ -29,11 +29,13 @@ if [ -d $EESSI_PREFIX ]; then
# if archdetect is enabled, use internal code
export EESSI_SOFTWARE_SUBDIR=$(${EESSI_INIT_DIR_PATH}/eessi_archdetect.sh cpupath)
echo "archdetect says ${EESSI_SOFTWARE_SUBDIR}" >> $output
else
elif [ "$EESSI_USE_ARCHSPEC" == "1" ]; then
# note: eessi_software_subdir_for_host.py will pick up value from $EESSI_SOFTWARE_SUBDIR_OVERRIDE if it's defined!
export EESSI_EPREFIX_PYTHON=$EESSI_EPREFIX/usr/bin/python3
export EESSI_SOFTWARE_SUBDIR=$($EESSI_EPREFIX_PYTHON ${EESSI_INIT_DIR_PATH}/eessi_software_subdir_for_host.py $EESSI_PREFIX)
echo "archspec says ${EESSI_SOFTWARE_SUBDIR}" >> $output
else
error "Don't know how to detect host CPU, giving up!"
fi
if [ ! -z $EESSI_SOFTWARE_SUBDIR ]; then

Expand Down Expand Up @@ -82,5 +84,5 @@ if [ -d $EESSI_PREFIX ]; then
error "Compatibility layer directory $EESSI_EPREFIX not found!"
fi
else
error "EESSI pilot repository at $EESSI_PREFIX not found!"
error "EESSI repository at $EESSI_PREFIX not found!"
fi

0 comments on commit baf0cc7

Please sign in to comment.