summaryrefslogtreecommitdiffstats
path: root/Modules/CMakeFindDependencyMacro.cmake
Commit message (Collapse)AuthorAgeFilesLines
* CMakeFindDependencyMacro: Document return() behavior and caveatsBrad King2017-09-081-7/+18
| | | | | | | | The `find_dependency` macro is designed to be called from Package Configuration Files, not from Find Modules. The return() behavior is particularly problematic for find modules. Document this more clearly. Issue: #17257
* CMakeFindDependencyMacro: Convert documentation to bracket commentBrad King2017-09-081-17/+17
|
* Improve find_dependency argument handlingMatthew Woehlke2017-05-221-29/+9
| | | | | | | | | | | | | | Remove highly specialized and totally positional argument handling in find_dependency macro, and instead just pass arguments through to find_package. This gives users access to the full suite of arguments that find_package knows, and is backward compatible with the old arguments. Also, rewrite the unit tests for this, since the old tests are exclusively focused on testing the old argument handling and are no longer applicable, and add some success tests (the old tests did not even set up the CMake state in a way that CMake had any hope of ever finding the test package).
* Simplify CMake per-source license noticesBrad King2016-09-271-13/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | 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.
* find_dependency: Give more helpful message if VERSION is emptyAurélien Gâteau2014-03-131-2/+5
|
* find_dependency: Make sure invalid EXACT use can be reported.Stephen Kelly2014-03-111-3/+3
| | | | | | Test the first argument directly for matching 'EXACT'. The error check in its previous position was incorrect and would only trigger with a version of '0' or similar.
* find_dependency: Don't propagate EXACT argument.Stephen Kelly2014-03-061-2/+11
| | | | | | | | If a package is requested with an EXACT version, that doesn't imply that dependencies must be found EXACTly too. Extend the macro to allow specifying that a dependency must be found by EXACT version instead.
* find_dependency: unset cmake_fd_version variable at end of macroAlex Merry2014-02-261-0/+1
| | | | This matches the other macro variables.
* find_dependency: use correct version variable nameAlex Merry2014-02-261-1/+1
| | | | The code set cmake_fd_version, but used ${version}.
* find_dependency: Ensure that ARGV1 has valid local contentStephen Kelly2014-02-241-1/+4
| | | | | The ARGV1 value could come from a wrapping context if find_dependency is called from a function.
* find_dependency: Add namespacing for variables in the macro.Stephen Kelly2014-02-241-13/+17
| | | | Avoid setting a variable called 'version' etc.
* Always set version variable of find_dependency macroAlex Merry2014-02-231-3/+1
| | | | | | | | | | | If there is no ARGV1, that is fine; version will be made empty, and no version will be passed to find_package(). This is relevant when find_dependency is invoked multiple times, sometimes with a version specified and sometimes without. find_dependency(dep1 3.4) find_dependency(dep2) # version still set to 3.4.
* FeatureSummary: Don't list transitive package dependenciesStephen Kelly2014-02-031-0/+9
| | | | | | | | | | | | | | Set a global property in the find_package implementation. Track and reset that property in the find_dependency macro. Read the property in FeatureSummary when determining whether to print output. This means that packages which are found only as dependencies are not listed by FeatureSummary, but if a project uses find_package elsewhere directly, then it will be listed by FeatureSummary. Suggested-by: Alex Merry http://thread.gmane.org/gmane.comp.kde.devel.frameworks/10640
* Split the find_dependency macro into a separate file.Stephen Kelly2013-12-131-0/+58
This allows Config file authors to use it without having to use CONFIGURE_PACKAGE_CONFIG_FILE.