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

sit: fix tests on aarch64 #40143

Merged
merged 1 commit into from May 7, 2018
Merged

sit: fix tests on aarch64 #40143

merged 1 commit into from May 7, 2018

Conversation

yrashk
Copy link
Contributor

@yrashk yrashk commented May 7, 2018

As we found out in #40032, sit tests won't pass on
aarch64. The problem seems to be related to
create_dir not returning an error if the directory
already exists, happening specifically on aarch64+debug
(not aarch64+release)

This update injects a patch for tests that will also
be included in subsequent versions of SIT.

Motivation for this change

Making SIT available for aarch64 users.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option build-use-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/)
  • Fits CONTRIBUTING.md.

As we found out in NixOS#40032, sit tests won't pass on
aarch64. The problem seems to be related to
`create_dir` not returning an error if the directory
already exists, happening specifically on aarch64+debug
(not aarch64+release)

This update injects a patch for tests that will also
be included in subsequent versions of SIT.
@yrashk
Copy link
Contributor Author

yrashk commented May 7, 2018

@GrahamcOfBorg build sit

@xeji
Copy link
Contributor

xeji commented May 7, 2018

Sorry, only registered ofborg users can trigger builds...

@GrahamcOfBorg build sit

@yrashk
Copy link
Contributor Author

yrashk commented May 7, 2018

@xeji I haven't had a slightest idea whether this will work or not but gave it a try anyway :)

@GrahamcOfBorg
Copy link

Success on x86_64-linux (full log)

Attempted: sit

Partial log (click to expand)

cp: -r not specified; omitting directory 'target/release/examples'
post-installation fixup
shrinking RPATHs of ELF executables and libraries in /nix/store/0qhnmsxxkc3w43zswg3pi2dyvgkq1ba2-sit-0.3.2
shrinking /nix/store/0qhnmsxxkc3w43zswg3pi2dyvgkq1ba2-sit-0.3.2/bin/sit-web
shrinking /nix/store/0qhnmsxxkc3w43zswg3pi2dyvgkq1ba2-sit-0.3.2/bin/sit
strip is /nix/store/j75dgadrff2d1fyc4fczmcgqkid2imdx-binutils-2.30/bin/strip
stripping (with command strip and flags -S) in /nix/store/0qhnmsxxkc3w43zswg3pi2dyvgkq1ba2-sit-0.3.2/bin
patching script interpreter paths in /nix/store/0qhnmsxxkc3w43zswg3pi2dyvgkq1ba2-sit-0.3.2
checking for references to /build in /nix/store/0qhnmsxxkc3w43zswg3pi2dyvgkq1ba2-sit-0.3.2...
/nix/store/0qhnmsxxkc3w43zswg3pi2dyvgkq1ba2-sit-0.3.2

@GrahamcOfBorg
Copy link

Success on aarch64-linux (full log)

Attempted: sit

Partial log (click to expand)

cp: -r not specified; omitting directory 'target/release/deps'
post-installation fixup
shrinking RPATHs of ELF executables and libraries in /nix/store/a6lkxgwd9lvhl2yf82vl99h0rar128lv-sit-0.3.2
shrinking /nix/store/a6lkxgwd9lvhl2yf82vl99h0rar128lv-sit-0.3.2/bin/sit
shrinking /nix/store/a6lkxgwd9lvhl2yf82vl99h0rar128lv-sit-0.3.2/bin/sit-web
strip is /nix/store/gp7fylxwn18b7pl2c18ks89hsiaxyfvf-binutils-2.30/bin/strip
stripping (with command strip and flags -S) in /nix/store/a6lkxgwd9lvhl2yf82vl99h0rar128lv-sit-0.3.2/bin
patching script interpreter paths in /nix/store/a6lkxgwd9lvhl2yf82vl99h0rar128lv-sit-0.3.2
checking for references to /build in /nix/store/a6lkxgwd9lvhl2yf82vl99h0rar128lv-sit-0.3.2...
/nix/store/a6lkxgwd9lvhl2yf82vl99h0rar128lv-sit-0.3.2

@xeji
Copy link
Contributor

xeji commented May 7, 2018

Looks good, thanks.

@xeji xeji merged commit 02fff46 into NixOS:master May 7, 2018
@yrashk yrashk deleted the sit-0.3.2-aarch64 branch May 7, 2018 21:02
@GrahamcOfBorg
Copy link

Failure on x86_64-darwin (full log)

Attempted: sit

Partial log (click to expand)

          clang-5.0: error: linker command failed with exit code 1 (use -v to see invocation)


error: aborting due to previous error

error: Could not compile `sit`.

To learn more, run the command again with --verbose.
builder for '/nix/store/4vw5qd3rya27asg1sm4c4dlfaf4w1f8f-sit-0.3.2.drv' failed with exit code 101
error: build of '/nix/store/4vw5qd3rya27asg1sm4c4dlfaf4w1f8f-sit-0.3.2.drv' failed

@yrashk
Copy link
Contributor Author

yrashk commented May 7, 2018

Oh, I think know what happened with the Darwin build and I believe @dysinger has a solution for this.

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

3 participants