Diffstat (limited to 'qmake/generators/win32/msvc_vcproj.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | qmake/generators/win32/msvc_vcproj.h | 129 |
1 files changed, 129 insertions, 0 deletions
diff --git a/qmake/generators/win32/msvc_vcproj.h b/qmake/generators/win32/msvc_vcproj.h new file mode 100644 index 0000000..583b164 --- a/dev/null +++ b/qmake/generators/win32/msvc_vcproj.h | |||
@@ -0,0 +1,129 @@ | |||
1 | /**************************************************************************** | ||
2 | ** $Id$ | ||
3 | ** | ||
4 | ** Definition of VcprojGenerator class. | ||
5 | ** | ||
6 | ** Created : 970521 | ||
7 | ** | ||
8 | ** Copyright (C) 1992-2000 Trolltech AS. All rights reserved. | ||
9 | ** | ||
10 | ** This file is part of the network module of the Qt GUI Toolkit. | ||
11 | ** | ||
12 | ** This file may be distributed under the terms of the Q Public License | ||
13 | ** as defined by Trolltech AS of Norway and appearing in the file | ||
14 | ** LICENSE.QPL included in the packaging of this file. | ||
15 | ** | ||
16 | ** This file may be distributed and/or modified under the terms of the | ||
17 | ** GNU General Public License version 2 as published by the Free Software | ||
18 | ** Foundation and appearing in the file LICENSE.GPL included in the | ||
19 | ** packaging of this file. | ||
20 | ** | ||
21 | ** Licensees holding valid Qt Enterprise Edition licenses may use this | ||
22 | ** file in accordance with the Qt Commercial License Agreement provided | ||
23 | ** with the Software. | ||
24 | ** | ||
25 | ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE | ||
26 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. | ||
27 | ** | ||
28 | ** See http://www.trolltech.com/pricing.html or email sales@trolltech.com for | ||
29 | ** information about Qt Commercial License Agreements. | ||
30 | ** See http://www.trolltech.com/qpl/ for QPL licensing information. | ||
31 | ** See http://www.trolltech.com/gpl/ for GPL licensing information. | ||
32 | ** | ||
33 | ** Contact info@trolltech.com if any conditions of this licensing are | ||
34 | ** not clear to you. | ||
35 | ** | ||
36 | **********************************************************************/ | ||
37 | #ifndef __VCPROJMAKE_H__ | ||
38 | #define __VCPROJMAKE_H__ | ||
39 | |||
40 | #include "winmakefile.h" | ||
41 | #include "msvc_objectmodel.h" | ||
42 | |||
43 | enum target { | ||
44 | Application, | ||
45 | SharedLib, | ||
46 | StaticLib | ||
47 | }; | ||
48 | |||
49 | class VcprojGenerator : public Win32MakefileGenerator | ||
50 | { | ||
51 | bool init_flag; | ||
52 | bool writeVcprojParts(QTextStream &); | ||
53 | |||
54 | bool writeMakefile(QTextStream &); | ||
55 | virtual void writeSubDirs(QTextStream &t); | ||
56 | QString findTemplate(QString file); | ||
57 | void init(); | ||
58 | |||
59 | public: | ||
60 | VcprojGenerator(QMakeProject *p); | ||
61 | ~VcprojGenerator(); | ||
62 | |||
63 | QString defaultMakefile() const; | ||
64 | virtual bool doDepends() const { return FALSE; } //never necesary | ||
65 | |||
66 | protected: | ||
67 | virtual bool openOutput(QFile &file) const; | ||
68 | virtual void processPrlVariable(const QString &, const QStringList &); | ||
69 | virtual bool findLibraries(); | ||
70 | virtual void outputVariables(); | ||
71 | |||
72 | void initOld(); | ||
73 | void initProject(); | ||
74 | void initConfiguration(); | ||
75 | void initCompilerTool(); | ||
76 | void initLinkerTool(); | ||
77 | void initLibrarianTool(); | ||
78 | void initIDLTool(); | ||
79 | void initCustomBuildTool(); | ||
80 | void initPreBuildEventTools(); | ||
81 | void initPostBuildEventTools(); | ||
82 | void initPreLinkEventTools(); | ||
83 | void initSourceFiles(); | ||
84 | void initHeaderFiles(); | ||
85 | void initMOCFiles(); | ||
86 | void initUICFiles(); | ||
87 | void initFormsFiles(); | ||
88 | void initTranslationFiles(); | ||
89 | void initLexYaccFiles(); | ||
90 | void initResourceFiles(); | ||
91 | |||
92 | /* | ||
93 | void writeGuid( QTextStream &t ); | ||
94 | void writeAdditionalOptions( QTextStream &t ); | ||
95 | void writeHeaders( QTextStream &t ); | ||
96 | void writeSources( QTextStream &t ); | ||
97 | void writeMocs( QTextStream &t ); | ||
98 | void writeLexs( QTextStream &t ); | ||
99 | void writeYaccs( QTextStream &t ); | ||
100 | void writePictures( QTextStream &t ); | ||
101 | void writeImages( QTextStream &t ); | ||
102 | void writeIDLs( QTextStream &t ); | ||
103 | |||
104 | void writeForms( QTextStream &t ); | ||
105 | void writeFormsSourceHeaders( QString &variable, QTextStream &t ); | ||
106 | void writeTranslations( QTextStream &t ); | ||
107 | void writeStrippedTranslations( QTextStream &t ); | ||
108 | */ | ||
109 | |||
110 | VCProject vcProject; | ||
111 | target projectTarget; | ||
112 | |||
113 | friend class VCFilter; | ||
114 | }; | ||
115 | |||
116 | inline VcprojGenerator::~VcprojGenerator() | ||
117 | { } | ||
118 | |||
119 | inline QString VcprojGenerator::defaultMakefile() const | ||
120 | { | ||
121 | return project->first("TARGET") + project->first("VCPROJ_EXTENSION"); | ||
122 | } | ||
123 | |||
124 | inline bool VcprojGenerator::findLibraries() | ||
125 | { | ||
126 | return Win32MakefileGenerator::findLibraries("MSVCVCPROJ_LIBS"); | ||
127 | } | ||
128 | |||
129 | #endif /* __VCPROJMAKE_H__ */ | ||