-
-
Notifications
You must be signed in to change notification settings - Fork 15.5k
kitty: support macOS #56740
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
kitty: support macOS #56740
Conversation
mkdir -p $terminfo/share | ||
mv $out/share/terminfo $terminfo/share/terminfo | ||
mv "$terminfo_src" $terminfo/share/terminfo |
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.
Does the app pick up the terminfo dirs?
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.
Does the app pick up the terminfo dirs?
Are you asking if terminfo files are correctly installed? I'm not sure if the terminfo stuff is properly installed, but the files do exist:
$ cat /nix/store/nqyzdmi844za1vqqjh7n2s719ma15y9f-kitty-0.13.3/nix-support/propagated-user-env-packages
/nix/store/frhw04kcjzf0wfz3kby0ahkja10wh8rw-kitty-0.13.3-terminfo
$ find /nix/store/frhw04kcjzf0wfz3kby0ahkja10wh8rw-kitty-0.13.3-terminfo
/nix/store/frhw04kcjzf0wfz3kby0ahkja10wh8rw-kitty-0.13.3-terminfo
/nix/store/frhw04kcjzf0wfz3kby0ahkja10wh8rw-kitty-0.13.3-terminfo/share
/nix/store/frhw04kcjzf0wfz3kby0ahkja10wh8rw-kitty-0.13.3-terminfo/share/terminfo
/nix/store/frhw04kcjzf0wfz3kby0ahkja10wh8rw-kitty-0.13.3-terminfo/share/terminfo/78
/nix/store/frhw04kcjzf0wfz3kby0ahkja10wh8rw-kitty-0.13.3-terminfo/share/terminfo/78/xterm-kitty
Do you know how to verify that these terminfo files are working?
Note: kitty's build system is a bit weird. On macOS, it renames the UNIX share
directory to kitty.app/Contents/Resources
: https://github.com/strager/kitty/blob/v0.13.3/setup.py#L703
pkgconfig which sphinx ncurses | ||
] ++ stdenv.lib.optionals stdenv.isDarwin [ | ||
imagemagick | ||
libicns |
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.
Libraries should be in buildInputs.
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.
libicns is used only for the png2icns program. png2icns is only used by kitty during compilation. kitty does not use the libicns library (at compile time or at run time).
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.
It would be good to add a comment about this.
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.
Ok looks to me then!
Do I need to do something in order to merge this? |
@GrahamcOfBorg build kitty |
For some reason this doesn't build on darwin. Complains about a missing header:
|
kitty requires macOS 10.12 or newer. I wrote a patch which backports kitty to macOS 10.11, but it wasn't merged upstream: kovidgoyal/kitty#1430 |
#56744 will provide os/log.h. Meanwhile we could use your patch. |
@veprbl, I updated my branch to include the patch for macOS 10.11 (and 10.10). |
@strager Let's not do the alias: it's not so uncommon for libfoo packages contain utilities, we don't want to later have to add alias for icns2png, there are already packages under those names out there. The comment in the kitty's code should suffice. |
Install the `kitty` command-line utility and the `kitty.app` macOS application. * Prefer libicns (png2icns) over Apple's non-free iconutil. * Work around warnings from Apple headers by disabling -pedantic-errors and -Werror. * Work around ld not support LLVM-LTO by disabling LTO. * Make Kitty and glfw compile for macOS 10.11 (and macOS 10.10).
@GrahamcOfBorg build kitty |
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!
Install the `kitty` command-line utility and the `kitty.app` macOS application. * Prefer libicns (png2icns) over Apple's non-free iconutil. * Work around warnings from Apple headers by disabling -pedantic-errors and -Werror. * Work around ld not support LLVM-LTO by disabling LTO. * Make Kitty and glfw compile for macOS 10.11 (and macOS 10.10). (cherry picked from commit 75aa846) cc #56740
Motivation for this change
Enable people to easily install and run kitty from source on macOS 10.12 and newer. This includes using kitty as a command-line utility (
kitty) and as a macOS application (
kitty.app`).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)Additional information