summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/find_program
Commit message (Collapse)AuthorAgeFilesLines
* 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.