LibAFL CC provides the functionalities to write compiler wrappers for LibAFL, by providing to the user a set of compiler extensions useful for instrumentation.
The online documentation for this crate is available here.
Currently, we support LLVM version 11 up to 18, but other versions may work. To install LLVM, use the official download page.
The LLVM tools (including clang, clang++) are needed (newer than LLVM 11.0.0 up to LLVM 17.0.0) - When compiling LLVM tools on Windows, you can try to compile LLVM with the below commands (tested on LLVM 16.0.6). - NOTE: This assumes you have Visual Studio 17 2022 and MSVC v143 Tools installed under "Individual Components" ```sh
RUN AS ADMINISTRATOR: %comspec% /k "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\Build\vcvars64.bat"
git clone https://github.com/llvm/llvm-project.git llvm
$ cmake -S llvm\llvm -B build -DLLVMENABLEPROJECTS=clang -DLLVMTARGETSTOBUILD=X86 -Thost=x64 -DCMAKEINSTALL_PREFIX=C:\llvm $ cd build $ cmake --build . --target install --config release
$ cd .. $ cmake -S llvm\llvm -B build -DLLVMENABLEPROJECTS=lld -DLLVMTARGETSTOBUILD=X86 -Thost=x64 -DCMAKEINSTALL_PREFIX=C:\llvm $ cd build $ cmake --build . --target install --config release ```