[LLVMdev] Compilation problem when addind a library

Rinaldini Julien julien.rinaldini at heig-vd.ch
Tue Mar 5 02:00:05 PST 2013


Ok, I finally got it… I just add to remove LOADABLE_MODULE = 1 from my Makefile and now it works…
It seems that it don't want to compile an archive and a loadable module…

Cheers

Le 27 févr. 2013 à 14:48, Rinaldini Julien <julien.rinaldini at heig-vd.ch> a écrit :

> Hi !
> 
> Here is the situation. I created a pass in lib/Transforms/Obfuscation. I added a createFlattening() in IPO.h and in my code
> to be able to use it in PassManagerBuilder.cpp (lib/Transforms/IPO) in the method PopulateModulePassManager() so I can add my pass to standard passes.
> 
> It all works if I add all my files in the lib/Transforms/IPO directory.
> 
> But I want to keep them away in the lib/Transforms/Obfuscation directory.
> 
> This is my Makefile:
> LEVEL = ../../..
> LIBRARYNAME = LLVMobfuscation
> LOADABLE_MODULE = 1
> BUILD_ARCHIVE = 1
> 
> include $(LEVEL)/Makefile.common
> 
> My CMakeListes.txt
> 
> add_llvm_library(LLVMobfuscation
>  Cgf.cpp
>  CgfFunction.cpp
>  Flattening.cpp
>  )
> 
> add_dependencies(LLVMobfuscation intrinsics_gen)
> 
> and my LLVMBuild.txt
> 
> [component_0]
> type = Library
> name = Obfuscation
> parent = Transforms
> library_name = Obfuscation
> 
> I added my directory and pass in the Transforms Makefile,LLVMBuild and CMakeLists, in the Transforms/IPO files and in the tools/opt files, but
> I still get this error:
> 
> make[2]: Entering directory `/home/pyknite/work/obfuscator/3.2/build/tools/opt'
> make[2]: *** No rule to make target `/home/pyknite/work/obfuscator/3.2/build/Release+Asserts/lib/libLLVMObfuscation.a', needed by `/home/pyknite/work/obfuscator/3.2/build/Release+Asserts/bin/opt'.  Stop.
> make[2]: Leaving directory `/home/pyknite/work/obfuscator/3.2/build/tools/opt'
> 
> Any idea ? Thx
> 
> Cheers
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev





More information about the llvm-dev mailing list