summaryrefslogtreecommitdiffstats
path: root/Source/CPack/WiX
Commit message (Collapse)AuthorAgeFilesLines
* Modernize: Use #pragma once in all header filesKitware Robot2020-09-0311-44/+11
| | | | | | | | | | | | | | | | #pragma once is a widely supported compiler pragma, even though it is not part of the C++ standard. Many of the issues keeping #pragma once from being standardized (distributed filesystems, build farms, hard links, etc.) do not apply to CMake - it is easy to build CMake on a single machine. CMake also does not install any header files which can be consumed by other projects (though cmCPluginAPI.h has been deliberately omitted from this conversion in case anyone is still using it.) Finally, #pragma once has been required to build CMake since at least August 2017 (7f29bbe6 enabled server mode unconditionally, which had been using #pragma once since September 2016 (b13d3e0d)). The fact that we now require C++11 filters out old compilers, and it is unlikely that there is a compiler which supports C++11 but does not support #pragma once.
* CPack/WiX: Add support for custom XML namespacesFritz Elfert2020-08-183-2/+52
| | | | | | Add a `CPACK_WIX_CUSTOM_XMLNS` option to specify these. Fixes: #21098
* Refactoring: Third-parties public headers are under cm3p prefixMarc Chevrier2020-05-071-1/+1
| | | | Fixes: #20666
* Refactoring: add cm::contains to <cmext/algorithm>Marc Chevrier2020-04-171-2/+2
|
* Merge topic 'string-prefix'Brad King2020-03-262-14/+16
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | ec7928ef26 use _s to construct static string_views at several places 94de927cab VS10Generator: avoid many string allocations 8ca2504a4d use string_views to avoid memory allocations 761f1adcae check for a valid URL scheme before starting to do any splitting ef778d77e0 replace std::string::substr() with operations that do not allocate memory 77616f4681 pass cm::string_view to cmVisualStudioSlnParser::ParseTag() ada6a3226f use cm::string_view for language extension lookups 48adc29721 replace "std::string::find(x) == 0" with cmHasPrefix() ... Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !4501
| * use string_views to avoid memory allocationsRolf Eike Beer2020-03-241-6/+9
| |
| * replace "std::string::find(x) == 0" with cmHasPrefix()Rolf Eike Beer2020-03-231-1/+1
| |
| * replace "substr(0, xx) ==" with cmHasPrefix()Rolf Eike Beer2020-03-231-2/+1
| |
| * CPackWIXGenerator: use cmStrCat for more partsRolf Eike Beer2020-03-231-5/+5
| |
* | CMake compilation: do not use compiler extensionsMarc Chevrier2020-03-231-0/+5
|/ | | | | | | For now, compiler extensions are no longer activated on CMake sources. However these extensions are still used for various third parties. This MR is a partial answer to the issue #20454.
* Modernize memory managementMarc Chevrier2020-03-085-23/+27
| | | | Update internals of various classes.
* CPack: Restore support for custom package configuration templatesBrad King2019-11-151-1/+1
| | | | | | | | | | | | Refactoring in commit 98617f1be0 (Refactor: Move CPack internal files to `Internal/CPack/` directory, 2019-07-09, v3.16.0-rc1~449^2) accidentally changed the public-facing names of the templates. The name passed to `FindTemplate` is searched in `CMAKE_MODULE_PATH` and should not change. Remove the `Internal/CPack/` prefix on the names added by that commit. Teach `FindTemplate` to use our builtin default directly when the public-facing name is not found in `CMAKE_MODULE_PATH`. Fixes: #19979
* Revise include order using clang-format-6.0Kitware Robot2019-10-0116-50/+39
| | | | | Run the `clang-format.bash` script to update our C and C++ code to a new include order `.clang-format`. Use `clang-format` version 6.0.
* cmstd: Modernize CMake system headersMarc Chevrier2019-09-202-3/+4
| | | | | | | | | | | | | | Provide a standardized way to handle the C++ "standard" headers customized to be used with current CMake C++ standard constraints. Offer under directory `cm` headers which can be used as direct replacements of the standard ones. For example: #include <cm/string_view> can be used safely for CMake development in place of the `<string_view>` standard header. Fixes: #19491
* CPackWIX: Allow omitting program menu folder and uninstall shortcutAlexej Harm2019-09-122-12/+33
|
* clang-tidy: Replace typedef with usingRegina Pfeifer2019-09-044-10/+10
| | | | | | | | Automate the conversion with perl -i -0pe 's/typedef ([^;]*) ([^ ]+);/using $2 = $1;/g' then manually fix a few places.
* Source sweep: Replace cmExpandList with the shorter cmExpandedListSebastian Holtermann2019-08-231-9/+5
| | | | | | | | | | | | This replaces the code pattern ``` std::vector<std::string> args; cmExpandList(valueStr, args, ...) ``` with ``` std::vector<std::string> args = cmExpandedList(valueStr, ...) ```
* Source sweep: Use cmStrCat for string concatenationSebastian Holtermann2019-08-221-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch is generated by a python script that uses regular expressions to search for string concatenation patterns of the kind ``` std::string str = <ARG0>; str += <ARG1>; str += <ARG2>; ... ``` and replaces them with a single `cmStrCat` call ``` std::string str = cmStrCat(<ARG0>, <ARG1>, <ARG2>, ...); ``` If any `<ARGX>` is itself a concatenated string of the kind ``` a + b + c + ...; ``` then `<ARGX>` is split into multiple arguments for the `cmStrCat` call. If there's a sequence of literals in the `<ARGX>`, then all literals in the sequence are concatenated and merged into a single literal argument for the `cmStrCat` call. Single character strings are converted to single char arguments for the `cmStrCat` call. `std::to_string(...)` wrappings are removed from `cmStrCat` arguments, because it supports numeric types as well as string types. `arg.substr(x)` arguments to `cmStrCat` are replaced with `cm::string_view(arg).substr(x)`
* Merge topic 'cm-contains'Brad King2019-08-211-3/+2
|\ | | | | | | | | | | | | | | | | 2dfc52675c cmAlgorithms: Add cmContains Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Sebastian Holtermann <sebholt@web.de> Acked-by: Daniel Pfeifer <daniel@pfeifer-mail.de> Merge-request: !3700
| * cmAlgorithms: Add cmContainsRegina Pfeifer2019-08-191-3/+2
| | | | | | | | Also, use the new function where applicable.
* | Source sweep: Use cmIsOn instead of cmSystemTools::IsOnSebastian Holtermann2019-08-171-2/+2
|/ | | | | | | | | This replaces invocations of - `cmSystemTools::IsInternallyOn` with `cmIsInternallyOn` - `cmSystemTools::IsNOTFOUND` with `cmIsNOTFOUND` - `cmSystemTools::IsOn` with `cmIsOn` - `cmSystemTools::IsOff` with `cmIsOff`
* Source code: Use cmExpandList instead of cmSystemTools::ExpandListArgumentSebastian Holtermann2019-08-141-10/+8
|
* cmStringAlgorithms: cmIsSpace, cmTrimWhitespace, cmEscapeQuotes, cmTokenizeSebastian Holtermann2019-08-052-6/+5
| | | | | | | | | | This adds the following functions to `cmStringAlgorithms`: - `cmIsSpace` - `cmTrimWhitespace` (moved from `cmSystemTools::TrimWhitespace`) - `cmEscapeQuotes` (moved from `cmSystemTools::EscapeQuotes`) - `cmTokenize` (moved from `cmSystemTools::tokenize` and adapted to accept `cm::string_view`)
* Refactor: Move CPack internal files to `Internal/CPack/` directoryAlex Turbov2019-07-091-1/+1
| | | | | | | | Some commits ago all CPack internal `*.cmake` files have been moved to `Internal/CPack/`. This commit also move some templates internally used by generators to the same location to make `Modules/` directory less noisy w/ files the end users don't need to use/see.
* cmMakefile::ConfigureFile: Accept `std::string` parametersVitaly Stakhovsky2019-02-191-1/+1
|
* cmSystemTools::RunSingleCommand: Accept std::string argumentVitaly Stakhovsky2019-02-061-3/+2
|
* Add missing overrideVitaly Stakhovsky2018-12-301-6/+6
|
* WiX: Add the build directory to IncludeSearchPaths for candle.exeLars Schmertmann2018-07-121-0/+4
| | | | | | | | | | CPack creates cpack_variables.wxi in the build directory. In the WiX template it can be used by <?include "cpack_variables.wxi"?> because the template is configured into main.wxs in the build directory. Because the extra source files are in the source directory it was necessary to use <?include "$(sys.CURRENTDIR)_CPack_Packages\win32\WIX\cpack_variables.wxi"?>. This requires knowledge about the build directory structure and is avoided by this change by adding the build directory to the IncludeSearchPaths.
* CPack: Move internal implementation modules into Internal/CPack directoryKyle Edwards2018-06-211-1/+1
| | | | | | | | | | | | | | | These modules are not meant to be included by user code, they are only an internal implementation detail for CPack. Having them live in the main Modules directory with documentation was misleading, so they have been moved into Modules/Internal/CPack, and their documentation has been stripped following its move into the new "CPack Generators" section. No-op modules which contained only documentation have been removed entirely. The only module that hasn't been moved is CPackIFW, because it contains user-facing macros which would be lost if it were moved. So, the CPackIFW module has been updated with a note explaining what needs to (eventually) happen.
* Revise C++ coding style using clang-format-6.0Kitware Robot2018-06-015-29/+37
| | | | | | | | | | | | Run the `clang-format.bash` script to update all our C and C++ code to a new style defined by `.clang-format`. Use `clang-format` version 6.0. * 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.
* Fix trivial typos in textluzpaz2017-11-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Some are user facing. Found using codespell -q 3 --skip="./Utilities" -I .cmake-whitelist.txt` whereby the whitelist contained: ans dum helpfull emmited emmitted buil iff isnt nto ot pathes substract te todays upto whitespaces
* cpack wix: support WiX generator on CygwinStephen Sorley2017-10-135-12/+93
| | | | | | | | | | | | Cygwin-built CMake now converts paths from Cygwin to Windows form (using cygpath -w) before they're passed to WiX. The Wix generator on Cygwin requires the libuuid-dev package when building CMake. However, the DLL it links to is installed by default as part of Cygwin's core libs, so it does not need to be distributed. If libuuid-dev isn't available, CMake is simply built without Wix support on Cygwin.
* Meta: modernize old-fashioned loops to range-based `for` (CPack).Pavel Solodovnikov2017-09-197-74/+44
| | | | | | Changes done via `clang-tidy` with some manual fine-tuning for the variable naming and `auto` type deduction where appropriate.
* IWYU: Mark cmConfigure.h with pragma: keepDaniel Pfeifer2017-08-261-1/+1
| | | | Also remove `#include "cmConfigure.h"` from most source files.
* Use C++11 nullptrDaniel Pfeifer2017-08-241-1/+1
|
* c++: prefer vectors over listsBen Boeckel2017-05-041-3/+3
| | | | | | | | | | | None of these usages of `std::list` were inserting or removing elements in the middle of the structure, so there were no benefits to using it. Other uses were related to C pointers being stable in a list of strings whereas in a vector of strings, small pointer optimizations could be moved and become invalid after a modification to the hosting vector. None of these uses modified the vector after handing out a C string to an external store.
* wix: adds ability to modify attributes with patchKeith Holman2017-04-245-12/+30
| | | | | | | | | Adds the ability to attributes to generated XML files for features with the WiX patch system. To modify attributes additional attributes may be added within the 'CPackWixFragment' xml tag. Fixes: #16813 Signed-off-by: Keith Holman <keith.holman@windriver.com>
* wix: fix spelling error in function nameKeith Holman2017-04-242-7/+7
| | | | | | | | The function "AddDirectoryAndFileDefinitions" was missing the last "i" in the function name. This patch corrects the spelling so that the function can be found easier when searching through the source code. Signed-off-by: Keith Holman <keith.holman@windriver.com>
* Use quotes for non-system includesDaniel Pfeifer2017-04-1111-22/+22
| | | | | | | | | | | | | Automate with: git grep -l '#include <cm_' -- Source \ | xargs sed -i 's/#include <\(cm_.*\)>/#include "\1"/g' git grep -l '#include <cmsys/' -- Source \ | xargs sed -i 's/#include <\(cmsys\/.*\)>/#include "\1"/g' git grep -l '#include <cm[A-Z]' -- Source \ | xargs sed -i 's/#include <\(cm[A-Z].*\)>/#include "\1"/g'
* CPack: drop CPack prefix for includesDaniel Pfeifer2017-04-1112-13/+13
| | | | | | | | | | Automate with: git grep -l '#include <CPack/' -- Source \ | xargs sed -i 's/#include <CPack\/\(.*\)>/#include "\1"/g' git grep -l '#include "CPack/' -- Source \ | xargs sed -i 's/#include "CPack\/\(.*\)"/#include "\1"/g'
* Add self-sufficient wrapper for <sys/stat.h>Daniel Pfeifer2017-03-241-3/+1
|
* CPackWIX: Introduce new CPACK_WIX_ROOT_FOLDER_ID variableNils Gladitz2017-02-062-6/+16
| | | | | | | | | | The new variable allows specification of a custom root folder ID. The implicit default is "ProgramFiles<64>Folder". The "<64>" token is replaced by "" for 32-bit and "64" for 64-bit builds. Inspired-By: Eric Backus Fixes: #16573
* avoid including cmStandardIncludes.hDaniel Pfeifer2016-11-282-2/+2
|
* Port hash computation to cmCryptoHashBrad King2016-11-101-2/+2
| | | | | Avoid using KWSys MD5 or `cm_sha2` and use the `cmCryptoHash` abstraction instead.
* Encoding: Remove option to use ANSI code page internallyClinton Stimpson2016-11-023-44/+2
| | | | | | The switch to use UTF-8 encoding has been defaulted to on for quite some time since commit v3.2.0-rc1~116^2 (Encoding: Switch to use UTF-8 internally by default on Windows, 2014-12-26).
* Simplify CMake per-source license noticesBrad King2016-09-2720-240/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | Per-source copyright/license notice headers that spell out copyright holder names and years are hard to maintain and often out-of-date or plain wrong. Precise contributor information is already maintained automatically by the version control tool. Ultimately it is the receiver of a file who is responsible for determining its licensing status, and per-source notices are merely a convenience. Therefore it is simpler and more accurate for each source to have a generic notice of the license name and references to more detailed information on copyright holders and full license terms. Our `Copyright.txt` file now contains a list of Contributors whose names appeared source-level copyright notices. It also references version control history for more precise information. Therefore we no longer need to spell out the list of Contributors in each source file notice. Replace CMake per-source copyright/license notice headers with a short description of the license and links to `Copyright.txt` and online information available from "https://cmake.org/licensing". The online URL also handles cases of modules being copied out of our source into other projects, so we can drop our notices about replacing links with full license text. Run the `Utilities/Scripts/filter-notices.bash` script to perform the majority of the replacements mechanically. Manually fix up shebang lines and trailing newlines in a few files. Manually update the notices in a few files that the script does not handle.
* CPackWIX: Enabled patching of WIX <Feature> tagsMichael Stürmer2016-09-093-8/+15
|
* CPackWIX: Fix incomplete CPACK_WIX_SKIP_PROGRAM_FOLDER implementationMichael Stürmer2016-09-0610-38/+79
| | | | | | | | | | Commit 17bbf6af (CPackWIX: Implement new CPACK_WIX_SKIP_PROGRAM_FOLDER feature) generates GUIDs for most but not all components when the feature is active. Generate the remaining GUIDs as well. Co-Author: Nils Gladitz <nilsgladitz@gmail.com>
* make sure to include cmConfigure.h before cmStandardIncludes.hDaniel Pfeifer2016-09-031-0/+2
|
* CPackWIX: Implement new CPACK_WIX_SKIP_PROGRAM_FOLDER featureMichael Stürmer2016-08-084-4/+31
| | | | | The new variable allows setting of a custom absolute installation prefix outside of the ProgramFiles folders.