summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/find_program
Commit message (Collapse)AuthorAgeFilesLines
* find_*(): Add CMAKE_IGNORE_PREFIX_PATH variableKyle Edwards2022-02-024-0/+33
| | | | Fixes: #20878
* cmake: Add filtered debug-find optionsJohn Parent2021-12-174-0/+65
| | | | | | | | | | Add a `--debug-find-pkg=` option to debug find calls for specific packages. Add a `--debug-find-var=` option to debug find calls for specific return variables. Fixes: #21880
* find_*: Add support for option NO_CACHEMarc Chevrier2021-06-023-0/+149
| | | | | | | | Request that find result is stored in a normal variable rather than a cache entry. Fixes: #20687 Issue: #20743
* MSYS: Add support for running under MSYS runtime environmentOrgad Shaneh2021-04-261-1/+1
| | | | Detect MSYS as CYGWIN, with the required adaptations.
* find_program: Find programs that are executable but not readableBrad King2020-06-1510-2/+46
| | | | | | | | | This fix was first made by commit 86e6349ef7 (find_program: Find programs that are executable but not readable, 2020-04-04, v3.18.0-rc1~372^2) but was reverted for compatibility. Re-introduce it with a policy for compatibility. Fixes: #10468
* Merge topic 'bundle-exe-space-in-name'Brad King2020-06-153-0/+13
|\ | | | | | | | | | | | | d3fd518c03 find_program: Properly decode URL for bundle exe name with spaces Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !4891
| * find_program: Properly decode URL for bundle exe name with spacesCraig Scott2020-06-143-0/+13
| | | | | | Fixes: #20817
* | find_program: Revert "Find programs that are executable but not readable"Brad King2020-06-122-4/+10
|/ | | | | | | | | | | | | | The fix in commit 86e6349ef7 (find_program: Find programs that are executable but not readable, 2020-04-04, v3.18.0-rc1~372^2) can break existing projects that were (likely accidentally) relying on the old behavior to find files that are readable but not executable. Revert the fix for now. We can re-introduce it with a policy later. Instead of reverting the test case, update it to cover the old behavior. That can serve as a reference for testing the policy when introduced. Fixes: #20814 Issue: #10468
* find_program: Find programs that are executable but not readableVladimir Menshakov2020-04-093-0/+9
| | | | | | | | | `find_program` internally uses `cmSystemTools::FileExists` which calls `access(R_OK)` instead of `access(X_OK)`. Use `cmSystemTools::IsFileExecutable` instead to fix this issue. An example of such a program is `sudo`. Fixes: #10468
* find_*: Add support for REQUIRED keywordSylvain Joubert2020-03-065-0/+19
| | | | | | In the same spirit as the REQUIRED keyword on find_package, this will stop cmake execution with an error on a failed find_program, find_file, find_path or find_library.
* find_*: Use debug logging infrastructureRobert Maynard2019-12-192-0/+30
| | | | | | Teach the find_package, find_library, find_program, find_path, and find_file commands to print debug log messages when enabled by the `--debug-find` command-line option or `CMAKE_FIND_DEBUG_MODE` variable.
* Tests: Remove stray source dir modification in RunCMake.find_programBrad King2019-07-261-1/+0
| | | | | | Since commit c76c1ea208 (find_program: Consider CWD only for paths with separator, 2018-05-31, v3.13.0-rc1~413^2) this test has created a directory in the source tree unnecessarily. Remove it.
* Find: Correct spelling and layout issues in CMAKE_FIND_USE_ docsRobert Maynard2019-07-091-1/+1
|
* Find: Provide global controls for the `NO_[]_PATH` call optionsRobert Maynard2019-06-214-0/+50
|
* find_program: Consider CWD only for paths with separatorSam Yates2018-06-144-0/+71
| | | | | | | | | | | | | | | | | | find_program() incorrectly prepended search path components to absolute file paths, and incorrectly searched the current working directory for files that contained no directory separators. * Replace calls cmFindProgramHelper::CheckDirectory(std::string()) with call of new method cmFindProgramHelper::CheckCompoundNames() that checks for the presence of a directory separator in the file name. * Use cmSystemTools::CollapseCombinedPath rather than string concatenation to properly combine absolute file names with search path components. * Add unit tests to verify corrections. Fixes: #18044
* Merge topic 'fix-find_program-regression'Brad King2015-11-024-0/+14
|\ | | | | | | | | 31e6571c find_program: Fix regression in finding an already-known path
| * find_program: Fix regression in finding an already-known pathBrad King2015-10-304-0/+14
| | | | | | | | | | | | | | | | Changes in commit v3.4.0-rc1~124^2~1 (cmFindProgramCommand: Re-implement search using more flexible approach, 2015-09-01) did not preserve the behavior of looking for the given name with no search path at all. Fix this and add a test case covering finding an absolute path with no search directories.
* | Tests: Cover find_program when the environment duplicate some HINTSBrad King2015-09-155-0/+12
|/ | | | Reported-by: Marc CHEVRIER <marc.chevrier@sap.com>
* find_program: Optionally consider all names in each directoryBrad King2015-09-023-0/+8
| | | | | | | When more than one value is given to the NAMES option this command by default will consider one name at a time and search every directory for it. Add a NAMES_PER_DIR option to tell this command to consider one directory at a time and search for all names in it.
* Tests: Add explicit testing for find_programBrad King2015-09-0213-0/+34
Previously this command was tested only implicitly as part of larger tests. Add a RunCMake.find_program test to cover find_program cases specifically and independently.