diff options
author | Brad King <brad.king@kitware.com> | 2005-02-24 18:45:37 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2005-02-24 18:45:37 (GMT) |
commit | c1ca5113314bdc7bc6476523aabe2be3ad1593eb (patch) | |
tree | 19aa101e621f1ac7204027a4b65686d81afd759b /Source | |
parent | a51f7b4f9afe8f39dc3a12c4872dc1dffe1c502a (diff) | |
download | CMake-c1ca5113314bdc7bc6476523aabe2be3ad1593eb.zip CMake-c1ca5113314bdc7bc6476523aabe2be3ad1593eb.tar.gz CMake-c1ca5113314bdc7bc6476523aabe2be3ad1593eb.tar.bz2 |
COMP: HP compiler does not like initializing a const std::string & with a const char* (which requires the reference to be bound to a temporary with the scope of the reference).
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmMakefile.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx index 7c863d1..b96201b 100644 --- a/Source/cmMakefile.cxx +++ b/Source/cmMakefile.cxx @@ -1116,6 +1116,7 @@ cmTarget* cmMakefile::AddExecutable(const char *exeName, cmSourceFile *cmMakefile::GetSourceFileWithOutput(const char *cname) { std::string name = cname; + std::string out; // look through all the source files that have custom commands // and see if the custom command has the passed source file as an output @@ -1127,7 +1128,7 @@ cmSourceFile *cmMakefile::GetSourceFileWithOutput(const char *cname) if ((*i)->GetCustomCommand()) { // is the output of the custom command match the source files name - const std::string &out = (*i)->GetCustomCommand()->GetOutput(); + out = (*i)->GetCustomCommand()->GetOutput(); if (out.rfind(name) != out.npos && out.rfind(name) == out.size() - name.size()) { |