diff options
author | Brad King <brad.king@kitware.com> | 2019-02-13 18:34:56 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2019-02-14 15:23:02 (GMT) |
commit | 72057d9c1582f4b6dec66cd0675860c4c335636e (patch) | |
tree | a8ef46af1c9bc0c90f2569393aed93f2b4d0f74f /Source/cmDependsFortran.cxx | |
parent | 7ae329e2ed84f62165cb11794ad85c6c43dbd7dc (diff) | |
download | CMake-72057d9c1582f4b6dec66cd0675860c4c335636e.zip CMake-72057d9c1582f4b6dec66cd0675860c4c335636e.tar.gz CMake-72057d9c1582f4b6dec66cd0675860c4c335636e.tar.bz2 |
Fortran: Thread compiler id through to internal Fortran parser
Diffstat (limited to 'Source/cmDependsFortran.cxx')
-rw-r--r-- | Source/cmDependsFortran.cxx | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/Source/cmDependsFortran.cxx b/Source/cmDependsFortran.cxx index cae3ff6..fe69d14 100644 --- a/Source/cmDependsFortran.cxx +++ b/Source/cmDependsFortran.cxx @@ -94,6 +94,8 @@ cmDependsFortran::cmDependsFortran(cmLocalGenerator* lg) } this->PPDefinitions.insert(def); } + + this->CompilerId = mf->GetSafeDefinition("CMAKE_Fortran_COMPILER_ID"); } cmDependsFortran::~cmDependsFortran() @@ -116,6 +118,9 @@ bool cmDependsFortran::WriteDependencies(const std::set<std::string>& sources, return false; } + cmFortranCompiler fc; + fc.Id = this->CompilerId; + bool okay = true; for (std::string const& src : sources) { // Get the information object for this source. @@ -123,7 +128,7 @@ bool cmDependsFortran::WriteDependencies(const std::set<std::string>& sources, // Create the parser object. The constructor takes info by reference, // so we may look into the resulting objects later. - cmFortranParser parser(this->IncludePath, this->PPDefinitions, info); + cmFortranParser parser(fc, this->IncludePath, this->PPDefinitions, info); // Push on the starting file. cmFortranParser_FilePush(&parser, src.c_str()); |