xyncro / chiron

JSON for F#
https://xyncro.tech/chiron
MIT License
175 stars 41 forks source link

Doesn't compile on *nix #9

Closed haf closed 9 years ago

haf commented 9 years ago
fsharpi build.fsx

/Users/henrik.feldt/dev/haf/chiron/build.fsx(1,1): warning FS0211: The search directory '/Users/henrik.feldt/dev/haf/chiron/packages/FAKE/tools' could not be found

/Users/henrik.feldt/dev/haf/chiron/build.fsx(2,1): error FS0078: Unable to find the file 'packages/FAKE/tools/FakeLib.dll' in any of
 /Library/Frameworks/Mono.framework/Versions/3.12.1/lib/mono/4.5
 /Users/henrik.feldt/dev/haf/chiron
 /Library/Frameworks/Mono.framework/Versions/3.12.1/lib/mono/4.0/
kolektiv commented 9 years ago

Ah, it needs a build.sh script to bootstrap fake. I'll grab one from another proj, no reason not to have one I think.

kolektiv commented 9 years ago

mono .paket/paket.bootstrapper.exe exit_code=$? if [ $exit_code -ne 0 ]; then exit $exit_code fi

mono .paket/paket.exe restore exit_code=$? if [ $exit_code -ne 0 ]; then exit $exit_code fi

mono packages/FAKE/tools/FAKE.exe $@ --fsiargs -d:MONO build.fsx

kolektiv commented 9 years ago

I'll add that in when I'm near a term :)

haf commented 9 years ago

Ok, so that makes this the error:

Attempting to build package from 'Chiron.1.0.1.nuspec'.
Directory '/Users/henrik.feldt/dev/haf/chiron/nuget/..\' not found.
Running build failed.
Error:
System.Exception: Error during NuGet package creation. /Users/henrik.feldt/dev/haf/chiron/packages/NuGet.Commandline/tools/nuget.exe pack -Version 1.0.1 -OutputDirectory "/Users/henrik.feldt/dev/haf/chiron/bin" "Chiron.1.0.1.nuspec"
  at Fake.NuGetHelper.NuGet (Microsoft.FSharp.Core.FSharpFunc`2 setParams, System.String nuspecFile) [0x00000] in <filename unknown>:0
  at FSI_0001.Build+clo@28-4.Invoke (Microsoft.FSharp.Core.Unit _arg3) [0x00000] in <filename unknown>:0
  at Fake.TargetHelper+targetFromTemplate@154[Microsoft.FSharp.Core.Unit].Invoke (Microsoft.FSharp.Core.Unit unitVar0) [0x00000] in <filename unknown>:0
  at Fake.TargetHelper.runTarget@326 (System.String targetName) [0x00000] in <filename unknown>:0
kolektiv commented 9 years ago

Ah, yeah nuget really doesn't like *nix. In other x-plat projects we've made nuget a windows only thing, it probably can get flagged out. I'll take a look at that later, probably wants something like we do with Freya here: https://github.com/freya-fs/freya/blob/master/build.fsx#L371-L378

haf commented 9 years ago

There, fixed. NuGet is not a Windows only thing...