[v0.20] Add debug option in build.sh script

This commit is contained in:
Dr-Noob
2021-12-21 16:40:28 +01:00
parent 69190612a1
commit 3e9f72fcf0

View File

@@ -7,6 +7,13 @@ rm -rf build/ gpufetch
mkdir build/ mkdir build/
cd build/ cd build/
if [ "$1" == "debug" ]
then
BUILD_TYPE="Debug"
else
BUILD_TYPE="Release"
fi
# In case you have CUDA installed but it is not detected, # In case you have CUDA installed but it is not detected,
# - set CMAKE_CUDA_COMPILER to your nvcc binary: # - set CMAKE_CUDA_COMPILER to your nvcc binary:
# - set CMAKE_CUDA_COMPILER_TOOLKIT_ROOT to the CUDA root dir # - set CMAKE_CUDA_COMPILER_TOOLKIT_ROOT to the CUDA root dir
@@ -19,7 +26,7 @@ cd build/
# Disable Intel backend: # Disable Intel backend:
# cmake -DENABLE_INTEL_BACKEND=OFF .. # cmake -DENABLE_INTEL_BACKEND=OFF ..
cmake .. cmake -DCMAKE_BUILD_TYPE=$BUILD_TYPE ..
make -j$(nproc) make -j$(nproc)
cd - cd -
ln -s build/gpufetch . ln -s build/gpufetch .