c++ - Library using libclang: linker reporting undefined reference to method -


as project of own, i'm writing refactoring library (so can used other applications) using libclang code analysis. problem when try compile program static library okey, when try link library (using clang code) demo application (just main function calling code) linker reporting:

./librefactor.a(renamer.o):(.data.rel.ro+0x60): undefined reference 'clang::astconsumer::handleinterestingdecl(clang::declgroupref)' ./librefactor.a(renamer.o):(.data.rel.ro+0x80): undefined reference `clang::astconsumer::handletopleveldeclinobjccontainer(clang::declgroupref)' ./librefactor.a(renamer.o):(.data.rel.ro+0x88): undefined reference `clang::astconsumer::handleimplicitimportdecl(clang::importdecl*)' collect2: error: ld returned 1 exit status 

here makefile build library with: library makefile

here makefile build example with: library example

i commented out parts of code make error short possible similiar errors (undefined reference) other part of clang use in project.

problem don't understand why linker can't find definitions of these functions/methods. not pure virtual in base class don't need defined them. see linker trying find definition of these in part of code istead in clang binaries. please explain me i'm wrong here , explain/repair it?


Comments

Popular posts from this blog

android - Get AccessToken using signpost OAuth without opening a browser (Two legged Oauth) -

org.mockito.exceptions.misusing.InvalidUseOfMatchersException: mockito -

google shop client API returns 400 bad request error while adding an item -