ENH: Added hook into Fortran dependency scanner.

This commit is contained in:
Brad King 2005-01-26 16:18:22 -05:00
parent 934346243e
commit a81a8263a5
2 changed files with 26 additions and 1 deletions

@ -55,6 +55,11 @@ SET(SRCS
cmDepends.cxx cmDepends.cxx
cmDependsC.h cmDependsC.h
cmDependsC.cxx cmDependsC.cxx
cmDependsFortran.h
cmDependsFortran.cxx
cmDependsFortranLexer.c
cmDependsFortranParser.h
cmDependsFortranParser.c
) )

@ -17,12 +17,18 @@
#include "cmLocalUnixMakefileGenerator2.h" #include "cmLocalUnixMakefileGenerator2.h"
#include "cmDepends.h" #include "cmDepends.h"
#include "cmDependsC.h"
#include "cmGeneratedFileStream.h" #include "cmGeneratedFileStream.h"
#include "cmGlobalGenerator.h" #include "cmGlobalGenerator.h"
#include "cmMakefile.h" #include "cmMakefile.h"
#include "cmSourceFile.h" #include "cmSourceFile.h"
// Include dependency scanners for supported languages. Only the
// C/C++ scanner is needed for bootstrapping CMake.
#include "cmDependsC.h"
#ifdef CMAKE_BUILD_WITH_CMAKE
# include "cmDependsFortran.h"
#endif
#include <memory> // auto_ptr #include <memory> // auto_ptr
#include <queue> #include <queue>
@ -2696,6 +2702,12 @@ cmLocalUnixMakefileGenerator2::GetDependsChecker(const std::string& lang,
{ {
return new cmDependsC(dir, objFile); return new cmDependsC(dir, objFile);
} }
#ifdef CMAKE_BUILD_WITH_CMAKE
else if(lang == "Fortran")
{
return new cmDependsFortran(dir, objFile);
}
#endif
return 0; return 0;
} }
@ -2735,6 +2747,14 @@ cmLocalUnixMakefileGenerator2
scanner.Write(); scanner.Write();
return true; return true;
} }
#ifdef CMAKE_BUILD_WITH_CMAKE
else if(lang == "Fortran")
{
cmDependsFortran scanner(".", objFile, srcFile, includes);
scanner.Write();
return true;
}
#endif
return false; return false;
} }