Re: nant multitarget support?
Richard Birkby <[email protected]> Sun, 9 Sep 2012 19:27:20 +0100
| Newsgroups | gmane.comp.windows.dotnet.nant.user |
|---|---|
| Message-ID | <CAO+Vd0iq7Qo7=DHk_qivnkTpbEh7o3v=fxov1tYv3BquB=8Aeg@mail.gmail.com> |
--===============2700675091698010166== Content-Type: multipart/alternative; boundary=20cf3079be54d7fa5704c948fd92 --20cf3079be54d7fa5704c948fd92 Content-Type: text/plain; charset=ISO-8859-1 I find the MSBuild task from NantContrib works perfectly. Richard On Sun, Sep 9, 2012 at 10:52 AM, Bevan Arps <[email protected]> wrote: > Fwiw, I've found the <csc> task too limiting. > > Instead I use <exec> to run msbuild for either the whole solution or a > specific project. This approach handles your scenario of using the C# 4.0 > compiler to target .Net 3.5. > > Keep smiling > Bevan. > > ------------------------------ > From: Stefan Arn > Sent: 9/5/2012 9:18 PM > > To: '[email protected]' > Subject: [NAnt-users] nant multitarget support? > > I have C# code with 4.0 language features that need a C#4.0 compiler to > compile. But the resulting code should run on .NET Framework 3.5. This is > possible with VS2010 by simply selecting the target framework 3.5. But I > had no luck with NAnt.**** > > ** ** > > Is it possible to use the 4.0 compiler and target the 3.5 framework? I > already tried to change the framework configuration in NAnt.exe.config > without success. I also looked around for an option to specify the compiler > exe file on the csc NAnt task.**** > > ** ** > > What should I do? Any suggestions?**** > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > NAnt-users mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/nant-users > > --20cf3079be54d7fa5704c948fd92 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable I find the MSBuild task from NantContrib works perfectly.<div><br></div><di= v><br></div><div>Richard<br><br><div class=3D"gmail_quote">On Sun, Sep 9, 2= 012 at 10:52 AM, Bevan Arps <span dir=3D"ltr"><<a href=3D"mailto:bevan.a= [email protected]" target=3D"_blank">[email protected]</a>></span> = wrote:<br> <blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1p= x #ccc solid;padding-left:1ex"><div lang=3D"DE-CH" vlink=3D"purple" link=3D= "blue"><div><div style=3D"font-family:Calibri,sans-serif;font-size:11pt">Fw= iw, I've found the <csc> task too limiting. <br> <br>Instead I use <exec> to run msbuild for either the whole solution= or a specific project. This approach handles your scenario of using the C#= 4.0 compiler to target .Net 3.5.<br><br>Keep smiling<br>Bevan.<br> <br> </div></div><hr><span style=3D"font-family:Tahoma,sans-serif;font-size:10pt= ;font-weight:bold">From: </span><span style=3D"font-family:Tahoma,sans-seri= f;font-size:10pt">Stefan Arn</span><br><span style=3D"font-family:Tahoma,sa= ns-serif;font-size:10pt;font-weight:bold">Sent: </span><span style=3D"font-= family:Tahoma,sans-serif;font-size:10pt">9/5/2012 9:18 PM</span><div class= =3D"im"> <br><span style=3D"font-family:Tahoma,sans-serif;font-size:10pt;font-weight= :bold">To: </span><span style=3D"font-family:Tahoma,sans-serif;font-size:10= pt">'<a href=3D"mailto:[email protected]" target=3D"_bla= nk">[email protected]</a>'</span><br> <span style=3D"font-family:Tahoma,sans-serif;font-size:10pt;font-weight:bol= d">Subject: </span><span style=3D"font-family:Tahoma,sans-serif;font-size:1= 0pt">[NAnt-users] nant multitarget support?</span><br><br><div><p class=3D"= MsoNormal"> I have C# code with 4.0 language features that need a C#4.0 compiler to com= pile. But the resulting code should run on .NET Framework 3.5. This is poss= ible with VS2010 by simply selecting the target framework 3.5. But I had no= luck with NAnt.<u></u><u></u></p> <p class=3D"MsoNormal"><u></u>=A0<u></u></p><p class=3D"MsoNormal">Is it po= ssible to use the 4.0 compiler and target the 3.5 framework? I already trie= d to change the framework configuration in NAnt.exe.config without success.= I also looked around for an option to specify the compiler exe file on the= csc NAnt task.<u></u><u></u></p> <p class=3D"MsoNormal"><u></u>=A0<u></u></p><p class=3D"MsoNormal">What sho= uld I do? Any suggestions?<u></u><u></u></p></div></div></div><br>---------= ---------------------------------------------------------------------<br> Live Security Virtual Conference<br> Exclusive live event will cover all the ways today's security and<br> threat landscape has changed and how IT managers can respond. Discussions<b= r> will include endpoint security, mobile security and the latest in malware<b= r> threats. <a href=3D"http://www.accelacomm.com/jaw/sfrnl04242012/114/5012226= 3/" target=3D"_blank">http://www.accelacomm.com/jaw/sfrnl04242012/114/50122= 263/</a><br>_______________________________________________<br> NAnt-users mailing list<br> <a href=3D"mailto:[email protected]">[email protected]= forge.net</a><br> <a href=3D"https://lists.sourceforge.net/lists/listinfo/nant-users" target= =3D"_blank">https://lists.sourceforge.net/lists/listinfo/nant-users</a><br> <br></blockquote></div><br></div> --20cf3079be54d7fa5704c948fd92-- --===============2700675091698010166== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ --===============2700675091698010166== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ NAnt-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/nant-users --===============2700675091698010166==--