diff options
author | Bill Hoffman <bill.hoffman@kitware.com> | 2008-08-19 19:42:48 (GMT) |
---|---|---|
committer | Bill Hoffman <bill.hoffman@kitware.com> | 2008-08-19 19:42:48 (GMT) |
commit | d632b96841b43e5a5d27e2787018353e7388a423 (patch) | |
tree | 0bb1ae5ae5922362ada681ee831547cc28ad3434 /Source/cmakemain.cxx | |
parent | d2e2ab72bfb2e21d189e0623880b2e376024a4bd (diff) | |
download | CMake-d632b96841b43e5a5d27e2787018353e7388a423.zip CMake-d632b96841b43e5a5d27e2787018353e7388a423.tar.gz CMake-d632b96841b43e5a5d27e2787018353e7388a423.tar.bz2 |
BUG: fix 6647 arguments after -E should not be parsed by CMake
Diffstat (limited to 'Source/cmakemain.cxx')
-rw-r--r-- | Source/cmakemain.cxx | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/Source/cmakemain.cxx b/Source/cmakemain.cxx index 233e87a..ff57eca 100644 --- a/Source/cmakemain.cxx +++ b/Source/cmakemain.cxx @@ -314,7 +314,7 @@ int do_cmake(int ac, char** av) #ifdef CMAKE_BUILD_WITH_CMAKE cmDocumentation doc; - if(doc.CheckOptions(ac, av) || nocwd) + if(doc.CheckOptions(ac, av, "-E") || nocwd) { // Construct and print requested documentation. cmake hcm; @@ -416,29 +416,29 @@ int do_cmake(int ac, char** av) { command = true; } - else if (strcmp(av[i], "-N") == 0) + else if (!command && strcmp(av[i], "-N") == 0) { view_only = true; } - else if (strcmp(av[i], "-L") == 0) + else if (!command && strcmp(av[i], "-L") == 0) { list_cached = true; } - else if (strcmp(av[i], "-LA") == 0) + else if (!command && strcmp(av[i], "-LA") == 0) { list_all_cached = true; } - else if (strcmp(av[i], "-LH") == 0) + else if (!command && strcmp(av[i], "-LH") == 0) { list_cached = true; list_help = true; } - else if (strcmp(av[i], "-LAH") == 0) + else if (!command && strcmp(av[i], "-LAH") == 0) { list_all_cached = true; list_help = true; } - else if (strncmp(av[i], "-P", strlen("-P")) == 0) + else if (!command && strncmp(av[i], "-P", strlen("-P")) == 0) { if ( i == ac -1 ) { @@ -457,7 +457,6 @@ int do_cmake(int ac, char** av) args.push_back(av[i]); } } - if(command) { int ret = cmake::ExecuteCMakeCommand(args); |