Nant config & sdkinstallroot

Dec 24, 2008 at 6:53 AM

With the very latest source, I had an issue where I kept getting a failed build  with the following message:



Failed to initialize the 'Microsoft .NET Framework 2.0' (net-2.0) target framework.

    Property evaluation failed.
Expression: ${path::combine(sdkInstallRoot, 'bin')}

        Property 'sdkInstallRoot' has not been set.

This is because I don't have that registry setting.  With a little research, I found the following helpful articles:

With a little bit of variations on a theme (ex, I have sdk 6.1 instead of 6.0a), I was able to get it working.



Dec 31, 2008 at 5:07 PM
It's a problem with nant not being able to find the 2.0 SDK on a machine where you only have VS2008 and/or the 3.5 SDK installed. The sdkInstallRoot key never gets set when you just install Visual Studio and only seems to get set when you install the 2.0 SDK. The two links you provided help.

The short answer and solution (if it is short) is to install the 2.0 SDK. I'm not a big fan of this because frankly, I have VS that will target the framework I want (2.0, 3.0 or 3.5) and don't *want* to install a huge SDK on top of something that's already working.

So I see that there are really only two options:
  1. Install the 2.0 SDK
  2. Change/add the registry key (as per the second link)
Neither gives me a warm and fuzzy but I think it's the only options given the whacky way MSFT decided to configure the frameworks.