forked from STEllAR-GROUP/hpxML
-
Notifications
You must be signed in to change notification settings - Fork 0
How to compile ClangTool and feature extraction
galabc edited this page Nov 28, 2018
·
7 revisions
install LLVM*
module load clang/6.0.0
module load cmake/3.9.0
wget http://releases.llvm.org/6.0.0/llvm-6.0.0.src.tar.xz
tar -xvf llvm-6.0.0.src.tar.xz
cd llvm-6.0.0.src/ && mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=Release -DLLVM_TARGETS_TO_BUILD="X86" ..
make -j
Build Clang on Rostam
export PATH=path/to/LLVM/llvm-6.0.0.src/build/bin/:$PATH
wget http://releases.llvm.org/6.0.0/cfe-6.0.0.src.tar.xz
tar -xvf cfe-6.0.0.src.tar.xz
cd cfe-6.0.0.src/
cd tools
mkdir extra && cd extra
wget http://releases.llvm.org/6.0.0/clang-tools-extra-6.0.0.src.tar.xz
tar -xvf clang-tools-extra-6.0.0.src.tar.xz
cp -r clang-tools-extra-6.0.0.src/* .
cd ../..
mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=Release ..
make -j
Build ClangTool
mkdir ../tools/extra/loop-convert
cp path/to/hpxML//ClangTool/LoopConvert.cpp ../tools/extra/loop-convert
cp path/to/hpxML/ClangTool/CMakeLists.txt ../tools/extra/loop-convert
echo 'add_subdirectory(loop-convert)' >> ../tools/extra/CMakeLists.txt
cmake ..
make loop-convert