[Nix-dev] Packaging daphny, a mono application.

Layus layus.on at gmail.com
Thu Sep 1 18:09:29 CEST 2016


On 01/09/16 12:33, obadz wrote:
>
> On Thu, Sep 1, 2016 at 10:23 AM, Layus <layus.on at gmail.com 
> <mailto:layus.on at gmail.com>> wrote:
>
>         mozroots --import --sync
>
>
> You don't need this part, as it's already taken care of here: 
> https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/compilers/mono/generic.nix#L69-L75
>
>         wget https://nuget.org/nuget.exe
>
>
> You definitely don't want this, we have nuget packaged and already 
> wired up in fetchNuGet
>
>         mono ./nuget.exe restore Source/Boogie.sln
>
>
> You don't want this one either, either fetchNuGet the dependencies or 
> build them from source. You'll find examples of both in 
> https://github.com/NixOS/nixpkgs/blob/master/pkgs/top-level/dotnet-packages.nix. 
> Then add them to buildInputs.
>
>         xbuild Source/Boogie.sln
>         ...
>         xbuild dafny/Source/Dafny.sln
>
>
> Those guys will get invoked for you by buildDotnetPackage. You may 
> have to specify xBuildFiles.
>
> Good luck :)
Thank you !
This got me started, and I have a very good prototype available at [1], 
or you can jump to the diff at [2].

The only remaining error is an annoying

Unhandled Exception:
System.TypeLoadException: Could not load type 
'Microsoft.Dafny.ConsoleErrorReporter' from assembly 'DafnyPipeline, 
Version=1.9.8.30829, Culture=neutral, PublicKeyToken=736440c9b414ea16'.
   at [...]

Could you help me with this tricky one ?
I have a hard time understanding the dotnet infrastructure...

[1] https://github.com/layus/nixpkgs/tree/dafny
[2] 
https://github.com/layus/nixpkgs/commit/15cc02b9990129eb8c037b67dcd832eaab97b163


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.science.uu.nl/pipermail/nix-dev/attachments/20160901/f5b1ba8b/attachment-0001.html>


More information about the nix-dev mailing list