Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ supported_distro( )
# This function is helpful for dockerfiles that do not have sudo installed, but the default user is root
check_exit_code( )
{
if (( $? != 0 )); then
exit $?
if (( $1 != 0 )); then
exit $1
fi
}

Expand All @@ -60,10 +60,10 @@ elevate_if_not_root( )

if (( ${uid} )); then
sudo $@
check_exit_code
check_exit_code "$?"
else
$@
check_exit_code
check_exit_code "$?"
fi
}

Expand Down Expand Up @@ -404,18 +404,18 @@ esac
else
CXX=${compiler} ${cmake_executable} ${cmake_common_options} -DCPACK_SET_DESTDIR=OFF -DCMAKE_INSTALL_PREFIX=rocblas-install -DCPACK_PACKAGING_INSTALL_PREFIX=/opt/rocm ../..
fi
check_exit_code
check_exit_code "$?"

make -j$(nproc) install
check_exit_code
check_exit_code "$?"

# #################################################
# install
# #################################################
# installing through package manager, which makes uninstalling easy
if [[ "${install_package}" == true ]]; then
make package
check_exit_code
check_exit_code "$?"

case "${ID}" in
ubuntu)
Expand Down