Completing the rest of the previous commit, forgot that it changed Core as well.
[castle.git] / default.build
blobdff2915a8a3b569a97278d03aa457658322e4bc1
1 <?xml version="1.0" encoding='iso-8859-1' ?>
2 <project
3 name="Castle"
4 default="build"
5 xmlns="http://nant.sf.net/release/0.85/nant.xsd"
8 <property name="root.dir" value="." />
9 <include buildfile="${root.dir}/common.xml" />
11 <fileset id="buildfiles.all">
12 <!-- Files have to be in dependency order -->
13 <include name="Core/core.build" />
14 <include name="Services/services.build" />
15 <include name="Tools/Tools.build" />
16 <include name="InversionOfControl/InversionOfControl.build" />
17 <include name="Components/components.build" />
18 <include name="ActiveRecord/activerecord.build" />
19 <include name="MonoRail/monorail.build" />
20 <!--
21 <include name="AspectSharp/aspectsharp.build" />
22 -->
23 <include name="Facilities/facilities.build" />
24 </fileset>
26 <target name="build"
27 depends="init copy-referenced-assemblies"
28 description="Builds Castle in the current configuration">
30 <nant target="build">
31 <buildfiles refid="buildfiles.all" />
32 </nant>
34 </target>
36 <target name="rebuild"
37 depends="init recreate-build-directory build"
38 description="Rebuilds Castle in the current configuration" />
40 <target name="installer" depends="init createreleasenotes zip-source zip-samples">
41 <nant buildfile="Setup/Setup.build" />
42 </target>
44 <target name="init" depends="common.init">
45 <mkdir dir="${build.dir}" />
46 <mkdir dir="${testresults.dir}" />
48 <call target="common.find-svninfo" />
49 <call target="common.find-nunit" />
50 </target>
52 <target name="clean" description="Deletes current build artifacts" depends="common.init">
53 <delete dir="${build.dir}" failonerror="false" />
54 <delete>
55 <fileset basedir="${build.base.dir}">
56 <include name="*.*" />
57 </fileset>
58 </delete>
59 </target>
61 <target name="clean-vs" description="Delete Visual Studio artifacts" depends="common.init">
62 <!-- NB - this target will fail if you have a solution open in Visual Studio -->
63 <echo message="Gathering files for removal..." />
64 <foreach item="File" property="filename">
65 <in>
66 <items basedir=".">
67 <include name="**/*.suo" />
68 <include name="*/*.csproj.user" />
69 </items>
70 </in>
71 <do>
72 <delete file="${filename}" />
73 </do>
74 </foreach>
75 <echo message="Gathering folders for removal..." />
76 <foreach item="Folder" property="foldername">
77 <in>
78 <items basedir=".">
79 <include name="**/obj" />
80 <include name="**/_ReSharper*" />
81 </items>
82 </in>
83 <do>
84 <delete dir="${foldername}" failonerror="false" />
85 </do>
86 </foreach>
87 </target>
89 <target name="cleanall" description="Deletes all build artifacts" depends="common.init">
90 <echo message="Deleting all builds from all configurations" />
91 <delete dir="${build.base.dir}" failonerror="false" />
92 <call target="clean-vs" />
93 </target>
95 <target name="recreate-build-directory">
96 <echo message="Current Directory is ${project::get-base-directory()}" />
97 <echo message="Build Directory is ${build.dir}" />
99 <!-- Prepare build directory -->
100 <delete dir="${build.dir}" failonerror="false" />
101 <mkdir dir="${build.dir}" />
102 <mkdir dir="${testresults.dir}" />
103 <call target="copy-referenced-assemblies" />
104 <property name="build.rebuild" value="true" />
105 </target>
107 <target name="copy-referenced-assemblies">
108 <!-- Copy framework-neutral libraries -->
109 <copy todir="${build.dir}" >
110 <fileset basedir="${lib.dir}">
111 <include name="*.dll" />
112 <include name="*.xml" />
113 <include name="*.license.txt" />
114 </fileset>
115 </copy>
117 <!-- Copy family-specific libraries -->
118 <!--
119 The build of log4net works just fine for all versions of .NET.
120 When they do get framework specific extensions then we
121 can just move them to the framework specific section
123 <copy todir="${build.dir}">
124 <fileset basedir="${lib.family.dir}">
125 <include name="*.dll" />
126 <include name="*.xml" />
127 <include name="*.license.txt" />
128 </fileset>
129 </copy>
131 <!-- Copy framework-specific libraries -->
132 <copy todir="${build.dir}">
133 <fileset basedir="${lib.framework.dir}">
134 <include name="*.dll" />
135 <include name="*.xml" />
136 <include name="*.license.txt" />
137 </fileset>
138 </copy>
139 </target>
141 <target name="generate-assemblyinfo"
142 depends="init"
143 description="Generate AssemblyInfo files">
145 <property name="visual-studio" value="true" />
146 <nant target="generate-assemblyinfo">
147 <buildfiles refid="buildfiles.all" />
148 </nant>
150 </target>
152 <target name="build-all-frameworks" depends="init">
153 <!-- Save the current framework -->
154 <property name="current.framework.saved" value="${nant.settings.currentframework}" />
156 <!-- Execute build for each framework -->
157 <foreach item="String" delim=" " property="framework" in="net-1.1 net-2.0">
158 <call target="set-${framework}-framework-configuration" />
159 <call target="build" />
160 </foreach>
162 <!-- Reset the current framework to the saved value -->
163 <call target="set-${current.framework.saved}-framework-configuration" />
164 </target>
166 <!-- Packaging related tasks -->
168 <target name="package" depends="zip-build"
169 description="Creates Zip files for Release">
171 <echo message="Created a '${project.config}' package in file://${build.zip.fullpath}" />
173 <delete file="${build.base.dir}/castle-sourcecode.zip" failonerror="false" />
174 <delete file="${build.dir}/test-results.zip" failonerror="false" />
175 <delete file="${build.dir}/external-dependencies.zip" failonerror="false" />
177 </target>
179 <target name="createreleasenotes" depends="init">
180 <mkdir dir="${releasenotes.dir}" />
181 <delete dir="${releasenotes.dir}" />
183 <echo message="Top level projects Release notes" />
185 <copy file="ActiveRecord/Changes.txt" tofile="${releasenotes.dir}/ActiveRecord Release Notes.txt" />
186 <copy file="ActiveRecord/License.txt" tofile="${releasenotes.dir}/License.txt" />
187 <copy file="MonoRail/Changes.txt" tofile="${releasenotes.dir}/MonoRail Release Notes.txt" />
188 <copy file="InversionOfControl/Changes.txt" tofile="${releasenotes.dir}/InversionOfControl Release Notes.txt" />
189 <copy file="AspectSharp/Changes.txt" tofile="${releasenotes.dir}/AspectSharp Release Notes.txt" />
190 <copy file="Tools/DynamicProxy/Changes.txt" tofile="${releasenotes.dir}/DynamicProxy Release Notes.txt" />
191 <copy file="Core/Changes.txt" tofile="${releasenotes.dir}/Core Release Notes.txt" />
193 <echo message="Components Release notes" />
195 <mkdir dir="${releasenotes.dir}/Components" />
196 <property name="target.folder" value="Components" />
197 <call target="copy-scope-releasednotes" />
199 <echo message="Facilities Release notes" />
201 <mkdir dir="${releasenotes.dir}/Facilities" />
202 <property name="target.folder" value="Facilities" />
203 <call target="copy-scope-releasednotes" />
205 <echo message="Services Release notes" />
207 <mkdir dir="${releasenotes.dir}/Services" />
208 <property name="target.folder" value="Services" />
209 <call target="copy-scope-releasednotes" />
211 </target>
213 <target name="copy-scope-releasednotes">
214 <foreach item="File" property="changeLogFile">
215 <in>
216 <items>
217 <include name="${target.folder}/**/Changes.txt"/>
218 </items>
219 </in>
220 <do>
221 <echo message="changeLogFile ${changeLogFile}" />
223 <property name="folder" value="${directory::get-parent-directory(changeLogFile)}" />
225 <if test="${platform::is-win32()}">
226 <property name="lastsepindex" value="${string::last-index-of(folder, '\') + 1}" />
227 </if>
229 <if test="${platform::is-unix()}">
230 <property name="lastsepindex" value="${string::last-index-of(folder, '/') + 1}" />
231 </if>
233 <property name="length" value="${string::get-length(folder) - int::parse(lastsepindex)}" />
235 <property name="project.name" value="${string::substring(folder, lastsepindex, length)}" />
237 <copy file="${changeLogFile}" tofile="${releasenotes.dir}/${target.folder}/${project.name} Release Notes.txt" />
238 </do>
239 </foreach>
240 </target>
242 <!-- depends="build" -->
243 <target name="zip-build" depends="build">
244 <property name="build.zip.dir" value="${build.dir}" overwrite="false" />
245 <property name="build.zip.file" value="Castle-${framework::get-target-framework()}-${project.config}-${datetime::get-year(datetime::now())}-${datetime::get-month(datetime::now())}-${datetime::get-day(datetime::now())} (r${svn.revision}).zip" overwrite="false" dynamic="true" />
246 <property name="build.zip.fullpath" value="${build.zip.dir}/${build.zip.file}" readonly="true" />
248 <delete>
249 <fileset basedir="${root.dir}">
250 <include name="*.zip" />
251 <include name="${build.dir}/external-dependencies.zip" />
252 </fileset>
253 </delete>
255 <!-- Prepare release note files -->
256 <call target="createreleasenotes" />
258 <!-- Include a zip file with all source code -->
259 <call target="zip-source" if="${build.debug}" />
261 <!-- Include a zip file with all dependencies -->
262 <call target="zip-dependencies" />
264 <!-- Create the master zip file with all files included -->
265 <zip zipfile="${build.zip.fullpath}">
266 <fileset basedir="${build.dir}" prefix="bin" >
267 <include name="**/Castle*.*" />
268 <include name="AspectSharp*.*" />
269 <include name="external-dependencies.zip" />
270 <exclude name="*Tests.*" />
271 <exclude name="test-results/**" />
272 </fileset>
273 <fileset basedir="${root.dir}">
274 <include name="ASL - Apache Software Foundation License.txt" />
275 <include name="Committers.txt" />
276 <include name="Castle main limitations.txt" />
277 </fileset>
278 <fileset basedir="${build.base.dir}" >
279 <include name="castle-sourcecode.zip" />
280 </fileset>
281 <fileset basedir="${releasenotes.dir}" prefix="ReleaseNotes" >
282 <include name="**/*.txt" />
283 </fileset>
284 </zip>
285 </target>
287 <target name="zip-dependencies" >
288 <zip zipfile="${build.dir}/external-dependencies.zip">
289 <fileset basedir="${build.dir}">
290 <include name="*.*" />
291 <exclude name="**/Castle*" />
292 <exclude name="**/AspectSharp*" />
293 <exclude name="**/db4o.dll" />
294 <exclude name="**/EULA.rtf" />
295 <exclude name="**/*.zip" />
296 </fileset>
297 </zip>
298 </target>
300 <target name="zip-doc">
301 <zip zipfile="${root.dir}/Castle-api-doc.zip">
302 <fileset basedir="${root.dir}/docs">
303 <include name="Castle.chm" />
304 </fileset>
305 </zip>
306 </target>
308 <target name="zip-samples-for-website" depends="init">
309 <delete dir="${root.dir}/samplesforwebsite/" failonerror="false" />
310 <mkdir dir="${root.dir}/samplesforwebsite/" />
312 <zip zipfile="${root.dir}/samplesforwebsite/InitializingAndConfiguring.zip">
313 <fileset basedir="${root.dir}/Samples/ActiveRecord/BlogSample">
314 <include name="**/*.build" />
315 <include name="**/*.sln" />
316 <include name="**/*.cs" />
317 <include name="**/*.ico" />
318 <include name="**/*.csproj" />
319 <include name="**/*.xml" />
320 <include name="**/*.config" />
321 <include name="**/*.lang" />
322 <include name="**/*.txt" />
323 <include name="**/*.inc" />
324 <include name="**/*.vm" />
325 <include name="*.snk" />
326 <exclude name="**/bin/*" />
327 <exclude name="**/bin/Debug/*" />
328 <exclude name="**/bin/Release/*" />
329 <exclude name="**/obj/*" />
330 <exclude name="**.user" />
331 <exclude name="**/_Resharper.*/*" />
332 </fileset>
333 </zip>
334 <zip zipfile="${root.dir}/samplesforwebsite/TableHierarchy.zip">
335 <fileset basedir="${root.dir}/Samples/ActiveRecord/TableHierarchySample">
336 <include name="**/*.build" />
337 <include name="**/*.sln" />
338 <include name="**/*.cs" />
339 <include name="**/*.ico" />
340 <include name="**/*.csproj" />
341 <include name="**/*.xml" />
342 <include name="**/*.config" />
343 <include name="**/*.lang" />
344 <include name="**/*.txt" />
345 <include name="**/*.inc" />
346 <include name="**/*.vm" />
347 <include name="*.snk" />
348 <exclude name="**/bin/*" />
349 <exclude name="**/bin/Debug/*" />
350 <exclude name="**/bin/Release/*" />
351 <exclude name="**/obj/*" />
352 <exclude name="**.user" />
353 <exclude name="**/_Resharper.*/*" />
354 </fileset>
355 </zip>
356 <zip zipfile="${root.dir}/samplesforwebsite/MonoRail.WizardSample.zip">
357 <fileset basedir="${root.dir}/Samples/MonoRail/WizardSample">
358 <include name="**/*.build" />
359 <include name="**/*.sln" />
360 <include name="**/*.cs" />
361 <include name="**/*.ico" />
362 <include name="**/*.csproj" />
363 <include name="**/*.xml" />
364 <include name="**/*.config" />
365 <include name="**/*.lang" />
366 <include name="**/*.txt" />
367 <include name="**/*.inc" />
368 <include name="**/*.vm" />
369 <include name="**/*.resx" />
370 <include name="**/*.aspx" />
371 <include name="**/*.asax" />
372 <include name="*.snk" />
373 <exclude name="**/bin/*" />
374 <exclude name="**/bin/Debug/*" />
375 <exclude name="**/bin/Release/*" />
376 <exclude name="**/obj/*" />
377 <exclude name="**.user" />
378 <exclude name="**/_Resharper.*/*" />
379 </fileset>
380 </zip>
381 <zip zipfile="${root.dir}/samplesforwebsite/MonoRail.SimpleBindingSample.zip">
382 <fileset basedir="${root.dir}/Samples/MonoRail/SimpleBindingSample">
383 <include name="**/*.build" />
384 <include name="**/*.sln" />
385 <include name="**/*.cs" />
386 <include name="**/*.ico" />
387 <include name="**/*.csproj" />
388 <include name="**/*.xml" />
389 <include name="**/*.config" />
390 <include name="**/*.lang" />
391 <include name="**/*.txt" />
392 <include name="**/*.inc" />
393 <include name="**/*.vm" />
394 <include name="**/*.resx" />
395 <include name="**/*.aspx" />
396 <include name="**/*.asax" />
397 <include name="*.snk" />
398 <exclude name="**/bin/*" />
399 <exclude name="**/bin/Debug/*" />
400 <exclude name="**/bin/Release/*" />
401 <exclude name="**/obj/*" />
402 <exclude name="**.user" />
403 <exclude name="**/_Resharper.*/*" />
404 </fileset>
405 </zip>
406 <zip zipfile="${root.dir}/samplesforwebsite/MonoRail.DataBindSample.zip">
407 <fileset basedir="${root.dir}/Samples/MonoRail/DataBindSample">
408 <include name="**/*.build" />
409 <include name="**/*.sln" />
410 <include name="**/*.cs" />
411 <include name="**/*.ico" />
412 <include name="**/*.csproj" />
413 <include name="**/*.xml" />
414 <include name="**/*.config" />
415 <include name="**/*.lang" />
416 <include name="**/*.txt" />
417 <include name="**/*.inc" />
418 <include name="**/*.vm" />
419 <include name="**/*.resx" />
420 <include name="**/*.aspx" />
421 <include name="**/*.asax" />
422 <include name="*.snk" />
423 <exclude name="**/bin/*" />
424 <exclude name="**/bin/Debug/*" />
425 <exclude name="**/bin/Release/*" />
426 <exclude name="**/obj/*" />
427 <exclude name="**.user" />
428 <exclude name="**/_Resharper.*/*" />
429 </fileset>
430 </zip>
431 <zip zipfile="${root.dir}/samplesforwebsite/MonoRail.SendingEmailSample.zip">
432 <fileset basedir="${root.dir}/Samples/MonoRail/SendingEmailSample">
433 <include name="**/*.build" />
434 <include name="**/*.sln" />
435 <include name="**/*.cs" />
436 <include name="**/*.ico" />
437 <include name="**/*.csproj" />
438 <include name="**/*.xml" />
439 <include name="**/*.config" />
440 <include name="**/*.lang" />
441 <include name="**/*.txt" />
442 <include name="**/*.inc" />
443 <include name="**/*.vm" />
444 <include name="**/*.resx" />
445 <include name="**/*.aspx" />
446 <include name="**/*.asax" />
447 <include name="*.snk" />
448 <exclude name="**/bin/*" />
449 <exclude name="**/bin/Debug/*" />
450 <exclude name="**/bin/Release/*" />
451 <exclude name="**/obj/*" />
452 <exclude name="**.user" />
453 <exclude name="**/_Resharper.*/*" />
454 </fileset>
455 </zip>
456 <zip zipfile="${root.dir}/samplesforwebsite/MonoRail.ViewComponentSample.zip">
457 <fileset basedir="${root.dir}/Samples/MonoRail/ViewComponentSample">
458 <include name="**/*.build" />
459 <include name="**/*.sln" />
460 <include name="**/*.cs" />
461 <include name="**/*.ico" />
462 <include name="**/*.csproj" />
463 <include name="**/*.xml" />
464 <include name="**/*.config" />
465 <include name="**/*.lang" />
466 <include name="**/*.txt" />
467 <include name="**/*.inc" />
468 <include name="**/*.vm" />
469 <include name="**/*.resx" />
470 <include name="**/*.aspx" />
471 <include name="**/*.asax" />
472 <include name="*.snk" />
473 <exclude name="**/bin/*" />
474 <exclude name="**/bin/Debug/*" />
475 <exclude name="**/bin/Release/*" />
476 <exclude name="**/obj/*" />
477 <exclude name="**.user" />
478 <exclude name="**/_Resharper.*/*" />
479 </fileset>
480 </zip>
481 <zip zipfile="${root.dir}/samplesforwebsite/MonoRail.AuthenticationUsingFilters.zip">
482 <fileset basedir="${root.dir}/Samples/MonoRail/AuthenticationUsingFilters">
483 <include name="**/*.build" />
484 <include name="**/*.sln" />
485 <include name="**/*.cs" />
486 <include name="**/*.ico" />
487 <include name="**/*.csproj" />
488 <include name="**/*.xml" />
489 <include name="**/*.config" />
490 <include name="**/*.lang" />
491 <include name="**/*.txt" />
492 <include name="**/*.inc" />
493 <include name="**/*.vm" />
494 <include name="**/*.resx" />
495 <include name="**/*.aspx" />
496 <include name="**/*.asax" />
497 <include name="*.snk" />
498 <exclude name="**/bin/*" />
499 <exclude name="**/bin/Debug/*" />
500 <exclude name="**/bin/Release/*" />
501 <exclude name="**/obj/*" />
502 <exclude name="**.user" />
503 <exclude name="**/_Resharper.*/*" />
504 </fileset>
505 </zip>
506 <zip zipfile="${root.dir}/samplesforwebsite/MonoRail.AuthenticationUsingForms.zip">
507 <fileset basedir="${root.dir}/Samples/MonoRail/AuthenticationUsingForms">
508 <include name="**/*.build" />
509 <include name="**/*.sln" />
510 <include name="**/*.cs" />
511 <include name="**/*.ico" />
512 <include name="**/*.csproj" />
513 <include name="**/*.xml" />
514 <include name="**/*.config" />
515 <include name="**/*.lang" />
516 <include name="**/*.txt" />
517 <include name="**/*.inc" />
518 <include name="**/*.vm" />
519 <include name="**/*.resx" />
520 <include name="**/*.aspx" />
521 <include name="**/*.asax" />
522 <include name="*.snk" />
523 <exclude name="**/bin/*" />
524 <exclude name="**/bin/Debug/*" />
525 <exclude name="**/bin/Release/*" />
526 <exclude name="**/obj/*" />
527 <exclude name="**.user" />
528 <exclude name="**/_Resharper.*/*" />
529 </fileset>
530 </zip>
531 <zip zipfile="${root.dir}/samplesforwebsite/MonoRail.LocalizationSample.zip">
532 <fileset basedir="${root.dir}/Samples/MonoRail/LocalizationSample">
533 <include name="**/*.build" />
534 <include name="**/*.sln" />
535 <include name="**/*.cs" />
536 <include name="**/*.ico" />
537 <include name="**/*.csproj" />
538 <include name="**/*.xml" />
539 <include name="**/*.config" />
540 <include name="**/*.lang" />
541 <include name="**/*.txt" />
542 <include name="**/*.inc" />
543 <include name="**/*.vm" />
544 <include name="**/*.resx" />
545 <include name="**/*.aspx" />
546 <include name="**/*.asax" />
547 <include name="*.snk" />
548 <exclude name="**/bin/*" />
549 <exclude name="**/bin/Debug/*" />
550 <exclude name="**/bin/Release/*" />
551 <exclude name="**/obj/*" />
552 <exclude name="**.user" />
553 <exclude name="**/_Resharper.*/*" />
554 </fileset>
555 </zip>
556 <zip zipfile="${root.dir}/samplesforwebsite/MonoRail.FormHelperSample.zip">
557 <fileset basedir="${root.dir}/Samples/MonoRail/FormHelperSample">
558 <include name="**/*.build" />
559 <include name="**/*.sln" />
560 <include name="**/*.cs" />
561 <include name="**/*.ico" />
562 <include name="**/*.csproj" />
563 <include name="**/*.xml" />
564 <include name="**/*.config" />
565 <include name="**/*.lang" />
566 <include name="**/*.txt" />
567 <include name="**/*.inc" />
568 <include name="**/*.vm" />
569 <include name="**/*.resx" />
570 <include name="**/*.aspx" />
571 <include name="**/*.asax" />
572 <include name="*.snk" />
573 <exclude name="**/bin/*" />
574 <exclude name="**/bin/Debug/*" />
575 <exclude name="**/bin/Release/*" />
576 <exclude name="**/obj/*" />
577 <exclude name="**.user" />
578 <exclude name="**/_Resharper.*/*" />
579 </fileset>
580 </zip>
582 <zip zipfile="${root.dir}/samplesforwebsite/MonoRail.GettingStartedSampleVS2003.zip">
583 <fileset basedir="${root.dir}/Samples/MonoRail/GettingStartedSampleVS2003">
584 <include name="**/*.build" />
585 <include name="**/*.sln" />
586 <include name="**/*.cs" />
587 <include name="**/*.ico" />
588 <include name="**/*.csproj" />
589 <include name="**/*.xml" />
590 <include name="**/*.config" />
591 <include name="**/*.lang" />
592 <include name="**/*.txt" />
593 <include name="**/*.inc" />
594 <include name="**/*.vm" />
595 <include name="**/*.resx" />
596 <include name="**/*.aspx" />
597 <include name="**/*.asax" />
598 <include name="*.snk" />
599 <exclude name="**/bin/*" />
600 <exclude name="**/bin/Debug/*" />
601 <exclude name="**/bin/Release/*" />
602 <exclude name="**/obj/*" />
603 <exclude name="**.user" />
604 <exclude name="**/_Resharper.*/*" />
605 </fileset>
606 </zip>
608 <zip zipfile="${root.dir}/samplesforwebsite/MonoRail.GettingStartedSampleVS2005.zip">
609 <fileset basedir="${root.dir}/Samples/MonoRail/GettingStartedSampleVS2005">
610 <include name="**/*.build" />
611 <include name="**/*.sln" />
612 <include name="**/*.cs" />
613 <include name="**/*.ico" />
614 <include name="**/*.csproj" />
615 <include name="**/*.xml" />
616 <include name="**/*.config" />
617 <include name="**/*.lang" />
618 <include name="**/*.txt" />
619 <include name="**/*.inc" />
620 <include name="**/*.vm" />
621 <include name="**/*.resx" />
622 <include name="**/*.aspx" />
623 <include name="**/*.asax" />
624 <include name="*.snk" />
625 <exclude name="**/bin/*" />
626 <exclude name="**/bin/Debug/*" />
627 <exclude name="**/bin/Release/*" />
628 <exclude name="**/obj/*" />
629 <exclude name="**.user" />
630 <exclude name="**/_Resharper.*/*" />
631 </fileset>
632 </zip>
634 <zip zipfile="${root.dir}/samplesforwebsite/MonoRail.DynActProvSample.zip">
635 <fileset basedir="${root.dir}/Samples/MonoRail/DynActProvSample">
636 <include name="**/*.build" />
637 <include name="**/*.sln" />
638 <include name="**/*.cs" />
639 <include name="**/*.ico" />
640 <include name="**/*.csproj" />
641 <include name="**/*.xml" />
642 <include name="**/*.config" />
643 <include name="**/*.lang" />
644 <include name="**/*.txt" />
645 <include name="**/*.inc" />
646 <include name="**/*.vm" />
647 <include name="**/*.resx" />
648 <include name="**/*.aspx" />
649 <include name="**/*.asax" />
650 <include name="*.snk" />
651 <exclude name="**/bin/*" />
652 <exclude name="**/bin/Debug/*" />
653 <exclude name="**/bin/Release/*" />
654 <exclude name="**/obj/*" />
655 <exclude name="**.user" />
656 <exclude name="**/_Resharper.*/*" />
657 </fileset>
658 </zip>
661 <zip zipfile="${root.dir}/samplesforwebsite/Windsor.TimeTracking.zip">
662 <fileset basedir="${root.dir}/Samples/InversionOfControl/TimeTracking">
663 <include name="**/*.build" />
664 <include name="**/*.sln" />
665 <include name="**/*.cs" />
666 <include name="**/*.ico" />
667 <include name="**/*.csproj" />
668 <include name="**/*.xml" />
669 <include name="**/*.config" />
670 <include name="**/*.lang" />
671 <include name="**/*.txt" />
672 <include name="**/*.inc" />
673 <include name="**/*.vm" />
674 <include name="**/*.resx" />
675 <include name="**/*.aspx" />
676 <include name="**/*.asax" />
677 <include name="*.snk" />
678 <exclude name="**/bin/*" />
679 <exclude name="**/bin/Debug/*" />
680 <exclude name="**/bin/Release/*" />
681 <exclude name="**/obj/*" />
682 <exclude name="**.user" />
683 <exclude name="**/_Resharper.*/*" />
684 </fileset>
685 </zip>
686 <zip zipfile="${root.dir}/samplesforwebsite/CustomTypeConverterSample.zip">
687 <fileset basedir="${root.dir}/Samples/InversionOfControl/CustomTypeConverterSample">
688 <include name="**/*.build" />
689 <include name="**/*.sln" />
690 <include name="**/*.cs" />
691 <include name="**/*.ico" />
692 <include name="**/*.csproj" />
693 <include name="**/*.xml" />
694 <include name="**/*.config" />
695 <include name="**/*.lang" />
696 <include name="**/*.txt" />
697 <include name="**/*.inc" />
698 <include name="**/*.vm" />
699 <include name="**/*.resx" />
700 <include name="**/*.aspx" />
701 <include name="**/*.asax" />
702 <include name="*.snk" />
703 <exclude name="**/bin/*" />
704 <exclude name="**/bin/Debug/*" />
705 <exclude name="**/bin/Release/*" />
706 <exclude name="**/obj/*" />
707 <exclude name="**.user" />
708 <exclude name="**/_Resharper.*/*" />
709 </fileset>
710 </zip>
711 <zip zipfile="${root.dir}/samplesforwebsite/FacilitySample2.zip">
712 <fileset basedir="${root.dir}/Samples/InversionOfControl/ExtendingSample2">
713 <include name="**/*.build" />
714 <include name="**/*.sln" />
715 <include name="**/*.cs" />
716 <include name="**/*.ico" />
717 <include name="**/*.csproj" />
718 <include name="**/*.xml" />
719 <include name="**/*.config" />
720 <include name="**/*.lang" />
721 <include name="**/*.txt" />
722 <include name="**/*.inc" />
723 <include name="**/*.vm" />
724 <include name="**/*.resx" />
725 <include name="**/*.aspx" />
726 <include name="**/*.asax" />
727 <include name="*.snk" />
728 <exclude name="**/bin/*" />
729 <exclude name="**/bin/Debug/*" />
730 <exclude name="**/bin/Release/*" />
731 <exclude name="**/obj/*" />
732 <exclude name="**.user" />
733 <exclude name="**/_Resharper.*/*" />
734 </fileset>
735 </zip>
736 <zip zipfile="${root.dir}/samplesforwebsite/GettingStartedPart1.zip">
737 <fileset basedir="${root.dir}/Samples/InversionOfControl/GettingStarted/GettingStartedPart1">
738 <include name="**/*.build" />
739 <include name="**/*.sln" />
740 <include name="**/*.cs" />
741 <include name="**/*.ico" />
742 <include name="**/*.csproj" />
743 <include name="**/*.xml" />
744 <include name="**/*.config" />
745 <include name="**/*.lang" />
746 <include name="**/*.txt" />
747 <include name="**/*.inc" />
748 <include name="**/*.resx" />
749 <include name="*.snk" />
750 <exclude name="**/bin/*" />
751 <exclude name="**/bin/Debug/*" />
752 <exclude name="**/bin/Release/*" />
753 <exclude name="**/obj/*" />
754 <exclude name="**.user" />
755 <exclude name="**/_Resharper.*/*" />
756 </fileset>
757 </zip>
759 <zip zipfile="${root.dir}/samplesforwebsite/KernelInOneEndPoint.Sample.zip">
760 <fileset basedir="${root.dir}/Samples/Facilities/Remoting/KernelInOneEndPoint">
761 <include name="**/*.build" />
762 <include name="**/*.sln" />
763 <include name="**/*.cs" />
764 <include name="**/*.ico" />
765 <include name="**/*.csproj" />
766 <include name="**/*.xml" />
767 <include name="**/*.config" />
768 <include name="**/*.txt" />
769 <include name="**/*.vm" />
770 <include name="**/*.resx" />
771 <include name="*.snk" />
772 <exclude name="**/bin/*" />
773 <exclude name="**/bin/Debug/*" />
774 <exclude name="**/bin/Release/*" />
775 <exclude name="**/obj/*" />
776 <exclude name="**.user" />
777 <exclude name="**/_Resharper.*/*" />
778 </fileset>
779 </zip>
780 <zip zipfile="${root.dir}/samplesforwebsite/KernelOnBothEndPoints.Sample.zip">
781 <fileset basedir="${root.dir}/Samples/Facilities/Remoting/KernelOnBothEndPoints">
782 <include name="**/*.build" />
783 <include name="**/*.sln" />
784 <include name="**/*.cs" />
785 <include name="**/*.ico" />
786 <include name="**/*.csproj" />
787 <include name="**/*.xml" />
788 <include name="**/*.config" />
789 <include name="**/*.txt" />
790 <include name="**/*.vm" />
791 <include name="**/*.resx" />
792 <include name="*.snk" />
793 <exclude name="**/bin/*" />
794 <exclude name="**/bin/Debug/*" />
795 <exclude name="**/bin/Release/*" />
796 <exclude name="**/obj/*" />
797 <exclude name="**.user" />
798 <exclude name="**/_Resharper.*/*" />
799 </fileset>
800 </zip>
801 <zip zipfile="${root.dir}/samplesforwebsite/ContainersConnected.Sample.zip">
802 <fileset basedir="${root.dir}/Samples/Facilities/Remoting/ContainersConnected">
803 <include name="**/*.build" />
804 <include name="**/*.sln" />
805 <include name="**/*.cs" />
806 <include name="**/*.ico" />
807 <include name="**/*.csproj" />
808 <include name="**/*.xml" />
809 <include name="**/*.config" />
810 <include name="**/*.txt" />
811 <include name="**/*.vm" />
812 <include name="**/*.resx" />
813 <include name="*.snk" />
814 <exclude name="**/bin/*" />
815 <exclude name="**/bin/Debug/*" />
816 <exclude name="**/bin/Release/*" />
817 <exclude name="**/obj/*" />
818 <exclude name="**.user" />
819 <exclude name="**/_Resharper.*/*" />
820 </fileset>
821 </zip>
822 </target>
824 <target name="zip-samples">
825 <zip zipfile="${build.base.dir}/ActiveRecord-Samples.zip">
826 <fileset basedir="${root.dir}/Samples/ActiveRecord">
827 <include name="**/*.build" />
828 <include name="**/*.sln" />
829 <include name="**/*.cs" />
830 <include name="**/*.ico" />
831 <include name="**/*.csproj" />
832 <include name="**/*.xml" />
833 <include name="**/*.config" />
834 <include name="**/*.lang" />
835 <include name="**/*.txt" />
836 <include name="**/*.inc" />
837 <include name="**/*.vm" />
838 <include name="**/*.resx" />
839 <include name="**/*.aspx" />
840 <include name="**/*.asax" />
841 <include name="**/*.sql" />
842 <include name="*.snk" />
843 <exclude name="**/bin/*" />
844 <exclude name="**/bin/Debug/*" />
845 <exclude name="**/bin/Release/*" />
846 <exclude name="**/obj/*" />
847 <exclude name="**.user" />
848 <exclude name="**/_Resharper.*/*" />
849 </fileset>
850 </zip>
851 <zip zipfile="${build.base.dir}/Facilities-Samples.zip">
852 <fileset basedir="${root.dir}/Samples/Facilities">
853 <include name="**/*.build" />
854 <include name="**/*.sln" />
855 <include name="**/*.cs" />
856 <include name="**/*.ico" />
857 <include name="**/*.csproj" />
858 <include name="**/*.xml" />
859 <include name="**/*.config" />
860 <include name="**/*.lang" />
861 <include name="**/*.txt" />
862 <include name="**/*.inc" />
863 <include name="**/*.vm" />
864 <include name="*.snk" />
865 <exclude name="**/bin/*" />
866 <exclude name="**/bin/Debug/*" />
867 <exclude name="**/bin/Release/*" />
868 <exclude name="**/obj/*" />
869 <exclude name="**.user" />
870 <exclude name="**/_Resharper.*/*" />
871 </fileset>
872 </zip>
873 <zip zipfile="${build.base.dir}/InversionOfControl-Samples.zip">
874 <fileset basedir="${root.dir}/Samples/InversionOfControl">
875 <include name="**/*.build" />
876 <include name="**/*.sln" />
877 <include name="**/*.cs" />
878 <include name="**/*.ico" />
879 <include name="**/*.csproj" />
880 <include name="**/*.xml" />
881 <include name="**/*.config" />
882 <include name="**/*.lang" />
883 <include name="**/*.txt" />
884 <include name="**/*.inc" />
885 <include name="**/*.vm" />
886 <include name="*.snk" />
887 <exclude name="**/bin/*" />
888 <exclude name="**/bin/Debug/*" />
889 <exclude name="**/bin/Release/*" />
890 <exclude name="**/obj/*" />
891 <exclude name="**.user" />
892 <exclude name="**/_Resharper.*/*" />
893 </fileset>
894 </zip>
895 <zip zipfile="${build.base.dir}/MonoRail-Samples.zip">
896 <fileset basedir="${root.dir}/Samples/MonoRail">
897 <include name="**/*.build" />
898 <include name="**/*.sln" />
899 <include name="**/*.cs" />
900 <include name="**/*.css" />
901 <include name="**/*.gif" />
902 <include name="**/*.png" />
903 <include name="**/*.jpg" />
904 <include name="**/*.js" />
905 <include name="**/*.ico" />
906 <include name="**/*.csproj" />
907 <include name="**/*.xml" />
908 <include name="**/*.config" />
909 <include name="**/*.lang" />
910 <include name="**/*.txt" />
911 <include name="**/*.inc" />
912 <include name="**/*.vm" />
913 <include name="*.snk" />
914 <exclude name="**/bin/*" />
915 <exclude name="**/bin/Debug/*" />
916 <exclude name="**/bin/Release/*" />
917 <exclude name="**/obj/*" />
918 <exclude name="**.user" />
919 <exclude name="**/_Resharper.*/*" />
920 </fileset>
921 </zip>
922 <zip zipfile="${build.base.dir}/Castle-Samples.zip">
923 <fileset basedir="${root.dir}/Samples/Castle">
924 <include name="**/*.build" />
925 <include name="**/*.sln" />
926 <include name="**/*.cs" />
927 <include name="**/*.ico" />
928 <include name="**/*.csproj" />
929 <include name="**/*.xml" />
930 <include name="**/*.config" />
931 <include name="**/*.lang" />
932 <include name="**/*.txt" />
933 <include name="**/*.inc" />
934 <include name="**/*.vm" />
935 <include name="*.snk" />
936 <exclude name="**/bin/*" />
937 <exclude name="**/bin/Debug/*" />
938 <exclude name="**/bin/Release/*" />
939 <exclude name="**/obj/*" />
940 <exclude name="**.user" />
941 <exclude name="**/_Resharper.*/*" />
942 </fileset>
943 </zip>
944 </target>
946 <target name="zip-source">
947 <zip zipfile="${build.base.dir}/castle-sourcecode.zip">
948 <fileset basedir="${root.dir}">
949 <include name="**/*.build" />
950 <include name="**/*.sln" />
951 <include name="**/*.cs" />
952 <include name="**/*.ico" />
953 <include name="**/*.csproj" />
954 <include name="**/*.xml" />
955 <include name="**/*.config" />
956 <include name="**/*.lang" />
957 <include name="**/*.txt" />
958 <include name="**/*.inc" />
959 <include name="**/*.vm" />
960 <include name="**/*.gif" />
961 <include name="**/*.resx" />
962 <include name="**/*.boo" />
963 <include name="**/*.booproj" />
964 <include name="**/*.prjx" />
965 <include name="**/*.cmbx" />
966 <exclude name="**/obj/" />
967 <exclude name="**/obj/**/*.*" />
968 <exclude name="**/bin*/**/*.*" />
969 <exclude name="**/temp/**/*.*" />
970 <exclude name="**/*.user" />
971 <exclude name="**/_ReSharper.*" />
972 <exclude name="**/_ReSharper.*/**/*.*" />
973 <exclude name="**/*.suo" />
974 <exclude name="SharedLibs/**/*.*" />
975 <exclude name="Samples/**/*.*" />
976 <exclude name="Experiments/**/*.*" />
977 <exclude name="build/**/*.*" />
978 <exclude name="Rook/**/*.*" />
979 <exclude name="setup/*.*" />
980 <exclude name="Tools/VSNetWizards/**/*.*" />
981 <exclude name="Tools/SubversionHooks/**/*.*" />
982 <exclude name="Tools/ManagedExtensions/**/*.*" />
983 <exclude name="Tools/Castle.DynamicProxy2/**/*.*" />
984 <exclude name="Tools/DynamicProxy2/**/*.*" />
985 </fileset>
986 </zip>
987 </target>
989 <description>Documentation generation.</description><property name="root.dir" value="." />
990 <property name="doc.dir" value="${root.dir}/docs" />
991 <property name="tempBin.dir" value="${doc.dir}/bin"/>
992 <property name="outputDocs.file" value="Castle"/>
994 <description>Docs generation properties.</description>
995 <property name="ShowMissing" value="false"/>
996 <property name="ShowPrivate" value="false"/>
997 <property name="OutputTarget" value="HTMLHelp"/>
999 <description>Generates documentation with default properties.</description>
1000 <target name="releaseDocs" depends="init,cleanup">
1001 <call target="copyFilesToDocument"/>
1002 <call target="generateReleaseDocs"/>
1003 </target>
1005 <description>Generates documentation for developers, with all missing information indicated and private members visible.</description>
1006 <target name="devDocs" depends="cleanup">
1007 <property name="ShowMissing" value="true"/>
1008 <property name="ShowPrivate" value="true"/>
1009 <property name="outputDocs.file" value="CastleDev"/>
1010 <call target="copyFilesToDocument"/>
1011 <call target="generateReleaseDocs"/>
1012 </target>
1014 <description>Generates documentation for release.</description>
1015 <target name="generateReleaseDocs">
1016 <ndoc failonerror="true">
1017 <assemblies basedir="${tempBin.dir}">
1018 <include name="Castle.*.dll"/>
1019 </assemblies>
1020 <referencepaths>
1021 <include name="ActiveRecord/lib"/>
1022 <include name="AspectSharp/bin"/>
1023 <include name="Monorail/lib"/>
1024 <include name="Tools/DynamicProxy/bin"/>
1025 <include name="Tools/NVelocity/bin"/>
1027 <!-- Components -->
1028 <include name="SharedLibs/Prevalence"/>
1029 <include name="SharedLibs/Db4o/net-1.1"/>
1030 <include name="SharedLibs/IBatis"/>
1031 <include name="SharedLibs/NHibernate"/>
1032 <include name="SharedLibs/boo"/>
1033 <include name="SharedLibs/cassini"/>
1034 <include name="SharedLibs/log4net"/>
1035 <include name="SharedLibs/netron"/>
1036 <include name="SharedLibs/Nlog"/>
1037 <include name="SharedLibs/log4net"/>
1038 <include name="SharedLibs/Nvelocity"/>
1039 <include name="SharedLibs/stringtemplate/net-1.1"/>
1040 </referencepaths>
1041 <documenters>
1042 <documenter name="MSDN">
1043 <property name="OutputTarget" value="${OutputTarget}" />
1044 <property name="Preliminary" value="true" />
1045 <property name="BinaryTOC" value="true" />
1046 <property name="CleanIntermediates" value="true" />
1047 <property name="SdkLinksOnWeb" value="true" />
1049 <property name="OutputDirectory" value="${doc.dir}" />
1050 <property name="HtmlHelpName" value="${outputDocs.file}" />
1051 <property name="IncludeFavorites" value="True" />
1052 <property name="SplitTOCs" value="False" />
1054 <property name="Title" value="Castle API documentation" />
1055 <property name="DefaulTOC" value="Castle.MicroKernel" />
1057 <property name="ShowVisualBasic" value="True" />
1058 <property name="ShowMissingSummaries" value="${ShowMissing}" />
1059 <property name="ShowMissingRemarks" value="${ShowMissing}" />
1060 <property name="ShowMissingParams" value="${ShowMissing}" />
1061 <property name="ShowMissingReturns" value="${ShowMissing}" />
1062 <property name="ShowMissingValues" value="${ShowMissing}" />
1063 <property name="DocumentEmptyNamespaces" value="${ShowMissing}" />
1065 <property name="AutoPropertyBackerSummaries" value="true" />
1066 <property name="AutoDocumentConstructors" value="true" />
1067 <property name="DocumentProtected" value="True" />
1068 <property name="DocumentInternals" value="${ShowPrivate}" />
1069 <property name="DocumentPrivates" value="${ShowPrivate}" />
1071 <property name="IncludeAssemblyVersion" value="True" />
1072 <property name="CopyrightText" value="Copyright 2004,2006 - Castle Project (original author or authors)" />
1073 <property name="CopyrightHref" value="http://www.castleproject.org" />
1074 </documenter>
1075 </documenters>
1076 </ndoc>
1077 </target>
1079 <description>Copies all files to be documented to a single location to speed up the documentation process.</description>
1080 <target name="copyFilesToDocument">
1081 <foreach item="Folder" property="foldername">
1082 <in>
1083 <!-- Hardcode projects folders to speed up assemblies search -->
1084 <items>
1085 <include name="${build.dir}"/>
1086 </items>
1087 </in>
1088 <do>
1089 <echo message="${foldername}" />
1091 <foreach item="File" property="file">
1092 <in>
1093 <items>
1094 <include name="${foldername}/Castle.*.dll"/>
1095 <include name="${foldername}/AspectSharp*.dll"/>
1096 <include name="${foldername}/NVelocity.dll"/>
1097 <exclude name="Castle.*.Tests.dll"/>
1098 </items>
1099 </in>
1100 <do>
1101 <property name="xml.file" value="${path::change-extension( file, 'xml' )}"/>
1102 <copy todir="${tempBin.dir}" if="${file::exists( xml.file )}" flatten="true">
1103 <fileset>
1104 <include name="${file}"/>
1105 <include name="${xml.file}"/>
1106 </fileset>
1107 </copy>
1108 </do>
1109 </foreach>
1110 </do>
1111 </foreach>
1112 </target>
1114 <description>Cleans up prior to documentation generation.</description>
1115 <target name="cleanup">
1116 <delete>
1117 <fileset>
1118 <include name="${doc.dir}/**"/>
1119 <exclude name="**/*.chm"/>
1120 </fileset>
1121 </delete>
1122 </target>
1124 </project>