kovidgoyal / kitty

Cross-platform, fast, feature-rich, GPU based terminal
https://sw.kovidgoyal.net/kitty/
GNU General Public License v3.0
24.47k stars 979 forks source link

prewarm-launcher.c fails to build on macOS MSG_NOSIGNAL undefined #5371

Closed derekschrock closed 2 years ago

derekschrock commented 2 years ago

Describe the bug No MSG_NOSIGNAL on macOS

To Reproduce Steps to reproduce the behavior:

  1. Build on macOS
  2. See error

Screenshots

clang -DKITTY_LIB_PATH="../Resources/kitty" -Wall -pedantic-errors -Werror -fpie -O3 -I/opt/local/Library/Frameworks/Python.framework/Versions/3.10/include/python3.10 -I /opt/local/include -c prewarm-launcher.c -o build/prewarm-launcher.o
prewarm-launcher.c:467:59: error: use of undeclared identifier 'MSG_NOSIGNAL'
    while ((n = sendmsg(socket_fd, &launch_msg_container, MSG_NOSIGNAL)) < 0 && errno == EINTR);
                                                          ^
prewarm-launcher.c:629:77: error: use of undeclared identifier 'MSG_NOSIGNAL'
    ssize_t n = safe_send(socket_fd, send_on_socket.buf, send_on_socket.sz, MSG_NOSIGNAL);

Solutions

kovidgoyal commented 2 years ago

It builds fine on macOS, kitty is built on macOS CI for every commit. What version of macOS are you building on?

derekschrock commented 2 years ago

10.15.7 (19H2026)

I thought something seemed odd... I thought I built kitty recently on my macOS 12 machine. Guess it has been a while since I've rebuilt kitty here.