[cmake-developers] [CMake 0014650]: Depend.make content

Mantis Bug Tracker mantis at public.kitware.com
Mon Dec 16 03:22:48 EST 2013


The following issue has been SUBMITTED. 
====================================================================== 
http://www.cmake.org/Bug/view.php?id=14650 
====================================================================== 
Reported By:                Lars
Assigned To:                
====================================================================== 
Project:                    CMake
Issue ID:                   14650
Category:                   CMake
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     new
====================================================================== 
Date Submitted:             2013-12-16 03:22 EST
Last Modified:              2013-12-16 03:22 EST
====================================================================== 
Summary:                    Depend.make content
Description: 
Building our software is very slow using CMake 2.8.12.1 and VS2005. Debugging
this issue I discovered the several of the depend.make files are huge. One
example is a depend.make file that is roughly 10 MB. It appears the dependency
scanner in cmake does not take into account preprocessor directive, so including
one boost header in a translation unit can cause this translation unit to depend
on several 100s of boost files. In our case, each translation unit dependent on
1000 or more boost header files. 

Adding the following code solved the issue for boost;
include_regular_expression("^([^b]|b[^o]|bo[^o]|boo[^s]|boos[^t]|boost[^/]).*$")
(this line reduced the build time by more than 50%)

This is is a limited solution because it only works on part of the header path.
We have other third party tools that we would like to filter out of the
depend.make file, for instance Qt. How do we accomplish that?

A suggestion from Nils Gladitz;
"Maybe CMake could filter out includes in system directories (like gcc -MM
does). System directories in this case could be directories added with e.g.
include_directories(SYSTEM)."
====================================================================== 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2013-12-16 03:22 Lars           New Issue                                    
======================================================================




More information about the cmake-developers mailing list