Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8338621
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T04:38:56+00:00 2026-06-09T04:38:56+00:00

I’m curious if it’s possible to use Nant to target the .NET 4.5 using

  • 0

I’m curious if it’s possible to use Nant to target the .NET 4.5 using the C# 5.0 compiler. As of right now, the latest version only states support for .NET 4.0.

I tried downloading the source and building the .sln with msbuild after installing the .net 4.5 framework, but that yielded a large number of errors.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T04:38:59+00:00Added an answer on June 9, 2026 at 4:38 am

    Might be best to hit NAnt mailing list with your findings. It’s not that active, but NAnt will definitely get an update to support the new framework. Problem is, Microsoft usually changes file locations with new release and registry keys pointing to those files change as well, so it’s not really possible to support it before there’s an actual release from Microsoft. for tests.

    I have it running currently, targeting 4.5. In NAnt.exe.config, change the <startup> node:

    <startup>
        <!-- .NET Framework 4.5 -->
        <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5"/>
        <!-- .NET Framework 4.0 -->
        <supportedRuntime version="v4.0.30319" />
        <!-- .NET Framework 2.0 -->
        <supportedRuntime version="v2.0.50727" />
    </startup>
    

    I’ve also added a new <framework> node (copy of net-4.0 except for reference assemblies):

    <framework
        name="net-4.5"
        family="net"
        version="4.5"
        description="Microsoft .NET Framework 4.5"
        sdkdirectory="${sdkInstallRoot}"
        frameworkdirectory="${path::combine(installRoot, 'v4.0.30319')}"
        frameworkassemblydirectory="${path::combine(installRoot, 'v4.0.30319')}"
        clrversion="4.0.30319"
        clrtype="Desktop"
        vendor="Microsoft"
          >
      <runtime>
        <probing-paths>
          <directory name="lib/common/2.0" />
          <directory name="lib/common/neutral" />
        </probing-paths>
        <modes>
          <strict>
            <environment>
              <variable name="COMPLUS_VERSION" value="v4.0.30319" />
            </environment>
          </strict>
        </modes>
      </runtime>
      <reference-assemblies basedir="${path::combine(installRoot, 'v4.0.30319')}">
        <include name="Accessibility.dll" />
        <include name="Microsoft.Build.Conversion.v4.0.dll" />
        <include name="Microsoft.Build.dll" />
        <include name="Microsoft.Build.Engine.dll" />
        <include name="Microsoft.Build.Framework.dll" />
        <include name="Microsoft.Build.Tasks.v4.0.dll" />
        <include name="Microsoft.Build.Utilities.v4.0.dll" />
        <include name="Microsoft.CSharp.dll" />
        <include name="Microsoft.Data.Entity.Build.Tasks.dll" />
        <include name="Microsoft.JScript.dll" />
        <include name="Microsoft.Transactions.Bridge.dll" />
        <include name="Microsoft.Transactions.Bridge.Dtc.dll" />
        <include name="Microsoft.VisualBasic.Activities.Compiler.dll" />
        <include name="Microsoft.VisualBasic.Compatibility.Data.dll" />
        <include name="Microsoft.VisualBasic.Compatibility.dll" />
        <include name="Microsoft.VisualBasic.dll" />
        <include name="Microsoft.VisualC.dll" />
        <include name="Microsoft.VisualC.STLCLR.dll" />
        <include name="mscorlib.dll" />
        <include name="System.Activities.Core.Presentation.dll" />
        <include name="System.Activities.dll" />
        <include name="System.Activities.DurableInstancing.dll" />
        <include name="System.Activities.Presentation.dll" />
        <include name="System.AddIn.Contract" />
        <include name="System.AddIn.dll" />
        <include name="System.ComponentModel.Composition.dll" />
        <include name="System.ComponentModel.DataAnnotations.dll" />
        <include name="System.Configuration.dll" />
        <include name="System.Configuration.Install.dll" />
        <include name="System.Core.dll" />
        <include name="System.Data.DataSetExtensions.dll" />
        <include name="System.Data.dll" />
        <include name="System.Data.Entity.Design.dll" />
        <include name="System.Data.Entity.dll" />
        <include name="System.Data.Linq.dll" />
        <include name="System.Data.OracleClient.dll" />
        <include name="System.Data.Services.Client.dll" />
        <include name="System.Data.Services.Design.dll" />
        <include name="System.Data.Services.dll" />
        <include name="System.Data.SqlXml.dll" />
        <include name="System.Deployment.dll" />
        <include name="System.Design.dll" />
        <include name="System.Device.dll" />
        <include name="System.DirectoryServices.dll" />
        <include name="System.DirectoryServices.Protocols.dll" />
        <include name="System.dll" />
        <include name="System.Drawing.Design.dll" />
        <include name="System.Drawing.dll" />
        <include name="System.Dynamic.dll" />
        <include name="System.EnterpriseServices.dll" />
        <include name="System.EnterpriseServices.Thunk.dll" />
        <include name="System.EnterpriseServices.Wrapper.dll" />
        <include name="System.IdentityModel.dll" />
        <include name="System.IdentityModel.Selectors.dll" />
        <include name="System.IO.Log.dll" />
        <include name="System.Management.dll" />
        <include name="System.Management.Instrumentation.dll" />
        <include name="System.Messaging.dll" />
        <include name="System.Net.dll" />
        <include name="System.Numerics.dll" />
        <include name="System.Runtime.Caching.dll" />
        <include name="System.Runtime.DurableInstancing.dll" />
        <include name="System.Runtime.Remoting.dll" />
        <include name="System.Runtime.Serialization.dll" />
        <include name="System.Runtime.Serialization.Formatters.Soap.dll" />
        <include name="System.Security.dll" />
        <include name="System.ServiceModel.Activation.dll" />
        <include name="System.ServiceModel.Activities.dll" />
        <include name="System.ServiceModel.Channels.dll" />
        <include name="System.ServiceModel.Discovery.dll" />
        <include name="System.ServiceModel.dll" />
        <include name="System.ServiceModel.Routing.dll" />
        <include name="System.ServiceModel.ServiceMoniker40.dll" />
        <include name="System.ServiceModel.WasHosting.dll" />
        <include name="System.ServiceModel.Web.dll" />
        <include name="System.ServiceProcess.dll" />
        <include name="System.Transactions.dll" />
        <include name="System.Web.Abstractions.dll" />
        <include name="System.Web.ApplicationServices.dll" />
        <include name="System.Web.DataVisualization.Design.dll" />
        <include name="System.Web.DataVisualization.dll" />
        <include name="System.Web.dll" />
        <include name="System.Web.DynamicData.Design.dll" />
        <include name="System.Web.DynamicData.dll" />
        <include name="System.Web.Entity.Design.dll" />
        <include name="System.Web.Entity.dll" />
        <include name="System.Web.Extensions.Design.dll" />
        <include name="System.Web.Extensions.dll" />
        <include name="System.Web.Mobile.dll" />
        <include name="System.Web.RegularExpressions.dll" />
        <include name="System.Web.Routing.dll" />
        <include name="System.Web.Services.dll" />
        <include name="System.Windows.Forms.DataVisualization.Design.dll" />
        <include name="System.Windows.Forms.DataVisualization.dll" />
        <include name="System.Windows.Forms.dll" />
        <include name="System.Workflow.Activities.dll" />
        <include name="System.Workflow.ComponentModel.dll" />
        <include name="System.Workflow.Runtime.dll" />
        <include name="System.WorkflowServices.dll" />
        <include name="System.Xaml.dll" />
        <include name="System.Xaml.Hosting.dll" />
        <include name="System.Xml.dll" />
        <include name="System.Xml.Linq.dll" />
      </reference-assemblies>
      <!-- WPF Assemblies -->
      <reference-assemblies basedir="${path::combine(installRoot, 'v4.0.30319')}/WPF">
        <include name="NaturalLanguage6.dll" />
        <include name="NlsData0009.dll" />
        <include name="NlsLexicons0009.dll" />
        <include name="PenIMC.dll" />
        <include name="PresentationCore.dll" />
        <include name="PresentationFramework.Aero.dll" />
        <include name="PresentationFramework.Classic.dll" />
        <include name="PresentationFramework.dll" />
        <include name="PresentationFramework.Luna.dll" />
        <include name="PresentationFramework.Royale.dll" />
        <include name="PresentationHost_v0400.dll" />
        <include name="PresentationNative_v0400.dll" />
        <include name="PresentationUI.dll" />
        <include name="ReachFramework.dll" />
        <include name="System.Printing.dll" />
        <include name="System.Speech.dll" />
        <include name="System.Windows.Input.Manipulations.dll" />
        <include name="System.Windows.Presentation.dll" />
        <include name="UIAutomationClient.dll" />
        <include name="UIAutomationClientsideProviders.dll" />
        <include name="UIAutomationProvider.dll" />
        <include name="UIAutomationTypes.dll" />
        <include name="WindowsBase.dll" />
        <include name="WindowsFormsIntegration.dll" />
        <include name="wpfgfx_v0400.dll" />
        <include name="wpftxt_v0400.dll" />
      </reference-assemblies>
      <reference-assemblies basedir="${environment::get-folder-path('ProgramFiles')}/Reference Assemblies/Microsoft/Framework/.NETFramework/v4.5">
        <include name="Microsoft.Build.Conversion.v4.0.dll" />
        <include name="Microsoft.Build.dll" />
        <include name="Microsoft.Build.Engine.dll" />
        <include name="Microsoft.Build.Framework.dll" />
        <include name="Microsoft.Build.Tasks.v4.0.dll" />
        <include name="Microsoft.Build.Utilities.v4.0.dll" />
        <include name="Microsoft.CSharp.dll" />
        <include name="Microsoft.JScript.dll" />
        <include name="Microsoft.VisualBasic.Compatibility.Data.dll" />
        <include name="Microsoft.VisualBasic.Comptatibility.dll" />
        <include name="Microsoft.VisualBasic.dll" />
        <include name="Microsoft.VisualC.dll" />
        <include name="Microsoft.VisualC.STLCLR.dll" />
        <include name="mscorlib.dll" />
        <include name="PresentationBuildTasks.dll" />
        <include name="PresentationCore.dll" />
        <include name="WindowsBase.dll" />
        <include name="PresentationFramework.dll" />
        <include name="PresentationFramework.Aero.dll" />
        <include name="PresentationFramework.Classic.dll" />
        <include name="PresentationFramework.Luna.dll" />
        <include name="PresentationFramework.Royale.dll" />
        <include name="ReachFramework.dll" />
        <include name="System.Activities.Core.Presentation.dll" />
        <include name="System.Activities.dll" />
        <include name="System.Activities.DurableInstancing.dll" />
        <include name="System.Activities.Presentation.dll" />
        <include name="System.AddIn.Contract.dll" />
        <include name="System.AddIn.dll" />
        <include name="System.ComponentModel.Composition.dll" />
        <include name="System.ComponentModel.DataAnnotations.dll" />
        <include name="System.Configuration.dll" />
        <include name="System.Core.dll" />
        <include name="System.Data.DataSetExtension.dll" />
        <include name="System.Data.dll" />
        <include name="System.Data.Entity.Design.dll" />
        <include name="System.Data.Entity.dll" />
        <include name="System.Data.Linq.dll" />
        <include name="System.Data.OracleClient.dll" />
        <include name="System.Data.Services.Client.dll" />
        <include name="System.Data.Services.Design.dll" />
        <include name="System.Data.Services.dll" />
        <include name="System.Data.SqlXml.dll" />
        <include name="System.Deployment.dll" />
        <include name="System.Design.dll" />
        <include name="System.Device.dll" />
        <include name="System.DirectoryServices.AccountManagement.dll" />
        <include name="System.DirectoryServices.dll" />
        <include name="System.DirectoryServices.Protocols.dll" />
        <include name="System.dll" />
        <include name="System.Drawing.Design.dll" />
        <include name="System.Drawing.dll" />
        <include name="System.EnterpriseServices.dll" />
        <include name="System.EnterpriseServices.Thunk.dll" />
        <include name="System.EnterpriseServices.Wrapper.dll" />
        <include name="System.IdentityModel.dll" />
        <include name="System.IdentityModel.Selectors.dll" />
        <include name="System.IO.Log.dll" />
        <include name="System.Management.dll" />
        <include name="System.Management.Instrumentation.dll" />
        <include name="System.Messaging.dll" />
        <include name="System.Net.dll" />
        <include name="System.Numerics.dll" />
        <include name="System.Printing.dll" />
        <include name="System.Runtime.Caching.dll" />
        <include name="System.Runtime.DurableInstancing.dll" />
        <include name="System.Runtime.Remoting.dll" />
        <include name="System.Runtime.Serialization.dll" />
        <include name="System.Runtime.Serialization.Formatters.Soap.dll" />
        <include name="System.Security.dll" />
        <include name="System.ServiceModel.Activation.dll" />
        <include name="System.ServiceModel.Activities.dll" />
        <include name="System.ServiceModel.Channels.dll" />
        <include name="System.ServiceModel.Discovery.dll" />
        <include name="System.ServiceModel.dll" />
        <include name="System.ServiceModel.Routing.dll" />
        <include name="System.ServiceModel.Web.dll" />
        <include name="System.ServiceProcess.dll" />
        <include name="System.Speech.dll" />
        <include name="System.Transactions.dll" />
        <include name="System.Web.Abstractions.dll" />
        <include name="System.Web.ApplicationServices.dll" />
        <include name="System.Web.DataVisualization.Design.dll" />
        <include name="System.Web.DataVisualization.dll" />
        <include name="System.Web.dll" />
        <include name="System.Web.DynamicData.Design.dll" />
        <include name="System.Web.DynamicData.dll" />
        <include name="System.Web.Entity.Design.dll" />
        <include name="System.Web.Entity.dll" />
        <include name="System.Web.Extensions.Design.dll" />
        <include name="System.Web.Extensions.dll" />
        <include name="System.Web.Mobile.dll" />
        <include name="System.Web.RegularExpressions.dll" />
        <include name="System.Web.Routing.dll" />
        <include name="System.Web.Services.dll" />
        <include name="System.Windows.Forms.DataVisualization.Design.dll" />
        <include name="System.Windows.Forms.DataVisualization.dll" />
        <include name="System.Windows.Forms.dll" />
        <include name="System.Windows.Input.Manipulations.dll" />
        <include name="System.Windows.Presentation.dll" />
        <include name="System.Workflow.Activities.dll" />
        <include name="System.Workflow.ComponentModel.dll" />
        <include name="System.Workflow.Runtime.dll" />
        <include name="System.WorkflowServices.dll" />
        <include name="System.Xaml.dll" />
        <include name="System.Xml.dll" />
        <include name="System.Xml.Linq.dll" />
      </reference-assemblies>
      <task-assemblies>
        <!-- include MS.NET version-neutral assemblies -->
        <include name="extensions/net/neutral/**/*.dll" />
        <!-- include MS.NET 4.0 specific assemblies -->
        <include name="extensions/net/4.0/**/*.dll" />
        <!-- include MS.NET specific task assembly -->
        <include name="NAnt.MSNetTasks.dll" />
        <!-- include MS.NET specific test assembly -->
        <include name="NAnt.MSNet.Tests.dll" />
        <!-- include .NET 4.0 specific assemblies -->
        <include name="extensions/common/4.0/**/*.dll" />
      </task-assemblies>
      <tool-paths>
        <directory name="${sdkInstallRoot}"
            if="${property::exists('sdkInstallRoot')}" />
        <directory name="${path::combine(installRoot, 'v4.0.30319')}" />
      </tool-paths>
      <project>
        <readregistry
            property="installRoot"
            key="SOFTWARE\Microsoft\.NETFramework\InstallRoot"
            hive="LocalMachine" />
        <locatesdk property="sdkInstallRoot" minwinsdkver="v7.0A" minnetfxver="4.0" maxnetfxver="4.0.99999" failonerror="false" />
      </project>
      <tasks>
        <task name="csc">
          <attribute name="supportsnowarnlist">true</attribute>
          <attribute name="supportswarnaserrorlist">true</attribute>
          <attribute name="supportskeycontainer">true</attribute>
          <attribute name="supportskeyfile">true</attribute>
          <attribute name="supportsdelaysign">true</attribute>
          <attribute name="supportsplatform">true</attribute>
          <attribute name="supportslangversion">true</attribute>
        </task>
        <task name="vbc">
          <attribute name="supportsdocgeneration">true</attribute>
          <attribute name="supportsnostdlib">true</attribute>
          <attribute name="supportsnowarnlist">true</attribute>
          <attribute name="supportskeycontainer">true</attribute>
          <attribute name="supportskeyfile">true</attribute>
          <attribute name="supportsdelaysign">true</attribute>
          <attribute name="supportsplatform">true</attribute>
          <attribute name="supportswarnaserrorlist">true</attribute>
        </task>
        <task name="jsc">
          <attribute name="supportsplatform">true</attribute>
        </task>
        <task name="vjc">
          <attribute name="supportsnowarnlist">true</attribute>
          <attribute name="supportskeycontainer">true</attribute>
          <attribute name="supportskeyfile">true</attribute>
          <attribute name="supportsdelaysign">true</attribute>
        </task>
        <task name="resgen">
          <attribute name="supportsassemblyreferences">true</attribute>
          <attribute name="supportsexternalfilereferences">true</attribute>
        </task>
        <task name="delay-sign">
          <attribute name="exename">sn</attribute>
        </task>
        <task name="license">
          <attribute name="exename">lc</attribute>
          <attribute name="supportsassemblyreferences">true</attribute>
        </task>
      </tasks>
    </framework>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

this is what i have right now Drawing an RSS feed into the php,
I want use html5's new tag to play a wav file (currently only supported
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I am trying to understand how to use SyndicationItem to display feed which is
I have a jquery bug and I've been looking for hours now, I can't
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I am reading a book about Javascript and jQuery and using one of the
I'm using v2.0 of ClassTextile.php, with the following call: $testimonial_text = $textile->TextileRestricted($_POST['testimonial']); ... and
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.