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

NewtonsoftJson: only build Newtonsoft.Json.csproj #46425

Closed

Conversation

bobvanderlinden
Copy link
Member

Motivation for this change

This fixes the build of Newtonsoft.Json, which is blocking other
builds. The tests were not able to compile due to changes in NUnit.
Upgrading Newtonsoft.Json is currently not possible as the project
structure is now using dotnet-core and is incompatible with xbuild.

Example of failing build:

https://hydra.nixos.org/build/81003982

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Fits CONTRIBUTING.md.

@samueldr
Copy link
Member

samueldr commented Sep 9, 2018

#45960 will need this backported (leaving a note for myself).

@samueldr samueldr mentioned this pull request Sep 9, 2018
8 tasks
@samueldr
Copy link
Member

samueldr commented Sep 9, 2018

@GrahamcOfBorg build openra gdata-sharp dotnetPackages.Paket dotnetPackages.FSharpAutoComplete

I have done local builds for openra, gdata-sharp, dotnetPackages.Paket and dotnetPackages.FSharpAutoComplete on 18.09. Of those, only openra built, but the failures are unrelated to this fix. Let's see what the CI sees. (99% sure this gets merged after it finishes building, then backported)

@GrahamcOfBorg
Copy link

No attempt on aarch64-linux (full log)

The following builds were skipped because they don't evaluate on aarch64-linux: openra, gdata-sharp, dotnetPackages.Paket, dotnetPackages.FSharpAutoComplete

Partial log (click to expand)


a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowBroken = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowBroken = true; }
to ~/.config/nixpkgs/config.nix.


@GrahamcOfBorg
Copy link

No attempt on x86_64-darwin (full log)

The following builds were skipped because they don't evaluate on x86_64-darwin: openra, gdata-sharp, dotnetPackages.Paket, dotnetPackages.FSharpAutoComplete

Partial log (click to expand)


a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowUnsupportedSystem = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowUnsupportedSystem = true; }
to ~/.config/nixpkgs/config.nix.


@bobvanderlinden
Copy link
Member Author

Awesome, thanks. Note that this just avoids building the unit tests of Newtonsoft.Json. It's not ideal, but I couldn't find another way. I think it won't affect other packages though.

@samueldr
Copy link
Member

samueldr commented Sep 9, 2018

Oh, (I'm deferring to your knowledge)

@bobvanderlinden there was an aborted PR earlier, #44478, with commit c632384 upgrading this package. Any comments? If this works, and the test suite passes, and dependencies are happy, it may be better to upgrade?


EDIT: on 18.09, the same amount of success/breakage happens with that update, which imho is good (since the breakage on the other package is seemingly unrelated).

@GrahamcOfBorg
Copy link

Failure on x86_64-linux (full log)

Attempted: openra, gdata-sharp, dotnetPackages.Paket, dotnetPackages.FSharpAutoComplete

Partial log (click to expand)

post-installation fixup
shrinking RPATHs of ELF executables and libraries in /nix/store/kpk9pmmxagqp7n7qxwr3nsmyb04dxmy0-openra-20180307
gzipping man pages under /nix/store/kpk9pmmxagqp7n7qxwr3nsmyb04dxmy0-openra-20180307/share/man/
patching script interpreter paths in /nix/store/kpk9pmmxagqp7n7qxwr3nsmyb04dxmy0-openra-20180307
/nix/store/gpy3r9ss5ngfkib8ylx7jzgahq7m0x5b-patch-shebangs.sh: line 22: warning: command substitution: ignored null byte in input
/nix/store/gpy3r9ss5ngfkib8ylx7jzgahq7m0x5b-patch-shebangs.sh: line 22: warning: command substitution: ignored null byte in input
/nix/store/kpk9pmmxagqp7n7qxwr3nsmyb04dxmy0-openra-20180307/lib/openra/.launch-game.sh-wrapped: interpreter directive changed from "/bin/sh" to "/nix/store/czx8vkrb9jdgjyz8qfksh10vrnqa723l-bash-4.4-p23/bin/sh"
/nix/store/kpk9pmmxagqp7n7qxwr3nsmyb04dxmy0-openra-20180307/lib/openra/launch-dedicated.sh: interpreter directive changed from "/bin/sh" to "/nix/store/czx8vkrb9jdgjyz8qfksh10vrnqa723l-bash-4.4-p23/bin/sh"
checking for references to /build in /nix/store/kpk9pmmxagqp7n7qxwr3nsmyb04dxmy0-openra-20180307...
error: build of '/nix/store/7alzda8pvyyigj4iggpy49lmhx552gz1-Paket-1.18.2.drv', '/nix/store/m5ixrpgimsz4jddip14qlnycf5hmq40r-gdata-sharp-2.2.0.0.drv', '/nix/store/msl5y9y0dw2lsyad7gbsfbha9ba0pvjq-FSharp.AutoComplete-0.18.2.drv' failed

@fpletz
Copy link
Member

fpletz commented Sep 9, 2018

I can confirm that OpenRA builds and works with c632384. 👍

@bobvanderlinden
Copy link
Member Author

This is related to getting all tests passing for 18.09: #45960

@samueldr
Copy link
Member

Maybe I wasn't clear enough, let me rephrase:

@bobvanderlinden what's your opinion on using c632384 instead of your PR? Do you see any downsides of upgrading? (I'd guess none, but you seem to be more knowledgeable with .NET stuff.)

@bobvanderlinden
Copy link
Member Author

Ah missed your comment. That seems like a better way to go if all packages indeed keep working. 👍

@xeji
Copy link
Contributor

xeji commented Sep 14, 2018

closing in favor of #46679

@xeji xeji closed this Sep 14, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants