[CMake] Merging static libraries

Bill Hoffman bill.hoffman at kitware.com
Wed Oct 15 18:24:51 EDT 2008


Emmanuel Blot wrote:
>> Well, sometimes just explaining the problem to somebody already helps :-)
> 
> It does, yes. Thanks again.
> 
> The fact is that this library "merging" thing has been existing for a 
> while. I've changed a directory name and forgot to update the 
> CMakeListst.txt file accordingly.
> The error looked really like another issue I've never been able to track 
> down (see below), so I thought I finally had a way to track down the 
> issue. Truth is that I got it wrong: two issues were not related ;-)
> 
> The error I can't resolved is something that only occurs on Linux Ubuntu 
> hosts.
> Our CMakeListst.txt files do work on Cygwin, Linux Debian & Mandriva, 
> and Mac OS X. But it sometimes fails on Linux Ubuntu.
> It looks like a dependency inversion, although I still need to 
> investigate the actual error: sometimes the generated "merged" library 
> contains code from previous builds, i.e. like if the library merge were 
> occurring before the actual compilation of the unit libraries...
> 
> The only difference I can think of between Ubuntu and other hosts is the 
> shell: Dash (100% POSIX) vs. Bash. But I don't see how this could impact 
> the results of a CMake/Makefile build sessions. This is really weird...
> 
What about the CMake build?  Do you use a different cmake on ubuntu? 
Does the kitware binary work?  What if you build CMake from source. 
Also, you should keep logs of make VERBOSE=1 >& buildlog, and try to 
figure out what is going wrong.

-Bill


More information about the CMake mailing list