Skip to content
Open
Show file tree
Hide file tree
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
3 changes: 1 addition & 2 deletions config-amdgpu.sh.template
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
# use Debug or Release
: ${BUILD_TYPE:=Debug}
: ${BUILD_JOBS:="8"}

: ${CMAKE_MAKE:=""}
: ${MAKE:="make -j4"}

# use this for ninja instead of make
#: ${CMAKE_MAKE:="-G Ninja -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DLLVM_PARALLEL_COMPILE_JOBS=4 -DLLVM_PARALLEL_LINK_JOBS=1"}
#: ${MAKE:="ninja"}

# set this to true if you don't have a github account
: ${HTTPS:=true}
Expand Down
3 changes: 1 addition & 2 deletions config.sh.template
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
# use Debug or Release
: ${BUILD_TYPE:=Debug}
: ${BUILD_JOBS:="8"}

: ${CMAKE_MAKE:=""}
: ${MAKE:="make -j4"}

# use this for ninja instead of make
#: ${CMAKE_MAKE:="-G Ninja -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DLLVM_PARALLEL_COMPILE_JOBS=4 -DLLVM_PARALLEL_LINK_JOBS=1"}
#: ${MAKE:="ninja"}

# set this to true if you don't have a github account
: ${HTTPS:=true}
Expand Down
14 changes: 12 additions & 2 deletions setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,14 @@ source config.sh

CUR=`pwd`

if [ ! -v BUILD_JOBS ]; then
echo "Please specify BUILD_JOBS in the config.sh file"
exit -1
fi

MAKE="cmake --build . --config ${BUILD_TYPE} -j ${BUILD_JOBS}"
MAKE_INSTALL="cmake --install . --config ${BUILD_TYPE}"

function remote {
if $HTTPS; then
echo "https://github.com/$1"
Expand Down Expand Up @@ -83,7 +91,8 @@ if [ "${CMAKE-}" == true ]; then

cd cmake_build
cmake ../CMake -DBUILD_CursesDialog:BOOL=ON -DCMAKE_BUILD_TYPE:STRING=Release -DCMAKE_INSTALL_PREFIX:PATH="${CUR}/cmake_install"
${MAKE} install
${MAKE}
${MAKE_INSTALL}
cd "${CUR}"

export PATH="${CUR}/cmake_install/bin:${PATH}"
Expand Down Expand Up @@ -130,7 +139,8 @@ if [ "${LLVM-}" == true ]; then
fi
cmake ../llvm-project/llvm ${CMAKE_MAKE} -DLLVM_BUILD_LLVM_DYLIB:BOOL=ON -DLLVM_LINK_LLVM_DYLIB:BOOL=ON -DCMAKE_BUILD_TYPE:STRING=${BUILD_TYPE} -DCMAKE_INSTALL_PREFIX:PATH="${CUR}/llvm_install" \
-DLLVM_ENABLE_RTTI:BOOL=ON -DLLVM_ENABLE_PROJECTS:STRING="clang;lld" -DLLVM_ENABLE_BINDINGS:BOOL=OFF -DLLVM_INCLUDE_TESTS:BOOL=ON -DLLVM_TARGETS_TO_BUILD:STRING="${LLVM_TARGETS}" -DDEFAULT_SYSROOT:PATH="${DEFAULT_SYSROOT}"
${MAKE} install
${MAKE}
${MAKE_INSTALL}
cd "${CUR}"

LLVM_VARS=-DLLVM_DIR:PATH="${CUR}/llvm_install/lib/cmake/llvm"
Expand Down