<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Exchange Server">
<!-- converted from rtf -->
<style><!-- .EmailQuote { margin-left: 1pt; padding-left: 4pt; border-left: #800000 2px solid; } --></style>
</head>
<body>
<font face="Calibri, sans-serif" size="2">
<div> </div>
<div>We have a cmake based project where cmake runtime is becoming a problem: everytime a CMakeLists.txt changes the build takes an extra 40-50 seconds. Our main CMakeLists.txt contains a lot of ADD_SUBDIRECTORY (and little else). Most of the subdirectories
then call FIND_PACKAGE(Qt4) with various required components. We have found that by moving this call into the top cmake we can save around 20 seconds. However there is objection to doing this because some executables don’t need all the qt components. (In
particular I object to linking QtTest into production code)</div>
<div> </div>
<div>Is there a way to do the Find package once, and then find individual components for link and include purposes separately? Is there a better way so solve this problem?</div>
<div> </div>
<div> </div>
<div>This is with cmake 2.8.7, but 2.8.8 is if anything slower (at most 1 second, I’m not sure if this is significant)</div>
<div> </div>
</font>
</body>
</html>