Merge amd64 NDK from amd64 branch:
[reactos.git] / reactos / tools / rbuild / backend / msbuild / msbuild.h
1 /*
2 * Copyright (C) 2007 Christoph von Wittich
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write to the Free Software
16 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
17 */
18 #ifndef __MSBUILD_H__
19 #define __MSBUILD_H__
20
21 #include <fstream>
22 #include <vector>
23 #include <string>
24
25 #include "../backend.h"
26
27 class MsBuildConfiguration
28 {
29 public:
30 MsBuildConfiguration(const std::string &name = "");
31 virtual ~MsBuildConfiguration() {}
32 std::string name;
33 };
34
35 class MsBuildBackend : public Backend
36 {
37 public:
38
39 MsBuildBackend(Project &project,
40 Configuration& configuration);
41 virtual ~MsBuildBackend() {}
42
43 virtual void Process();
44
45 private:
46
47 FILE* m_MsBuildFile;
48
49 std::vector<MsBuildConfiguration*> m_configurations;
50 void _generate_makefile ( const Module& module );
51 void _generate_sources ( const Module& module );
52 void _clean_project_files ( void );
53 void ProcessModules();
54 const Property* _lookup_property ( const Module& module, const std::string& name ) const;
55 std::string _replace_str(std::string string1, const std::string &find_str, const std::string &replace_str);
56
57 struct module_data
58 {
59 std::vector <std::string> libraries;
60 std::vector <std::string> references;
61
62 module_data()
63 {}
64 ~module_data()
65 {}
66 };
67
68 };
69
70
71 #endif // __MsBuild_H__
72