summaryrefslogtreecommitdiff
path: root/qmake/generators/win32/msvc_objectmodel.h
Unidiff
Diffstat (limited to 'qmake/generators/win32/msvc_objectmodel.h') (more/less context) (ignore whitespace changes)
-rw-r--r--qmake/generators/win32/msvc_objectmodel.h43
1 files changed, 29 insertions, 14 deletions
diff --git a/qmake/generators/win32/msvc_objectmodel.h b/qmake/generators/win32/msvc_objectmodel.h
index 1dca68d..9ce38d2 100644
--- a/qmake/generators/win32/msvc_objectmodel.h
+++ b/qmake/generators/win32/msvc_objectmodel.h
@@ -1,20 +1,20 @@
1/**************************************************************************** 1/****************************************************************************
2** $Id$ 2**
3** 3**
4** Definition of ________ class. 4** Definition of VCProject class.
5** 5**
6** Copyright (C) 2002 Trolltech AS. All rights reserved. 6** Copyright (C) 2002-2003 Trolltech AS. All rights reserved.
7** 7**
8** This file is part of the network module of the Qt GUI Toolkit. 8** This file is part of qmake.
9** 9**
10** This file may be distributed under the terms of the Q Public License 10** This file may be distributed under the terms of the Q Public License
11** as defined by Trolltech AS of Norway and appearing in the file 11** as defined by Trolltech AS of Norway and appearing in the file
12** LICENSE.QPL included in the packaging of this file. 12** LICENSE.QPL included in the packaging of this file.
13** 13**
14** This file may be distributed and/or modified under the terms of the 14** This file may be distributed and/or modified under the terms of the
15** GNU General Public License version 2 as published by the Free Software 15** GNU General Public License version 2 as published by the Free Software
16** Foundation and appearing in the file LICENSE.GPL included in the 16** Foundation and appearing in the file LICENSE.GPL included in the
17** packaging of this file. 17** packaging of this file.
18** 18**
19** Licensees holding valid Qt Enterprise Edition licenses may use this 19** Licensees holding valid Qt Enterprise Edition licenses may use this
20** file in accordance with the Qt Commercial License Agreement provided 20** file in accordance with the Qt Commercial License Agreement provided
@@ -23,49 +23,51 @@
23** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 23** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
24** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 24** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
25** 25**
26** See http://www.trolltech.com/pricing.html or email sales@trolltech.com for 26** See http://www.trolltech.com/pricing.html or email sales@trolltech.com for
27** information about Qt Commercial License Agreements. 27** information about Qt Commercial License Agreements.
28** See http://www.trolltech.com/qpl/ for QPL licensing information. 28** See http://www.trolltech.com/qpl/ for QPL licensing information.
29** See http://www.trolltech.com/gpl/ for GPL licensing information. 29** See http://www.trolltech.com/gpl/ for GPL licensing information.
30** 30**
31** Contact info@trolltech.com if any conditions of this licensing are 31** Contact info@trolltech.com if any conditions of this licensing are
32** not clear to you. 32** not clear to you.
33** 33**
34**********************************************************************/ 34**********************************************************************/
35
35#ifndef __MSVC_OBJECTMODEL_H__ 36#ifndef __MSVC_OBJECTMODEL_H__
36#define __MSVC_OBJECTMODEL_H__ 37#define __MSVC_OBJECTMODEL_H__
37 38
38#include "project.h" 39#include "project.h"
39#include <qstring.h> 40#include <qstring.h>
40#include <qstringlist.h> 41#include <qstringlist.h>
41 42
42/* 43/*
43 This Object model is of course VERY simplyfied, 44 This Object model is of course VERY simplyfied,
44 and does not actually follow the original MSVC 45 and does not actually follow the original MSVC
45 object model. However, it fulfilles the basic 46 object model. However, it fulfilles the basic
46 needs for qmake 47 needs for qmake
47*/ 48*/
48 49
49/* 50/*
50 If a triState value is 'unset' then the 51 If a triState value is 'unset' then the
51 corresponding property is not in the output, 52 corresponding property is not in the output,
52 forcing the tool to utilize default values. 53 forcing the tool to utilize default values.
53 False/True values will be in the output... 54 False/True values will be in the output...
54*/ 55*/
55enum customBuildCheck { 56enum customBuildCheck {
56 none, 57 none,
57 moc, 58 moc,
58 uic, 59 uic,
59 lexyacc 60 lexyacc,
61 resource
60}; 62};
61enum triState { 63enum triState {
62 unset = -1, 64 unset = -1,
63 _False = 0, 65 _False = 0,
64 _True = 1 66 _True = 1
65}; 67};
66enum addressAwarenessType { 68enum addressAwarenessType {
67 addrAwareDefault, 69 addrAwareDefault,
68 addrAwareNoLarge, 70 addrAwareNoLarge,
69 addrAwareLarge 71 addrAwareLarge
70}; 72};
71enum asmListingOption { 73enum asmListingOption {
@@ -105,24 +107,25 @@ enum CompileAsOptions{
105 compileAsDefault, 107 compileAsDefault,
106 compileAsC, 108 compileAsC,
107 compileAsCPlusPlus 109 compileAsCPlusPlus
108}; 110};
109enum ConfigurationTypes { 111enum ConfigurationTypes {
110 typeUnknown = 0, 112 typeUnknown = 0,
111 typeApplication = 1, 113 typeApplication = 1,
112 typeDynamicLibrary = 2, 114 typeDynamicLibrary = 2,
113 typeStaticLibrary = 4, 115 typeStaticLibrary = 4,
114 typeGeneric = 10 116 typeGeneric = 10
115}; 117};
116enum debugOption { 118enum debugOption {
119 debugUnknown = -1,
117 debugDisabled, 120 debugDisabled,
118 debugOldStyleInfo, 121 debugOldStyleInfo,
119 debugLineInfoOnly, 122 debugLineInfoOnly,
120 debugEnabled, 123 debugEnabled,
121 debugEditAndContinue 124 debugEditAndContinue
122}; 125};
123enum eAppProtectionOption { 126enum eAppProtectionOption {
124 eAppProtectUnchanged, 127 eAppProtectUnchanged,
125 eAppProtectLow, 128 eAppProtectLow,
126 eAppProtectMedium, 129 eAppProtectMedium,
127 eAppProtectHigh 130 eAppProtectHigh
128}; 131};
@@ -231,25 +234,26 @@ enum enumSccEvent {
231enum favorSizeOrSpeedOption { 234enum favorSizeOrSpeedOption {
232 favorNone, 235 favorNone,
233 favorSpeed, 236 favorSpeed,
234 favorSize 237 favorSize
235}; 238};
236enum genProxyLanguage { 239enum genProxyLanguage {
237 genProxyNative, 240 genProxyNative,
238 genProxyManaged 241 genProxyManaged
239}; 242};
240enum inlineExpansionOption { 243enum inlineExpansionOption {
241 expandDisable, 244 expandDisable,
242 expandOnlyInline, 245 expandOnlyInline,
243 expandAnySuitable 246 expandAnySuitable,
247 expandDefault // Not useful number, but stops the output
244}; 248};
245enum linkIncrementalType { 249enum linkIncrementalType {
246 linkIncrementalDefault, 250 linkIncrementalDefault,
247 linkIncrementalNo, 251 linkIncrementalNo,
248 linkIncrementalYes 252 linkIncrementalYes
249}; 253};
250enum linkProgressOption { 254enum linkProgressOption {
251 linkProgressNotSet, 255 linkProgressNotSet,
252 linkProgressAll, 256 linkProgressAll,
253 linkProgressLibs 257 linkProgressLibs
254}; 258};
255enum machineTypeOption { 259enum machineTypeOption {
@@ -287,58 +291,61 @@ enum midlWarningLevelOption {
287 midlWarningLevel_4 291 midlWarningLevel_4
288}; 292};
289enum optFoldingType { 293enum optFoldingType {
290 optFoldingDefault, 294 optFoldingDefault,
291 optNoFolding, 295 optNoFolding,
292 optFolding 296 optFolding
293}; 297};
294enum optimizeOption { 298enum optimizeOption {
295 optimizeDisabled, 299 optimizeDisabled,
296 optimizeMinSpace, 300 optimizeMinSpace,
297 optimizeMaxSpeed, 301 optimizeMaxSpeed,
298 optimizeFull, 302 optimizeFull,
299 optimizeCustom 303 optimizeCustom,
304 optimizeDefault // Not useful number, but stops the output
300}; 305};
301enum optRefType { 306enum optRefType {
302 optReferencesDefault, 307 optReferencesDefault,
303 optNoReferences, 308 optNoReferences,
304 optReferences 309 optReferences
305}; 310};
306enum optWin98Type { 311enum optWin98Type {
307 optWin98Default, 312 optWin98Default,
308 optWin98No, 313 optWin98No,
309 optWin98Yes 314 optWin98Yes
310}; 315};
311enum pchOption { 316enum pchOption {
312 pchNone, 317 pchNone,
313 pchCreateUsingSpecific, 318 pchCreateUsingSpecific,
314 pchGenerateAuto, 319 pchGenerateAuto,
315 pchUseUsingSpecific 320 pchUseUsingSpecific
316}; 321};
317enum preprocessOption { 322enum preprocessOption {
323 preprocessUnknown = -1,
318 preprocessNo, 324 preprocessNo,
319 preprocessYes, 325 preprocessYes,
320 preprocessNoLineNumbers 326 preprocessNoLineNumbers
321}; 327};
322enum ProcessorOptimizeOption { 328enum ProcessorOptimizeOption {
323 procOptimizeBlended, 329 procOptimizeBlended,
324 procOptimizePentium, 330 procOptimizePentium,
325 procOptimizePentiumProAndAbove 331 procOptimizePentiumProAndAbove
326}; 332};
327enum RemoteDebuggerType { 333enum RemoteDebuggerType {
328 DbgLocal, 334 DbgLocal,
329 DbgRemote, 335 DbgRemote,
330 DbgRemoteTCPIP 336 DbgRemoteTCPIP
331}; 337};
332enum runtimeLibraryOption { 338enum runtimeLibraryOption {
339 rtUnknown = -1,
333 rtMultiThreaded, 340 rtMultiThreaded,
334 rtMultiThreadedDebug, 341 rtMultiThreadedDebug,
335 rtMultiThreadedDLL, 342 rtMultiThreadedDLL,
336 rtMultiThreadedDebugDLL, 343 rtMultiThreadedDebugDLL,
337 rtSingleThreaded, 344 rtSingleThreaded,
338 rtSingleThreadedDebug 345 rtSingleThreadedDebug
339}; 346};
340enum structMemberAlignOption { 347enum structMemberAlignOption {
341 alignNotSet, 348 alignNotSet,
342 alignSingleByte, 349 alignSingleByte,
343 alignTwoBytes, 350 alignTwoBytes,
344 alignFourBytes, 351 alignFourBytes,
@@ -370,24 +377,25 @@ enum TypeOfDebugger {
370}; 377};
371enum useOfATL { 378enum useOfATL {
372 useATLNotSet, 379 useATLNotSet,
373 useATLStatic, 380 useATLStatic,
374 useATLDynamic 381 useATLDynamic
375}; 382};
376enum useOfMfc { 383enum useOfMfc {
377 useMfcStdWin, 384 useMfcStdWin,
378 useMfcStatic, 385 useMfcStatic,
379 useMfcDynamic 386 useMfcDynamic
380}; 387};
381enum warningLevelOption { 388enum warningLevelOption {
389 warningLevelUnknown = -1,
382 warningLevel_0, 390 warningLevel_0,
383 warningLevel_1, 391 warningLevel_1,
384 warningLevel_2, 392 warningLevel_2,
385 warningLevel_3, 393 warningLevel_3,
386 warningLevel_4 394 warningLevel_4
387}; 395};
388 396
389class VCToolBase { 397class VCToolBase {
390protected: 398protected:
391 // Functions 399 // Functions
392 VCToolBase(){}; 400 VCToolBase(){};
393 virtual ~VCToolBase(){} 401 virtual ~VCToolBase(){}
@@ -602,27 +610,27 @@ public:
602}; 610};
603 611
604class VCCustomBuildTool : public VCToolBase 612class VCCustomBuildTool : public VCToolBase
605{ 613{
606public: 614public:
607 // Functions 615 // Functions
608 VCCustomBuildTool(); 616 VCCustomBuildTool();
609 virtual ~VCCustomBuildTool(){} 617 virtual ~VCCustomBuildTool(){}
610 bool parseOption( const char* ){ return FALSE; }; 618 bool parseOption( const char* ){ return FALSE; };
611 619
612 // Variables 620 // Variables
613 QStringList AdditionalDependencies; 621 QStringList AdditionalDependencies;
614 QString CommandLine; 622 QStringList CommandLine;
615 QString Description; 623 QString Description;
616 QString Outputs; 624 QStringList Outputs;
617 QString ToolName; 625 QString ToolName;
618 QString ToolPath; 626 QString ToolPath;
619}; 627};
620 628
621class VCResourceCompilerTool : public VCToolBase 629class VCResourceCompilerTool : public VCToolBase
622{ 630{
623public: 631public:
624 // Functions 632 // Functions
625 VCResourceCompilerTool(); 633 VCResourceCompilerTool();
626 virtual ~VCResourceCompilerTool(){} 634 virtual ~VCResourceCompilerTool(){}
627 bool parseOption( const char* ){ return FALSE; }; 635 bool parseOption( const char* ){ return FALSE; };
628 636
@@ -710,64 +718,71 @@ public:
710 VCPreBuildEventTool preBuild; 718 VCPreBuildEventTool preBuild;
711 VCPreLinkEventTool preLink; 719 VCPreLinkEventTool preLink;
712 VCResourceCompilerTool resource; 720 VCResourceCompilerTool resource;
713}; 721};
714 722
715class VcprojGenerator; 723class VcprojGenerator;
716class VCFilter 724class VCFilter
717{ 725{
718public: 726public:
719 // Functions 727 // Functions
720 VCFilter(); 728 VCFilter();
721 ~VCFilter(){} 729 ~VCFilter(){}
722 void generateMOC( QTextStream &strm, QString str ) const; 730 void addMOCstage( QTextStream &strm, QString str );
723 void generateUIC( QTextStream &strm, const QString& str ) const; 731 void addUICstage( QTextStream &strm, QString str );
732 bool addIMGstage( QTextStream &strm, QString str );
733 void modifyPCHstage( QTextStream &strm, QString str );
724 734
725 // Variables 735 // Variables
726 QString Name; 736 QString Name;
727 QString Filter; 737 QString Filter;
728 triState ParseFiles; 738 triState ParseFiles;
729 QStringList Files; 739 QStringList Files;
730 VcprojGenerator*Project; 740 VcprojGenerator*Project;
731 VCConfiguration*Config; 741 QValueList<VCConfiguration> *Config;
732 customBuildCheckCustomBuild; 742 customBuildCheckCustomBuild;
743 bool useCustomBuildTool;
744 VCCustomBuildTool CustomBuildTool;
745 bool useCompilerTool;
746 VCCLCompilerTool CompilerTool;
747 bool flat_files;
733}; 748};
734 749
735class VCProject 750class VCProject
736{ 751{
737public: 752public:
738 // Functions 753 // Functions
739 VCProject(); 754 VCProject();
740 ~VCProject(){} 755 ~VCProject(){}
741 756
742 // Variables 757 // Variables
743 QString Name; 758 QString Name;
744 QString Version; 759 QString Version;
745 QString ProjectGUID; 760 QString ProjectGUID;
746 QString SccProjectName; 761 QString SccProjectName;
747 QString SccLocalPath; 762 QString SccLocalPath;
748 QString PlatformName; 763 QString PlatformName;
749 764
750 // XML sub-parts 765 // XML sub-parts
751 VCConfigurationConfiguration; 766 QValueList<VCConfiguration> Configuration;
752 VCFilter SourceFiles; 767 VCFilter SourceFiles;
753 VCFilter HeaderFiles; 768 VCFilter HeaderFiles;
754 VCFilter MOCFiles; 769 VCFilter MOCFiles;
755 VCFilter UICFiles; 770 VCFilter UICFiles;
756 VCFilter FormFiles; 771 VCFilter FormFiles;
757 VCFilter TranslationFiles; 772 VCFilter TranslationFiles;
758 VCFilter LexYaccFiles; 773 VCFilter LexYaccFiles;
759 VCFilter ResourceFiles; 774 VCFilter ResourceFiles;
760}; 775};
761 776
762QTextStream &operator<<( QTextStream &, const VCCLCompilerTool & ); 777QTextStream &operator<<( QTextStream &, const VCCLCompilerTool & );
763QTextStream &operator<<( QTextStream &, const VCLinkerTool & ); 778QTextStream &operator<<( QTextStream &, const VCLinkerTool & );
764QTextStream &operator<<( QTextStream &, const VCMIDLTool & ); 779QTextStream &operator<<( QTextStream &, const VCMIDLTool & );
765QTextStream &operator<<( QTextStream &, const VCCustomBuildTool & ); 780QTextStream &operator<<( QTextStream &, const VCCustomBuildTool & );
766QTextStream &operator<<( QTextStream &, const VCLibrarianTool & ); 781QTextStream &operator<<( QTextStream &, const VCLibrarianTool & );
767QTextStream &operator<<( QTextStream &, const VCResourceCompilerTool & ); 782QTextStream &operator<<( QTextStream &, const VCResourceCompilerTool & );
768QTextStream &operator<<( QTextStream &, const VCEventTool & ); 783QTextStream &operator<<( QTextStream &, const VCEventTool & );
769QTextStream &operator<<( QTextStream &, const VCConfiguration & ); 784QTextStream &operator<<( QTextStream &, const VCConfiguration & );
770QTextStream &operator<<( QTextStream &, const VCFilter & ); 785QTextStream &operator<<( QTextStream &, VCFilter & );
771QTextStream &operator<<( QTextStream &, const VCProject & ); 786QTextStream &operator<<( QTextStream &, const VCProject & );
772 787
773#endif //__MSVC_OBJECTMODEL_H__ 788#endif //__MSVC_OBJECTMODEL_H__