Skip to content

Build failure on latest ubuntu #11

@Emoun

Description

@Emoun

We get the following build failure on Ubuntu 24:

[100%] Building CXX object lib/Support/CMakeFiles/LLVMSupport.dir/TargetRegistry.cpp.o
In file included from /home/runner/work/patmos-llvm-project/patmos-llvm-project/llvm/lib/Support/Signals.cpp:14:
/home/runner/work/patmos-llvm-project/patmos-llvm-project/llvm/include/llvm/Support/Signals.h:119:8: error: variable or field ‘CleanupOnSignal’ declared void
  119 |   void CleanupOnSignal(uintptr_t Context);
      |        ^~~~~~~~~~~~~~~
/home/runner/work/patmos-llvm-project/patmos-llvm-project/llvm/include/llvm/Support/Signals.h:119:24: error: ‘uintptr_t’ was not declared in this scope
  119 |   void CleanupOnSignal(uintptr_t Context);
      |                        ^~~~~~~~~
/home/runner/work/patmos-llvm-project/patmos-llvm-project/llvm/include/llvm/Support/Signals.h:18:1: note: ‘uintptr_t’ is defined in header ‘<cstdint>’; did you forget to ‘#include <cstdint>’?
   17 | #include <string>
  +++ |+#include <cstdint>
   18 | 
[100%] Building CXX object lib/Support/CMakeFiles/LLVMSupport.dir/ThreadLocal.cpp.o
In file included from /home/runner/work/patmos-llvm-project/patmos-llvm-project/llvm/lib/Support/Signals.cpp:225:
/home/runner/work/patmos-llvm-project/patmos-llvm-project/llvm/lib/Support/Unix/Signals.inc:348:44: error: ‘void llvm::sys::CleanupOnSignal(uintptr_t)’ should have been declared inside ‘llvm::sys’
  348 | void sys::CleanupOnSignal(uintptr_t Context) {
      |                                            ^
make[3]: *** [lib/Support/CMakeFiles/LLVMSupport.dir/build.make:1882: lib/Support/CMakeFiles/LLVMSupport.dir/Signals.cpp.o] Error 1
make[3]: *** Waiting for unfinished jobs....
make[2]: *** [CMakeFiles/Makefile2:9539: lib/Support/CMakeFiles/LLVMSupport.dir/all] Error 2
make[1]: *** [CMakeFiles/Makefile2:16904: utils/FileCheck/CMakeFiles/FileCheck.dir/rule] Error 2
make: *** [Makefile:3621: FileCheck] Error 2

This seems to me to have already been fixed in upstream LLVM, so the solution is to upgrade. See here and here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions