Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit93a1730

Browse files
committed
Use strong names for bootstrap compiler to help with compile on windows
switch to strong names for compiler binaries and update the bootstrapcompiler with those names. The strong names are based onsrc\fsharp\test.snkthis means the strong name for FSharp.Compiler.dll changes, but no oneshould be depending on that and the new names are useful as the won'tcollide with the visual studio versions of these DLLs on windows. Themonodevelop binding is neutral to the strong names used.we still compile FSharp.Core asdelay-signed-with-the-microsoft-key-and-then-mono-key-signed which Monorecognizes as strong named but i think windows does not. We have to usethis identity for FSHarp.Core to keep binary compatibility withWindows-compiled thing like type provider DLLs.We may have to use the Microsoft FSHarp.Core.dll on Windows, i think itgets picked up automatically from the GAC but need to check tomorrow.also fixes bugs in ilsupp.fs in strong nae signing.tested by bootstrapping, and manually examining the names on the dlls.
1 parent6a7a40b commit93a1730

File tree

23 files changed

+62
-35
lines changed

23 files changed

+62
-35
lines changed

‎config.make.in‎

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,11 +52,15 @@ FLAGS = \
5252
--times \
5353
--nowarn:9
5454

55-
FINAL_FLAGS = \
55+
DELAY_SIGN_FLAGS = \
5656
--define:STRONG_NAME_AND_DELAY_SIGN_FSHARP_COMPILER_WITH_MSFT_KEY \
5757
--delaysign+ \
5858
--keyfile:$(topdir)msfinal.pub
5959

60+
SIGN_FLAGS = \
61+
--define:STRONG_NAME_FSHARP_COMPILER_WITH_TEST_KEY \
62+
--keyfile:$(topdir)/src/fsharp/test.snk
63+
6064
DEFINES_GENERAL = \
6165
--define:TRACE \
6266
--define:MONO

‎lib/bootstrap/4.0/FSharp.Build.dll‎

0 Bytes
Binary file not shown.
0 Bytes
Binary file not shown.
0 Bytes
Binary file not shown.
0 Bytes
Binary file not shown.

‎lib/bootstrap/4.0/FSharp.Core.dll‎

0 Bytes
Binary file not shown.

‎lib/bootstrap/4.0/Microsoft.FSharp.targets‎

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,18 @@ Copyright (C) Microsoft Corporation. All rights reserved.
1717

1818
<Projectxmlns="http://schemas.microsoft.com/developer/msbuild/2003">
1919

20-
<UsingTaskTaskName="Fsc"AssemblyFile="FSharp.Build.dll"/>
21-
<UsingTaskTaskName="CreateFSharpManifestResourceName"AssemblyFile="FSharp.Build.dll"/>
20+
21+
<UsingTaskTaskName="Fsc"AssemblyFile="FSharp.Build.dll"Condition="Exists('$(MSBuildToolsPath)\Microsoft.Build.Tasks.v4.0.dll')" />
22+
<UsingTaskTaskName="CreateFSharpManifestResourceName"AssemblyFile="FSharp.Build.dll"Condition="Exists('$(MSBuildToolsPath)\Microsoft.Build.Tasks.v4.0.dll')" />
23+
24+
<!-- The next two are for when the ToolsVersion is 3.5, i.e. we're referencing .NET 2.0-->
25+
<UsingTaskTaskName="Fsc"AssemblyFile="$(MSBuildExtensionsPath32)\..\2.0\FSharp.Build.dll"Condition="!Exists('$(MSBuildToolsPath)\Microsoft.Build.Tasks.v4.0.dll') AND Exists('$(MSBuildExtensionsPath32)\..\2.0\FSharp.Build.dll')" />
26+
<UsingTaskTaskName="CreateFSharpManifestResourceName"AssemblyFile="$(MSBuildExtensionsPath32)\..\2.0\FSharp.Build.dll"Condition="!Exists('$(MSBuildToolsPath)\Microsoft.Build.Tasks.v4.0.dll') AND Exists('$(MSBuildExtensionsPath32)\..\2.0\FSharp.Build.dll')" />
27+
28+
2229

2330

2431
<PropertyGroup>
25-
<MSBuildAllProjects>$(MSBuildAllProjects);$(FSharpTargetsFullPath)</MSBuildAllProjects>
2632
<DefaultLanguageSourceExtension>.fs</DefaultLanguageSourceExtension>
2733
<Language>F#</Language>
2834
<TailcallsCondition="'$(Tailcalls)'==''">$(Optimize)</Tailcalls>
@@ -98,7 +104,7 @@ Copyright (C) Microsoft Corporation. All rights reserved.
98104
</ItemGroup>
99105

100106
<PropertyGroup>
101-
<CoreCompileDependsOn>_ComputeNonExistentFileProperty</CoreCompileDependsOn>
107+
<CoreCompileDependsOn></CoreCompileDependsOn>
102108
</PropertyGroup>
103109

104110
<Target
@@ -108,6 +114,7 @@ Copyright (C) Microsoft Corporation. All rights reserved.
108114
@(Compile);
109115
@(CompileAfter);
110116
@(_CoreCompileResourceInputs);
117+
@(ManifestNonResxWithNoCultureOnDisk);
111118
$(ApplicationIcon);
112119
$(AssemblyOriginatorKeyFile);
113120
@(ReferencePath);
@@ -185,4 +192,3 @@ Copyright (C) Microsoft Corporation. All rights reserved.
185192

186193
</Project>
187194

188-

‎lib/bootstrap/4.0/fsc.exe‎

512 Bytes
Binary file not shown.

‎lib/bootstrap/4.0/fsi.exe‎

3 KB
Binary file not shown.

‎src/FSharpSource.targets‎

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,19 +25,26 @@
2525
<VersionFileCondition="'$(TargetFramework)' == 'net40'">$(FSharpSourcesRoot)\source-build-version-4.3.0.0</VersionFile>
2626
</PropertyGroup>
2727

28-
<!-- We sign with the Microsoft key and use delay-signing.-->
28+
<!-- We signFSharp.Corewith the Microsoft key and use delay-signing.-->
2929
<!-- These can then be signed with the special mono.snk (we don't do this as part of this build,-->
3030
<!-- but it can be done manually later, e.g. on the target machine). This is how the Mono team build the binaries-->
3131
<!-- at github.com/fsharp/fsharp and how they are shipped with Mono-->
3232
<!---->
3333
<!-- However FSharp.Core must use the Microsoft key name, otherwise the compiler can't load type provider components.-->
3434

35-
<PropertyGroupCondition="'$(Configuration)'=='Debug' OR '$(Configuration)'=='Release'">
35+
<PropertyGroupCondition="('$(Configuration)'=='Debug' OR '$(Configuration)'=='Release') AND ('$(AssemblyName)'=='FSharp.Core')">
3636
<DefineConstants>STRONG_NAME_AND_DELAY_SIGN_FSHARP_COMPILER_WITH_MSFT_KEY;$(DefineConstants)</DefineConstants>
3737
<OtherFlags>$(OtherFlags) --delaysign+ --keyfile:$(FSharpSourcesRoot)\fsharp\msft.pubkey</OtherFlags>
3838
<StrongNames>true</StrongNames>
3939
</PropertyGroup>
4040

41+
<PropertyGroupCondition="('$(Configuration)'=='Debug' OR '$(Configuration)'=='Release') AND ('$(AssemblyName)'!='FSharp.Core')">
42+
<DefineConstants>STRONG_NAME_FSHARP_COMPILER_WITH_TEST_KEY;$(DefineConstants)</DefineConstants>
43+
<OtherFlags>$(OtherFlags) --keyfile:$(FSharpSourcesRoot)\fsharp\test.snk</OtherFlags>
44+
<StrongNames>true</StrongNames>
45+
</PropertyGroup>
46+
47+
4148
<!-- For the proto build and exotic framework implementations, we don't use strong names. For non-exotic framework implementations, this gets adjusted below-->
4249
<PropertyGroupCondition="'$(StrongNames)' != 'true'">
4350
<DefineConstants>NO_STRONG_NAMES;$(DefineConstants)</DefineConstants>

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp