class FsharpPackage(GitHubTarballPackage):
def __init__(self):
- GitHubTarballPackage.__init__(self,
- 'fsharp', 'fsharp',
- '4.0.1.20',
- '9bd7c2420e06c1597ef5a37b6cb6e0f8d2911b10',
- configure='./configure --prefix="%{package_prefix}"')
+ GitHubTarballPackage.__init__(
+ self,
+ 'fsharp',
+ 'fsharp',
+ '4.1.8',
+ '991186f6c95b30a80f217b9319354b32c86212de',
+ configure='./configure --prefix="%{package_prefix}"',
+ override_properties={
+ 'make': 'make'})
self.extra_stage_files = [
'lib/mono/xbuild/Microsoft/VisualStudio/v/FSharp/Microsoft.FSharp.Targets']
+ self.sources.extend(
+ [
+ 'patches/fsharp-enable-jit-tracking-for-portable-pdb.patch',
+ 'patches/fsharp-fix-mdb-support.patch',
+ 'patches/fsharp-Fix-mono-gac-location.patch',
+ 'patches/fsharp-fix-xbuild-check.patch'])
def prep(self):
Package.prep(self)
--- /dev/null
+From 208aa8170bede4c176b5e3afa6811d1d7a5a330c Mon Sep 17 00:00:00 2001
+From: nosami <jasonimison@gmail.com>
+Date: Tue, 11 Apr 2017 12:10:04 +0100
+Subject: [PATCH] Fix mono/gac location
+
+---
+ src/fsharp/targets.make | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/src/fsharp/targets.make b/src/fsharp/targets.make
+index 014294a..716adb7 100644
+--- a/src/fsharp/targets.make
++++ b/src/fsharp/targets.make
+@@ -157,9 +157,9 @@ install-gac-lib:
+ echo "Using gacutil to install $(outdir)$(ASSEMBLY) into GAC root $(DESTDIR)$(libdir) as package $(TARGET)"; \
+ $(monobindir)/gacutil -i $(outdir)$(ASSEMBLY) -root $(DESTDIR)$(libdir) -package $(TARGET); \
+ else \
+- echo "Installing $(outdir)$(NAME).dll to $(DESTDIR)$(gacdir)/gac/$(NAME)/$(VERSION)__$(TOKEN)/"; \
+- mkdir -p $(DESTDIR)$(gacdir)/gac/$(NAME)/$(VERSION)__$(TOKEN)/; \
+- $(INSTALL_LIB) $(outdir)$(NAME).dll $(DESTDIR)$(gacdir)/gac/$(NAME)/$(VERSION)__$(TOKEN)/; \
++ echo "Installing $(outdir)$(NAME).dll to $(DESTDIR)$(monodir)/gac/$(NAME)/$(VERSION)__$(TOKEN)/"; \
++ mkdir -p $(DESTDIR)$(monodir)/gac/$(NAME)/$(VERSION)__$(TOKEN)/; \
++ $(INSTALL_LIB) $(outdir)$(NAME).dll $(DESTDIR)$(monodir)/gac/$(NAME)/$(VERSION)__$(TOKEN)/; \
+ fi; \
+ fi
+
+--
+2.8.0
+
--- /dev/null
+From f28dbdfaa4427c1e62c16bc6d59106f9f5db15f7 Mon Sep 17 00:00:00 2001
+From: nosami <jasonimison@gmail.com>
+Date: Fri, 21 Apr 2017 16:34:27 +0100
+Subject: [PATCH] Enable JIT tracking for portable PDB debugging
+
+Setting JIT tracking to true adds the `DebuggableAttribute.DebuggingModes.Default`
+flag to the generated Debuggable attribute
+See https://msdn.microsoft.com/en-us/library/system.diagnostics.debuggableattribute.debuggingmodes(v=vs.110).aspx
+
+Without this flag I see the following message when debugging unless I have "Debug project code only: do not step into framework code" unchecked to allow stepping into framework code.
+```
+Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
+```
+Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=55092
+---
+ src/fsharp/CompileOptions.fs | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/fsharp/CompileOptions.fs b/src/fsharp/CompileOptions.fs
+index 209cdd90..97860085 100755
+--- a/src/fsharp/CompileOptions.fs
++++ b/src/fsharp/CompileOptions.fs
+@@ -466,9 +466,9 @@ let SetDebugSwitch (tcConfigB : TcConfigBuilder) (dtype : string option) (s : Op
+ match dtype with
+ | Some(s) ->
+ match s with
+- | "portable" -> tcConfigB.portablePDB <- true; tcConfigB.embeddedPDB <- false; tcConfigB.jitTracking <- false; tcConfigB.ignoreSymbolStoreSequencePoints <- true
++ | "portable" -> tcConfigB.portablePDB <- true; tcConfigB.embeddedPDB <- false; tcConfigB.jitTracking <- true; tcConfigB.ignoreSymbolStoreSequencePoints <- true
+ | "pdbonly" -> tcConfigB.portablePDB <- false; tcConfigB.embeddedPDB <- false; tcConfigB.jitTracking <- false
+- | "embedded" -> tcConfigB.portablePDB <- true; tcConfigB.embeddedPDB <- true; tcConfigB.jitTracking <- false; tcConfigB.ignoreSymbolStoreSequencePoints <- true
++ | "embedded" -> tcConfigB.portablePDB <- true; tcConfigB.embeddedPDB <- true; tcConfigB.jitTracking <- true; tcConfigB.ignoreSymbolStoreSequencePoints <- true
+ | "full" -> tcConfigB.portablePDB <- false; tcConfigB.embeddedPDB <- false; tcConfigB.jitTracking <- true
+ | _ -> error(Error(FSComp.SR.optsUnrecognizedDebugType(s), rangeCmdArgs))
+ | None -> tcConfigB.portablePDB <- false; tcConfigB.embeddedPDB <- false; tcConfigB.jitTracking <- s = OptionSwitch.On;
+--
+2.11.0 (Apple Git-81)
+
F# yet.
diff --git a/src/fsharp/FSharp.Build/Microsoft.FSharp.targets b/src/fsharp/FSharp.Build/Microsoft.FSharp.targets
-index 82125d2..e7ddac2 100644
+index e185bdf..2788988 100644
--- a/src/fsharp/FSharp.Build/Microsoft.FSharp.targets
+++ b/src/fsharp/FSharp.Build/Microsoft.FSharp.targets
-@@ -40,6 +40,10 @@ Copyright (C) Microsoft Corporation. Apache 2.0 License.
+@@ -38,6 +38,10 @@ this file.
<RootNamespace Condition="'$(RootNamespace)'==''">RootNamespace</RootNamespace>
<Actual32Bit Condition="'$(TargetFrameworkVersion)'=='v2.0' or '$(TargetFrameworkVersion)'=='v3.0' or '$(TargetFrameworkVersion)'=='v3.5' or '$(TargetFrameworkVersion)'=='v4.0'">false</Actual32Bit>
<Actual32Bit Condition="!('$(TargetFrameworkVersion)'=='v2.0' or '$(TargetFrameworkVersion)'=='v3.0' or '$(TargetFrameworkVersion)'=='v3.5' or '$(TargetFrameworkVersion)'=='v4.0')">$(Prefer32Bit)</Actual32Bit>
+ <_DebugFileExt Condition="'$(FscDebugFileExt)' != ''">$(FscDebugFileExt)</_DebugFileExt>
+ <_DebugFileExt Condition="'$(_DebugFileExt)' == ''">.mdb</_DebugFileExt>
</PropertyGroup>
-
+
<!--
--- /dev/null
+commit 8f93ad340dc81a23155e68c79a5c3eab53b6eeb5
+Author: Ankit Jain <ankit.jain@xamarin.com>
+Date: Sat Apr 15 04:17:18 2017 -0400
+
+ [msbuild] Fix test for is-running-on-xbuild
+
+diff --git a/src/fsharp/FSharp.Build/Microsoft.FSharp.targets b/src/fsharp/FSharp.Build/Microsoft.FSharp.targets
+index ec28077d..10840ada 100644
+--- a/src/fsharp/FSharp.Build/Microsoft.FSharp.targets
++++ b/src/fsharp/FSharp.Build/Microsoft.FSharp.targets
+@@ -66,7 +66,7 @@ this file.
+
+ <PropertyGroup>
+ <UsingXBuild>false</UsingXBuild>
+- <UsingXBuild Condition="$(MSBuildExtensionsPath32.Contains('xbuild'))">true</UsingXBuild>
++ <UsingXBuild Condition="'$(MSBuildAssemblyVersion)' == ''">true</UsingXBuild>
+ </PropertyGroup>
+
+ <Target