cbp2make
Makefile generation tool for Code::Blocks IDE
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
src
cbproject.h
Go to the documentation of this file.
1
/*
2
cbp2make : Makefile generation tool for the Code::Blocks IDE
3
Copyright (C) 2010-2013 Mirai Computing (mirai.computing@gmail.com)
4
5
This program is free software: you can redistribute it and/or modify
6
it under the terms of the GNU General Public License as published by
7
the Free Software Foundation, either version 3 of the License, or
8
(at your option) any later version.
9
10
This program is distributed in the hope that it will be useful,
11
but WITHOUT ANY WARRANTY; without even the implied warranty of
12
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
GNU General Public License for more details.
14
15
You should have received a copy of the GNU General Public License
16
along with this program. If not, see <http://www.gnu.org/licenses/>.
17
*/
18
19
//------------------------------------------------------------------------------
20
#ifndef CBPROJECT_H
21
#define CBPROJECT_H
22
//------------------------------------------------------------------------------
23
#include "
stlstrings.h
"
24
#include "
stlconfig.h
"
25
//#include "cbptarget.h"
26
//#include "cbpunit.h"
27
#include "
depsearch.h
"
28
#include "
makefile.h
"
29
//------------------------------------------------------------------------------
30
31
class
CBuildTarget
;
32
class
CVirtualTarget
;
33
class
CBuildUnit
;
34
class
CToolChain
;
35
class
CCodeBlocksBuildConfig
;
36
37
class
TiXmlElement;
38
39
class
CCodeBlocksProject
40
{
41
private
:
42
//bool m_ValidProject;
43
int
m_VersionMajor
;
44
int
m_VersionMinor
;
45
CString
m_Title
;
46
CString
m_DefaultTarget
;
47
CString
m_Compiler
;
48
bool
m_ExtendedObjectNames
;
49
CStringList
m_CompilerOptions
;
50
CStringList
m_CompilerDirectories
;
51
CStringList
m_LinkerOptions
;
52
CStringList
m_LinkerLibraries
;
53
CStringList
m_LinkerDirectories
;
54
CStringList
m_ResourceCompilerDirectories
;
55
CStringList
m_BeforeBuildCommands
;
56
CStringList
m_AfterBuildCommands
;
57
bool
m_ForceBeforeBuildCommands
;
58
bool
m_ForceAfterBuildCommands
;
59
std::vector<CBuildTarget*>
m_BuildTargets
;
60
std::vector<CVirtualTarget*>
m_VirtualTargets
;
61
std::vector<CBuildUnit*>
m_Units
;
62
CConfiguration
m_Environment
;
63
CStringList
m_Platforms
;
64
//
65
bool
m_SinglePlatform
;
66
std::vector<CBuildTarget*>
m_BuildTargetIndex
;
67
std::vector<CVirtualTarget*>
m_VirtualTargetIndex
;
68
std::vector<CBuildUnit*>
m_UnitIndex
;
69
std::vector<CToolChain*>
m_ToolChainIndex
;
70
std::vector<int>
m_TargetToolChainIndex
;
71
//
72
CDependencyInfo
m_Dependencies
;
73
//CStringList m_MakefileText;
74
CMakefile
m_Makefile
;
75
protected
:
76
//void DecorateTargetNames(void);
77
void
SortUnitsByWeight
(
void
);
78
public
:
79
void
Clear
(
void
);
80
void
Read
(
const
TiXmlElement *ProjectRoot);
81
bool
LoadProject
(
const
CString
& FileName);
82
void
Show
(
void
);
83
private
:
84
void
UpdatePlatformIndex
(
const
size_t
Platform,
CCodeBlocksBuildConfig
& Config);
85
void
UpdateTargetIndex
(
const
int
Target,
CCodeBlocksBuildConfig
& Config);
86
public
:
87
static
CString
DecorateVariableName
(
const
CString
& VariableName,
const
int
Case = 0);
88
static
CString
DecorateTargetName
(
const
CString
& TargetName,
const
int
Case = 2);
89
CString
ToolChainSuffix
(
const
int
ToolChainIndex,
CCodeBlocksBuildConfig
& Config);
90
//bool GenerateMakefileText(const CString& FileName, CCodeBlocksBuildConfig& Config);
91
bool
GenerateMakefile
(
const
CString
& FileName,
CCodeBlocksBuildConfig
& Config);
92
public
:
93
CCodeBlocksProject
(
void
);
94
~CCodeBlocksProject
(
void
);
95
};
96
97
#endif
98
//------------------------------------------------------------------------------
Generated on Sun Jun 9 2013 10:55:52 for cbp2make by
1.8.4