Skip to content

Commit

Permalink
Add local copy of the F# project and reference that copy of FSharp.Core.
Browse files Browse the repository at this point in the history
  • Loading branch information
panesofglass committed Aug 4, 2012
1 parent b9d39ec commit 1d36ecc
Show file tree
Hide file tree
Showing 21 changed files with 504 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Agents.fsproj
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,10 @@
<None Include="MailboxProcessors.fsx" />
</ItemGroup>
<ItemGroup>
<Reference Include="FSharp.Core">
<HintPath>lib\FSharp\FSharp.Core.dll</HintPath>
</Reference>
<Reference Include="mscorlib" />
<Reference Include="FSharp.Core" />
<Reference Include="System" />
<Reference Include="System.Core">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
Expand Down
Binary file added lib/FSharp/FSharp.Build.dll
Binary file not shown.
Binary file not shown.
Binary file added lib/FSharp/FSharp.Compiler.Server.Shared.dll
Binary file not shown.
Binary file added lib/FSharp/FSharp.Compiler.dll
Binary file not shown.
Binary file added lib/FSharp/FSharp.Core.dll
Binary file not shown.
Binary file added lib/FSharp/FSharp.Core.optdata
Binary file not shown.
Binary file added lib/FSharp/FSharp.Core.sigdata
Binary file not shown.
Binary file added lib/FSharp/FSharp.LanguageService.Base.dll
Binary file not shown.
Binary file added lib/FSharp/FSharp.LanguageService.dll
Binary file not shown.
Binary file added lib/FSharp/FSharp.ProjectSystem.Base.dll
Binary file not shown.
Binary file added lib/FSharp/FSharp.ProjectSystem.FSharp.dll
Binary file not shown.
Binary file not shown.
Binary file added lib/FSharp/FSharp.VS.FSI.dll
Binary file not shown.
6 changes: 6 additions & 0 deletions lib/FSharp/Fsi.exe.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<runtime>
<legacyUnhandledExceptionPolicy enabled="true" />
</runtime>
</configuration>
231 changes: 231 additions & 0 deletions lib/FSharp/Microsoft.FSharp.targets
Original file line number Diff line number Diff line change
@@ -0,0 +1,231 @@
<!--
***********************************************************************************************
Microsoft.FSharp.targets
WARNING: DO NOT MODIFY this file unless you are knowledgeable about MSBuild and have
created a backup copy. Incorrect changes to this file will make it
impossible to load or build your projects from the command-line or the IDE.
This file defines the steps in the standard build process specific for F# .NET projects.
For example, it contains the step that actually calls the F# compiler. The remainder
of the build process is defined in Microsoft.Common.targets, which is imported by
this file.
Copyright (C) Microsoft Corporation. All rights reserved.
***********************************************************************************************
-->

<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

<UsingTask TaskName="Fsc" AssemblyFile="FSharp.Build.dll"/>
<UsingTask TaskName="CreateFSharpManifestResourceName" AssemblyFile="FSharp.Build.dll"/>

<PropertyGroup>
<ImportByWildcardBeforeMicrosoftFSharpTargets Condition="'$(ImportByWildcardBeforeMicrosoftFSharpTargets)' == ''">true</ImportByWildcardBeforeMicrosoftFSharpTargets>
<ImportByWildcardAfterMicrosoftFSharpTargets Condition="'$(ImportByWildcardAfterMicrosoftFSharpTargets)' == ''">true</ImportByWildcardAfterMicrosoftFSharpTargets>
</PropertyGroup>

<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\$(MSBuildThisFile)\ImportBefore\*" Condition="'$(ImportByWildcardBeforeMicrosoftFSharpTargets)' == 'true' and exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\$(MSBuildThisFile)\ImportBefore')"/>

<PropertyGroup>
<MSBuildAllProjects>$(MSBuildAllProjects);$(MSBuildThisFileFullPath)</MSBuildAllProjects>
<DefaultLanguageSourceExtension>.fs</DefaultLanguageSourceExtension>
<Language>F#</Language>
<Tailcalls Condition="'$(Tailcalls)'==''">$(Optimize)</Tailcalls>
</PropertyGroup>

<!--
The CreateManifestResourceNames target create the manifest resource names from the .RESX
files.
[IN]
@(EmbeddedResource) - The list of EmbeddedResource items that have been pre-processed to add metadata about resource type
Expected Metadata "Type" can either be "Resx" or "Non-Resx"
[OUT]
@(EmbeddedResource) - EmbeddedResource items with metadata
For F# applications the transformation is like:
Resources1.resx => Resources1 => Build into main assembly
SubFolder\Resources1.resx => SubFolder.Resources1 => Build into main assembly
Resources1.fr.resx => Resources1.fr => Build into satellite assembly
Resources1.notaculture.resx => Resources1.notaculture => Build into main assembly
For other project systems, this transformation may be different.
-->
<PropertyGroup>
<CreateManifestResourceNamesDependsOn></CreateManifestResourceNamesDependsOn>
</PropertyGroup>
<Target
Name="CreateManifestResourceNames"
Condition="'@(EmbeddedResource)' != ''"
DependsOnTargets="$(CreateManifestResourceNamesDependsOn)"
>

<ItemGroup>
<_Temporary Remove="@(_Temporary)" />
</ItemGroup>

<!-- Create manifest names for culture and non-culture Resx files, and for non-culture Non-Resx resources -->
<CreateFSharpManifestResourceName
ResourceFiles="@(EmbeddedResource)"
RootNamespace="$(RootNamespace)"
Condition="'%(EmbeddedResource.ManifestResourceName)' == '' and ('%(EmbeddedResource.WithCulture)' == 'false' or '%(EmbeddedResource.Type)' == 'Resx')">

<Output TaskParameter="ResourceFilesWithManifestResourceNames" ItemName="_Temporary" />

</CreateFSharpManifestResourceName>

<!-- Create manifest names for all culture non-resx resources -->
<CreateFSharpManifestResourceName
ResourceFiles="@(EmbeddedResource)"
RootNamespace="$(RootNamespace)"
PrependCultureAsDirectory="false"
Condition="'%(EmbeddedResource.ManifestResourceName)' == '' and '%(EmbeddedResource.WithCulture)' == 'true' and '%(EmbeddedResource.Type)' == 'Non-Resx'">

<Output TaskParameter="ResourceFilesWithManifestResourceNames" ItemName="_Temporary" />

</CreateFSharpManifestResourceName>

<ItemGroup>
<EmbeddedResource Remove="@(EmbeddedResource)" Condition="'%(EmbeddedResource.ManifestResourceName)' == ''"/>
<EmbeddedResource Include="@(_Temporary)" />
<_Temporary Remove="@(_Temporary)" />
</ItemGroup>
</Target>

<ItemGroup>
<DocFileItem Include="$(DocumentationFile)" Condition="'$(DocumentationFile)'!=''"/>
</ItemGroup>

<ItemGroup Condition="'$(_DebugSymbolsProduced)' == 'true' and '$(PdbFile)' != ''">
<_DebugSymbolsIntermediatePathTemporary Include="$(PdbFile)"/>
<!-- Add any missing .pdb extension, as the compiler does -->
<_DebugSymbolsIntermediatePath Include="@(_DebugSymbolsIntermediatePathTemporary->'%(RootDir)%(Directory)%(Filename).pdb')"/>
</ItemGroup>

<PropertyGroup>
<CoreCompileDependsOn>_ComputeNonExistentFileProperty</CoreCompileDependsOn>
</PropertyGroup>

<Target
Name="CoreCompile"
Inputs="$(MSBuildAllProjects);
@(CompileBefore);
@(Compile);
@(CompileAfter);
@(_CoreCompileResourceInputs);
$(ApplicationIcon);
$(AssemblyOriginatorKeyFile);
@(ReferencePath);
@(CompiledLicenseFile);
@(EmbeddedDocumentation);
$(Win32Resource);
$(Win32Manifest);
@(CustomAdditionalCompileInputs);
$(VersionFile);
$(KeyOriginatorFile)"
Outputs="@(DocFileItem);
@(IntermediateAssembly);
@(_DebugSymbolsIntermediatePath);
$(NonExistentFile);
@(CustomAdditionalCompileOutputs)"
Returns=""
DependsOnTargets="$(CoreCompileDependsOn)"
>

<Error
Condition="'$(SilverlightVersion)' != '' and !(Exists('$(ProgramFiles)\Microsoft F#\Silverlight\Libraries\Client\$(SilverlightVersion)\FSharp.Core.dll'))"
Text="F# runtime for Silverlight version $(SilverlightVersion) is not installed. Please go to http://go.microsoft.com/fwlink/?LinkId=177463 to download and install matching F# runtime"
/>

<Warning
Condition="'$(Win32ResourceFile)' != '' "
Text="The property &lt;Win32ResourceFile> has been renamed to &lt;Win32Resource>. Update your project file to ensure that the correct value is passed via the --win32res option to the F# compiler."
/>

<!-- Condition is to filter out the _CoreCompileResourceInputs so that it doesn't pass in culture resources to the compiler -->
<Fsc Condition=" '%(_CoreCompileResourceInputs.WithCulture)' != 'true' "
BaseAddress="$(BaseAddress)"
CodePage="$(CodePage)"
DebugSymbols="$(DebugSymbols)"
DebugType="$(DebugType)"
DefineConstants="$(DefineConstants)"
DisabledWarnings="$(NoWarn)"
DocumentationFile="$(DocumentationFile)"
GenerateInterfaceFile="$(GenerateInterfaceFile)"
KeyFile="$(KeyOriginatorFile)"
LCID="$(LCID)"
NoFramework="true"
Optimize="$(Optimize)"
OtherFlags="$(OtherFlags)"
OutputAssembly="@(IntermediateAssembly)"
PdbFile="$(PdbFile)"
Platform="$(PlatformTarget)"
References="@(ReferencePath)"
ReferencePath="$(ReferencePath)"
Resources="@(_CoreCompileResourceInputs);@(CompiledLicenseFile);@(AdditionalEmbeddedResource)"
Sources="@(CompileBefore);@(Compile);@(CompileAfter)"
Tailcalls="$(Tailcalls)"
TargetType="$(OutputType)"
ToolExe="$(FscToolExe)"
ToolPath="$(FscToolPath)"
TreatWarningsAsErrors="$(TreatWarningsAsErrors)"
Utf8Output="$(Utf8Output)"
VersionFile="$(VersionFile)"
VisualStudioStyleErrors="$(VisualStudioStyleErrors)"
WarningLevel="$(WarningLevel)"
WarningsAsErrors="$(WarningsAsErrors)"
Win32ManifestFile="$(Win32Manifest)"
Win32ResourceFile="$(Win32Resource)"
/>

<ItemGroup>
<_CoreCompileResourceInputs Remove="@(_CoreCompileResourceInputs)" />
</ItemGroup>

</Target>


<Import Project="$(MSBuildBinPath)\Microsoft.Common.targets"/>

<!--
============================================================
GenerateTargetFrameworkMonikerAttribute
Emit the target framework moniker attribute as a code fragment into a temporary source file for the compiler.
============================================================
-->

<Target Name="GenerateTargetFrameworkMonikerAttribute" BeforeTargets="BeforeCompile" DependsOnTargets="PrepareForBuild;GetReferenceAssemblyPaths" Inputs="$(MSBuildThisFileFullPath)" Outputs="$(TargetFrameworkMonikerAssemblyAttributesPath)" Condition="'$(GenerateTargetFrameworkAttribute)' == 'true'">

<PropertyGroup>
<!-- This attribute is only available in mscorlib v4 and later -->
<AdditionalSourcesText Condition="'$(TargetFrameworkMoniker)' != '' and '$(TargetingClr2Framework)' != 'true'">
$(AdditionalSourcesText)
namespace Microsoft.BuildSettings
[&lt;System.Runtime.Versioning.TargetFrameworkAttribute(&quot;$(TargetFrameworkMoniker)&quot;, FrameworkDisplayName=&quot;$(TargetFrameworkMonikerDisplayName)&quot;)&gt;]
do ()
</AdditionalSourcesText>
</PropertyGroup>

<!-- This is a file shared between projects so we have to take care to handle simultaneous writes (by ContinueOnError)
and a race between clean from one project and build from another (by not adding to FilesWritten so it doesn't clean) -->
<WriteLinesToFile
File="$(TargetFrameworkMonikerAssemblyAttributesPath)"
Lines="$(AdditionalSourcesText)"
Condition="'$(AdditionalSourcesText)' != ''"
ContinueOnError="true"
Overwrite="true"/>

<ItemGroup>
<CompileBefore Include="$(TargetFrameworkMonikerAssemblyAttributesPath)" Condition="'$(AdditionalSourcesText)' != ''"/>
</ItemGroup>

</Target>

<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\$(MSBuildThisFile)\ImportAfter\*" Condition="'$(ImportByWildcardAfterMicrosoftFSharpTargets)' == 'true' and exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\$(MSBuildThisFile)\ImportAfter')"/>

</Project>
4 changes: 4 additions & 0 deletions lib/templates/_footer.spark
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<div id="footer">
<p>Based on v${WriteVersion(Assemblies[0])} of ${WriteAssemblyTitle(Assemblies[0])}</p>
<p>Generated by <a href="http://docu.jagregory.com">docu</a></p>
</div>
8 changes: 8 additions & 0 deletions lib/templates/_namespaces.spark
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<div id="namespaces">
<h2 class="fixed">Namespaces</h2>
<div class="scroll">
<ul>
<li each="var ns in Namespaces">${Format(ns)}</li>
</ul>
</div>
</div>
10 changes: 10 additions & 0 deletions lib/templates/_types.spark
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<div id="types">
<h2 class="fixed">All Types</h2>
<div class="scroll">
<ul>
<for each="var ns in Namespaces">
<li each="var type in ns.Types">${Format(type)}</li>
</for>
</ul>
</div>
</div>
17 changes: 17 additions & 0 deletions lib/templates/index.htm.spark
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>${WriteProductName(Assemblies[0])} Documentation</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link type="text/css" rel="stylesheet" href="main.css" />
</head>
<body>
<namespaces />
<types />
<div class="header">
<p class="class">${WriteProductName(Assemblies[0])} Documentation</p>
</div>

<use file="_footer" />
</body>
</html>
Loading

0 comments on commit 1d36ecc

Please sign in to comment.