[Mono-dev] Microsoft.Build: The parameter 'FrameworkVersion45Path' was not found for the 'GetFrameworkPath' task
marek.safar at gmail.com
Thu Jan 31 15:29:19 UTC 2013
This is most likely Mono bug in how we load Task libraries. It'll load the
version from folder where Microsoft.Common.targets is which is incorrect in
your case because it's 4.0 version and not 4.5. Some kind of self contained
sample how F# is using Microsoft.Build* would be useful.
I'm trying to execute the ResolveAssemblyReferences task using the
> Microsoft.Build namespace. This (F#) project builds nicely from the command
> line using xbuild, so the logic is capable. The project file can be found
> https://github.com/fsharp/fsharpbinding/blob/master/FSharp.AutoComplete/FSharp.AutoComplete.fsproj and
> has TargetFrameworkVersion set to 4.5. If I change TargetFrameworkVersion
> to 4.0, it works.
> I downloaded mono from github and am running the latest version: Mono JIT
> compiler version 3.0.4 (master/e5fba9d Wed Jan 30 18:38:48 GMT 2013). I
> also tried with 3.0.3, with the same effect.
> The following fsi script is what I am using:
> #r "Microsoft.Build.Engine"
> #r "Microsoft.Build.Framework"
> #r "Microsoft.Build.Tasks.v4.0"
> open Microsoft.Build.BuildEngine
> open Microsoft.Build.Framework
> open Microsoft.Build.Tasks
> let p = new Project()
> let cl = new ConsoleLogger(LoggerVerbosity.Diagnostic)
> which results in:
> <path>/FSharp.AutoComplete.fsproj (ResolveAssemblyReferences) ->
> (GetFrameworkPaths target) ->
> /home/scratch/local_mono/lib/mono/4.0/Microsoft.Common.targets: error :
> Error executing task GetFrameworkPath: The parameter
> 'FrameworkVersion45Path' was not found for the 'GetFrameworkPath' task.
> I found that the framework path for 4.5 doesn't seem to be defined:
> let gfp = GetFrameworkPath()
> error FS0039: The field, constructor or member 'FrameworkVersion45Path' is
> not defined
> Although in
> has a #if NET_4_5 around FrameworkVersion45Path, and .NET 4.5 is definitely
> enabled in the configure script, and I have a fully populated lib/mono/4.5
> I also found that the Engine toolsets do not include 4.5. I tried adding
> it manually, but this didn't help.
> I think this is a bug, and would appreciate any hints in tracking it down.
> Robin Neatherway
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Mono-devel-list