Lay down the foundation for packaging the .NET echosystem

- fetchNuGet can fetch binaries from nuget servers
- buildDotnetPackage can build .NET packages using mono/xbuild
- Places nuget & paket as they would clash with nix
- Patch project files because F# targets are expected to be found in
the mono directory (and we know that's not going to happen on nix)
- Find DLLs that were copied from buildInputs and replace by symlink
for sharing
- Export produced DLL via the pkg-config mechanism
- Create wrappers for produced EXEs
- Repackaged this new infrastructure: keepass, monodevelop
- Newly packaged: ExtCore, UnionArgParser, FSharp.Data, Paket, and a
bunch more..

This is a combination of 73 commits.

obadz d4681bf6 4cf3596f

+1159 -76
+19 -58
pkgs/applications/editors/monodevelop/default.nix
··· 1 - { stdenv, fetchurl, fetchgit 1 + { stdenv, fetchurl, fetchgit, fetchNuGet 2 2 , autoconf, automake, pkgconfig, shared_mime_info, intltool 3 3 , glib, mono, gtk-sharp, gnome, gnome-sharp, unzip 4 + , dotnetPackages 4 5 }: 5 6 6 7 stdenv.mkDerivation rec { ··· 13 14 sha256 = "1bgqvlfi6pilj2zxsviqilh63qq98wsijqdiqwpkqchcw741zlyn"; 14 15 }; 15 16 16 - srcNugetBinary = fetchgit { 17 - url = "https://github.com/mono/nuget-binary.git"; 18 - rev = "da1f2102f8172df6f7a1370a4998e3f88b91c047"; 19 - sha256 = "1hbnckc4gvqkknf8gh1k7iwqb4vdzifdjd19i60fnczly5v8m1c3"; 20 - }; 21 - 22 - srcNUnit = fetchurl { 23 - url = "https://www.nuget.org/api/v2/package/NUnit/2.6.3"; 24 - sha256 = "0bb16i4ggwz32wkxsh485wf014cqqzhbyx0b3wbpmqjw7p4canph"; 25 - }; 26 - 27 - srcNUnitRunners = fetchurl { 28 - url = "https://www.nuget.org/api/v2/package/NUnit.Runners/2.6.3"; 29 - sha256 = "0qwx1i9lxkp9pijj2bsczzgsamz651hngkxraqjap1v4m7d09a3b"; 30 - }; 31 - 32 - srcNUnit2510 = fetchurl { 17 + nunit2510 = fetchurl { 33 18 url = "http://launchpad.net/nunitv2/2.5/2.5.10/+download/NUnit-2.5.10.11092.zip"; 34 19 sha256 = "0k5h5bz1p2v3d0w0hpkpbpvdkcszgp8sr9ik498r1bs72w5qlwnc"; 35 20 }; 36 21 37 - srcNugetSystemWebMvcExtensions = fetchurl { 38 - url = https://www.nuget.org/api/v2/package/System.Web.Mvc.Extensions.Mvc.4/1.0.9; 39 - sha256 = "19wi662m8primpimzifv8k560m6ymm73z0mf1r8ixl0xqag1hx6j"; 40 - }; 41 - 42 - srcNugetMicrosoftAspNetMvc = fetchurl { 43 - url = https://www.nuget.org/api/v2/package/Microsoft.AspNet.Mvc/5.2.2; 44 - sha256 = "1jwfmz42kw2yb1g2hgp2h34fc4wx6s8z71da3mw5i4ivs25w9n2b"; 45 - }; 46 - 47 - srcNugetMicrosoftAspNetRazor = fetchurl { 48 - url = https://www.nuget.org/api/v2/package/Microsoft.AspNet.Razor/3.2.2; 49 - sha256 = "1db3apn4vzz1bx6q5fyv6nyx0drz095xgazqbw60qnhfs7z45axd"; 50 - }; 51 - 52 - srcNugetMicrosoftAspNetWebPages = fetchurl { 53 - url = https://www.nuget.org/api/v2/package/Microsoft.AspNet.WebPages/3.2.2; 54 - sha256 = "17fwb5yj165sql80i47zirjnm0gr4n8ypz408mz7p8a1n40r4i5l"; 55 - }; 56 - 57 - srcNugetMicrosoftWebInfrastructure = fetchurl { 58 - url = https://www.nuget.org/api/v2/package/Microsoft.Web.Infrastructure/1.0.0.0; 59 - sha256 = "1mxl9dri5729d0jl84gkpqifqf4xzb6aw1rzcfh6l0r24bix9afn"; 60 - }; 61 - 62 22 postPatch = '' 63 23 # From https://bugzilla.xamarin.com/show_bug.cgi?id=23696#c19 64 24 65 - # it seems parts of MonoDevelop 5.2+ need NUnit 2.6.4, which isn't included 66 - # (?), so download it and put it in the right place in the tree 67 - mkdir packages 68 - unzip ${srcNUnit} -d packages/NUnit.2.6.3 69 - unzip ${srcNUnitRunners} -d packages/NUnit.Runners.2.6.3 70 - 71 25 # cecil needs NUnit 2.5.10 - this is also missing from the tar 72 - unzip -j ${srcNUnit2510} -d external/cecil/Test/libs/nunit-2.5.10 NUnit-2.5.10.11092/bin/net-2.0/framework/\* 26 + unzip -j ${nunit2510} -d external/cecil/Test/libs/nunit-2.5.10 NUnit-2.5.10.11092/bin/net-2.0/framework/\* 73 27 74 28 # the tar doesn't include the nuget binary, so grab it from github and copy it 75 29 # into the right place 76 - cp -vfR ${srcNugetBinary}/* external/nuget-binary/ 77 - 78 - # AspNet plugin requires these packages 79 - unzip ${srcNugetSystemWebMvcExtensions} -d packages/System.Web.Mvc.Extensions.Mvc.4.1.0.9 80 - unzip ${srcNugetMicrosoftAspNetMvc} -d packages/Microsoft.AspNet.Mvc.5.2.2 81 - unzip ${srcNugetMicrosoftAspNetRazor} -d packages/Microsoft.AspNet.Razor.3.2.2 82 - unzip ${srcNugetMicrosoftAspNetWebPages} -d packages/Microsoft.AspNet.WebPages.3.2.2 83 - unzip ${srcNugetMicrosoftWebInfrastructure} -d packages/Microsoft.Web.Infrastructure.1.0.0.0 30 + cp -vfR "$(dirname $(pkg-config NuGet.Core --variable=Libraries))"/* external/nuget-binary/ 84 31 ''; 85 32 33 + # Revert this commit which broke the ability to use pkg-config to locate dlls 34 + patchFlags = [ "-p2" ]; 35 + patches = [ ./git-revert-12d610fb3f6dce121df538e36f21d8c2eeb0a6e3.patch ]; 36 + 86 37 buildInputs = [ 87 38 autoconf automake pkgconfig shared_mime_info intltool 88 39 mono gtk-sharp gnome-sharp unzip 40 + pkgconfig 41 + dotnetPackages.NUnit 42 + dotnetPackages.NUnitRunners 43 + dotnetPackages.Nuget 89 44 ]; 90 45 91 46 preConfigure = "patchShebangs ./configure"; ··· 108 63 > 109 64 EOF 110 65 done 66 + 67 + # Without this, you get a missing DLL error any time you install an addin.. 68 + ln -sv `pkg-config nunit.core --variable=Libraries` $out/lib/monodevelop/AddIns/NUnit 69 + ln -sv `pkg-config nunit.core.interfaces --variable=Libraries` $out/lib/monodevelop/AddIns/NUnit 70 + ln -sv `pkg-config nunit.framework --variable=Libraries` $out/lib/monodevelop/AddIns/NUnit 71 + ln -sv `pkg-config nunit.util --variable=Libraries` $out/lib/monodevelop/AddIns/NUnit 111 72 ''; 112 73 113 74 dontStrip = true;
+57
pkgs/applications/editors/monodevelop/git-revert-12d610fb3f6dce121df538e36f21d8c2eeb0a6e3.patch
··· 1 + diff --git a/main/src/addins/AspNet/MonoDevelop.AspNet.csproj b/main/src/addins/AspNet/MonoDevelop.AspNet.csproj 2 + index 02d3a01..c6daaad 100644 3 + --- a/main/src/addins/AspNet/MonoDevelop.AspNet.csproj 4 + +++ b/main/src/addins/AspNet/MonoDevelop.AspNet.csproj 5 + @@ -452,34 +452,6 @@ 6 + <None Include="Templates\Projects\WebApplication.xpt.xml"> 7 + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> 8 + </None> 9 + - <None Include="..\..\..\packages\Microsoft.AspNet.Mvc.5.2.2\lib\net45\System.Web.Mvc.dll"> 10 + - <Link>System.Web.Mvc.dll</Link> 11 + - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> 12 + - </None> 13 + - <None Include="..\..\..\packages\Microsoft.AspNet.Razor.3.2.2\lib\net45\System.Web.Razor.dll"> 14 + - <Link>System.Web.Razor.dll</Link> 15 + - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> 16 + - </None> 17 + - <None Include="..\..\..\packages\Microsoft.AspNet.WebPages.3.2.2\lib\net45\System.Web.Helpers.dll"> 18 + - <Link>System.Web.Helpers.dll</Link> 19 + - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> 20 + - </None> 21 + - <None Include="..\..\..\packages\Microsoft.AspNet.WebPages.3.2.2\lib\net45\System.Web.WebPages.Deployment.dll"> 22 + - <Link>System.Web.WebPages.Deployment.dll</Link> 23 + - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> 24 + - </None> 25 + - <None Include="..\..\..\packages\Microsoft.AspNet.WebPages.3.2.2\lib\net45\System.Web.WebPages.dll"> 26 + - <Link>System.Web.WebPages.dll</Link> 27 + - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> 28 + - </None> 29 + - <None Include="..\..\..\packages\Microsoft.AspNet.WebPages.3.2.2\lib\net45\System.Web.WebPages.Razor.dll"> 30 + - <Link>System.Web.WebPages.Razor.dll</Link> 31 + - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> 32 + - </None> 33 + - <None Include="..\..\..\packages\Microsoft.Web.Infrastructure.1.0.0.0\lib\net40\Microsoft.Web.Infrastructure.dll"> 34 + - <Link>Microsoft.Web.Infrastructure.dll</Link> 35 + - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> 36 + - </None> 37 + <None Include="packages.config" /> 38 + </ItemGroup> 39 + <ItemGroup> 40 + diff --git a/main/src/addins/AspNet/Properties/MonoDevelop.AspNet.addin.xml b/main/src/addins/AspNet/Properties/MonoDevelop.AspNet.addin.xml 41 + index eab7c32..4a75311 100644 42 + --- a/main/src/addins/AspNet/Properties/MonoDevelop.AspNet.addin.xml 43 + +++ b/main/src/addins/AspNet/Properties/MonoDevelop.AspNet.addin.xml 44 + @@ -1,13 +1,6 @@ 45 + <ExtensionModel> 46 + 47 + <Runtime> 48 + - <Import assembly = "System.Web.Helpers.dll" /> 49 + - <Import assembly = "System.Web.Mvc.dll" /> 50 + - <Import assembly = "System.Web.Razor.dll" /> 51 + - <Import assembly = "System.Web.WebPages.Deployment.dll" /> 52 + - <Import assembly = "System.Web.WebPages.dll" /> 53 + - <Import assembly = "System.Web.WebPages.Razor.dll" /> 54 + - 55 + <Import file = "Html/Schemas/xhtml1-strict.xsd" /> 56 + <Import file = "Html/Schemas/xhtml1-transitional.xsd" /> 57 + <Import file = "Html/Schemas/xhtml1-frameset.xsd" />
+15 -15
pkgs/applications/misc/keepass/default.nix
··· 1 - { stdenv, fetchurl, unzip, makeDesktopItem, mono }: 1 + { stdenv, fetchurl, buildDotnetPackage, makeWrapper, unzip, makeDesktopItem }: 2 2 3 - stdenv.mkDerivation rec { 4 - name = "keepass-${version}"; 3 + buildDotnetPackage rec { 4 + baseName = "keepass"; 5 5 version = "2.29"; 6 6 7 7 src = fetchurl { 8 - url = "mirror://sourceforge/keepass/KeePass-${version}.zip"; 9 - sha256 = "16x7m899akpi036c0wlr41w7fz9q0b69yac9q97rqkixb03l4g9d"; 8 + url = "mirror://sourceforge/keepass/KeePass-${version}-Source.zip"; 9 + sha256 = "051s0aznyyhbpdbly6h5rs0ax0zvkp45dh93nmq6lwhicswjwn5m"; 10 10 }; 11 11 12 12 sourceRoot = "."; 13 13 14 - phases = [ "unpackPhase" "installPhase" ]; 14 + buildInputs = [ unzip ]; 15 + 16 + patches = [ ./keepass.patch ]; 17 + 18 + preConfigure = "rm -rvf Build/*"; 15 19 16 20 desktopItem = makeDesktopItem { 17 21 name = "keepass"; ··· 22 26 categories = "Application;Other;"; 23 27 }; 24 28 29 + outputFiles = [ "Build/KeePass/Release/*" "Build/KeePassLib/Release/*" ]; 30 + dllFiles = [ "KeePassLib.dll" ]; 31 + exeFiles = [ "KeePass.exe" ]; 25 32 26 - installPhase = '' 27 - mkdir -p "$out/bin" 28 - echo "${mono}/bin/mono $out/KeePass.exe" > $out/bin/keepass 29 - chmod +x $out/bin/keepass 30 - echo $out 31 - cp -r ./* $out/ 33 + postInstall = '' 32 34 mkdir -p "$out/share/applications" 33 35 cp ${desktopItem}/share/applications/* $out/share/applications 34 36 ''; 35 37 36 - buildInputs = [ unzip ]; 37 - 38 38 meta = { 39 39 description = "GUI password manager with strong cryptography"; 40 40 homepage = http://www.keepass.info/; 41 - maintainers = with stdenv.lib.maintainers; [amorsillo]; 41 + maintainers = with stdenv.lib.maintainers; [ amorsillo obadz ]; 42 42 platforms = with stdenv.lib.platforms; all; 43 43 license = stdenv.lib.licenses.gpl2; 44 44 };
+89
pkgs/applications/misc/keepass/keepass.patch
··· 1 + diff -Naur old/KeePass/KeePass.csproj new/KeePass/KeePass.csproj 2 + --- old/KeePass/KeePass.csproj 2015-04-10 11:00:46.000000000 +0100 3 + +++ new/KeePass/KeePass.csproj 2015-05-27 16:35:52.196177593 +0100 4 + @@ -1,4 +1,4 @@ 5 + -<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="3.5"> 6 + +<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0"> 7 + <PropertyGroup> 8 + <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> 9 + <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> 10 + @@ -10,7 +10,7 @@ 11 + <RootNamespace>KeePass</RootNamespace> 12 + <AssemblyName>KeePass</AssemblyName> 13 + <ApplicationIcon>KeePass.ico</ApplicationIcon> 14 + - <SignAssembly>true</SignAssembly> 15 + + <SignAssembly>false</SignAssembly> 16 + <AssemblyOriginatorKeyFile>KeePass.pfx</AssemblyOriginatorKeyFile> 17 + <FileUpgradeFlags> 18 + </FileUpgradeFlags> 19 + @@ -1316,6 +1316,5 @@ 20 + </Target> 21 + --> 22 + <PropertyGroup> 23 + - <PostBuildEvent>"$(FrameworkSDKDir)bin\sgen.exe" /assembly:"$(TargetPath)" /force /nologo /compiler:/keycontainer:VS_KEY_33430356D8D7D1B8 /compiler:/delaysign-</PostBuildEvent> 24 + </PropertyGroup> 25 + -</Project> 26 + \ No newline at end of file 27 + +</Project> 28 + diff -Naur old/KeePassLib/KeePassLib.csproj new/KeePassLib/KeePassLib.csproj 29 + --- old/KeePassLib/KeePassLib.csproj 2014-05-08 15:00:24.000000000 +0100 30 + +++ new/KeePassLib/KeePassLib.csproj 2015-05-27 16:35:52.197177562 +0100 31 + @@ -1,4 +1,4 @@ 32 + -<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="3.5"> 33 + +<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0"> 34 + <PropertyGroup> 35 + <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> 36 + <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> 37 + @@ -9,7 +9,7 @@ 38 + <AppDesignerFolder>Properties</AppDesignerFolder> 39 + <RootNamespace>KeePassLib</RootNamespace> 40 + <AssemblyName>KeePassLib</AssemblyName> 41 + - <SignAssembly>true</SignAssembly> 42 + + <SignAssembly>false</SignAssembly> 43 + <AssemblyOriginatorKeyFile>KeePassLib.pfx</AssemblyOriginatorKeyFile> 44 + <FileUpgradeFlags> 45 + </FileUpgradeFlags> 46 + diff -Naur old/KeePass.sln new/KeePass.sln 47 + --- old/KeePass.sln 2009-08-31 19:47:28.000000000 +0100 48 + +++ new/KeePass.sln 2015-05-27 16:35:59.568953518 +0100 49 + @@ -1,11 +1,9 @@ 50 + -Microsoft Visual Studio Solution File, Format Version 10.00 51 + +Microsoft Visual Studio Solution File, Format Version 12.00 52 + # Visual Studio 2008 53 + Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KeePassLib", "KeePassLib\KeePassLib.csproj", "{53573E4E-33CB-4FDB-8698-C95F5E40E7F3}" 54 + EndProject 55 + Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KeePass", "KeePass\KeePass.csproj", "{10938016-DEE2-4A25-9A5A-8FD3444379CA}" 56 + EndProject 57 + -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KeePassLibSD", "KeePassLibSD\KeePassLibSD.csproj", "{DC15F71A-2117-4DEF-8C10-AA355B5E5979}" 58 + -EndProject 59 + Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TrlUtil", "Translation\TrlUtil\TrlUtil.csproj", "{B7E890E7-BF50-4450-9A52-C105BD98651C}" 60 + EndProject 61 + Global 62 + @@ -44,18 +42,6 @@ 63 + {10938016-DEE2-4A25-9A5A-8FD3444379CA}.Release|Mixed Platforms.Build.0 = Release|Any CPU 64 + {10938016-DEE2-4A25-9A5A-8FD3444379CA}.Release|Win32.ActiveCfg = Release|Any CPU 65 + {10938016-DEE2-4A25-9A5A-8FD3444379CA}.Release|x64.ActiveCfg = Release|Any CPU 66 + - {DC15F71A-2117-4DEF-8C10-AA355B5E5979}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 67 + - {DC15F71A-2117-4DEF-8C10-AA355B5E5979}.Debug|Any CPU.Build.0 = Debug|Any CPU 68 + - {DC15F71A-2117-4DEF-8C10-AA355B5E5979}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU 69 + - {DC15F71A-2117-4DEF-8C10-AA355B5E5979}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU 70 + - {DC15F71A-2117-4DEF-8C10-AA355B5E5979}.Debug|Win32.ActiveCfg = Debug|Any CPU 71 + - {DC15F71A-2117-4DEF-8C10-AA355B5E5979}.Debug|x64.ActiveCfg = Debug|Any CPU 72 + - {DC15F71A-2117-4DEF-8C10-AA355B5E5979}.Release|Any CPU.ActiveCfg = Release|Any CPU 73 + - {DC15F71A-2117-4DEF-8C10-AA355B5E5979}.Release|Any CPU.Build.0 = Release|Any CPU 74 + - {DC15F71A-2117-4DEF-8C10-AA355B5E5979}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU 75 + - {DC15F71A-2117-4DEF-8C10-AA355B5E5979}.Release|Mixed Platforms.Build.0 = Release|Any CPU 76 + - {DC15F71A-2117-4DEF-8C10-AA355B5E5979}.Release|Win32.ActiveCfg = Release|Any CPU 77 + - {DC15F71A-2117-4DEF-8C10-AA355B5E5979}.Release|x64.ActiveCfg = Release|Any CPU 78 + {B7E890E7-BF50-4450-9A52-C105BD98651C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 79 + {B7E890E7-BF50-4450-9A52-C105BD98651C}.Debug|Any CPU.Build.0 = Debug|Any CPU 80 + {B7E890E7-BF50-4450-9A52-C105BD98651C}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU 81 + diff -Naur old/Translation/TrlUtil/TrlUtil.csproj new/Translation/TrlUtil/TrlUtil.csproj 82 + --- old/Translation/TrlUtil/TrlUtil.csproj 2013-07-21 10:06:38.000000000 +0100 83 + +++ new/Translation/TrlUtil/TrlUtil.csproj 2015-05-27 16:35:52.197177562 +0100 84 + @@ -1,4 +1,4 @@ 85 + -<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="3.5"> 86 + +<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0"> 87 + <PropertyGroup> 88 + <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> 89 + <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
+109
pkgs/build-support/build-dotnet-package/default.nix
··· 1 + { stdenv, lib, makeWrapper, pkgconfig, mono, dotnetbuildhelpers }: 2 + 3 + attrsOrig @ 4 + { baseName 5 + , version 6 + , buildInputs ? [] 7 + , xBuildFiles ? [ ] 8 + , xBuildFlags ? [ "/p:Configuration=Release" ] 9 + , outputFiles ? [ "bin/Release/*" ] 10 + , dllFiles ? [ "*.dll" ] 11 + , exeFiles ? [ "*.exe" ] 12 + , ... }: 13 + let 14 + arrayToShell = (a: toString (map (lib.escape (lib.stringToCharacters "\\ ';$`()|<>\t") ) a)); 15 + 16 + attrs = { 17 + name = "${baseName}-${version}"; 18 + 19 + buildInputs = [ 20 + pkgconfig 21 + mono 22 + dotnetbuildhelpers 23 + makeWrapper 24 + ] ++ buildInputs; 25 + 26 + configurePhase = '' 27 + runHook preConfigure 28 + 29 + [ -z "$dontPlacateNuget" ] && placate-nuget.sh 30 + [ -z "$dontPlacatePaket" ] && placate-paket.sh 31 + [ -z "$dontPatchFSharpTargets" ] && patch-fsharp-targets.sh 32 + 33 + runHook postConfigure 34 + ''; 35 + 36 + buildPhase = '' 37 + runHook preBuild 38 + 39 + echo Building dotNET packages... 40 + 41 + # Probably needs to be moved to fsharp 42 + if pkg-config FSharp.Core 43 + then 44 + export FSharpTargetsPath="$(dirname $(pkg-config FSharp.Core --variable=Libraries))/Microsoft.FSharp.Targets" 45 + fi 46 + 47 + ran="" 48 + for xBuildFile in ${arrayToShell xBuildFiles} ''${xBuildFilesExtra} 49 + do 50 + ran="yes" 51 + xbuild ${arrayToShell xBuildFlags} ''${xBuildFlagsArray} $xBuildFile 52 + done 53 + 54 + [ -z "$ran" ] && xbuild ${arrayToShell xBuildFlags} ''${xBuildFlagsArray} 55 + 56 + runHook postBuild 57 + ''; 58 + 59 + dontStrip = true; 60 + 61 + installPhase = '' 62 + runHook preInstall 63 + 64 + target="$out/lib/dotnet/${baseName}" 65 + mkdir -p "$target" 66 + 67 + cp -rv ${arrayToShell outputFiles} "''${outputFilesArray[@]}" "$target" 68 + 69 + if [ -z "$dontRemoveDuplicatedDlls" ] 70 + then 71 + pushd "$out" 72 + remove-duplicated-dlls.sh 73 + popd 74 + fi 75 + 76 + set -f 77 + for dllPattern in ${arrayToShell dllFiles} ''${dllFilesArray[@]} 78 + do 79 + set +f 80 + for dll in "$target"/$dllPattern 81 + do 82 + [ -f "$dll" ] || continue 83 + if pkg-config $(basename -s .dll "$dll") 84 + then 85 + echo "$dll already exported by a buildInputs, not re-exporting" 86 + else 87 + ${dotnetbuildhelpers}/bin/create-pkg-config-for-dll.sh "$out/lib/pkgconfig" "$dll" 88 + fi 89 + done 90 + done 91 + 92 + set -f 93 + for exePattern in ${arrayToShell exeFiles} ''${exeFilesArray[@]} 94 + do 95 + set +f 96 + for exe in "$target"/$exePattern 97 + do 98 + [ -f "$exe" ] || continue 99 + mkdir -p "$out"/bin 100 + commandName="$(basename -s .exe "$(echo "$exe" | tr "[A-Z]" "[a-z]")")" 101 + makeWrapper "${mono}/bin/mono \"$exe\"" "$out"/bin/"$commandName" 102 + done 103 + done 104 + 105 + runHook postInstall 106 + ''; 107 + }; 108 + in 109 + stdenv.mkDerivation (attrs // (builtins.removeAttrs attrsOrig [ "buildInputs" ] ))
+23
pkgs/build-support/dotnetbuildhelpers/create-pkg-config-for-dll.sh
··· 1 + #!/usr/bin/env bash 2 + 3 + targetDir="$1" 4 + dllFullPath="$2" 5 + 6 + dllVersion="$(monodis --assembly "$dllFullPath" | grep ^Version: | cut -f 2 -d : | xargs)" 7 + [ -z "$dllVersion" ] && echo "Defaulting dllVersion to 0.0.0" && dllVersion="0.0.0" 8 + dllFileName="$(basename $dllFullPath)" 9 + dllRootName="$(basename -s .dll $dllFileName)" 10 + targetPcFile="$targetDir"/"$dllRootName".pc 11 + 12 + mkdir -p "$targetDir" 13 + 14 + cat > $targetPcFile << EOF 15 + Libraries=$dllFullPath 16 + 17 + Name: $dllRootName 18 + Description: $dllRootName 19 + Version: $dllVersion 20 + Libs: -r:$dllFileName 21 + EOF 22 + 23 + echo "Created $targetPcFile"
+18
pkgs/build-support/dotnetbuildhelpers/default.nix
··· 1 + { helperFunctions, mono, pkgconfig }: 2 + helperFunctions.runCommand 3 + "dotnetbuildhelpers" 4 + { preferLocalBuild = true; } 5 + '' 6 + target="$out/bin" 7 + mkdir -p "$target" 8 + 9 + for script in ${./create-pkg-config-for-dll.sh} ${./patch-fsharp-targets.sh} ${./remove-duplicated-dlls.sh} ${./placate-nuget.sh} ${./placate-paket.sh} 10 + do 11 + scriptName="$(basename "$script" | cut -f 2- -d -)" 12 + cp -v "$script" "$target"/"$scriptName" 13 + chmod 755 "$target"/"$scriptName" 14 + patchShebangs "$target"/"$scriptName" 15 + substituteInPlace "$target"/"$scriptName" --replace pkg-config ${pkgconfig}/bin/pkg-config 16 + substituteInPlace "$target"/"$scriptName" --replace monodis ${mono}/bin/monodis 17 + done 18 + ''
+20
pkgs/build-support/dotnetbuildhelpers/patch-fsharp-targets.sh
··· 1 + #!/bin/bash 2 + 3 + # Some project files look for F# targets in $(FSharpTargetsPath) 4 + # so it's a good idea to add something like this to your ~/.bash_profile: 5 + 6 + # export FSharpTargetsPath=$(dirname $(which fsharpc))/../lib/mono/4.0/Microsoft.FSharp.Targets 7 + 8 + # In build scripts, you would add somehting like this: 9 + 10 + # export FSharpTargetsPath="${fsharp}/lib/mono/4.0/Microsoft.FSharp.Targets" 11 + 12 + # However, some project files look for F# targets in the main Mono directory. When that happens 13 + # patch the project files using this script so they will look in $(FSharpTargetsPath) instead. 14 + 15 + echo "Patching F# targets in fsproj files..." 16 + 17 + find -iname \*.fsproj -print -exec \ 18 + sed --in-place=.bak \ 19 + -e 's,<FSharpTargetsPath>\([^<]*\)</FSharpTargetsPath>,<FSharpTargetsPath Condition="Exists('\'\\1\'')">\1</FSharpTargetsPath>,'g \ 20 + {} \;
+7
pkgs/build-support/dotnetbuildhelpers/placate-nuget.sh
··· 1 + #!/usr/bin/env bash 2 + 3 + echo Placating Nuget in nuget.targets 4 + find -iname nuget.targets -print -exec sed --in-place=bak -e 's,mono --runtime[^<]*,true NUGET PLACATED BY buildDotnetPackage,g' {} \; 5 + 6 + echo Just to be sure, replacing Nuget executables by empty files. 7 + find . -iname nuget.exe \! -size 0 -exec mv -v {} {}.bak \; -exec touch {} \;
+7
pkgs/build-support/dotnetbuildhelpers/placate-paket.sh
··· 1 + #!/usr/bin/env bash 2 + 3 + echo Placating Paket in paket.targets 4 + find -iname paket.targets -print -exec sed --in-place=bak -e 's,mono --runtime[^<]*,true PAKET PLACATED BY buildDotnetPackage,g' {} \; 5 + 6 + echo Just to be sure, replacing Paket executables by empty files. 7 + find . -iname paket\*.exe \! -size 0 -exec mv -v {} {}.bak \; -exec touch {} \;
+22
pkgs/build-support/dotnetbuildhelpers/remove-duplicated-dlls.sh
··· 1 + #!/usr/bin/env bash 2 + 3 + IFS=" 4 + " 5 + 6 + for dll in $(find -iname \*.dll) 7 + do 8 + baseName="$(basename "$dll" | sed "s/.dll$//i")" 9 + if pkg-config "$baseName" 10 + then 11 + candidateDll="$(pkg-config "$baseName" --variable=Libraries)" 12 + 13 + if diff "$dll" "$candidateDll" >/dev/null 14 + then 15 + echo "$dll is identical to $candidateDll. Substituting..." 16 + rm -vf "$dll" 17 + ln -sv "$candidateDll" "$dll" 18 + else 19 + echo "$dll and $candidateDll share the same name but have different contents, leaving alone." 20 + fi 21 + fi 22 + done
+40
pkgs/build-support/fetchnuget/default.nix
··· 1 + { stdenv, fetchurl, buildDotnetPackage, unzip }: 2 + 3 + attrs @ 4 + { baseName 5 + , version 6 + , url ? "https://www.nuget.org/api/v2/package/${baseName}/${version}" 7 + , sha256 ? "" 8 + , md5 ? "" 9 + , ... 10 + }: 11 + buildDotnetPackage ({ 12 + src = fetchurl { 13 + inherit url sha256 md5; 14 + name = "${baseName}.${version}.zip"; 15 + }; 16 + 17 + sourceRoot = "."; 18 + 19 + buildInputs = [ unzip ]; 20 + 21 + phases = [ "unpackPhase" "installPhase" ]; 22 + 23 + preInstall = '' 24 + function traverseRename () { 25 + for e in * 26 + do 27 + t="$(echo "$e" | sed -e "s/%20/\ /g" -e "s/%2B/+/g")" 28 + [ "$t" != "$e" ] && mv -vn "$e" "$t" 29 + if [ -d "$t" ] 30 + then 31 + cd "$t" 32 + traverseRename 33 + cd .. 34 + fi 35 + done 36 + } 37 + 38 + traverseRename 39 + ''; 40 + } // attrs)
+8 -2
pkgs/development/compilers/fsharp/default.nix
··· 1 - { stdenv, fetchurl, mono, pkgconfig, autoconf, automake, which }: 1 + # Temporaririly avoid dependency on dotnetbuildhelpers to avoid rebuilding many times while working on it 2 + 3 + { stdenv, fetchurl, mono, pkgconfig, dotnetbuildhelpers, autoconf, automake, which }: 2 4 3 5 stdenv.mkDerivation rec { 4 6 name = "fsharp-${version}"; ··· 9 11 sha256 = "16kqgdx0y0lmxv59mc4g7l5ll60nixg5b8bg07vxfnqrf7i6dffd"; 10 12 }; 11 13 12 - buildInputs = [ mono pkgconfig autoconf automake which ]; 14 + buildInputs = [ mono pkgconfig dotnetbuildhelpers autoconf automake which ]; 13 15 configurePhase = '' 14 16 substituteInPlace ./autogen.sh --replace "/usr/bin/env sh" "/bin/sh" 15 17 ./autogen.sh --prefix $out ··· 23 25 substituteInPlace $out/bin/fsharpiAnyCpu --replace " mono " " ${mono}/bin/mono " 24 26 ln -s $out/bin/fsharpc $out/bin/fsc 25 27 ln -s $out/bin/fsharpi $out/bin/fsi 28 + for dll in "$out/lib/mono/4.5"/FSharp*.dll 29 + do 30 + create-pkg-config-for-dll.sh "$out/lib/pkgconfig" "$dll" 31 + done 26 32 ''; 27 33 28 34 # To fix this error when running:
+14 -1
pkgs/development/compilers/mono/default.nix
··· 1 - { stdenv, fetchurl, bison, pkgconfig, glib, gettext, perl, libgdiplus, libX11, callPackage, ncurses, zlib, withLLVM ? true }: 1 + { stdenv, fetchurl, bison, pkgconfig, glib, gettext, perl, libgdiplus, libX11, callPackage, ncurses, zlib, withLLVM ? false, cacert }: 2 2 3 3 let 4 4 llvm = callPackage ./llvm.nix { }; ··· 31 31 # Parallel building doesn't work, as shows http://hydra.nixos.org/build/2983601 32 32 enableParallelBuilding = false; 33 33 34 + # We want pkg-config to take priority over the dlls in the Mono framework and the GAC 35 + # because we control pkg-config 36 + patches = [ ./pkgconfig-before-gac.patch ]; 37 + 34 38 # Patch all the necessary scripts. Also, if we're using LLVM, we fix the default 35 39 # LLVM path to point into the Mono LLVM build, since it's private anyway. 36 40 preBuild = '' 37 41 makeFlagsArray=(INSTALL=`type -tp install`) 38 42 patchShebangs ./ 43 + substituteInPlace mcs/class/corlib/System/Environment.cs --replace /usr/share "$out/share" 39 44 '' + stdenv.lib.optionalString withLLVM '' 40 45 substituteInPlace mono/mini/aot-compiler.c --replace "llvm_path = g_strdup (\"\")" "llvm_path = g_strdup (\"${llvm}/bin/\")" 41 46 ''; ··· 48 53 sed -i "s@libX11.so.6@${libX11}/lib/libX11.so.6@g" $i 49 54 sed -i "s@/.*libgdiplus.so@${libgdiplus}/lib/libgdiplus.so@g" $i 50 55 done 56 + ''; 57 + 58 + # Without this, any Mono application attempting to open an SSL connection will throw with 59 + # The authentication or decryption has failed. 60 + # ---> Mono.Security.Protocol.Tls.TlsException: Invalid certificate received from server. 61 + postInstall = '' 62 + echo "Updating Mono key store" 63 + $out/bin/cert-sync ${cacert}/etc/ssl/certs/ca-bundle.crt 51 64 ''; 52 65 53 66 meta = {
+65
pkgs/development/compilers/mono/pkgconfig-before-gac.patch
··· 1 + diff -Naur mono-4.0.1.old/mcs/tools/xbuild/data/12.0/Microsoft.Common.targets mono-4.0.1/mcs/tools/xbuild/data/12.0/Microsoft.Common.targets 2 + --- mono-4.0.1.old/mcs/tools/xbuild/data/12.0/Microsoft.Common.targets 2015-04-24 02:26:18.000000000 +0100 3 + +++ mono-4.0.1/mcs/tools/xbuild/data/12.0/Microsoft.Common.targets 2015-05-26 00:52:33.997847464 +0100 4 + @@ -229,8 +229,8 @@ 5 + $(ReferencePath); 6 + @(AdditionalReferencePath); 7 + {HintPathFromItem}; 8 + - {TargetFrameworkDirectory}; 9 + {PkgConfig}; 10 + + {TargetFrameworkDirectory}; 11 + {GAC}; 12 + {RawFileName}; 13 + $(OutDir) 14 + diff -Naur mono-4.0.1.old/mcs/tools/xbuild/data/14.0/Microsoft.Common.targets mono-4.0.1/mcs/tools/xbuild/data/14.0/Microsoft.Common.targets 15 + --- mono-4.0.1.old/mcs/tools/xbuild/data/14.0/Microsoft.Common.targets 2015-04-24 02:26:18.000000000 +0100 16 + +++ mono-4.0.1/mcs/tools/xbuild/data/14.0/Microsoft.Common.targets 2015-05-26 00:52:41.832612748 +0100 17 + @@ -214,8 +214,8 @@ 18 + $(ReferencePath); 19 + @(AdditionalReferencePath); 20 + {HintPathFromItem}; 21 + - {TargetFrameworkDirectory}; 22 + {PkgConfig}; 23 + + {TargetFrameworkDirectory}; 24 + {GAC}; 25 + {RawFileName}; 26 + $(OutDir) 27 + diff -Naur mono-4.0.1.old/mcs/tools/xbuild/data/2.0/Microsoft.Common.targets mono-4.0.1/mcs/tools/xbuild/data/2.0/Microsoft.Common.targets 28 + --- mono-4.0.1.old/mcs/tools/xbuild/data/2.0/Microsoft.Common.targets 2015-04-24 02:26:18.000000000 +0100 29 + +++ mono-4.0.1/mcs/tools/xbuild/data/2.0/Microsoft.Common.targets 2015-05-26 00:52:46.298478961 +0100 30 + @@ -139,8 +139,8 @@ 31 + $(ReferencePath); 32 + @(AdditionalReferencePath); 33 + {HintPathFromItem}; 34 + - {TargetFrameworkDirectory}; 35 + {PkgConfig}; 36 + + {TargetFrameworkDirectory}; 37 + {GAC}; 38 + {RawFileName}; 39 + $(OutDir) 40 + diff -Naur mono-4.0.1.old/mcs/tools/xbuild/data/3.5/Microsoft.Common.targets mono-4.0.1/mcs/tools/xbuild/data/3.5/Microsoft.Common.targets 41 + --- mono-4.0.1.old/mcs/tools/xbuild/data/3.5/Microsoft.Common.targets 2015-04-24 02:26:18.000000000 +0100 42 + +++ mono-4.0.1/mcs/tools/xbuild/data/3.5/Microsoft.Common.targets 2015-05-26 00:52:52.119304583 +0100 43 + @@ -167,8 +167,8 @@ 44 + $(ReferencePath); 45 + @(AdditionalReferencePath); 46 + {HintPathFromItem}; 47 + - {TargetFrameworkDirectory}; 48 + {PkgConfig}; 49 + + {TargetFrameworkDirectory}; 50 + {GAC}; 51 + {RawFileName}; 52 + $(OutDir) 53 + diff -Naur mono-4.0.1.old/mcs/tools/xbuild/data/4.0/Microsoft.Common.targets mono-4.0.1/mcs/tools/xbuild/data/4.0/Microsoft.Common.targets 54 + --- mono-4.0.1.old/mcs/tools/xbuild/data/4.0/Microsoft.Common.targets 2015-04-24 02:26:18.000000000 +0100 55 + +++ mono-4.0.1/mcs/tools/xbuild/data/4.0/Microsoft.Common.targets 2015-05-26 00:52:56.519172776 +0100 56 + @@ -229,8 +229,8 @@ 57 + $(ReferencePath); 58 + @(AdditionalReferencePath); 59 + {HintPathFromItem}; 60 + - {TargetFrameworkDirectory}; 61 + {PkgConfig}; 62 + + {TargetFrameworkDirectory}; 63 + {GAC}; 64 + {RawFileName}; 65 + $(OutDir)
+88
pkgs/development/dotnet-modules/patches/monodevelop-fsharpbinding.addin-xml.patch
··· 1 + --- fsharpbinding-a09c818/monodevelop/MonoDevelop.FSharpBinding/FSharpBinding.addin.xml.orig.old 2015-06-03 19:53:00.116849746 +0100 2 + +++ fsharpbinding-a09c818/monodevelop/MonoDevelop.FSharpBinding/FSharpBinding.addin.xml.orig 2015-06-03 19:56:30.112579384 +0100 3 + @@ -130,6 +130,11 @@ 4 + <!-- New projects will be created with this targets file. --> 5 + <Extension path="/MonoDevelop/ProjectModel/MSBuildItemTypes"> 6 + <!-- If FSharp 3.1 is available, use it. Note XS looks for the first DotNetProject node under 'Extension' --> 7 + + <Condition id="MSBuildTargetIsAvailable" target="$(FSharpTargetsPath)" > 8 + + <DotNetProject language="F#" extension="fsproj" guid="{f2a71f9b-5d33-465a-a702-920d77279786}" import="$(FSharpTargetsPath)" resourceHandler="MonoDevelop.FSharp.FSharpResourceIdBuilder"/> 9 + + </Condition> 10 + + 11 + + <!-- If FSharp 3.1 is available, use it. Note XS looks for the first DotNetProject node under 'Extension' --> 12 + <Condition id="MSBuildTargetIsAvailable" target="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.1\Framework\v4.0\Microsoft.FSharp.Targets" > 13 + <DotNetProject language="F#" extension="fsproj" guid="{f2a71f9b-5d33-465a-a702-920d77279786}" import="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.1\Framework\v4.0\Microsoft.FSharp.Targets" resourceHandler="MonoDevelop.FSharp.FSharpResourceIdBuilder"/> 14 + </Condition> 15 + @@ -182,14 +187,7 @@ 16 + <ProjectTemplate id="FSharpConsoleProject" file="Templates/FSharpConsoleProject.xpt.xml"/> 17 + <ProjectTemplate id="FSharpLibraryProject" file="Templates/FSharpLibraryProject.xpt.xml"/> 18 + <!-- Only include the tutorial project if an F# 3.0 or 3.1 target is available as this includes F# 3.0 specific features --> 19 + - <ComplexCondition> 20 + - <Or> 21 + - <Condition id="MSBuildTargetIsAvailable" target="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets" /> 22 + - <Condition id="MSBuildTargetIsAvailable" target="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.1\Framework\v4.0\Microsoft.FSharp.Targets" /> 23 + - </Or> 24 + <ProjectTemplate id="FSharpTutorialProject" file="Templates/FSharpTutorialProject.xpt.xml"/> 25 + - </ComplexCondition> 26 + - 27 + <ProjectTemplate id="FSharpGtkProject" file="Templates/FSharpGtkProject.xpt.xml"/> 28 + <ProjectTemplate id="FSharpNUnitLibraryProject" file="Templates/FSharpNUnitLibraryProject.xpt.xml"/> 29 + </Extension> 30 + @@ -267,13 +265,7 @@ 31 + <!-- F# interactive --> 32 + 33 + <Extension path="/MonoDevelop/Ide/Pads"> 34 + - <ComplexCondition> 35 + - <Or> 36 + - <Condition id="MSBuildTargetIsAvailable" target="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets" /> 37 + - <Condition id="MSBuildTargetIsAvailable" target="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.1\Framework\v4.0\Microsoft.FSharp.Targets" /> 38 + - </Or> 39 + <Pad id="MonoDevelop.FSharp.FSharpInteractivePad" defaultPlacement="Bottom" _label="F# Interactive" icon="md-project" class="MonoDevelop.FSharp.FSharpInteractivePad" /> 40 + - </ComplexCondition> 41 + </Extension> 42 + 43 + <Extension path = "/MonoDevelop/Ide/Pads/ProjectPad"> 44 + @@ -281,11 +273,6 @@ 45 + </Extension> 46 + 47 + <Extension path="/MonoDevelop/Ide/Commands"> 48 + - <ComplexCondition> 49 + - <Or> 50 + - <Condition id="MSBuildTargetIsAvailable" target="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets" /> 51 + - <Condition id="MSBuildTargetIsAvailable" target="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.1\Framework\v4.0\Microsoft.FSharp.Targets" /> 52 + - </Or> 53 + <Category _name = "F# Integration" id="F# Integration"> 54 + <Command id="MonoDevelop.FSharp.FSharpCommands.ShowFSharpInteractive" 55 + _label = "F# Interactive" 56 + @@ -330,32 +317,19 @@ 57 + macShortcut="Meta|Control|C" 58 + shortcut="Ctrl|Alt|C" /> 59 + </Category> 60 + - </ComplexCondition> 61 + </Extension> 62 + 63 + <Extension path = "/MonoDevelop/SourceEditor2/ContextMenu/Editor"> 64 + - <ComplexCondition> 65 + - <Or> 66 + - <Condition id="MSBuildTargetIsAvailable" target="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets" /> 67 + - <Condition id="MSBuildTargetIsAvailable" target="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.1\Framework\v4.0\Microsoft.FSharp.Targets" /> 68 + - </Or> 69 + <SeparatorItem id = "FSharpInteractiveStart" /> 70 + <CommandItem id = "MonoDevelop.FSharp.FSharpCommands.SendSelection" /> 71 + <CommandItem id = "MonoDevelop.FSharp.FSharpCommands.SendLine" /> 72 + <CommandItem id = "MonoDevelop.FSharp.FSharpCommands.SendReferences" /> 73 + - </ComplexCondition> 74 + </Extension> 75 + 76 + <Extension path = "/MonoDevelop/Ide/MainMenu/Edit"> 77 + - <ComplexCondition> 78 + - <Or> 79 + - <Condition id="MSBuildTargetIsAvailable" target="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets" /> 80 + - <Condition id="MSBuildTargetIsAvailable" target="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.1\Framework\v4.0\Microsoft.FSharp.Targets" /> 81 + - </Or> 82 + <CommandItem id = "MonoDevelop.FSharp.FSharpCommands.SendSelection" /> 83 + <CommandItem id = "MonoDevelop.FSharp.FSharpCommands.SendLine" /> 84 + <CommandItem id = "MonoDevelop.FSharp.FSharpCommands.SendReferences" /> 85 + - </ComplexCondition> 86 + </Extension> 87 + 88 + <!--- F# Android -->
+43
pkgs/development/dotnet-modules/patches/monodevelop-fsharpbinding.references.patch
··· 1 + --- fsharpbinding-a09c818/monodevelop/MonoDevelop.FSharpBinding/MonoDevelop.FSharp.fsproj.orig.old 2015-06-03 18:48:55.345385084 +0100 2 + +++ fsharpbinding-a09c818/monodevelop/MonoDevelop.FSharpBinding/MonoDevelop.FSharp.fsproj.orig 2015-06-03 19:00:11.453399028 +0100 3 + @@ -185,19 +185,19 @@ 4 + <Private>False</Private> 5 + <HintPath>INSERT_FSPROJ_MDROOT\AddIns\NUnit\MonoDevelop.NUnit.dll</HintPath> 6 + </Reference> 7 + - <ProjectReference Include="..\..\FSharp.CompilerBinding\FSharp.CompilerBinding.fsproj"> 8 + - <Project>{88F6940F-D300-474C-B2A7-E2ECD5B04B57}</Project> 9 + - <Name>FSharp.CompilerBinding</Name> 10 + - </ProjectReference> 11 + + <Reference Include="FSharp.CompilerBinding"> 12 + + <Private>True</Private> 13 + + </Reference> 14 + <ProjectReference Include="Gui\MonoDevelop.FSharp.Gui.csproj"> 15 + <Project>{FD0D1033-9145-48E5-8ED8-E2365252878C}</Project> 16 + <Name>MonoDevelop.FSharp.Gui</Name> 17 + </ProjectReference> 18 + - <Reference Include="FSharp.Core, Version=$(TargetFSharpCoreVersion), Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> 19 + + <Reference Include="FSharp.Core"> 20 + <Private>True</Private> 21 + </Reference> 22 + <Reference Include="FSharp.Compiler.Service"> 23 + <HintPath>packages\FSharp.Compiler.Service.0.0.85\lib\net45\FSharp.Compiler.Service.dll</HintPath> 24 + + <Private>True</Private> 25 + </Reference> 26 + <Reference Include="Mono.Cecil"> 27 + <HintPath>packages\Mono.Cecil.0.9.5.4\lib\net40\Mono.Cecil.dll</HintPath> 28 + @@ -213,12 +213,15 @@ 29 + </Reference> 30 + <Reference Include="FantomasLib"> 31 + <HintPath>packages\Fantomas.1.6.0\lib\FantomasLib.dll</HintPath> 32 + + <Private>True</Private> 33 + </Reference> 34 + <Reference Include="FSharp.Compiler.CodeDom"> 35 + <HintPath>packages\FSharp.Compiler.CodeDom.0.9.1\lib\net40\FSharp.Compiler.CodeDom.dll</HintPath> 36 + + <Private>True</Private> 37 + </Reference> 38 + <Reference Include="ExtCore"> 39 + <HintPath>packages\ExtCore.0.8.45\lib\net40\ExtCore.dll</HintPath> 40 + + <Private>True</Private> 41 + </Reference> 42 + </ItemGroup> 43 + <Import Project="$(SolutionDir)\.nuget\NuGet.targets" Condition="Exists('$(SolutionDir)\.nuget\NuGet.targets')" />
+11
pkgs/development/dotnet-modules/patches/newtonsoft-json.references.patch
··· 1 + --- Newtonsoft.Json-6.0.8/Src/Newtonsoft.Json.Tests/Newtonsoft.Json.Tests.csproj.old 2015-01-11 06:46:39.000000000 +0000 2 + +++ Newtonsoft.Json-6.0.8/Src/Newtonsoft.Json.Tests/Newtonsoft.Json.Tests.csproj 2015-05-25 21:29:40.546808622 +0100 3 + @@ -52,6 +52,8 @@ 4 + <Reference Include="System.Data.Linq" /> 5 + <Reference Include="System.Drawing" /> 6 + <Reference Include="System.Numerics" /> 7 + + <Reference Include="System.Collections" /> 8 + + <Reference Include="System.Runtime" /> 9 + <Reference Include="System.Runtime.Serialization" /> 10 + <Reference Include="System.Web" /> 11 + <Reference Include="System.Web.Extensions" />
+9
pkgs/top-level/all-packages.nix
··· 285 285 dotnetfx = dotnetfx40; 286 286 }; 287 287 288 + dotnetbuildhelpers = import ../build-support/dotnetbuildhelpers { 289 + inherit mono helperFunctions pkgconfig; 290 + }; 291 + 288 292 scatterOutputHook = makeSetupHook {} ../build-support/setup-hooks/scatter_output.sh; 289 293 290 294 vsenv = callPackage ../build-support/vsenv { ··· 408 412 url = "http://repo.or.cz/${repo}.git/snapshot/${rev}.tar.gz"; 409 413 meta.homepage = "http://repo.or.cz/${repo}.git/"; 410 414 }; 415 + 416 + fetchNuGet = import ../build-support/fetchnuget { inherit stdenv fetchurl buildDotnetPackage unzip; }; 417 + buildDotnetPackage = import ../build-support/build-dotnet-package { inherit stdenv lib makeWrapper mono pkgconfig dotnetbuildhelpers; }; 411 418 412 419 resolveMirrorURLs = {url}: fetchurl { 413 420 showURLs = true; ··· 3871 3878 falcon = callPackage ../development/interpreters/falcon { }; 3872 3879 3873 3880 fsharp = callPackage ../development/compilers/fsharp {}; 3881 + 3882 + dotnetPackages = recurseIntoAttrs (callPackage ./dotnet-packages.nix { inherit stdenv fetchNuGet; }); 3874 3883 3875 3884 go_1_0 = callPackage ../development/compilers/go { }; 3876 3885
+495
pkgs/top-level/dotnet-packages.nix
··· 1 + { stdenv 2 + , pkgs 3 + , buildDotnetPackage 4 + , fetchurl 5 + , fetchFromGitHub 6 + , fetchNuGet 7 + , pkgconfig 8 + , mono 9 + , monodevelop 10 + , fsharp 11 + , unzip 12 + , overrides ? {} 13 + }: 14 + 15 + let self = dotnetPackages // overrides; dotnetPackages = with self; { 16 + 17 + Autofac = fetchNuGet { 18 + baseName = "Autofac"; 19 + version = "3.5.2"; 20 + sha256 = "194cs8ybn5xjqnzy643w5i62m0d5s34d3nshwxp2v4fcb94wa4ri"; 21 + outputFiles = [ "lib/portable-net4+sl5+netcore45+wpa81+wp8+MonoAndroid1+MonoTouch1/*" ]; 22 + }; 23 + 24 + Fake = fetchNuGet { 25 + baseName = "FAKE"; 26 + version = "3.33.0"; 27 + sha256 = "04gllx9d1w8zn9gq9p5k76b79ix07rilk3apdi72dmz6h3yylcdm"; 28 + outputFiles = [ "tools/*" ]; 29 + dllFiles = [ "Fake*.dll" ]; 30 + }; 31 + 32 + Fantomas = fetchNuGet { 33 + baseName = "Fantomas"; 34 + version = "1.6.0"; 35 + sha256 = "1b9rd3i76b5xzv0j62dvfr1ksdwvb59vxw6jhzpi018axjn6757q"; 36 + outputFiles = [ "lib/*" ]; 37 + dllFiles = [ "Fantomas*.dll" ]; 38 + }; 39 + 40 + FSharpCompilerCodeDom = fetchNuGet { 41 + baseName = "FSharp.Compiler.CodeDom"; 42 + version = "0.9.2"; 43 + sha256 = "0cy9gbvmfx2g74m7bgp6x9mr4avb6s560yjii7cyyxb7jlwabfcj"; 44 + outputFiles = [ "lib/net40/*" ]; 45 + }; 46 + 47 + FsCheck = fetchNuGet { 48 + baseName = "FsCheck"; 49 + version = "1.0.4"; 50 + sha256 = "1q2wk4d4d1q94qzcccgmxb2lh0b8qkmpyz0p7lfphkw2gx6cy5ad"; 51 + outputFiles = [ "lib/net45/*" ]; 52 + }; 53 + 54 + FsCheckNunit = fetchNuGet { 55 + baseName = "FsCheck.Nunit"; 56 + version = "1.0.4"; 57 + sha256 = "1s62jrsa5hxqy1ginl8r29rjdc8vbkwmz7mb0hglhwccdqfyr5xy"; 58 + outputFiles = [ "lib/net45/*" ]; 59 + }; 60 + 61 + FsUnit = fetchNuGet { 62 + baseName = "FsUnit"; 63 + version = "1.3.0.1"; 64 + sha256 = "1k7w8pc81aplsfn7n46617khmzingd2v7hcgdhh7vgsssibwms64"; 65 + outputFiles = [ "Lib/Net40/*" ]; 66 + }; 67 + 68 + NUnit = fetchNuGet { 69 + baseName = "NUnit"; 70 + version = "2.6.4"; 71 + sha256 = "1acwsm7p93b1hzfb83ia33145x0w6fvdsfjm9xflsisljxpdx35y"; 72 + outputFiles = [ "lib/*" ]; 73 + }; 74 + 75 + NUnitRunners = fetchNuGet { 76 + baseName = "NUnit.Runners"; 77 + version = "2.6.4"; 78 + sha256 = "11nmi7vikn9idz8qcad9z7f73arsh5rw18fc1sri9ywz77mpm1s4"; 79 + outputFiles = [ "tools/*" ]; 80 + preInstall = "mv -v tools/lib/* tools && rmdir -v tools/lib"; 81 + }; 82 + 83 + SystemCollectionsImmutable = fetchNuGet { 84 + baseName = "System.Collections.Immutable"; 85 + version = "1.1.36"; 86 + sha256 = "0760kzf5s771pnvnxsgas446kqdh1b71w6g3k75jpzldfmsd3vyq"; 87 + outputFiles = [ "lib/portable-net45+win8+wp8+wpa81/*" ]; 88 + }; 89 + 90 + ExtCore = buildDotnetPackage rec { 91 + baseName = "ExtCore"; 92 + version = "0.8.46"; 93 + 94 + src = fetchFromGitHub { 95 + owner = "jack-pappas"; 96 + repo = "ExtCore"; 97 + rev = "0269b6d3c479f45abd7aa983aaeca08d07473943"; 98 + sha256 = "1kxkiszpvqisffhd6wciha8j3dhkq06w9c540bmq8zixa4xaj83p"; 99 + }; 100 + 101 + buildInputs = [ 102 + fsharp 103 + dotnetPackages.NUnit 104 + dotnetPackages.FsCheck 105 + ]; 106 + 107 + postConfigure = '' 108 + # Fix case 109 + sed -i -e s,nuget.targets,NuGet.targets, ExtCore.Tests/ExtCore.Tests.fsproj 110 + ''; 111 + 112 + xBuildFlags = [ "/p:Configuration=Release (net45)" ]; 113 + outputFiles = [ "ExtCore/bin/net45/Release/*" ]; 114 + 115 + meta = { 116 + description = "ExtCore is an extended core library for F#"; 117 + homepage = "https://github.com/jack-pappas/ExtCore"; 118 + license = stdenv.lib.licenses.asl20; 119 + maintainers = with stdenv.lib.maintainers; [ obadz ]; 120 + platforms = with stdenv.lib.platforms; linux; 121 + }; 122 + }; 123 + 124 + FSharpAutoComplete = buildDotnetPackage rec { 125 + baseName = "FSharp.AutoComplete"; 126 + version = "0.16.0"; 127 + 128 + src = fetchurl { 129 + name = "${baseName}-${version}.tar.gz"; 130 + url = "https://github.com/fsharp/FSharp.AutoComplete/archive/${version}.tar.gz"; 131 + sha256 = "0mwp456zfw1sjy2mafz2shx0sjn4f858pfnsmawy50g8l2znw8qg"; 132 + }; 133 + 134 + buildInputs = [ 135 + fsharp 136 + dotnetPackages.FSharpCompilerService 137 + dotnetPackages.NewtonsoftJson 138 + dotnetPackages.NDeskOptions 139 + ]; 140 + 141 + outputFiles = [ "FSharp.AutoComplete/bin/Release/*" ]; 142 + 143 + meta = { 144 + description = "This project provides a command-line interface to the FSharp.Compiler.Service project. It is intended to be used as a backend service for rich editing or 'intellisense' features for editors."; 145 + homepage = "https://github.com/fsharp/FSharp.AutoComplete"; 146 + license = stdenv.lib.licenses.asl20; 147 + maintainers = with stdenv.lib.maintainers; [ obadz ]; 148 + platforms = with stdenv.lib.platforms; linux; 149 + }; 150 + }; 151 + 152 + FSharpCompilerService = buildDotnetPackage rec { 153 + baseName = "FSharp.Compiler.Service"; 154 + version = "0.0.89"; 155 + 156 + src = fetchFromGitHub { 157 + owner = "fsharp"; 158 + repo = "FSharp.Compiler.Service"; 159 + rev = "55a8143a82bb31c3e8c1ad2af64eb64162fed0d7"; 160 + sha256 = "1f5f97382h8v9p0j7c2gksrps12d869m752n692b3g0k8h4zpial"; 161 + }; 162 + 163 + buildInputs = [ 164 + fsharp 165 + dotnetPackages.NUnit 166 + ]; 167 + 168 + outputFiles = [ "bin/v4.5/*" ]; 169 + 170 + meta = { 171 + description = "The F# compiler services package is a component derived from the F# compiler source code that exposes additional functionality for implementing F# language bindings"; 172 + homepage = "http://fsharp.github.io/FSharp.Compiler.Service/"; 173 + license = stdenv.lib.licenses.asl20; 174 + maintainers = with stdenv.lib.maintainers; [ obadz ]; 175 + platforms = with stdenv.lib.platforms; linux; 176 + }; 177 + }; 178 + 179 + FSharpData = buildDotnetPackage rec { 180 + baseName = "FSharp.Data"; 181 + version = "2.2.2"; 182 + 183 + src = fetchurl { 184 + name = "${baseName}-${version}.tar.gz"; 185 + url = "https://github.com/fsharp/FSharp.Data/archive/${version}.tar.gz"; 186 + sha256 = "1li33ydjxz18v8siw53vv1nmkp5w7sdlsjcrfp6dzcynpvwbjw3s"; 187 + }; 188 + 189 + buildInputs = [ fsharp ]; 190 + 191 + fileProvidedTypes = fetchurl { 192 + name = "ProvidedTypes.fs"; 193 + url = https://raw.githubusercontent.com/fsprojects/FSharp.TypeProviders.StarterPack/877014bfa6244ac382642e113d7cd6c9bc27bc6d/src/ProvidedTypes.fs; 194 + sha256 = "1lb056v1xld1rfx6a8p8i2jz8i6qa2r2823n5izsf1qg1qgf2980"; 195 + }; 196 + 197 + fileDebugProvidedTypes = fetchurl { 198 + name = "DebugProvidedTypes.fs"; 199 + url = https://raw.githubusercontent.com/fsprojects/FSharp.TypeProviders.StarterPack/877014bfa6244ac382642e113d7cd6c9bc27bc6d/src/DebugProvidedTypes.fs; 200 + sha256 = "1whyrf2jv6fs7kgysn2086v15ggjsd54g1xfs398mp46m0nxp91f"; 201 + }; 202 + 203 + preConfigure = '' 204 + # Copy single-files-in-git-repos 205 + mkdir -p "paket-files/fsprojects/FSharp.TypeProviders.StarterPack/src" 206 + cp -v "${fileProvidedTypes}" "paket-files/fsprojects/FSharp.TypeProviders.StarterPack/src/ProvidedTypes.fs" 207 + cp -v "${fileDebugProvidedTypes}" "paket-files/fsprojects/FSharp.TypeProviders.StarterPack/src/DebugProvidedTypes.fs" 208 + ''; 209 + 210 + xBuildFiles = [ "src/FSharp.Data.fsproj" "src/FSharp.Data.DesignTime.fsproj" ]; 211 + outputFiles = [ "bin/*.dll" "bin/*.xml" ]; 212 + 213 + meta = { 214 + description = "F# Data: Library for Data Access"; 215 + homepage = "http://fsharp.github.io/FSharp.Data/"; 216 + license = stdenv.lib.licenses.asl20; 217 + maintainers = with stdenv.lib.maintainers; [ obadz ]; 218 + platforms = with stdenv.lib.platforms; linux; 219 + }; 220 + }; 221 + 222 + # FSharpxExtras = buildDotnetPackage rec { 223 + # baseName = "FSharpx.Extras"; 224 + # version = "1.8.41"; 225 + # 226 + # src = fetchurl { 227 + # name = "${baseName}-${version}.tar.gz"; 228 + # url = "https://github.com/fsprojects/FSharpx.Extras/archive/${version}.tar.gz"; 229 + # sha256 = "102z5bvk3ffi1crgyp51488vamv41fsf61n8x8pdiznq155zydhl"; 230 + # }; 231 + # 232 + # buildInputs = [ 233 + # fsharp 234 + # dotnetPackages.NUnit 235 + # dotnetPackages.FsCheck 236 + # dotnetPackages.FsCheckNunit 237 + # dotnetPackages.FsUnit 238 + # ]; 239 + # 240 + # patches = [ ./disable_excel.patch ]; 241 + # 242 + # xBuildFiles = [ "FSharpx.WithTypeProviders.sln" ]; 243 + # outputFiles = [ "build/*" ]; 244 + # 245 + # meta = { 246 + # description = "FSharpx.Extras is a collection of libraries and tools for use with F#."; 247 + # homepage = "http://fsprojects.github.io/FSharpx.Extras/"; 248 + # license = stdenv.lib.licenses.asl20; 249 + # maintainers = with stdenv.lib.maintainers; [ obadz ]; 250 + # platforms = with stdenv.lib.platforms; linux; 251 + # }; 252 + # }; 253 + 254 + MonoDevelopFSharpBinding = buildDotnetPackage rec { 255 + baseName = "MonoDevelop.FSharpBinding"; 256 + version = "git-a09c8185eb"; 257 + 258 + src = fetchFromGitHub { 259 + owner = "fsharp"; 260 + repo = "fsharpbinding"; 261 + rev = "a09c8185ebf23fe2f7d22b14b4af2e3268d4f011"; 262 + sha256 = "1zp5gig42s1h681kch0rw5ykbbj0mcsmdvpyz1319wy9s7n2ng91"; 263 + }; 264 + 265 + buildInputs = [ 266 + fsharp 267 + monodevelop 268 + pkgs.gtk-sharp 269 + pkgs.gnome-sharp 270 + dotnetPackages.ExtCore 271 + dotnetPackages.FSharpCompilerService 272 + dotnetPackages.FSharpCompilerCodeDom 273 + dotnetPackages.FSharpAutoComplete 274 + dotnetPackages.Fantomas 275 + ]; 276 + 277 + patches = [ 278 + ../development/dotnet-modules/patches/monodevelop-fsharpbinding.references.patch 279 + ../development/dotnet-modules/patches/monodevelop-fsharpbinding.addin-xml.patch 280 + ]; 281 + 282 + preConfigure = '' 283 + substituteInPlace monodevelop/configure.fsx --replace /usr/lib/monodevelop ${monodevelop}/lib/monodevelop 284 + substituteInPlace monodevelop/configure.fsx --replace bin/MonoDevelop.exe ../../bin/monodevelop 285 + (cd monodevelop; fsharpi ./configure.fsx) 286 + ''; 287 + 288 + # This will not work as monodevelop probably looks in absolute nix store path rather than path 289 + # relative to its executable. Need to ln -s /run/current-system/sw/lib/dotnet/MonoDevelop.FSharpBinding 290 + # ~/.local/share/MonoDevelop-5.0/LocalInstall/Addins/ to install until we have a better way 291 + 292 + # postInstall = '' 293 + # mkdir -p "$out/lib/monodevelop/AddIns" 294 + # ln -sv "$out/lib/dotnet/${baseName}" "$out/lib/monodevelop/AddIns" 295 + # ''; 296 + 297 + xBuildFiles = [ "monodevelop/MonoDevelop.FSharpBinding/MonoDevelop.FSharp.mac-linux.fsproj" ]; 298 + outputFiles = [ "monodevelop/bin/mac-linux/Release/*" ]; 299 + 300 + meta = { 301 + description = "F# addin for MonoDevelop 5.9"; 302 + homepage = "https://github.com/fsharp/fsharpbinding/tree/5.9"; 303 + license = stdenv.lib.licenses.asl20; 304 + maintainers = with stdenv.lib.maintainers; [ obadz ]; 305 + platforms = with stdenv.lib.platforms; linux; 306 + }; 307 + }; 308 + 309 + NDeskOptions = stdenv.mkDerivation rec { 310 + baseName = "NDesk.Options"; 311 + version = "0.2.1"; 312 + name = "${baseName}-${version}"; 313 + 314 + src = fetchurl { 315 + name = "${baseName}-${version}.tar.gz"; 316 + url = "http://www.ndesk.org/archive/ndesk-options/ndesk-options-0.2.1.tar.gz"; 317 + sha256 = "1y25bfapafwmifakjzyb9c70qqpvza8g5j2jpf08j8wwzkrb6r28"; 318 + }; 319 + 320 + buildInputs = [ 321 + mono 322 + pkgconfig 323 + ]; 324 + 325 + preConfigure = '' 326 + substituteInPlace configure --replace gmcs mcs 327 + ''; 328 + 329 + postInstall = '' 330 + # Otherwise pkg-config won't find it and the DLL will get duplicated 331 + ln -sv $out/lib/pkgconfig/ndesk-options.pc $out/lib/pkgconfig/NDesk.Options.pc 332 + ''; 333 + 334 + dontStrip = true; 335 + 336 + meta = { 337 + description = "NDesk.Options is a callback-based program option parser for C#."; 338 + homepage = "http://www.ndesk.org/Options"; 339 + license = stdenv.lib.licenses.mit; 340 + maintainers = with stdenv.lib.maintainers; [ obadz ]; 341 + platforms = with stdenv.lib.platforms; linux; 342 + }; 343 + }; 344 + 345 + NewtonsoftJson = buildDotnetPackage rec { 346 + baseName = "Newtonsoft.Json"; 347 + version = "6.0.8"; 348 + 349 + src = fetchurl { 350 + name = "${baseName}-${version}.tar.gz"; 351 + url = "https://github.com/JamesNK/Newtonsoft.Json/archive/${version}.tar.gz"; 352 + sha256 = "14znf5mycka578bxjnlnz6a3f9nfkc682hgmgg42gdzksnarvhlm"; 353 + }; 354 + 355 + buildInputs = [ 356 + fsharp 357 + dotnetPackages.NUnit 358 + dotnetPackages.SystemCollectionsImmutable 359 + dotnetPackages.Autofac 360 + ]; 361 + 362 + patches = [ ../development/dotnet-modules/patches/newtonsoft-json.references.patch ]; 363 + 364 + postConfigure = '' 365 + # Just to make sure there's no attempt to call these executables 366 + rm -rvf Tools 367 + ''; 368 + 369 + xBuildFiles = [ "Src/Newtonsoft.Json.sln" ]; 370 + outputFiles = [ "Src/Newtonsoft.Json/bin/Release/Net45/*" ]; 371 + 372 + meta = { 373 + description = "Popular high-performance JSON framework for .NET"; 374 + homepage = "http://www.newtonsoft.com/json"; 375 + license = stdenv.lib.licenses.mit; 376 + maintainers = with stdenv.lib.maintainers; [ obadz ]; 377 + platforms = with stdenv.lib.platforms; linux; 378 + }; 379 + }; 380 + 381 + Nuget = buildDotnetPackage { 382 + baseName = "Nuget"; 383 + version = "2.8.5"; 384 + 385 + src = fetchFromGitHub { 386 + owner = "mono"; 387 + repo = "nuget-binary"; 388 + rev = "da1f2102f8172df6f7a1370a4998e3f88b91c047"; 389 + sha256 = "1hbnckc4gvqkknf8gh1k7iwqb4vdzifdjd19i60fnczly5v8m1c3"; 390 + }; 391 + 392 + buildInputs = [ unzip ]; 393 + 394 + phases = [ "unpackPhase" "installPhase" ]; 395 + 396 + outputFiles = [ "*" ]; 397 + dllFiles = [ "NuGet*.dll" ]; 398 + exeFiles = [ "NuGet.exe" ]; 399 + }; 400 + 401 + Paket = buildDotnetPackage rec { 402 + baseName = "Paket"; 403 + version = "1.6.2"; 404 + 405 + src = fetchurl { 406 + name = "${baseName}-${version}.tar.gz"; 407 + url = "https://github.com/fsprojects/Paket/archive/${version}.tar.gz"; 408 + sha256 = "1ryslxdgc3r7kcn1gq4bqcyrqdi8z6364aj3lr7yjz71wi22fca8"; 409 + }; 410 + 411 + buildInputs = [ 412 + fsharp 413 + dotnetPackages.NewtonsoftJson 414 + dotnetPackages.UnionArgParser 415 + dotnetPackages.NUnit 416 + ]; 417 + 418 + fileFsUnit = fetchurl { 419 + name = "FsUnit.fs"; 420 + url = https://raw.githubusercontent.com/forki/FsUnit/81d27fd09575a32c4ed52eadb2eeac5f365b8348/FsUnit.fs; 421 + sha256 = "1zxigqgb2s2v755622jbbzibvf91990x2dijhbdgg646vsybkpdp"; 422 + }; 423 + 424 + # fileOctokit = fetchurl { 425 + # name = "Octokit.fsx"; 426 + # url = https://raw.githubusercontent.com/fsharp/FAKE/8e65e2fc1406f326b44f3f87ec9ca9b3127a6e78/modules/Octokit/Octokit.fsx; 427 + # sha256 = "16qxwmgyg3fn3z9a8hppv1m579828x7lvfj8qflcgs2g6ciagsir"; 428 + # }; 429 + 430 + fileGlobbing = fetchurl { 431 + name = "Globbing.fs"; 432 + url = https://raw.githubusercontent.com/fsharp/FAKE/8e65e2fc1406f326b44f3f87ec9ca9b3127a6e78/src/app/FakeLib/Globbing/Globbing.fs; 433 + sha256 = "1v7d7666a61j6f8ksh0q40hfsc5b03448viq17xa91xgb7skhyx7"; 434 + }; 435 + 436 + fileErrorHandling = fetchurl { 437 + name = "ErrorHandling.fs"; 438 + url = https://raw.githubusercontent.com/fsprojects/Chessie/3017092260b4a59a3b4b25bf8fca6be6eb7487eb/src/Chessie/ErrorHandling.fs; 439 + sha256 = "0ka9ilfbl4izxc1wqd5vlfjnp7n2xcckfhp13gzhqbdx7464van9"; 440 + }; 441 + 442 + postConfigure = '' 443 + # Copy said single-files-in-git-repos 444 + mkdir -p "paket-files/forki/FsUnit" 445 + cp -v "${fileFsUnit}" "paket-files/forki/FsUnit/FsUnit.fs" 446 + 447 + mkdir -p "paket-files/fsharp/FAKE/src/app/FakeLib/Globbing" 448 + cp -v "${fileGlobbing}" "paket-files/fsharp/FAKE/src/app/FakeLib/Globbing/Globbing.fs" 449 + 450 + mkdir -p "paket-files/fsprojects/Chessie/src/Chessie" 451 + cp -v "${fileErrorHandling}" "paket-files/fsprojects/Chessie/src/Chessie/ErrorHandling.fs" 452 + ''; 453 + 454 + xBuildFiles = [ ]; 455 + 456 + outputFiles = [ "bin/*" ]; 457 + exeFiles = [ "paket.exe" ]; 458 + 459 + meta = { 460 + description = "A dependency manager for .NET and Mono projects"; 461 + homepage = "http://fsprojects.github.io/Paket/"; 462 + license = stdenv.lib.licenses.mit; 463 + maintainers = with stdenv.lib.maintainers; [ obadz ]; 464 + platforms = with stdenv.lib.platforms; linux; 465 + }; 466 + }; 467 + 468 + UnionArgParser = buildDotnetPackage rec { 469 + baseName = "UnionArgParser"; 470 + version = "0.8.7"; 471 + 472 + src = fetchFromGitHub { 473 + owner = "nessos"; 474 + repo = "UnionArgParser"; 475 + rev = "acaeb946e53cbb0bd9768977c656b3242146070a"; 476 + sha256 = "1yrs7ycf2hg7h8z6vm9lr7i3gr9s30k74fr2maigdydnnls93als"; 477 + }; 478 + 479 + buildInputs = [ 480 + fsharp 481 + dotnetPackages.NUnit 482 + dotnetPackages.FsUnit 483 + ]; 484 + 485 + outputFiles = [ "bin/net40/*" ]; 486 + 487 + meta = { 488 + description = "A declarative CLI argument/XML configuration parser for F# applications."; 489 + homepage = "http://nessos.github.io/UnionArgParser/"; 490 + license = stdenv.lib.licenses.mit; 491 + maintainers = with stdenv.lib.maintainers; [ obadz ]; 492 + platforms = with stdenv.lib.platforms; linux; 493 + }; 494 + }; 495 + }; in self