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
vim_configurable: fix darwin build with guiSupport #45352
Conversation
Using vim_configurable.override { guiSupport = "no"; } would still pull in gtk2 as a dependency.
Using gtk + darwin support seems broken at the moment, we probably want guiSupport = "carbon" instead but that doesn't work and something like macvim is probably better for that. This fixes the build while keeping guiSupport enabled which might be desirable for eg. +clientserver. Fixes NixOS#45025
Success on x86_64-linux (full log) Attempted: vim_configurable Partial log (click to expand)
|
Success on aarch64-linux (full log) Attempted: vim_configurable Partial log (click to expand)
|
Success on x86_64-darwin (full log) Attempted: vim_configurable Partial log (click to expand)
|
pkgs/top-level/all-packages.nix
Outdated
@@ -9682,6 +9682,10 @@ with pkgs; | |||
inherit (darwin.apple_sdk.frameworks) AppKit Cocoa; | |||
}; | |||
|
|||
gtk3-x11 = gtk3.override { | |||
x11Support = true; |
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.
Can you maybe add a comment that is for macOS where by default gtk3 uses Cocoa (?) instead of x11?
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.
If it's Darwin specific, maybe call it gtk3-darwin
or gtk3-cocoa
?
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.
That sounds confusing. gtk3 uses cocoa by default which makes sense and gtk3-x11
uses x11 everywhere. Using gtk3-x11 on linux doesn't change anything.
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 see now. Is it intentional that gtk3 is built without x11 support by default on Darwin? Should we do this also on Linux?
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.
Cocoa/x11 support is probably mutual exclusive - cocoa is preferred as it is the native environment. Building gtk3 without x11 support on linux does not make sense.
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.
Exactly, I'm not sure if this broke because of the refactor or a recent update but gui support was disabled or actually didn't work before. I couldn't get Cocoa to work and while gvim with X11 isn't very nice/useful on darwin it does enable +clientserver support.
Success on x86_64-linux (full log) Attempted: vim_configurable Partial log (click to expand)
|
Success on aarch64-linux (full log) Attempted: vim_configurable Partial log (click to expand)
|
Success on x86_64-darwin (full log) Attempted: vim_configurable Partial log (click to expand)
|
Motivation for this change
Fixes #45025
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)