Ben Boeckel
668e005db5
Use cmake::IssueMessage for warnings
2010-12-07 16:38:25 -05:00
Ben Boeckel
88cd4c1e92
Use 'CMake Warning' versus 'warning' for CDash
2010-12-07 14:40:21 -05:00
Ben Boeckel
3c3b98ddd3
Initialize the class before setting warn flags
...
Since Initialize sets variables that we don't want to warn about, don't
leak the original class' settings.
2010-12-03 12:52:36 -05:00
Ben Boeckel
cf8b15a5c1
Ignore files under the CMakeFiles directory
2010-12-03 12:49:37 -05:00
Ben Boeckel
fd50f06b21
Don't check for unused vars at configure time
...
The generate step should catch all of them.
2010-12-02 16:57:30 -05:00
Ben Boeckel
c18c977ce8
When checking for variables, specify a reason
...
Allow reasons to begiven for checking for unused variables.
2010-11-15 10:32:15 -05:00
David Cole
b0fb2ad3e1
Merge topic 'AddCMAKE_CURRENT_LIST_DIR'
...
b011840 Use absolute path to FindPackageHandleStandardArgs.cmake everywhere
41e4f1a Add automatic variable CMAKE_CURRENT_LIST_DIR(dir of CMAKE_CURRENT_LIST_FILE)
f9fc79c Remove trailing whitespace
2010-10-19 15:53:16 -04:00
Ben Boeckel
3f1121f722
Use a long int since Line is a long as well
2010-10-08 13:49:39 -04:00
Ben Boeckel
8dbb2090a2
Wrong boolean value for CLI warnings
2010-10-07 12:28:25 -04:00
Ben Boeckel
d4ee998b61
Hard-code the --no-warn-unused-cli flag
2010-10-07 12:22:00 -04:00
Ben Boeckel
82ed104dcb
Flag that the directories have been set
2010-10-05 13:45:34 -04:00
Ben Boeckel
367e5c37bb
Revert "Revert "When calling CMake, set the args and the cache""
...
This reverts commit ab5d4e43d9a9ddde24a242092a0d5e5f9a6cbd01.
2010-10-05 12:27:37 -04:00
Ben Boeckel
ab5d4e43d9
Revert "When calling CMake, set the args and the cache"
...
This reverts commit 9b90040edba1f89395295c27cd9919b0d5efd30b.
2010-10-01 16:52:16 -04:00
Ben Boeckel
9b90040edb
When calling CMake, set the args and the cache
2010-10-01 13:44:55 -04:00
Bill Hoffman
3d68dd230d
Fix for bug #11274 , VS10 custom commands that create files in INTDIR fix.
2010-09-29 17:02:04 -04:00
Alex Neundorf
41e4f1a210
Add automatic variable CMAKE_CURRENT_LIST_DIR(dir of CMAKE_CURRENT_LIST_FILE)
...
Comes with a simple test and docs.
Alex
2010-09-28 22:10:47 +02:00
Alex Neundorf
f9fc79cac5
Remove trailing whitespace
...
Alex
2010-09-28 21:44:22 +02:00
Ben Boeckel
535253f385
Initialize the warning variables earlier
2010-09-22 12:46:15 -04:00
Ben Boeckel
cbb286c0b2
Fix the path detection to work for top-level
2010-09-22 12:46:15 -04:00
Ben Boeckel
62be1f78ae
Initialize the usage stack earlier
2010-09-22 12:46:15 -04:00
Ben Boeckel
c6e7fabc0f
Factor out the checks for unused variables
2010-09-22 12:46:15 -04:00
Ben Boeckel
5e41ba8e4a
When using the API, check for Add vs. Remove
2010-09-17 10:13:19 -04:00
Ben Boeckel
2c82f2b759
Exempt CMAKE(CURRENT|PARENT)_LIST_FILE from usage
2010-09-16 17:50:07 -04:00
Ben Boeckel
bef3aeebab
Use the API so that warnings can be tracked
2010-09-16 16:06:16 -04:00
Ben Boeckel
05cb0f4daf
Check for unused variables in the dtor
2010-09-16 16:05:59 -04:00
Ben Boeckel
ca90f673a0
Fix detection of unused variables when setting
2010-09-16 13:53:41 -04:00
Ben Boeckel
995cfb0e2a
Don't warn if the variable wasn't defined
2010-09-16 13:52:17 -04:00
Ben Boeckel
a8e97f8a08
Remove VarRemoved code since it's been superceded
2010-09-16 13:50:39 -04:00
Ben Boeckel
59463ef1a3
Rework CheckVariableForUnused usage
2010-09-16 11:50:57 -04:00
Ben Boeckel
f117423336
Fix line lengths to be no more than 78
2010-09-16 11:49:58 -04:00
Ben Boeckel
e49a935c20
Improve unused warning logic
...
Only warn when changing the definition of an initialized variable.
2010-09-15 11:41:27 -04:00
Ben Boeckel
02a114dfe8
Add method to allow variables to be marked as used
2010-09-15 11:34:35 -04:00
Ben Boeckel
ae3eff35b4
Fix the path used for ignoring system warnings
2010-09-14 17:14:25 -04:00
Ben Boeckel
056b44113f
Fix missing case for usage of a variable
2010-09-14 17:10:22 -04:00
Ben Boeckel
980e048a7d
Factor out checks for unused variables
2010-09-14 17:10:04 -04:00
Brad King
b06fb16684
No CMAKE_CONFIGURATION_TYPES in single-config generators ( #10202 )
...
Factor out reading of CMAKE_CONFIGURATION_TYPES and CMAKE_BUILD_TYPE
into cmMakefile::GetConfigurations. Read the former only in
multi-config generators.
2010-09-08 14:54:49 -04:00
Ben Boeckel
3801463c9f
Use built-ins for readability and maintainability
2010-09-08 12:03:42 -04:00
Ben Boeckel
8b520158c3
Push the initialize and unused states when copying
2010-09-07 15:12:15 -04:00
Ben Boeckel
300fc15779
Fix detection of system files
...
Instead of looking to see if the file is under CMAKE_ROOT, check to see
if it is instead under the source or binary directories in use.
2010-09-02 11:33:34 -04:00
Ben Boeckel
d784e6af4d
Run the unused variables check on the final pass
2010-09-02 11:29:05 -04:00
Ben Boeckel
74997000c8
Add a flag to warn about system files
2010-09-01 13:09:08 -04:00
Ben Boeckel
fff9f6d6f7
Rename flags again and use variablewatch for cli
2010-09-01 13:09:08 -04:00
Ben Boeckel
636e6c4ef7
Default to marking things as used
...
If we don't then:
cmake --warn-unused --warn-unused-all
acts differently than:
cmake --warn-unused-all --warn-unused
2010-09-01 13:08:15 -04:00
Ben Boeckel
4ff03402fc
Rename find-unused to warn-unused
2010-09-01 13:08:14 -04:00
Ben Boeckel
e141bc950a
Detect unused variables
2010-09-01 13:08:14 -04:00
Ben Boeckel
f332e14ff2
Complete strict-mode checks for uninitialized vars
2010-09-01 13:08:14 -04:00
Bill Hoffman
48b5b85593
Add a warning when variables are used uninitialized.
2010-09-01 13:08:13 -04:00
Brad King
3ebb41d58a
Merge branch 'version'
2010-05-17 13:34:29 -04:00
Brad King
6e1b510319
Remove unused cmData and cmMakefile::DataMap
...
These were implementation details of the unused methods
cmMakefile::RegisterData
cmMakefile::LookupData
We simply remove the methods, members, and class cmData.
2010-04-26 14:22:51 -04:00
Brad King
5bfffd6f29
New version scheme to support branchy workflow
...
Prepare to switch to the workflow described by "git help workflows". In
this workflow, the "master" branch is always used to integrate topics
ready for release. Brand new work merges into a "next" branch instead.
We need a new versioning scheme to work this way because the version on
"master" must always increase.
We no longer use an even/odd minor number to distinguish releases from
development versions. Since we still support cvs checkout of our source
tree we cannot depend on "git describe" to compute a version number
based on the history graph. We can use the CCYYMMDD nightly date stamp
to get a monotonically increasing version component.
The new version format is "major.minor.patch.(tweak|date)". Releases
use a tweak level in the half-open range [0,20000000), which is smaller
than any current or future date. For tweak=0 we do not show the tweak
component, leaving the format "major.minor.patch" for most releases.
Development versions use date=CCYYMMDD for the tweak level. The
major.minor.patch part of development versions on "master" always
matches the most recent release.
For example, a first-parent traversal of "master" might see
v2.8.1 2.8.1.20100422 v2.8.2
| | |
----o----o----o----o----o----o----o----o----
Since the date appears in the tweak component, the next release can
increment the patch level (or any more significant component) to be
greater than any version leading to it. Topic branches not ready for
release are published only on "next" so we know that all versions on
master lead between two releases.
2010-04-23 09:44:23 -04:00