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

[WIP] imake: only use tradcpp on Darwin #51578

Closed

Conversation

thefloweringash
Copy link
Member

Motivation for this change

Fixing x11_ssh_askpass on aarch64, see hydra failure.

For reasons I don't understand, when building with tradcpp as the IMAKECPP, the aarch64 build passes LinuxMachineDefines where it should pass -D__aarch64__.

This change was introduced in 613e262, cc @matthewbauer as the author.

Good:

building
build flags: SHELL=/nix/store/bsb6596kk4fp20hyl9yl55xwv1ax4b6s-bash-4.4-p23/bin/bash
gcc -O2 -fno-strict-aliasing      -I/nix/store/xisa9pqa1706nqiprscnp4qgvkqqysg8-xorg-cf-files-1.0.6/include    -Dlinux -D__aarch64__ -D_POSIX_C_SOURCE=199309L                          -D_POSIX_SOURCE -D_XOPEN_SOURCE                                 -D_BSD_SOURCE -D_SVID_SOURCE                                 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64                                                                   -DFUNCPROTO=15 -DNARROWPROTO       -c -o drawing.o drawing.c
...

Bad:

building
build flags: SHELL=/nix/store/bsb6596kk4fp20hyl9yl55xwv1ax4b6s-bash-4.4-p23/bin/bash
gcc -O      -I/nix/store/xisa9pqa1706nqiprscnp4qgvkqqysg8-xorg-cf-files-1.0.6/include    -Dlinux LinuxMachineDefines -D_POSIX_C_SOURCE=199309L                          -D_POSIX_SOURCE -D_XOPEN_SOURCE                                 -D_BSD_SOURCE -D_SVID_SOURCE                                 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64                                                                   -DFUNCPROTO=15 -DNARROWPROTO       -c -o drawing.o drawing.c
gcc: error: LinuxMachineDefines: No such file or directory
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)
  • Assured whether relevant documentation is up to date
  • Fits CONTRIBUTING.md.

@veprbl
Copy link
Member

veprbl commented Dec 5, 2018

xorg-cf-files-1.0.6 should have support for aarch64: https://bugs.launchpad.net/linaro-aarch64/+bug/1137510

Could it be that tradcpp fails to define __aarch64__?

@matthewbauer
Copy link
Member

Thanks! I think this looks okay... The main reason for using tradcpp everywhere is so that we have some consistency between Darwin & Linux - if it breaks on one it will be more likely to break on the other. But, if this fixes something, it looks like a good idea.

@veprbl veprbl mentioned this pull request Dec 5, 2018
10 tasks
@veprbl
Copy link
Member

veprbl commented Dec 5, 2018

I have an idea: #51585

@thefloweringash
Copy link
Member Author

I like your idea! It builds for me on aarch64. Let’s go with that instead.

@thefloweringash thefloweringash deleted the imake-tradcpp-darwin branch December 7, 2018 16:02
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

4 participants