summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalVisualStudioGenerator.cxx
Commit message (Collapse)AuthorAgeFilesLines
* Use std::replace for replacing chars in strings.Daniel Pfeifer2016-05-241-1/+1
| | | | | | | | | | | Find uses of `cmSystemTools::ReplaceString` where both `replace` and `with` are string literals with a size of one. Automate with: git grep -l ReplaceString | xargs sed -i "s|cmSystemTools::ReplaceString(\([^,]*\), \"\(.\)\", \"\(.\)\");|std::replace(\1.begin(), \1.end(), '\2', '\3');|g" git grep -l ReplaceString | xargs sed -i "s|cmSystemTools::ReplaceString(\([^,]*\), \"\(.\)\", \"\\\\\\\\\");|std::replace(\1.begin(), \1.end(), '\2', '\\\\\\\\');|g" git grep -l ReplaceString | xargs sed -i "s|cmSystemTools::ReplaceString(\([^,]*\), \"\\\\\\\\\", \"\(.\)\");|std::replace(\1.begin(), \1.end(), '\\\\\\\\', '\2');|g"
* Revise C++ coding style using clang-formatKitware Robot2016-05-161-394/+276
| | | | | | | | | | | | | Run the `Utilities/Scripts/clang-format.bash` script to update all our C++ code to a new style defined by `.clang-format`. Use `clang-format` version 3.8. * If you reached this commit for a line in `git blame`, re-run the blame operation starting at the parent of this commit to see older history for the content. * See the parent commit for instructions to rebase a change across this style transition commit.
* Remove `//------...` horizontal separator commentsBrad King2016-05-091-30/+0
| | | | | | | | | | | | | | | | | | | | | | | | Modern editors provide plenty of ways to visually separate functions. Drop the explicit comments that previously served this purpose. Use the following command to automate the change: $ git ls-files -z -- \ "*.c" "*.cc" "*.cpp" "*.cxx" "*.h" "*.hh" "*.hpp" "*.hxx" | egrep -z -v "^Source/cmCommandArgumentLexer\." | egrep -z -v "^Source/cmCommandArgumentParser(\.y|\.cxx|Tokens\.h)" | egrep -z -v "^Source/cmDependsJavaLexer\." | egrep -z -v "^Source/cmDependsJavaParser(\.y|\.cxx|Tokens\.h)" | egrep -z -v "^Source/cmExprLexer\." | egrep -z -v "^Source/cmExprParser(\.y|\.cxx|Tokens\.h)" | egrep -z -v "^Source/cmFortranLexer\." | egrep -z -v "^Source/cmFortranParser(\.y|\.cxx|Tokens\.h)" | egrep -z -v "^Source/cmListFileLexer\." | egrep -z -v "^Source/cm_sha2" | egrep -z -v "^Source/(kwsys|CursesDialog/form)/" | egrep -z -v "^Utilities/(KW|cm).*/" | xargs -0 sed -i '/^\(\/\/---*\|\/\*---*\*\/\)$/ {d;}' This avoids modifying third-party sources and generated sources.
* Format include directive blocks and ordering with clang-formatBrad King2016-04-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Sort include directives within each block (separated by a blank line) in lexicographic order (except to prioritize `sys/types.h` first). First run `clang-format` with the config file: --- SortIncludes: false ... Commit the result temporarily. Then run `clang-format` again with: --- SortIncludes: true IncludeCategories: - Regex: 'sys/types.h' Priority: -1 ... Commit the result temporarily. Start a new branch and cherry-pick the second commit. Manually resolve conflicts to preserve indentation of re-ordered includes. This cleans up the include ordering without changing any other style. Use the following command to run `clang-format`: $ git ls-files -z -- \ '*.c' '*.cc' '*.cpp' '*.cxx' '*.h' '*.hh' '*.hpp' '*.hxx' | egrep -z -v '(Lexer|Parser|ParserHelper)\.' | egrep -z -v '^Source/cm_sha2' | egrep -z -v '^Source/(kwsys|CursesDialog/form)/' | egrep -z -v '^Utilities/(KW|cm).*/' | egrep -z -v '^Tests/Module/GenerateExportHeader' | egrep -z -v '^Tests/RunCMake/CommandLine/cmake_depends/test_UTF-16LE.h' | xargs -0 clang-format -i This selects source files that do not come from a third-party. Inspired-by: Daniel Pfeifer <daniel@pfeifer-mail.de>
* VS: Ignore USE_FOLDER property on VS versions that do not support itBrad King2016-04-261-1/+1
| | | | | Solution folders are supported on VS 8 and above in the full versions and on VS 11 and above in the express versions.
* VS: Put ALL_BUILD in the PREDEFINED_TARGETS_FOLDERTaylor Braun-Jones2016-03-231-7/+1
|
* VS: Add option to choose the `.sln` startup project (#15578)Davy Durham2016-03-221-0/+26
| | | | | | | | Add a `VS_STARTUP_PROJECT` directory property to specify the project that should be placed first in the `.sln` file so that it will be selected as the default startup project. Co-Author: Taylor Braun-Jones <taylor.braunjones@avigilon.com>
* Avoid depending on CMAKE_ROOT cache entry internally (#16015)Brad King2016-03-161-2/+1
| | | | | | Use cmSystemTools::GetCMakeRoot() which always knows the location of our resources. Do not depend on CMAKE_ROOT because the user could unset it from the cache.
* Merge topic 'minor-cleanups'Brad King2015-10-281-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 13a37f5f cmMakefile: Fix typo in comment 958508bb cmMakefile: Fix style 91a829c1 Makefiles: Remove unused variable e0213882 cmTarget: Remove obsolete member 0554c2c9 cmTarget: Fix style b22e5d0a Remove some obsolete declarations ce43ed2c Use LocalGenerator when possible d90c9738 Makefiles: Remove some unneeded casts 331023ae Export: Remove unused variable a03f3d0e cmFunctionBlocker: Constify method d50c4220 Xcode: Fix typo in comment 803f1901 Xcode: Remove trailing semicolon
| * Use LocalGenerator when possibleStephen Kelly2015-10-261-1/+1
| |
* | cmGlobalGenerator: Remove map from cmTarget to cmGeneratorTargetStephen Kelly2015-10-271-1/+0
|/ | | | | | | The configure-time and generate-time types should be completely independent. Add ownership of cmGeneratorTarget instances to the cmLocalGenerator.
* VS: Port interface to cmGeneratorTargetStephen Kelly2015-10-241-21/+18
|
* VS: Port WriteUtilityDepends to cmGeneratorTargetStephen Kelly2015-10-241-1/+1
|
* VS: Port utility depends to cmGeneratorTargetStephen Kelly2015-10-241-3/+4
|
* VS: Port target depends to cmGeneratorTargetStephen Kelly2015-10-241-13/+13
|
* VS: Port TargetIsFortranOnly to cmGeneratorTargetStephen Kelly2015-10-241-3/+1
|
* VS: Port LinkClosure to cmGeneratorTargetStephen Kelly2015-10-241-10/+11
|
* Port to GetGeneratorTargets.Stephen Kelly2015-10-241-3/+3
|
* cmLocalGenerator: Store a vector of generator targets.Stephen Kelly2015-10-211-7/+8
| | | | Not a map from cmTarget to cmGeneratorTarget.
* cmLocalGenerator: Simplify semantic of adding generator targets.Stephen Kelly2015-10-201-0/+1
| | | | Don't store on the global generator as a side effect. Update clients to adapt.
* cmGeneratorTarget: Move IsLinkable from cmTarget.Stephen Kelly2015-10-191-2/+3
|
* Merge topic 'clean-up-cmTarget'Brad King2015-10-161-10/+10
|\ | | | | | | | | | | | | | | | | | | | | | | | | 55474e61 cmState: Move GetTargetTypeName from cmTarget. 38df5c36 Remove now-obsolete casts. 4ee2b267 cmGeneratorTarget: Use enum for GetType. eac15298 cmState: Move TargetType enum from cmTarget. 482b3811 cmTarget: Move link type enum out. 2ee1cb85 cmTarget: Move ImportInfoMap out of internal class. a48bcabd cmTarget: Move backtrace member out of internal class. 6694d993 cmTarget: Remove unneeded constructors. 983c00f8 Generators: Use GetType from the cmGeneratorTarget.
| * cmState: Move TargetType enum from cmTarget.Stephen Kelly2015-10-141-10/+10
| | | | | | | | | | | | | | Mostly automated: values=( "EXECUTABLE" "STATIC_LIBRARY" "SHARED_LIBRARY" "MODULE_LIBRARY" "OBJECT_LIBRARY" "UTILITY" "GLOBAL_TARGET" "INTERFACE_LIBRARY" "UNKNOWN_LIBRARY" "TargetType") for i in "${values[@]}"; do git grep -l cmTarget::$i | xargs sed -i "s|cmTarget::$i|cmState::$i|g"; done
* | cmLocalGenerator: Port GetTargetDirectory to cmGeneratorTarget.Stephen Kelly2015-10-141-1/+1
|/
* cmLocalGenerator: Store cmGeneratorTargets.Stephen Kelly2015-10-141-2/+2
| | | | Relieve cmMakefile of this responsibility.
* cmLocalGenerator: Add GetProjectName method.Stephen Kelly2015-10-081-1/+1
|
* VisualStudio: Replace Compute override with AddExtraIDETargets override.Stephen Kelly2015-10-051-7/+1
|
* VS: Remove impossible condition.Stephen Kelly2015-09-271-3/+2
|
* VS: Refactor target ordering logicBrad King2015-09-221-6/+12
| | | | | | | | Refactor cmGlobalVisualStudioGenerator::TargetCompare to store the name of the target that should come first instead of hard-coding "ALL_BUILD". Update client sites to specify "ALL_BUILD" when ordering for .sln files and an empty string otherwise (in cases when "ALL_BUILD" should not be encountered anyway).
* cmGeneratorTarget: Move GetConfigCommonSourceFiles from cmTarget.Stephen Kelly2015-08-261-1/+1
|
* cmGeneratorTarget: Move GetLanguages from cmTarget.Stephen Kelly2015-08-261-1/+3
|
* cmGeneratorTarget: Move compile defintions processing from cmTarget.Stephen Kelly2015-08-261-1/+1
|
* Replace foo.size() pattern with !foo.empty().Stephen Kelly2015-08-241-1/+1
|
* Replace 'foo.size() > 0' pattern with !foo.empty().Stephen Kelly2015-08-241-1/+1
|
* Merge topic 'use-generator-target'Brad King2015-08-111-0/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | 29886ce7 cmTarget: Use a simpler delete algorithm. 197f4de1 cmTarget: Split storage of compile definitions from genexes. 44e071ae cmTarget: Split storage of compile features from genexes. 772ecef4 cmTarget: Split storage of compile options from genexes. 1f54bc1c cmTarget: Split storage of include directories from genexes. 7568199b cmTarget: Request only the link libraries where needed. 10040601 cmLinkImplementationLibraries: Move to namespace scope. d9da6ee2 cmLinkItem: Split to separate file. 27252b24 cmComputeLinkInformation: Simplify generator object access.
| * cmTarget: Split storage of include directories from genexes.Stephen Kelly2015-08-071-0/+1
| |
* | cmGlobalGenerator: Base exclusion computation on cmGeneratorTarget.Stephen Kelly2015-08-061-4/+6
|/
* cmGlobalGenerator: Virtualize the Compute step and override it.Stephen Kelly2015-07-301-4/+7
|
* cmGlobalGenerator: Move generation object creation to Compute().Stephen Kelly2015-07-301-0/+2
|
* VisualStudio: Skip global targets when processing.Stephen Kelly2015-07-291-0/+4
|
* Merge topic 'auto_export_dll_symbols'Brad King2015-07-081-0/+70
|\ | | | | | | | | | | | | | | | | | | | | | | | | 8f86407c Windows: Optionally generate DLL module definition files automatically 069aa93b bindexplib: Add support for "/bigobj" format objects 61bbbdcf bindexplib: Fix treatment of some symbols de70c922 bindexplib: Teach DumpFile to return errors 8ea69dfe bindexplib: Build source as part of CMakeLib 2963cb2a bindexplib: Wrap long lines 4ff09893 bindexplib: Drop code that CMake does not need 7de8276c bindexplib: Add copyright/license notice block 65086ad7 bindexplib: Import original implementation from CERN
| * Windows: Optionally generate DLL module definition files automaticallyBill Hoffman2015-07-061-0/+70
| | | | | | | | | | | | | | Create target property WINDOWS_EXPORT_ALL_SYMBOLS to automatically generate a module definition file from MS-compatible .obj files and give it to the linker in order to export all symbols from the .dll part of a SHARED library.
* | cmComputeTargetDepends: Change API to use cmGeneratorTarget.Stephen Kelly2015-07-011-9/+18
|/
* cmState: Host some state from the cmGlobalGenerator.Stephen Kelly2015-05-271-2/+2
|
* cmGlobalGenerator: Require a cmake instance in ctor.Stephen Kelly2015-05-271-1/+2
| | | | It is required anyway, so this makes it explicit.
* VS: Move version information to global generator.Stephen Kelly2015-05-191-0/+13
|
* cmGlobalGenerator: Move some flags from cmLocalGenerator.Stephen Kelly2015-05-141-0/+2
| | | | | These flags are global, and so they belong here instead of being set on each local generator.
* cmMakefile: Port users of GetStart* methods to new names.Stephen Kelly2015-04-201-1/+1
|
* cmMakefile: Rename GetCurrent{Output,Binary}Directory.Stephen Kelly2015-04-201-1/+1
| | | | Match names used in CMake code.
* Use two-iterator std::set::insert where appropriate.Stephen Kelly2015-01-111-10/+2
|