Subversion Repositories DevTools

Rev

Rev 1762 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1762 Rev 1764
Line 32... Line 32...
32
 
32
 
33
		<attribute	name="rtti"				
33
		<attribute	name="rtti"				
34
					default="true"
34
					default="true"
35
					description="Optional flag, used to enable Run-Time Type Information"/>
35
					description="Optional flag, used to enable Run-Time Type Information"/>
36
									
36
									
37
		<attribute	name="usevcl"				
37
		<attribute	name="buildproperties"				
38
					default="false"
38
					default=""
39
					description="Optional flag, used to include vcl libraries"/>
39
					description="Optional flag, used to add 'database', or 'vcl' libraries when needed"/>
40
					
40
					
41
		<attribute	name="exceptions"		
41
		<attribute	name="exceptions"		
42
					default="true"
42
					default="true"
43
					description="Optional flag, used to enable exception handling support. Defaults to true"/>
43
					description="Optional flag, used to enable exception handling support. Defaults to true"/>
44
 
44
 
Line 77... Line 77...
77
 
77
 
78
			<!-- Determine any compile type dependent flags
78
			<!-- Determine any compile type dependent flags
79
				 Including naming standards, optimizations, etc -->
79
				 Including naming standards, optimizations, etc -->
80
			<if>
80
			<if>
81
				<equals arg1="@{buildtype}" arg2="debug"/>
81
				<equals arg1="@{buildtype}" arg2="debug"/>
82
				<then>
82
				<then>
-
 
83
					<property name="debug_build" value="true"/>
83
					<property name="@{name}@{compiler}@{buildtype}-compile_type_symbol" value="D"/>
84
					<property name="@{name}@{compiler}@{buildtype}-compile_type_symbol" value="D"/>
84
					<property name="@{name}@{compiler}@{buildtype}-debug_flag" value="true"/>
85
					<property name="@{name}@{compiler}@{buildtype}-debug_flag" value="true"/>
85
					<property name="@{name}@{compiler}@{buildtype}-compile_optimize" value="none"/>
86
					<property name="@{name}@{compiler}@{buildtype}-compile_optimize" value="none"/>
86
				</then>
87
				</then>
87
				<else>
88
				<else>
-
 
89
					<property name="release_build" value="true"/>
88
					<property name="@{name}@{compiler}@{buildtype}-compile_type_symbol" value="P"/>
90
					<property name="@{name}@{compiler}@{buildtype}-compile_type_symbol" value="P"/>
89
					<property name="@{name}@{compiler}@{buildtype}-debug_flag" value="false"/>
91
					<property name="@{name}@{compiler}@{buildtype}-debug_flag" value="false"/>
90
					<if>
92
					<if>
91
						<equals arg1="@{optimize}" arg2=""/>
93
						<equals arg1="@{optimize}" arg2=""/>
92
						<then>
94
						<then>
Line 129... Line 131...
129
			<!-- Type of target => Linker Options for bcpp compiler according type executable,plugin,shared,static-->
131
			<!-- Type of target => Linker Options for bcpp compiler according type executable,plugin,shared,static-->
130
				
132
				
131
			<if>
133
			<if>
132
			<equals arg1="@{compiler}" arg2="bcpp"/>
134
			<equals arg1="@{compiler}" arg2="bcpp"/>
133
			<then>
135
			<then>
134
				<if>
-
 
135
				<equals arg1="@{outtype}" arg2="executable"/>
136
				<if><equals arg1="@{outtype}" arg2="executable"/>
136
				<then>
-
 
137
				<property name="@{buildtype}@{compiler}@{name}--linker" value="@{compiler}_linker_@{buildtype}_@{subsystem}"/>
-
 
138
				</then>
-
 
139
				<else>
-
 
140
				<if>
-
 
141
					<equals arg1="@{outtype}" arg2="shared"/>
-
 
142
					<then>
137
					<then>
143
						<property name="@{buildtype}@{compiler}@{name}--linker" value="@{compiler}_linker_@{buildtype}_@{subsystem}"/>	
138
						<property name="@{buildtype}@{compiler}@{name}--linker" value="@{compiler}_linker_@{buildtype}_@{subsystem}"/>
144
					</then>
139
					</then>
-
 
140
				<else>
-
 
141
					<if><equals arg1="@{outtype}" arg2="shared"/>
-
 
142
						<then>
-
 
143
							<property name="@{buildtype}@{compiler}@{name}--linker" value="@{compiler}_linker_@{buildtype}_@{subsystem}"/>	
-
 
144
						</then>
145
					<else>
145
					<else>
-
 
146
						<if><equals arg1="@{outtype}" arg2="runtime-package"/>
-
 
147
							<then>
-
 
148
								<property name="@{buildtype}@{compiler}@{name}--linker" value="@{compiler}_linker_@{buildtype}_@{subsystem}"/>	
-
 
149
							</then>
-
 
150
						<else>
-
 
151
							<if><equals arg1="@{outtype}" arg2="designtime-package"/>
-
 
152
								<then>
-
 
153
									<property name="@{buildtype}@{compiler}@{name}--linker" value="@{compiler}_linker_@{buildtype}_@{subsystem}"/>	
-
 
154
								</then>
-
 
155
							<else>
146
						<property name="@{buildtype}@{compiler}@{name}--linker" value="@{compiler}_linker_none"/>
156
								<property name="@{buildtype}@{compiler}@{name}--linker" value="@{compiler}_linker_none"/>
-
 
157
							</else>
-
 
158
							</if>
-
 
159
						</else>
-
 
160
						</if>
147
					</else>
161
					</else>
148
				</if>
162
					</if>
149
				</else>
163
				</else>
150
				</if>
164
				</if>
151
			</then>
165
			</then>
152
			<else>
166
			<else>
153
				<property name="@{buildtype}@{compiler}@{name}--linker" value="@{compiler}_linker_@{buildtype}_@{subsystem}"/>	
167
				<property name="@{buildtype}@{compiler}@{name}--linker" value="@{compiler}_linker_@{buildtype}_@{subsystem}"/>	
154
			</else>
168
			</else>
155
			</if>
169
			</if>
156
			
170
			
157
			<!-- Type of target => Linker Options with VCL-->
171
			<!-- libraries to add to the linker according the buildproperties attribute -->		
158
			<if>
-
 
159
				<equals arg1="@{usevcl}" arg2="true"/>
172
			<for list="@{buildproperties}" delimiter="," param="bproperties">
160
				<then>
173
				<sequential>
161
					<property name="@{name}_@{compiler}--vcl" value="_vcl"/>
174
					<echo>BUILD PROPERTIES @{bproperties}</echo>		
162
 
-
 
163
				</then>
-
 
164
				<else>
-
 
165
					<property name="@{name}_@{compiler}--vcl" value=""/>
175
					<property name="@{compiler}_properties_@{bproperties}" value="true"/>	
166
 
-
 
167
				</else>
176
				</sequential>
168
			</if>
177
            		</for>
169
			
-
 
170
			
178
			
171
			<mkdir dir="${objdir}/@{buildtype}_@{compiler}"/>
179
			<mkdir dir="${objdir}/@{buildtype}_@{compiler}"/>
172
			<mkdir dir="${objdir}/@{buildtype}_@{compiler}/@{targetname}"/>
180
			<mkdir dir="${objdir}/@{buildtype}_@{compiler}/@{targetname}"/>
173
			<mkdir dir="@{pkgdir}"/>
181
			<mkdir dir="@{pkgdir}"/>
174
			<mkdir dir="@{pkgdir}/${@{name}@{buildtype}--targetfolder}"/>
182
			<mkdir dir="@{pkgdir}/${@{name}@{buildtype}--targetfolder}"/>
175
 
183
 
176
			<echo taskname="ant-cppcompile-task">Compile @{name} into @{pkgdir}/${@{name}@{buildtype}--targetfolder}/${@{name}@{compiler}@{outtype}@{buildtype}-output_name}</echo>
184
			<echo taskname="ant-cppcompile-task">Compile @{name} into @{pkgdir}/${@{name}@{buildtype}--targetfolder}/${@{name}@{compiler}@{outtype}@{buildtype}-output_name}</echo>
177
			<echo taskname="ant-cppcompile-task">Using Compiler @{compiler} from @{compilerpath}</echo>
185
			<echo taskname="ant-cppcompile-task">Using Compiler @{compiler} (${@{compiler}_compilername}) from @{compilerpath}</echo>
178
			<echo taskname="ant-cppcompile-task">Placing Objects in ${objdir}/@{buildtype}_@{compiler}/@{targetname}</echo>
186
			<echo taskname="ant-cppcompile-task">Placing Objects in ${objdir}\@{buildtype}_@{compiler}\@{targetname}</echo>
179
			<echo taskname="ant-cppcompile-task">Use Compiler Includes from ${@{compiler}_include_@{buildtype}}</echo>
187
			<echo taskname="ant-cppcompile-task">Use Compiler Includes from ${@{compiler}_include_@{buildtype}}</echo>
180
			<echo taskname="ant-cppcompile-task">Use Package Includes from @{pkgdir}/include</echo>
188
			<echo taskname="ant-cppcompile-task">Use Package Includes from @{pkgdir}/include</echo>
181
			<echo taskname="ant-cppcompile-task">Linking with Library ${@{compiler}_lib_@{buildtype}} Files: ${@{compiler}_libraries_@{buildtype}}</echo>
189
			<echo taskname="ant-cppcompile-task">Linking with Library ${@{compiler}_lib_@{buildtype}} Files: ${@{compiler}_libraries_@{buildtype}}</echo>
182
 
190
			
183
			<echo taskname="ant-cppcompile-task">Linker   ${@{buildtype}@{compiler}@{name}--linker}${@{name}_@{compiler}--vcl}</echo>
-
 
184
			<echo taskname="ant-cppcompile-task">Compiler @{compiler}_compiler_@{buildtype}_@{subsystem}</echo>
191
			<echo taskname="ant-cppcompile-task">Compiler @{compiler}_compiler_@{buildtype}_@{subsystem}</echo>
185
			<echo taskname="ant-cppcompile-task">Output File Name ${@{name}@{compiler}@{outtype}@{buildtype}-output_name}</echo>
192
			<echo taskname="ant-cppcompile-task">Output File Name ${@{name}@{compiler}@{outtype}@{buildtype}-output_name}</echo>
186
					
193
					
187
			<echo taskname="ant-cppcompile-task">Include Path: ${@{compiler}_include_@{buildtype}}</echo>
194
			<echo taskname="ant-cppcompile-task">Include Path: ${@{compiler}_include_@{buildtype}}</echo>
188
			
195
			
-
 
196
			
189
		     
197
			<if>
-
 
198
				<equals arg1="@{outtype}" arg2="static"/>
-
 
199
				<then>
190
  			<cc name="${@{compiler}_compilername}" 
200
  					<cc name="${@{compiler}_compilername}" 
191
				path="@{compilerpath}"
201
						path="@{compilerpath}"
192
				rtti="@{rtti}"
202
						rtti="@{rtti}"
193
				exceptions="@{exceptions}"
203
						exceptions="@{exceptions}"
194
				multithreaded="@{multithreaded}"
204
						multithreaded="@{multithreaded}"
195
				optimize="${@{name}@{compiler}@{buildtype}-compile_optimize}"
205
						optimize="${@{name}@{compiler}@{buildtype}-compile_optimize}"
196
				debug="${@{name}@{compiler}@{buildtype}-debug_flag}" 
206
						debug="${@{name}@{compiler}@{buildtype}-debug_flag}" 
197
				outtype="@{outtype}" 
207
						outtype="@{outtype}" 
198
				subsystem="@{subsystem}" 
208
						subsystem="@{subsystem}" 
199
				outfile="@{pkgdir}/${@{name}@{buildtype}--targetfolder}/${@{name}@{compiler}@{outtype}@{buildtype}-output_name}"
209
						outfile="@{pkgdir}\${@{name}@{buildtype}--targetfolder}\${@{name}@{compiler}@{outtype}@{buildtype}-output_name}"
200
				objdir="${objdir}/@{buildtype}_@{compiler}/@{targetname}">
210
						objdir="${objdir}\@{buildtype}_@{compiler}\@{targetname}">
201
 
211
 
202
				<compiler refid="@{compiler}_compiler_@{buildtype}_@{subsystem}"/>
212
						<compiler refid="@{compiler}_compiler_@{buildtype}_@{subsystem}"/>
-
 
213
						
203
				<linker refid="${@{buildtype}@{compiler}@{name}--linker}${@{name}_@{compiler}--vcl}"/>
214
						<includepath path="${@{compiler}_include_@{buildtype}}"/>
-
 
215
						<includepath path="@{pkgdir}\include"/>
-
 
216
 
-
 
217
						<compiler-elements/>
204
			
218
						
-
 
219
  					</cc>
-
 
220
				</then>
-
 
221
				<else>
-
 
222
  					<cc name="${@{compiler}_compilername}" 
-
 
223
						path="@{compilerpath}"
-
 
224
						rtti="@{rtti}"
-
 
225
						exceptions="@{exceptions}"
-
 
226
						multithreaded="@{multithreaded}"
-
 
227
						optimize="${@{name}@{compiler}@{buildtype}-compile_optimize}"
-
 
228
						debug="${@{name}@{compiler}@{buildtype}-debug_flag}" 
-
 
229
						outtype="@{outtype}" 
-
 
230
						subsystem="@{subsystem}" 
-
 
231
						outfile="@{pkgdir}\${@{name}@{buildtype}--targetfolder}\${@{name}@{compiler}@{outtype}@{buildtype}-output_name}"
-
 
232
						objdir="${objdir}\@{buildtype}_@{compiler}\@{targetname}">
-
 
233
 
-
 
234
						<compiler refid="@{compiler}_compiler_@{buildtype}_@{subsystem}"/>
-
 
235
						<linker refid="${@{buildtype}@{compiler}@{name}--linker}"/>					
205
				
236
						
206
				<includepath path="${@{compiler}_include_@{buildtype}}"/>
237
						<includepath path="${@{compiler}_include_@{buildtype}}"/>
207
				<includepath path="@{pkgdir}/include"/>
238
						<includepath path="@{pkgdir}\include"/>
208
 
239
 
209
				<compiler-elements/>
240
						<compiler-elements/>
210
				
241
						
211
  			</cc>
242
  					</cc>
-
 
243
				</else>
-
 
244
			</if>
212
 
245
		     
213
		</sequential>
246
		</sequential>
214
	</macrodef>
247
	</macrodef>
215
 
248
 
216
</project>
249
</project>