Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version of LLVM #11

Closed
sr-tream opened this issue Mar 3, 2020 · 2 comments
Closed

Version of LLVM #11

sr-tream opened this issue Mar 3, 2020 · 2 comments

Comments

@sr-tream
Copy link

sr-tream commented Mar 3, 2020

Which version of LLVM need for building? With LLVM 9 it fail:

make[1]: Entering directory '/home/sr_team/Projects/FakePDB/src_pdbgen/build'
make[2]: Entering directory '/home/sr_team/Projects/FakePDB/src_pdbgen/build'
Scanning dependencies of target pdbgen_common
make[2]: Leaving directory '/home/sr_team/Projects/FakePDB/src_pdbgen/build'
make[2]: Entering directory '/home/sr_team/Projects/FakePDB/src_pdbgen/build'
[ 12%] Building CXX object CMakeFiles/pdbgen_common.dir/pefile.cpp.o
[ 25%] Building CXX object CMakeFiles/pdbgen_common.dir/pdbcreator.cpp.o
/home/sr_team/Projects/FakePDB/src_pdbgen/pefile.cpp: In member function 'uint32_t PeFile::GetImageSize()':
/home/sr_team/Projects/FakePDB/src_pdbgen/pefile.cpp:118:38: error: no matching function for call to 'llvm::object::COFFObjectFile::getPE32Header()'
  118 |     auto* pe32 = _obj->getPE32Header();
      |                                      ^
In file included from /home/sr_team/Projects/FakePDB/src_pdbgen/pefile.h:26,
                 from /home/sr_team/Projects/FakePDB/src_pdbgen/pefile.cpp:17:
/usr/include/llvm/Object/COFF.h:975:19: note: candidate: 'std::error_code llvm::object::COFFObjectFile::getPE32Header(const llvm::object::pe32_header*&) const'
  975 |   std::error_code getPE32Header(const pe32_header *&Res) const;
      |                   ^~~~~~~~~~~~~
/usr/include/llvm/Object/COFF.h:975:19: note:   candidate expects 1 argument, 0 provided
/home/sr_team/Projects/FakePDB/src_pdbgen/pefile.cpp:123:46: error: no matching function for call to 'llvm::object::COFFObjectFile::getPE32PlusHeader()'
  123 |     auto* pe32plus = _obj->getPE32PlusHeader();
      |                                              ^
In file included from /home/sr_team/Projects/FakePDB/src_pdbgen/pefile.h:26,
                 from /home/sr_team/Projects/FakePDB/src_pdbgen/pefile.cpp:17:
/usr/include/llvm/Object/COFF.h:976:19: note: candidate: 'std::error_code llvm::object::COFFObjectFile::getPE32PlusHeader(const llvm::object::pe32plus_header*&) const'
  976 |   std::error_code getPE32PlusHeader(const pe32plus_header *&Res) const;
      |                   ^~~~~~~~~~~~~~~~~
/usr/include/llvm/Object/COFF.h:976:19: note:   candidate expects 1 argument, 0 provided
make[2]: *** [CMakeFiles/pdbgen_common.dir/build.make:63: CMakeFiles/pdbgen_common.dir/pefile.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
/home/sr_team/Projects/FakePDB/src_pdbgen/pdbcreator.cpp: In member function 'bool PdbCreator::Commit(std::filesystem::__cxx11::path&)':
/home/sr_team/Projects/FakePDB/src_pdbgen/pdbcreator.cpp:108:81: error: taking address of rvalue [-fpermissive]
  108 |     if (_pdbBuilder.commit(path.string(), &_pdbBuilder.getInfoBuilder().getGuid())) {
      |                                                                                 ^
make[2]: *** [CMakeFiles/pdbgen_common.dir/build.make:89: CMakeFiles/pdbgen_common.dir/pdbcreator.cpp.o] Error 1
make[2]: Leaving directory '/home/sr_team/Projects/FakePDB/src_pdbgen/build'
make[1]: *** [CMakeFiles/Makefile2:81: CMakeFiles/pdbgen_common.dir/all] Error 2
make[1]: Leaving directory '/home/sr_team/Projects/FakePDB/src_pdbgen/build'
make: *** [Makefile:84: all] Error 2

@laomaiweng
Copy link
Contributor

FWIW it builds fine with LLVM 10.

@Mixaill
Copy link
Owner

Mixaill commented Apr 26, 2020

LLVM 10 required, LLVM git preferable.

Added info into readme.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants