Hello.
I have an Ubuntu 24.04 LTS installation, with clang and llvm version 18.1.3.
I cloned today the PPCG source code from git://
repo.or.cz/ppcg.git. I followed the instructions from the README. Everything works OK until I give make, which fails with the following error:
<<extract_interface.cc:413:41: error: no matching function for call to ‘clang::SourceManager::createFileID(const clang::FileEntry*&, clang::SourceLocation, clang::SrcMgr::CharacteristicK
ind)’
413 | SM.setMainFileID(SM.createFileID(file, SourceLocation(),
| ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
414 | SrcMgr::C_User));
| ~~~~~~~~~~~~~~~
In file included from /usr/lib/llvm-18/include/clang/Frontend/CompilerInstance.h:14,
from extract_interface.cc:67:
/usr/lib/llvm-18/include/clang/Basic/SourceManager.h:911:10: note: candidate: ‘clang::FileID clang::SourceManager::createFileID(clang::FileEntryRef, clang::SourceLocation, clang::SrcMgr::CharacteristicKind, int, clang::SourceLocation::UIntTy)’
911 | FileID createFileID(FileEntryRef SourceFile, SourceLocation IncludePos,
| ^~~~~~~~~~~~
/usr/lib/llvm-18/include/clang/Basic/SourceManager.h:911:36: note: no known conversion for argument 1 from ‘const clang::FileEntry*’ to ‘clang::FileEntryRef’>>
Did anybody else encounter this error?
I changed the file extract_interface.cc and was able to get past this error, but another error appeared:
<<extract_interface.cc: In function ‘void set_lang_defaults(clang::CompilerInstance*)’:
extract_interface.cc:441:29: error: ‘setLangDefaults’ is not a member of ‘clang::CompilerInvocation’
441 | CompilerInvocation::setLangDefaults(Clang->getLangOpts(), IK_C,>>
I'm currently trying to fix this error.
Any help is appreciated.
Thank you,
Alex