[CMake] CMake always perfoms a full link. INCREMENTAL linking is never working.

Gabriel Petrovay gabipetrovay at gmail.com
Sat Dec 4 06:30:08 EST 2010


Hi,

I have debugged a little why CMake always performs a full link instead
of an incremental one.

The problem is that after the linking, mt.exe comes and embeds the
manifest into the dll:
MT:
C:/Program Files/Microsoft SDKs/Windows/v7.0A/bin/mt.exe /nologo
/manifest zorba_simplestore.dll.manifest
/outputresource:zorba_simplestore.dll;#2

This will make sure a full re-link will always be performed. This is
also stated here
http://msdn.microsoft.com/en-us/library/ms235591(VS.80).aspx :
"If you are doing an increment build, directly editing the resource as
shown above will disable incremental building and cause a full
rebuild; therefore a different approach should be taken:
-> Link the binary to generate the MyApp.exe.manifest file.
-> Convert the manifest to a resource file.
-> Re-link (incrementally) to embed the manifest resource into the binary."


How can I stop CMake from generating the mt.exe command and allow
incremental linking.

For us, it takes at least 20 seconds to link the dll, so it would save
us a lot of time.


Thanks!

-- 
MSc Gabriel Petrovay
Mobile: +41(0)787978034
www.28msec.com


More information about the CMake mailing list