From https://github.com/kovidgoyal/kitty/commit/90223b5d146828c65179da49c75ce31b304fa1b8 Mon Sep 17 00:00:00 2001
From: Kovid Goyal <kovid@kovidgoyal.net>
Date: Tue, 11 Jul 2023 09:22:40 +0530
Subject: [PATCH] Fix compilation against musl

As usual in C stdlib world. Ill thought out break the world changes.
Sigh. musl no longer defines off64_t.

Fixes #6441
--- a/kitty/fast-file-copy.c
+++ b/kitty/fast-file-copy.c
@@ -83,7 +83,7 @@ copy_with_file_range(int infd, int outfd, off_t in_pos, size_t len, FastFileCopy
 #ifdef HAS_COPY_FILE_RANGE
     unsigned num_of_consecutive_zero_returns = 128;
     while (len) {
-        off64_t r = in_pos;
+        int64_t r = in_pos;
         ssize_t n = copy_file_range(infd, &r, outfd, NULL, len, 0);
         if (n < 0) {
             if (errno == EAGAIN) continue;
