Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
ProfugusMC
ProfugusMC
Commits
4c1d567f
Commit
4c1d567f
authored
Jun 02, 2017
by
Hamilton, Steven P
Browse files
Adding build script.
parent
b3614ad4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Profugus/Source/build_profugus.sh
0 → 100755
View file @
4c1d567f
#!/bin/bash -l
#
# Script to build the raytrace code on different systems.
#
# Author: Mark Berrill, modified by Steven Hamilton
#
function
usage
{
echo
"Usage: ./build_profugus <type of build>"
echo
""
echo
" Default: compiles the code for current host"
echo
""
echo
" Possible build types values: gnu, xl, pgi, clang"
exit
}
if
[[
$1
==
"-h"
||
$1
==
"--help"
]]
then
usage
exit
fi
# Clear existing modules
module unload clang gnu pgi xl xlf cuda kokkos cmake
module purge
module load gcc/4.8.5
module load cmake
module load git
module load hdf5
module load cuda
module load spectrum_mpi
module load netlib-lapack
rm
-rf
CMake
*
echo
cmake
\
-DCMAKE_BUILD_TYPE
:STRING
=
Release
\
-DProfugus_ENABLE_CXX11
:BOOL
=
ON
\
-DCMAKE_C_COMPILER
=
"
${
MPI_ROOT
}
/bin/mpicc"
\
-DCMAKE_CXX_COMPILER
=
"
${
MPI_ROOT
}
/bin/mpicxx"
\
-DBUILD_SHARED_LIBS
:BOOL
=
OFF
\
-DTPL_ENABLE_MPI
:BOOL
=
ON
\
-DMPI_BASE_DIR
:PATH
=
${
MPI_ROOT
}
\
-DTPL_ENABLE_DLlib
=
OFF
\
-DTPL_ENABLE_HDF5
:BOOL
=
ON
\
-DProfugus_ASSERT_MISSING_PACKAGES
:BOOL
=
OFF
\
-DTPL_ENABLE_CUDA
:BOOL
=
ON
\
-DProfugus_ENABLE_CUDA
:BOOL
=
ON
\
-DCUDA_PROPAGATE_HOST_FLAGS
:BOOL
=
OFF
\
-DCUDA_NVCC_FLAGS
:STRING
=
"--std=c++11;-arch=sm_60;-Xptxas=-dlcm=cg"
\
-DProfugus_ENABLE_TESTS
:BOOL
=
OFF
\
-DProfugus_ENABLE_MC
:BOOL
=
ON
\
-DProfugus_ENABLE_CUDA
:BOOL
=
ON
\
-DProfugus_ENABLE_CudaUtils
:BOOL
=
ON
\
src
cmake
\
-DCMAKE_BUILD_TYPE
:STRING
=
Release
\
-DProfugus_ENABLE_CXX11
:BOOL
=
ON
\
-DCMAKE_C_COMPILER
=
"
${
MPI_ROOT
}
/bin/mpicc"
\
-DCMAKE_CXX_COMPILER
=
"
${
MPI_ROOT
}
/bin/mpicxx"
\
-DBUILD_SHARED_LIBS
:BOOL
=
OFF
\
-DTPL_ENABLE_MPI
:BOOL
=
ON
\
-DMPI_BASE_DIR
:PATH
=
${
MPI_ROOT
}
\
-DTPL_ENABLE_DLlib
=
OFF
\
-DTPL_ENABLE_HDF5
:BOOL
=
ON
\
-DProfugus_ASSERT_MISSING_PACKAGES
:BOOL
=
OFF
\
-DTPL_ENABLE_CUDA
:BOOL
=
ON
\
-DProfugus_ENABLE_CUDA
:BOOL
=
ON
\
-DCUDA_PROPAGATE_HOST_FLAGS
:BOOL
=
OFF
\
-DCUDA_NVCC_FLAGS
:STRING
=
"--std=c++11;-arch=sm_60;-Xptxas=-dlcm=cg"
\
-DProfugus_ENABLE_TESTS
:BOOL
=
OFF
\
-DProfugus_ENABLE_MC
:BOOL
=
ON
\
-DProfugus_ENABLE_CUDA
:BOOL
=
ON
\
-DProfugus_ENABLE_CudaUtils
:BOOL
=
ON
\
src
make
-j
8
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment