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

haskell generic-builder: Yet more cross fixes #42247

Merged
merged 2 commits into from Jun 20, 2018

Conversation

Ericson2314
Copy link
Member

@Ericson2314 Ericson2314 commented Jun 19, 2018

Motivation for this change
  1. nativeGhc targets the build platform so it should be a depsBuildBuild. This is more important because GHC propagates some dependencies, and we want those to be propagated properly.

  2. The --extra-* flags are only for host dependencies. They ought to be harmless when given others as the linker can just skip, but we ran into some issue indicating otherwise. Best to preemptively fix.

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/)
  • Fits CONTRIBUTING.md.

CC @kirelagin @angerman

@Ericson2314
Copy link
Member Author

@matthewbauer
Copy link
Member

This looks good but please don't merge until we can figure out the libiconv in iOS.

@kirelagin
Copy link
Member

libiconv

This is very interesting, because today I discovered that after updating the channel I no longer can build even a trivial program that uses text on macOS (no cross-compiling involved):

Undefined symbols for architecture x86_64:
  "_iconv", referenced from:
      _hs_iconv in libHSbase-4.9.1.0.a(iconv.o)
     (maybe you meant: <...> )
  "_iconv_close", referenced from:
      _hs_iconv_close in libHSbase-4.9.1.0.a(iconv.o)
     (maybe you meant: _hs_iconv_close)
  "_iconv_open", referenced from:
      _hs_iconv_open in libHSbase-4.9.1.0.a(iconv.o)
     (maybe you meant: _hs_iconv_open)
  "_locale_charset", referenced from:
      _localeEncoding in libHSbase-4.9.1.0.a(PrelIOUtils.o)
ld: symbol(s) not found for architecture x86_64

@Ericson2314 Ericson2314 merged commit 142a228 into NixOS:master Jun 20, 2018
@Ericson2314 Ericson2314 deleted the yet-more-haskell-cross branch June 20, 2018 00:12
@Ericson2314
Copy link
Member Author

Ericson2314 commented Jun 20, 2018

If there are problems, cross or native, with base libraries, we should solve them another way.#42069 should cover.

@mpickering
Copy link
Contributor

@kirelagin Did you solve this problem?

@kirelagin
Copy link
Member

@mpickering No, but I do plan to work on it this week, you can follow #42069.

@jwiegley
Copy link
Contributor

jwiegley commented Jul 3, 2018

I would suggest this be reverted until the problems are resolved.

@Ericson2314
Copy link
Member Author

arg max problems? I don't think this one is to blame, is it?

@matthewbauer
Copy link
Member

It could be actually which is very unfortunate because the depsBuildBuild things is definitely correct.

@mpickering
Copy link
Contributor

This patch is responsible for the problems mentioned in #42247 (comment) according to @kirelagin

@matthewbauer
Copy link
Member

@mpickering But are you sure it's not the separate setup db thing? That seemed much more likely to me.

@mpickering
Copy link
Contributor

I am not sure. I tried reverting the patch but it caused a lot of rebuilding so I haven't been able to confirm yet.

@matthewbauer
Copy link
Member

You should try this branch if you have a free machine & some extra time:

https://github.com/matthewbauer/nixpkgs/tree/ghc-macos-argmax-fix

@jwiegley
Copy link
Contributor

jwiegley commented Jul 3, 2018

@matthewbauer Starting the builds now...

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

7 participants