You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We implemented two methods(cc_library, cc_binary) that accept LINK_ALL_SYMBOLS (which means export all symbols when linking, by wrapping the libs with gcc options "-Wl,--whole-archive" and "-Wl,--no-whole-archive" around) as argument in cmake/generic.cmake.
A binary or a library can use ALL_SYMBOLS_DEPS to tell the linker that it needs all the symbols in its deps.
A library who have LINK_ALL_SYMBOLS attribute should export all symbols to the ones that depend on it. We expect these symbols can be exported recursively, however only the ones that depend this library directly will link all the symbols currently.
cc_test don't have similar functionality.
So, cmake/generic.cmake's cc_library/cc_binary/cc_test needs improvements to handle LINK_ALL_SYMBOLS.
The text was updated successfully, but these errors were encountered:
acmol
changed the title
we should implement a better LINK_ALL_SYMBOLS in CMake
We should implement a better LINK_ALL_SYMBOLS in CMake
Nov 15, 2017
acmol
changed the title
We should implement a better LINK_ALL_SYMBOLS in CMake
We should implement a better LINK_ALL_SYMBOLS in CMake
Nov 15, 2017
advancedxy
changed the title
We should implement a better LINK_ALL_SYMBOLS in CMake
Better handle LINK_ALL_SYMBOLS option in cmake/generic.cmake
Nov 15, 2017
We implemented two methods(cc_library, cc_binary) that accept LINK_ALL_SYMBOLS (which means export all symbols when linking, by wrapping the libs with gcc options "-Wl,--whole-archive" and "-Wl,--no-whole-archive" around) as argument in
cmake/generic.cmake
.A binary or a library can use
ALL_SYMBOLS_DEPS
to tell the linker that it needs all the symbols in its deps.A library who have
LINK_ALL_SYMBOLS
attribute should export all symbols to the ones that depend on it. We expect these symbols can be exported recursively, however only the ones that depend this library directly will link all the symbols currently.cc_test don't have similar functionality.
So, cmake/generic.cmake's cc_library/cc_binary/cc_test needs improvements to handle LINK_ALL_SYMBOLS.
The text was updated successfully, but these errors were encountered: