-
-
Notifications
You must be signed in to change notification settings - Fork 14.5k
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
LLVM: fix cross compilation (llvm_6 & llvm_7) #52031
Conversation
, debugVersion ? false | ||
, enableManpages ? false | ||
, enableSharedLibraries ? true | ||
, targets ? [ stdenv.hostPlatform stdenv.targetPlatform ] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Ericson2314 changed the name as it might be ambiguous when somebody adds a targets
package.
, debugVersion ? false | ||
, enableManpages ? false | ||
, enableSharedLibraries ? true | ||
, targets ? [ stdenv.hostPlatform stdenv.targetPlatform ] | ||
, enableWasm ? true # TODO fold this into `targets` somehow |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did not want to have this as an API, because it should be in targets
once it leaves the experimental stage.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great!
LLVM’s `LLVM_TARGETS_TO_BUILD` build flag defauls to `all`, which contains `AMDGPU` among others. [1] Changes in llvm [2] switched to explicitly listing host and target platforms, excluding the AMDGPU target, which is required for Mesa to build. [1]: https://github.com/llvm-mirror/llvm/blob/db50b6fe399b8ad8caef80fd8ee77607fb051fa5/CMakeLists.txt#L286-L302 [2]: NixOS#52031
cc #53920 -- thoughts? :) |
Is there a reason not to build all targets by default? |
@orivej closure size maybe? My intention was that it is also used for jit-compiling like in mesa and for cross-compiling we would have to rebuild it anyway as the default target changes. I have not measured the size difference though. |
This commit broke Zig, which depends on all LLVM targets being enabled. LLVM should include all default targets by default. |
Never mind, I think this was fixed. Sorry for the noise. |
@Mic92 @Ericson2314 looks like _8 and _9 have been broken since they were added. Could you take a look at #76887? |
Motivation for this change
road to gtk
Things done
sandbox
innix.conf
on non-NixOS)nix-shell -p nox --run "nox-review wip"
./result/bin/
)nix path-info -S
before and after)