summaryrefslogtreecommitdiffstats
path: root/Source/cmExportBuildAndroidMKGenerator.cxx
Commit message (Collapse)AuthorAgeFilesLines
* cmGeneratorTarget: Avoid boolean trap in usage requirement lookupBrad King2021-12-091-1/+2
| | | | | Replace `bool usage_requirements_only` arguments with a proper enumeration to clarify meaning at call sites.
* cmGeneratorTarget: Remove default config from Get* methodsBrad King2020-05-181-1/+3
| | | | Ensure all call sites pass an explicit configuration.
* Refactoring: add cm::contains to <cmext/algorithm>Marc Chevrier2020-04-171-2/+3
|
* replace "substr(0, xx) ==" with cmHasPrefix()Rolf Eike Beer2020-03-231-2/+2
|
* Source sweep: Replace cmExpandList with the shorter cmExpandedListSebastian Holtermann2019-08-231-4/+3
| | | | | | | | | | | | 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-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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)`
* cmAlgorithms: Add cmContainsRegina Pfeifer2019-08-191-3/+2
| | | | Also, use the new function where applicable.
* Source code: Use cmExpandList instead of cmSystemTools::ExpandListArgumentSebastian Holtermann2019-08-141-2/+2
|
* cmStringAlgorithms: Move string functions to the new cmStringAlgorithms.hSebastian Holtermann2019-07-291-1/+1
| | | | | This adds the `cmStringAlgorithms.h` header and moves all string functions from `cmAlgorithms.h` to `cmStringAlgorithms.h`.
* IWYU: Fix handling of <memory> standard headerBrad King2019-07-101-1/+0
| | | | | | | | An old workaround for `std::allocator_traits<>::value_type` lints from IWYU on `std::vector<>` usage breaks IWYU's handling of `<memory>`. Convert the workaround to use the same approach we already use for a workaround of `std::__decay_and_strip<>::::__type` lints. Then update the `<memory>` inclusions to follow the now-correct IWYU lints.
* Factor out enum MessageType into dedicated headerBruno Manganelli2019-01-161-2/+2
| | | | Reduce the number of files relying on `cmake.h`.
* Android.mk: De-duplicate link libraries logic during exportBrad King2018-09-111-21/+5
| | | | | | Use the normal target link interface computation logic to get the list of libraries in the link interface instead of trying to interpret the `INTERFACE_LINK_LIBRARIES` property directly.
* Fix transitive usage requirements through same-name imported targetsBrad King2018-09-101-1/+1
| | | | | | | | | | If two imported targets in different directories have the same name we should still be able to propagate transitive usage requirements from both. Fix the DAG checker to work with target pointers instead of target names since the pointers will not be duplicated even if the names are. Fixes: #18345
* LINK_OPTIONS: Add new family of propertiesMarc Chevrier2018-06-061-0/+6
| | | | | | | | | | | | | | This family enable to manage link flags Three new properties: * directory property: LINK_OPTIONS * target properties: LINK_OPTIONS and INTERFACE_LINK_OPTIONS Two new commands * add_link_options(): to populate directory property * target_link_options(): to populate target properties Fixes: #16543
* Merge topic 'object-library-export-as-interface'Brad King2018-03-011-1/+2
|\ | | | | | | | | | | | | ea0ce73a19 install,export: Maybe transform OBJECT libraries to INTERFACE libraries Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !1811
| * install,export: Maybe transform OBJECT libraries to INTERFACE librariesBrad King2018-02-281-1/+2
| | | | | | | | | | | | | | | | | | | | | | Teach the `install` and `export` commands to support installing and exporting `OBJECT` libraries without their object files. Transform them to `INTERFACE` libraries in such cases. For `install(TARGETS)`, activate this when no destination for the object files is specified. For `export`, activate this only under Xcode with multiple architectures when we have no well-defined object file locations to give to clients.
* | Android.mk: Fix export of static libraries with PRIVATE dependenciesBrad King2018-02-141-2/+5
| | | | | | | | | | | | | | | | The `LINK_ONLY` generator expression is used to represent private dependencies of static libraries in their `INTERFACE_LINK_LIBRARIES` property value. Fix evaluation of generator expressions during export to support the `LINK_ONLY` genex. Extend the RunCMake.AndroidMK test with a case for this.
* | Android.mk: Evaluate generator expressions up frontBrad King2018-02-141-12/+13
|/ | | | | | When exporting `INTERFACE_LINK_LIBRARIES`, we must evaluate generator expressions first, before expanding the `;` list, in case they contain or generate semicolons.
* Reduce raw string pointers usage.Pavel Solodovnikov2018-01-311-2/+1
| | | | | | | | | | * Change some functions to take `std::string` instead of `const char*` in the following classes: `cmMakeFile`, `cmake`, `cmCoreTryCompile`, `cmSystemTools`, `cmState`, `cmLocalGenerator` and a few others. * Greatly reduce using of `const char*` overloads for `cmSystemTools::MakeDirectory` and `cmSystemTools::RelativePath`. * Remove many redundant `c_str()` conversions throughout the code.
* Retire std::auto_ptr and its macro CM_AUTO_PTRMatthias Maennich2017-09-251-2/+2
| | | | Signed-off-by: Matthias Maennich <matthias@maennich.net>
* Meta: modernize old-fashioned loops to range-based `for`.Pavel Solodovnikov2017-09-121-20/+16
| | | | | | Changes done via `clang-tidy` with some manual fine-tuning for the variable naming and `auto` type deduction where appropriate.
* Use C++11 nullptrDaniel Pfeifer2017-08-241-2/+2
|
* clang-tidy: apply readability-redundant-string-init fixesDaniel Pfeifer2016-12-121-1/+1
|
* Fix several include-what-you-use findingsDaniel Pfeifer2016-11-081-5/+13
|
* cmState: Move TargetType enum to separate namespaceStephen Kelly2016-10-191-12/+12
|
* Android: Record use of C++ by static libs in exported Android.mk filesBrad King2016-10-071-0/+12
| | | | | | | | When a `PREBUILT_STATIC_LIBRARY` uses C++ in its sources then the `.a` file will have a link-time dependency on the C++ runtime libraries. Android NDK r14 will add a way to give this information to the NDK build system by adding a `LOCAL_HAS_CPP` setting to the `Android.mk` file. Add this for exported static libraries that use C++.
* Simplify CMake per-source license noticesBrad King2016-09-271-11/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | 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.
* Convert: Inline MAKERULE conversionsStephen Kelly2016-09-191-2/+2
| | | | This is a trivial use of a static method.
* use empty method to check for emptynessDaniel Pfeifer2016-09-151-1/+1
|
* Add support for creating prebuilt Android.mk filesBill Hoffman2016-09-131-0/+193
Add options to the `install()` and `export()` commands to export the targets we build into Android.mk files that reference them as prebuilt libraries with associated usage requirements (compile definitions, include directories, link libraries). This will allow CMake-built projects to be imported into projects using the Android NDK build system. Closes: #15562