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

cannot find -lLLVMTransformUtils #1

Closed
lkmidas opened this issue Oct 7, 2021 · 2 comments
Closed

cannot find -lLLVMTransformUtils #1

lkmidas opened this issue Oct 7, 2021 · 2 comments

Comments

@lkmidas
Copy link

lkmidas commented Oct 7, 2021

Hi, I've recently built this project and ran into the following issues:

  • the line link_libraries("libLLVMTransformUtils.so") in Transforms/CMakeLists.txt results in /usr/bin/ld: cannot find -lLLVMTransformUtils and so LLVMObfuscator.so cannot be built.
  • but then I tried to remove that line from Transforms/CMakeLists.txt and the test successfully ran, I've also checked the generated binaries and they seemed to be obfuscated fine.

I wonder how can the project be built successfully without that line, and does it affect the result if I remove it?
Thank you.

@bluesadi
Copy link
Owner

Hi, I'm not quite sure why this error occurred. Maybe it is because you didn't install LLVM to /usr/bin or /usr/local/bin.

About you question:
In Transforms/CMakeLists.txt line 20 opt -lowerswitch -S IR/TestProgram_orig.ll -o IR/TestProgram_lowerswitch.ll I used the lowerswitch Pass from libLLVMTransformUtils.so. However, it still worked fine without link_libraries("libLLVMTransformUtils.so").
So that line is practically useless, you can remove it.

@lkmidas
Copy link
Author

lkmidas commented Oct 18, 2021

Thanks for the answer!

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

No branches or pull requests

2 participants