Skip to content

Haiku debug build, rdynamic flag unsupported. #247

New issue

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

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

Already on GitHub? # to your account

Merged
merged 1 commit into from
Sep 14, 2020

Conversation

devnexen
Copy link
Collaborator

No description provided.

CMakeLists.txt Outdated
@@ -175,10 +175,10 @@ if(NOT DEFINED SNMALLOC_ONLY_HEADER_LIBRARY)
# Static TLS model unsupported on Haiku
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mind updating this comment while you're at it?

@devnexen devnexen force-pushed the haiku_debug_build_fix branch from 3842a94 to 1d964a6 Compare September 11, 2020 17:17
@davidchisnall
Copy link
Collaborator

Is this just a compiler driver bug? Does -Wl,-rdynamic work? If so, that should work everywhere and we can fix at least the clang driver to forward -rdynamic to the linker quite easily to prevent this being a problem for other projects in the future.

@devnexen
Copy link
Collaborator Author

It s really unsupported (even what you propose).

@davidchisnall
Copy link
Collaborator

That’s surprising. -rdynamic just puts everything in the dynamic symbol table. I don’t see how you can have an ELF target that supports shared libraries and doesn’t support it.

@devnexen
Copy link
Collaborator Author

All symbols are exported by default on Haiku, it is -shared implicitly ; it behaves differently than other oses in that matter.

@davidchisnall
Copy link
Collaborator

I see, so -rdynamic is the default? A bit surprising it isn't accepted as an argument then. Can you add that as a comment in this PR?

@devnexen
Copy link
Collaborator Author

I think I updated the comment in CMakeLists.txt earlier

CMakeLists.txt Outdated
@@ -172,13 +172,13 @@ if(NOT DEFINED SNMALLOC_ONLY_HEADER_LIBRARY)
set(CMAKE_EXE_LINKER_FLAGS_RELEASE "${CMAKE_EXE_LINKER_FLAGS_RELEASE} /DEBUG")
else()
add_compile_options(-fno-exceptions -fno-rtti -g -fomit-frame-pointer)
# Static TLS model unsupported on Haiku
# Static TLS model and -rdynamic flag (always -shared) are unsupported on Haiku
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# Static TLS model and -rdynamic flag (always -shared) are unsupported on Haiku
# Static TLS model is unsupported on Haiku.
# All symbols are always dynamic on Haiku and so -rdynamic is redundant (and unsupported).

@devnexen devnexen force-pushed the haiku_debug_build_fix branch from 1d964a6 to b43380a Compare September 13, 2020 17:16
@mjp41 mjp41 merged commit e615c33 into microsoft:master Sep 14, 2020
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants