Commit Graph

39 Commits

Author SHA1 Message Date
Brad King 8dc7501d50 Normalize slashes in scanned #include lines (#10281)
On Windows platforms source files may contain '\' in include directives:

  #include "a\b.h"

Normalize these while scanning to use forward slashes.  CMake will
convert from forward slashes to the direction preferred by the native
build tools when writing the path to 'depend.make' files.
2011-01-17 15:03:53 -05:00
Alexander Neundorf 8a5ae4c15e speedup C dependency scanning even more
Scanning the dependencies for kdelibs/khtml/ (when all files are scanned) is
now down to 4.6 s from 6.3 s before this change (without the
headerLocationCache it takes about 14 s here).
It doesn't really make sense to include the complete include path as part
of the key for the map, since the include path will be the same for
all files in a project, so it doesn't add anything.

Alex
2009-10-06 13:57:41 -04:00
Brad King 96afb12087 Convert CMake to OSI-approved BSD License
This converts the CMake license to a pure 3-clause OSI-approved BSD
License.  We drop the previous license clause requiring modified
versions to be plainly marked.  We also update the CMake copyright to
cover the full development time range.
2009-09-28 11:43:28 -04:00
Alexander Neundorf 39383ef8cb Major optimization of C/C++ dependency scanning.
Now only the dependencies for the file where the dependencies actually may
have changed are rescanned, before that this was done for all source files
even if only one source file had changed.
This reduces e.g. on my machine the time for scanning the dependencies
of kdelibs/khtml/ when only one file (khtml_global.cpp) has changed from
around 7.5 seconds to 1.2 seconds.

The tests succeed, it does what I expected it to do on kdelibs, and Brad
also reviewed the patch, so I think it should be ok.

Alex
2009-09-23 14:02:05 -04:00
Brad King 7652a8a1e5 ENH: Teach cmDependsC about user-configured macro transformations.
- Syntax is SOME_MACRO(%)=value-with-%
  - Later we will configure these with target and directory properties.
  - See issue #6648.
2008-05-14 11:54:32 -04:00
Brad King 12935b1599 ENH: Light refactoring of implicit dependency scanning configuration implementation.
- Move lookup of config variables from cmLocalUnixMakefileGenerator3 to cmDepends hierarchy.
2008-05-08 10:09:14 -04:00
Bill Hoffman a5e76555bf BUG: fix for bug 6136 make sure includes are not directories 2007-12-14 20:31:27 -05:00
Brad King 96665eb79d STYLE: Fixed line-too-long. 2007-02-07 09:23:41 -05:00
Brad King 6bba86c8c8 BUG: Patch from Alex to recompute dependencies when the include regex changes. This addresses bug#4168. 2007-02-05 09:48:38 -05:00
Brad King 61d3b2f1fb STYLE: Fixed line-too-long. 2006-09-27 12:55:58 -04:00
Andy Cedilnik e10f739571 BUG: Handle header file dependencies for objective C 2006-09-26 08:04:23 -04:00
Brad King 79d6047117 STYLE: Fixed line-too-long. 2006-09-16 11:54:19 -04:00
Brad King 6a347e9858 ENH: Patch from Alex to speed dependency scanning approximately 2x. 2006-09-13 12:43:32 -04:00
Brad King 409f70bc91 ENH: Make sure all custom command outputs are up to date before scanning dependencies. This avoids the need to pass a list of generated files to the dependency scanning code and to rescan after the files have been generated. Currently there is no notion of implicit dependencies of the custom commands themselves so this design is safe. We only need to make sure implicit dependencies are up to date before the make process for the /build part of a target is executed because only this process loads them. This is a step towards fixing bug#3658. 2006-08-31 14:09:56 -04:00
Ken Martin 7d5bc02c9d ENH: line lengths 2006-06-05 14:32:12 -04:00
Brad King ec2104cd31 BUG: Updated Makefile dependency scanning to provide a full local generator to the dependency scanner to do proper path conversions. This allows the rules written into the depend.make files to use the same relative path conversion as those written into the build.make files. Several previous changes added more and more information for use by the dependency scanner and it was converging to having the full local generator anyway. 2006-05-25 09:47:30 -04:00
Ken Martin a5ed047d4b STYLE: fix line length 2006-05-10 14:54:46 -04:00
Brad King 826d238ebd BUG: Fix to avoid repeated calls to CollapseFullPath during dependency scanning. This addresses bug#3191. 2006-05-03 10:07:08 -04:00
Ken Martin 4b83a08b37 ENH: a warning fix and some more cleanup 2006-03-16 09:33:23 -05:00
Ken Martin 3d96e52261 STYLE: some m_ to this-> cleanup 2006-03-15 11:02:08 -05:00
Andy Cedilnik 634343c3e8 STYLE: Fix some style issues 2006-03-10 13:06:26 -05:00
Brad King 8dc1de6efd BUG: Fix for scanning generated headers included with double-quotes. Also fixed double-quote include support to not use the special quoted location when a full path is given on the include line. 2006-01-05 17:16:22 -05:00
Bill Hoffman 90bdb216a4 ENH: try to fix hp build problem 2005-12-09 23:04:33 -05:00
Bill Hoffman d13643aa92 ENH: clean up style a bit 2005-12-09 14:30:11 -05:00
Bill Hoffman 92b6c8e742 PERF: apply patch for bug 2575 speeds up depend scanning 2005-12-09 13:58:55 -05:00
Andy Cedilnik f18e7c7ff7 ENH: Improve performance of check build system by creating another file that is simpler to parse and therefore much faster overall 2005-10-12 13:52:29 -04:00
Brad King a5d1e0ef58 COMP: Work-around iterator/const_iterator comparison problem on Borland 5.5. 2005-08-18 09:19:55 -04:00
Brad King f4920b8369 ENH: Adding support for automatically adding the OBJECT_DEPENDS for generated header files. 2005-08-17 11:43:58 -04:00
Bill Hoffman baffdde535 ENH: fix bug in depend file removing for deleted depend files 2005-08-10 10:01:43 -04:00
Ken Martin f85f919dbc ENH: reduce the number of files produced still needs a bit more cleanup 2005-07-27 09:49:37 -04:00
Bill Hoffman dc43a3d265 ENH: string += is very slow, so don't use it 2005-07-22 15:32:00 -04:00
Ken Martin c85069b290 ENH: some changes to the depends signature to be more flexible 2005-05-11 13:16:45 -04:00
Brad King dd9e2b904c BUG: Re-implemented dependency line parsing to deal with quoted paths and escaped spaces. 2005-05-10 11:00:15 -04:00
Brad King e8911705d6 ENH: Added optional verbose output to build system dependency check. 2005-05-06 09:58:58 -04:00
Brad King 2fe4e650bf BUG: Fixed scanning to account for double-quote includes. 2005-03-03 15:22:18 -05:00
Brad King 9c4997bf06 BUG: Avoid putting a leading ./ on the dependency names. 2005-02-24 12:44:56 -05:00
Brad King 6d487c33d4 ENH: Removing collapsing of files to full path before checking. The current working directory is set correctly because the dependency lines are used by make anyway. This drastically improves the speed of dependency checking. 2005-02-17 10:18:29 -05:00
Brad King 337ad802c6 ENH: Implemented support for include/complain regular expressions for dependency scanning. This now includes the possibility that scanning will return failure and the build will stop. 2005-02-07 16:11:01 -05:00
Brad King 195cdf172e ENH: Split dependency scanning and checking into separate cmDepends superclass with language-specific subclasses such as cmDependsC. 2005-01-18 17:09:05 -05:00