summaryrefslogtreecommitdiffstats
path: root/Source/cmFileCommand.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2008-05-16 21:50:24 (GMT)
committerBrad King <brad.king@kitware.com>2008-05-16 21:50:24 (GMT)
commit0c6ba12efd365c08334385589a4e1b5432cd6780 (patch)
treea845856cd1c04c16b52ac9b1e02ba1003e77e1da /Source/cmFileCommand.cxx
parent10db44a81d7be2ebd93c7fb1b70883d62c421723 (diff)
downloadCMake-0c6ba12efd365c08334385589a4e1b5432cd6780.zip
CMake-0c6ba12efd365c08334385589a4e1b5432cd6780.tar.gz
CMake-0c6ba12efd365c08334385589a4e1b5432cd6780.tar.bz2
ENH: Teach Fortran compiler identification about the Portland Group compiler (PGI).
Diffstat (limited to 'Source/cmFileCommand.cxx')
-rw-r--r--Source/cmFileCommand.cxx14
1 files changed, 9 insertions, 5 deletions
diff --git a/Source/cmFileCommand.cxx b/Source/cmFileCommand.cxx
index d6c6f56..23272f7 100644
--- a/Source/cmFileCommand.cxx
+++ b/Source/cmFileCommand.cxx
@@ -533,12 +533,16 @@ bool cmFileCommand::HandleStringsCommand(std::vector<std::string> const& args)
(limit_input < 0 || static_cast<int>(fin.tellg()) < limit_input) &&
(c = fin.get(), fin))
{
- if(c == '\0')
+ if(c == '\0' || c == '\f')
{
- // A terminating null character has been found. Check if the
- // current string matches the requirements. Since it was
- // terminated by a null character, we require that the length be
- // at least one no matter what the user specified.
+ // A terminating character has been found. In most cases it is
+ // a NULL character, but at least one compiler (Portland Group
+ // Fortran) produces binaries that terminate strings with a form
+ // feed.
+
+ // Check if the current string matches the requirements. Since
+ // it was terminated by a null character, we require that the
+ // length be at least one no matter what the user specified.
if(s.length() >= minlen && s.length() >= 1 &&
(!have_regex || regex.find(s.c_str())))
{