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

buildRustCrateTests: Fix link order test on darwin #83616

Merged
merged 1 commit into from Mar 28, 2020

Conversation

andir
Copy link
Member

@andir andir commented Mar 28, 2020

Motivation for this change

Fixes the tests on Darwin that I broke by merging #83379
cc @kolloch

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS (does that have a sandbox?)

As it turns out Darwin does most of the things differently then "normal"
systems. They are using a different shared library extension and require
an obscure commandline parameter that has to be added to every build
system out there. That issue seems to be with clang on Darwin as on
Linux that flag isn't required to build the very same tests (when using
clang).

After adjusting these two details the tests are running fine on the
darwin box that I was able to obtain.
@andir andir force-pushed the buildRustCrate-fix-link-order-test branch from 3562cc5 to c8de31b Compare March 28, 2020 20:14
Copy link
Member

@LnL7 LnL7 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks reasonable, assuming there's a reason to not properly link the example libb against liba.

@andir
Copy link
Member Author

andir commented Mar 28, 2020 via email

@LnL7
Copy link
Member

LnL7 commented Mar 28, 2020

Looks like there are a couple of cases out there, but I've not encountered that before. Presumably things that need this already handle it in their build system making it something we don't really have to worry about.

@andir andir merged commit a078ee2 into NixOS:master Mar 28, 2020
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