create only the project files specified on cmdline
[reactos.git] / reactos / tools / rbuild / backend / devcpp / devcpp.cpp
index a6f6cea..a105111 100644 (file)
@@ -1,11 +1,11 @@
 /*
- * Dev-C++ Backend
- * Copyright (C) 2005  Trevor McCort
+ * Copyright (C) 2005 Trevor McCort
+ * Copyright (C) 2005 Casper S. Hornstrup
  *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
+#ifdef _MSC_VER
+#pragma warning ( disable : 4786 )
+#endif//_MSC_VER
 
 #include <iostream>
 #include <fstream>
@@ -30,15 +33,17 @@ static class DevCppFactory : public Backend::Factory
        public:
 
                DevCppFactory() : Factory("devcpp") {}
-               Backend *operator() (Project &project)
+               Backend *operator() (Project &project,
+                                    Configuration& configuration)
                {
-                       return new DevCppBackend(project);
+                       return new DevCppBackend(project, configuration);
                }
                
 } factory;
 
 
-DevCppBackend::DevCppBackend(Project &project) : Backend(project)
+DevCppBackend::DevCppBackend(Project &project,
+                             Configuration& configuration) : Backend(project, configuration)
 {
        m_unitCount = 0;
 }
@@ -103,7 +108,9 @@ void DevCppBackend::Process()
        
        cout << "Creating Makefile: " << ProjectNode.makefile << endl;
        
-       Backend *backend = Backend::Factory::Create("mingw", ProjectNode);
+       Backend *backend = Backend::Factory::Create("mingw",
+                                                   ProjectNode,
+                                                   configuration );
        backend->Process();
        delete backend;
 
@@ -122,9 +129,9 @@ void DevCppBackend::ProcessModules()
        {
                Module &module = *ProjectNode.modules[i];
 
-               for(size_t k = 0; k < module.files.size(); k++)
+               for(size_t k = 0; k < module.non_if_data.files.size(); k++)
                {
-                       File &file = *module.files[k];
+                       File &file = *module.non_if_data.files[k];
                        
                        ProcessFile(file.name);
                }