Skip to content

Commit

Permalink
Fixed deployment script to check for LD_LIBRARY_PATH.
Browse files Browse the repository at this point in the history
  • Loading branch information
TimDettmers committed Jul 27, 2022
1 parent 389f66c commit bd51532
Showing 1 changed file with 37 additions and 29 deletions.
66 changes: 37 additions & 29 deletions deploy_from_slurm.sh
Original file line number Diff line number Diff line change
@@ -1,28 +1,37 @@
#!/bin/bash
BASE_PATH=$1

echo "MAKE SURE LD_LIBRARY_PATH IS EMPTY!"
echo $LD_LIBRARY_PATH

if [[ ! -z "${LD_LIBRARY_PATH}" ]]; then
echo "Compilation unsuccessul!" 1>&2
exit 64
fi


module unload cuda
module unload gcc

#rm -rf dist build
#make clean
#make cleaneggs
#export CUDA_HOME=
#make cpuonly
#
#if [ ! -f "./bitsandbytes/libbitsandbytes.so" ]; then
# # Control will enter here if $DIRECTORY doesn't exist.
# echo "Compilation unsuccessul!" 1>&2
# exit 64
#fi
#CUDA_VERSION=cpu python -m build
#python -m twine upload dist/* --verbose --repository testpypi
rm -rf dist build
make clean
make cleaneggs
export CUDA_HOME=
make cpuonly

if [ ! -f "./bitsandbytes/libbitsandbytes.so" ]; then
# Control will enter here if $DIRECTORY doesn't exist.
echo "Compilation unsuccessul!" 1>&2
exit 64
fi
CUDA_VERSION=cpu python -m build
python -m twine upload dist/* --verbose --repository testpypi

rm -rf dist build
make clean
make cleaneggs
export CUDA_HOME=$BASE_PATH/cuda-11.0
make cuda110
make cuda110

if [ ! -f "./bitsandbytes/libbitsandbytes.so" ]; then
# Control will enter here if $DIRECTORY doesn't exist.
Expand Down Expand Up @@ -102,20 +111,20 @@ fi
CUDA_VERSION=115 python -m build
python -m twine upload dist/* --verbose --repository testpypi

#rm -rf dist build
#make clean
#make cleaneggs
#export CUDA_HOME=$BASE_PATH/cuda-11.6
#
#make cuda11x
#if [ ! -f "./bitsandbytes/libbitsandbytes.so" ]; then
# # Control will enter here if $DIRECTORY doesn't exist.
# echo "Compilation unsuccessul!" 1>&2
# exit 64
#fi
#CUDA_VERSION=116 python -m build
#python -m twine upload dist/* --verbose --repository testpypi
#
rm -rf dist build
make clean
make cleaneggs
export CUDA_HOME=$BASE_PATH/cuda-11.6

make cuda11x
if [ ! -f "./bitsandbytes/libbitsandbytes.so" ]; then
# Control will enter here if $DIRECTORY doesn't exist.
echo "Compilation unsuccessul!" 1>&2
exit 64
fi
CUDA_VERSION=116 python -m build
python -m twine upload dist/* --verbose --repository testpypi

rm -rf dist build
make clean
make cleaneggs
Expand Down Expand Up @@ -257,5 +266,4 @@ if [ ! -f "./bitsandbytes/libbitsandbytes.so" ]; then
exit 64
fi
CUDA_VERSION=117-nomatmul python -m build
python -m twine upload dist/* --verbose
python -m twine upload dist/* --verbose --repository testpypi

0 comments on commit bd51532

Please sign in to comment.