Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Chuck Atkins
KWSys
Commits
c9213fbb
Commit
c9213fbb
authored
Dec 10, 2005
by
Andy Cedilnik
Browse files
ENH: Add another signature to FindProgram that matches more to the one from CMake
parent
444d9b98
Changes
2
Hide whitespace changes
Inline
Side-by-side
SystemTools.cxx
View file @
c9213fbb
...
...
@@ -1947,6 +1947,22 @@ kwsys_stl::string SystemTools::FindProgram(
return
""
;
}
kwsys_stl
::
string
SystemTools
::
FindProgram
(
const
kwsys_stl
::
vector
<
kwsys_stl
::
string
>&
names
,
const
kwsys_stl
::
vector
<
kwsys_stl
::
string
>&
path
,
bool
noSystemPath
)
{
for
(
kwsys_stl
::
vector
<
kwsys_stl
::
string
>::
const_iterator
it
=
names
.
begin
();
it
!=
names
.
end
()
;
++
it
)
{
// Try to find the program.
std
::
string
result
=
SystemTools
::
FindProgram
(
it
->
c_str
(),
path
,
noSystemPath
);
return
result
;
}
return
""
;
}
/**
* Find the library with the given name. Searches the given path and then
...
...
SystemTools.hxx.in
View file @
c9213fbb
...
...
@@ -493,6 +493,11 @@ public:
const kwsys_stl::vector<kwsys_stl::string>& path =
kwsys_stl::vector<kwsys_stl::string>(),
bool no_system_path = false);
static kwsys_stl::string FindProgram(
const kwsys_stl::vector<kwsys_stl::string>& names,
const kwsys_stl::vector<kwsys_stl::string>& path =
kwsys_stl::vector<kwsys_stl::string>(),
bool no_system_path = false);
/**
* Find a library in the system PATH, with optional extra paths
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment