summaryrefslogtreecommitdiffstats
path: root/Source/cmCableSourceFilesCommand.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2001-03-08 21:13:27 (GMT)
committerBrad King <brad.king@kitware.com>2001-03-08 21:13:27 (GMT)
commit71153219e19446350006f84e0b712e912bb0e291 (patch)
tree8a316ed37e6ba9392373ee0900caab3e2ac6c9e8 /Source/cmCableSourceFilesCommand.cxx
parent02fe9118038019e05320081d893340a659f8daa3 (diff)
downloadCMake-71153219e19446350006f84e0b712e912bb0e291.zip
CMake-71153219e19446350006f84e0b712e912bb0e291.tar.gz
CMake-71153219e19446350006f84e0b712e912bb0e291.tar.bz2
ENH: Added creation of custom rules for generating CABLE packages.
Diffstat (limited to 'Source/cmCableSourceFilesCommand.cxx')
-rw-r--r--Source/cmCableSourceFilesCommand.cxx24
1 files changed, 24 insertions, 0 deletions
diff --git a/Source/cmCableSourceFilesCommand.cxx b/Source/cmCableSourceFilesCommand.cxx
index 97a6c51..f384cd8 100644
--- a/Source/cmCableSourceFilesCommand.cxx
+++ b/Source/cmCableSourceFilesCommand.cxx
@@ -16,6 +16,30 @@
#include "cmCableSourceFilesCommand.h"
#include "cmCacheManager.h"
+void cmCableSourceFilesCommand::FinalPass()
+{
+ // Get the index of the current package's cmClassFile.
+ // If it doesn't exist, ignore this command.
+ int index = m_CableData->GetPackageClassIndex();
+ if(index < 0)
+ { return; }
+
+ // The package's file has not yet been generated yet. The dependency
+ // finder will need hints. Add one for each source file.
+ cmClassFile& cFile = m_Makefile->GetClasses()[index];
+
+ std::string curPath = m_Makefile->GetCurrentDirectory();
+ curPath += "/";
+
+ for(Entries::const_iterator f = m_Entries.begin();
+ f != m_Entries.end(); ++f)
+ {
+ std::string header = curPath+*f+".h";
+ cFile.m_Depends.push_back(header);
+ }
+}
+
+
/**
* Write the CABLE configuration code to indicate header dependencies for
* a package.