**** Merged from MCS ****
[mono-project.git] / mcs / nant / src / Tasks / CscTask.cs
blob202082bcd8d4f7bdf0b64c37a088720218faec2f
1 // NAnt - A .NET build tool
2 // Copyright (C) 2001 Gerry Shaw
3 //
4 // This program is free software; you can redistribute it and/or modify
5 // it under the terms of the GNU General Public License as published by
6 // the Free Software Foundation; either version 2 of the License, or
7 // (at your option) any later version.
8 //
9 // This program is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 // GNU General Public License for more details.
14 // You should have received a copy of the GNU General Public License
15 // along with this program; if not, write to the Free Software
16 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18 // Gerry Shaw (gerry_shaw@yahoo.com)
19 // Mike Krueger (mike@icsharpcode.net)
21 namespace SourceForge.NAnt {
23 using System;
24 using System.IO;
26 [TaskName("csc")]
27 public class CscTask : CompilerBase {
29 // C# specific compiler options
30 [TaskAttribute("doc")]
31 string _doc = null;
33 protected override void WriteOptions(TextWriter writer) {
34 WriteOption(writer, "fullpaths");
35 if (_doc != null) {
36 WriteOption(writer, "doc", _doc);
40 protected override bool NeedsCompiling() {
41 // TODO: add checks for any referenced files OR return false to always compile
42 return base.NeedsCompiling();