diff --git a/modules/TDEMacros.cmake b/modules/TDEMacros.cmake index 13fa54a..a5603cf 100644 --- a/modules/TDEMacros.cmake +++ b/modules/TDEMacros.cmake @@ -833,7 +833,11 @@ macro( tde_add_library _arg_target ) # set embedded archives if( _embed ) - list( INSERT _link 0 -Wl,-whole-archive ${_embed} -Wl,-no-whole-archive ) + if( ${CMAKE_SYSTEM_NAME} MATCHES "SunOS" ) + list( INSERT _link 0 -Wl,-zallextract ${_embed} -Wl,-zdefaultextract ) + else( ) + list( INSERT _link 0 -Wl,-whole-archive ${_embed} -Wl,-no-whole-archive ) + endif( ) endif( _embed ) # set link libraries