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

rustllvm conditional build #3701

Closed
lucab opened this issue Oct 8, 2012 · 1 comment
Closed

rustllvm conditional build #3701

lucab opened this issue Oct 8, 2012 · 1 comment
Labels
E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
Milestone

Comments

@lucab
Copy link
Contributor

lucab commented Oct 8, 2012

In rustllvm, Rustwrapper.cpp uses an external symbol (DebugFlag), which is conditionally exported by LLVM in llvm/Support/Debug.h in between an #ifndef NDEBUG block.

Unfortunately the Debian packaged llvm is currently configured to define it:

$ llvm-config --cxxflags
-I/usr/lib/llvm-3.1/include  -DNDEBUG -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -g -O2 -fomit-frame-pointer -fvisibility-inlines-hidden -fno-exceptions -fPIC -Woverloaded-virtual -Wcast-qual

Thus rust fails to build. Would adding a #ifndef inside LLVMSetDebug() suffice?

@brson
Copy link
Contributor

brson commented Oct 8, 2012

I think an #ifndef inside LLVMSetDebug is fine.

catamorphism added a commit that referenced this issue Oct 17, 2012
RalfJung pushed a commit to RalfJung/rust that referenced this issue Jul 29, 2024
show warning when Stacked Borrows skips a reborrow due to 'extern type'

When this happens, we can't actually be sure to catch all bugs -- LLVM will still get a `noalias` but Miri can't do reborrowing. That's not good.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
Projects
None yet
Development

No branches or pull requests

3 participants