Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nuget pack does not work as expected on a fresh install of Linux. #5627

Closed
ArtOfSettling opened this issue Jul 21, 2017 · 5 comments
Closed

Comments

@ArtOfSettling
Copy link

ArtOfSettling commented Jul 21, 2017

This is very similar to the following bug (#1946), NuGet seems to have issues on Linux based platforms. I've filed a bug with Xamarin, as you stated in the previous bug, this was a problem with mono.

That bug is here : https://bugzilla.xamarin.com/show_bug.cgi?id=52797 However, they've stated the issue lies in your hands. Thankfully, it seems they're also proposing a solution!

Please let me know if I'm doing something incorrect on my end, but everything should be fine, since I'm running fresh installs of everything.

Ubuntu with a fresh install of mono-complete (4.8.0) and the provided xbuild
nuget pack aProject.csproj -verbosity detailed

example output :
System.NotImplementedException: The method or operation is not implemented. at (wrapper dynamic-method) System.Object:CallSite.Target (System.Runtime.CompilerServices.Closure,System.Runtime.CompilerServices.CallSite,object) at System.Dynamic.UpdateDelegates.UpdateAndExecuteVoid1[T0] (System.Runtime.CompilerServices.CallSite site, T0 arg0) [0x0011d] in <2392cff65f724abaaed9de072f62bc4a>:0 at NuGet.CommandLine.ProjectFactory.ResolveTargetPath () [0x00345] in <dac647f5255f4f14a29ff0994941da2f>:0 at NuGet.CommandLine.ProjectFactory.BuildProject () [0x0016e] in <dac647f5255f4f14a29ff0994941da2f>:0 at NuGet.CommandLine.ProjectFactory.CreateBuilder (System.String basePath, NuGet.Versioning.NuGetVersion version, System.String suffix, System.Boolean buildIfNeeded) [0x0000d] in <dac647f5255f4f14a29ff0994941da2f>:0 at NuGet.Commands.PackCommandRunner.BuildFromProjectFile (System.String path) [0x00123] in <dac647f5255f4f14a29ff0994941da2f>:0 at NuGet.Commands.PackCommandRunner.BuildPackage (System.String path) [0x00033] in <dac647f5255f4f14a29ff0994941da2f>:0 at NuGet.Commands.PackCommandRunner.BuildPackage () [0x00021] in <dac647f5255f4f14a29ff0994941da2f>:0 at NuGet.CommandLine.PackCommand.ExecuteCommand () [0x001f8] in <dac647f5255f4f14a29ff0994941da2f>:0 at NuGet.CommandLine.Command.ExecuteCommandAsync () [0x00000] in <dac647f5255f4f14a29ff0994941da2f>:0 at NuGet.CommandLine.Command.Execute () [0x000b7] in <dac647f5255f4f14a29ff0994941da2f>:0 at NuGet.CommandLine.Program.MainCore (System.String workingDirectory, System.String[] args) [0x001f8] in <dac647f5255f4f14a29ff0994941da2f>:0

@rohit21agrawal
Copy link
Contributor

@zhili1208 would you take a look at this?

@zhili1208
Copy link
Contributor

Could you try to use nuget.exe 4.3 from https://www.nuget.org/downloads? Specify -MsbuildPath [the directory contains msbuild]

mono nuget.exe pack aProject.csproj -MsbuildPath [the directory contains msbuild.exe]

@ArtOfSettling
Copy link
Author

This command actually worked, which is great!

I couldn't use my manually installed version of MSBuild, but It was sufficient to tell mono not to use Build, like follows ....

-MsbuildPath /usr/lib/mono/msbuild/15.0/bin/

;)

@rohit21agrawal
Copy link
Contributor

@ArtOfSettling glad that it works for you now, are we good to close this issue now? :)

@ArtOfSettling
Copy link
Author

Sure!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants