You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[X ] I have searched open and closed issues for duplicates
[ X] I made sure that I am not using an old project version (DO: pull PhASAR, update git submodules, rebuild the project and check if the bug is still there)
Bug description
CMake does not use the include directory of the self-built LLVM/clang.
Steps to reproduce
Use an LLVM version greater than 14 due a bug when building it on Debian 12
Expected result: The CMake files should honor the custom LLVM installation. The parameter -I/usr/lib/llvm-14/include should be replaced by -I/fs/scratch/al/llvm-14//include.
(Important/fs/scratch/al/llvm-14/ does contain a built of LLVM 17.0.6. The directory name is misleading.)
The CMake variable LLVM_INCLUDE_DIRS, used in cmake/phasar_macros.cmake:209 shall point to the aforementioned directory.
That variable is set in /fs/scratch/al/llvm-14/lib/cmake/llvm/LLVMConfig.cmake. I assume CMake must use the CMake files for LLVM from /fs/scratch/al/llvm-14/lib/cmake.
Example files
Files:
The text was updated successfully, but these errors were encountered:
PhASAR currently requires LLVM 14. We are in the process of supporting newer LLVM versions, but there are two major problems that have to be solved first (#533 and #687).
In our build configuration, we use find_package(LLVM 14 REQUIRED CONFIG) to find the required LLVM version. Even if there is a newer version installed, this command will prefer LLVM 14.
Please note, that this LLVM version is independent from the clang version that you use for compilation -- you just cannot compile the unittests with clang>14.
Your invocation
Currently, the custom build of LLVM must be located in
/usr/local/llvm-14.
If not, CMake will either fail finding LLVMConfig.cmake or use a
different LLVM installation, e.g., the system-wide one.
This will, for example, result in an include path different from the
custom LLVM installation.
This commit extends 'bootstrap.sh' to set 'LLVM_ROOT' to the
custom installation. Moreover, it allows the user to select
an arbitrary location for LLVM.
(Fixed#689)
Co-authored-by: Fabian Schiebel <[email protected]>
Bug description
CMake does not use the include directory of the self-built LLVM/clang.
Steps to reproduce
bootstrap.sh
CC=/fs/scratch/al/llvm-14/bin/clang CXX=/fs/scratch/al/llvm-14/bin/clang++ cmake -G Ninja -DCMAKE_BUILD_TYPE=Release -DPHASAR_BUILD_UNITTESTS=true /fs/scratch/al/phasar/src
cmake --build . -j 1
Actual result: Due to the newer LLVM, the build process aborts. This in turn shows the wrong include dir:
-I/usr/lib/llvm-14/include
.Expected result: The CMake files should honor the custom LLVM installation. The parameter
-I/usr/lib/llvm-14/include
should be replaced by-I/fs/scratch/al/llvm-14//include
.(Important
/fs/scratch/al/llvm-14/
does contain a built of LLVM 17.0.6. The directory name is misleading.)Context (Environment)
Operating System:
Build Type:
Possible solution
The CMake variable
LLVM_INCLUDE_DIRS
, used incmake/phasar_macros.cmake:209
shall point to the aforementioned directory.That variable is set in
/fs/scratch/al/llvm-14/lib/cmake/llvm/LLVMConfig.cmake
. I assume CMake must use the CMake files for LLVM from/fs/scratch/al/llvm-14/lib/cmake
.Example files
Files:
The text was updated successfully, but these errors were encountered: