[cmake-developers] Should CMAKE_LINK_DEPENDS_NO_SHARED be on by default?

Stephen Kelly steveire at gmail.com
Mon Feb 25 18:09:45 EST 2013


Brad King wrote:

> On 02/25/2013 03:09 PM, dlrdave at aol.com wrote:
>> 
>>> Can you elaborate on some of the theoretical cases where relinking
>>> will be needed but no header files have changed?  It would be useful
>>> to have them available for discussion.
>> I can think of one, but it’s probably not that common:
>>  
>> A header file declares a function prototype, but there is no
>> implementation of it.
>>  
>> When it’s discovered, when somebody finally tries to add an
>> implementation, you only have the change the C++ file to add it.
>>  
>> Of course, for the caller that discovers this, it had never linked
>> successfully in the first place, and would relink after that rebuild
>> anyhow...
>>  
>> But for other callers that had never discovered it, though, a relink may
>> be necessary in case the ordinals of some of the *other* functions in the
>> dll changed due to the addition of one in the middle.
>>  
>> Uncommon, but possible.
> 
> Actually for DLL platforms the dependency goes on the import library,
> and some toolchains may not touch the import library if it has not
> changed.  Perhaps we should not make this option affect DLL platforms.
> Some investigation into Windows toolchain behavior may be needed.
> 

As the DLL platforms (and Mac for a reason I don't see 
http://open.cdash.org/testDetails.php?test=176688935&build=2827249) are 
failing, I've reverted the patches for now so as to not turn the dashboard 
all red tomorrow.

Thanks,

Steve.





More information about the cmake-developers mailing list