blob: f0f2632d54cbc96a079485ce95aeaa274216fd10 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
|
[Compilation Error] Build Thunklibs fails with LLVM-19
# Description
Building main trunk after upgrading to LLVM-19 is failing with this log:
```
% ninja
[0/2] Re-checking globbed directories...
[1/67] Building CXX object ThunkLibs/Generator/CMakeFiles/thunkgenlib.dir/analysis.cpp.o
FAILED: ThunkLibs/Generator/CMakeFiles/thunkgenlib.dir/analysis.cpp.o
/usr/bin/clang++ -DFEX_HAS_PRESERVE_ALL_ATTR=1 -DFEX_PRESERVE_ALL_ATTR="__attribute__((preserve_all))" -DGDB_SYMBOLS_ENABLED=1 -DGLOBAL_DATA_DIRECTORY=\"/usr/share/fex-emu/\" -D_M_ARM_64=1 -I/home/ektor5/FEX/build/ThunkLibs/Generator -I/home/ektor5/FEX/ThunkLibs/Generator -I/home/ektor5/FEX/External/robin-map/include -I/home/ektor5/FEX/External/tiny-json -I/home/ektor5/FEX/Source -I/home/ektor5/FEX/build/Source -I/home/ektor5/FEX/External/fmt/include -isystem /usr/lib/llvm-19/include -O3 -DNDEBUG -fomit-frame-pointer -std=gnu++20 -flto=thin -fPIC -Wno-trigraphs -fdiagnostics-color=always -fcolor-diagnostics -Wno-deprecated-enum-enum-conversion -Wall -MD -MT ThunkLibs/Generator/CMakeFiles/thunkgenlib.dir/analysis.cpp.o -MF ThunkLibs/Generator/CMakeFiles/thunkgenlib.dir/analysis.cpp.o.d -o ThunkLibs/Generator/CMakeFiles/thunkgenlib.dir/analysis.cpp.o -c /home/ektor5/FEX/ThunkLibs/Generator/analysis.cpp
/home/ektor5/FEX/ThunkLibs/Generator/analysis.cpp:248:36: error: no member named 'getTypeAsWritten' in 'clang::ClassTemplateSpecializationDecl'
248 | throw report_error(decl->getTypeAsWritten()->getTypeLoc().getAs<clang::TemplateSpecializationTypeLoc>().getArgLoc(1).getLocation(),
| ~~~~ ^
/home/ektor5/FEX/ThunkLibs/Generator/analysis.cpp:257:36: error: no member named 'getTypeAsWritten' in 'clang::ClassTemplateSpecializationDecl'
257 | throw report_error(decl->getTypeAsWritten()->getTypeLoc().getAs<clang::TemplateSpecializationTypeLoc>().getArgLoc(2).getLocation(),
| ~~~~ ^
/home/ektor5/FEX/ThunkLibs/Generator/analysis.cpp:300:17: error: no member named 'getTypeAsWritten' in 'clang::ClassTemplateSpecializationDecl'
300 | decl->getTypeAsWritten()->getTypeLoc().castAs<clang::TemplateSpecializationTypeLoc>().getArgLoc(0).getLocation();
| ~~~~ ^
/home/ektor5/FEX/ThunkLibs/Generator/analysis.cpp:302:18: warning: variable 'emitted_function' set but not used [-Wunused-but-set-variable]
302 | if (auto emitted_function = llvm::dyn_cast<clang::FunctionDecl>(template_args[0].getAsDecl())) {
| ^
/home/ektor5/FEX/ThunkLibs/Generator/analysis.cpp:337:17: error: no member named 'getTypeAsWritten' in 'clang::ClassTemplateSpecializationDecl'
337 | decl->getTypeAsWritten()->getTypeLoc().castAs<clang::TemplateSpecializationTypeLoc>().getArgLoc(0).getLocation();
| ~~~~ ^
1 warning and 4 errors generated.
ninja: build stopped: subcommand failed.
```
# Environment
Machine: Snapdragon X Elite X1E80100 ARM64
Kernel: 6.11.0-rc6-gf60a0fc0c2a7 arch: aarch64 bits: 64
Distro: Debian Sid
Compiler: Clang
```
Debian clang version 19.1.1 (1)
Target: aarch64-unknown-linux-gnu
Thread model: posix
InstalledDir: /usr/lib/llvm-19/bin
```
FEX Build Configuration:
```
CC=clang CXX=clang++ cmake \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_BUILD_TYPE=Release \
-DUSE_LINKER=lld \
-DENABLE_LTO=True \
-DBUILD_TESTS=False \
-DENABLE_ASSERTIONS=False \
-DBUILD_THUNKS=True \
-G Ninja ..
```
# Other Information
Removed `build` directory completely and compiled from scratch.
Compilation works fine with LLVM-18 or disabling Thunks.
|