@@ -12,21 +12,27 @@
1212
1313--- a/kitty/desktop.c
1414+++ b/kitty/desktop.c
15−@@ -30,7 +30,7 @@
16− static PyObject*
17− init_x11_startup_notification(PyObject UNUSED *self, PyObject *args) {
18− static bool done = false;
19−- static const char* libname = "libstartup-notification-1.so";
20−+ static const char* libname = "@libstartup_notification@";
21− // some installs are missing the .so symlink, so try the full name
22− static const char* libname2 = "libstartup-notification-1.so.0";
23− static const char* libname3 = "libstartup-notification-1.so.0.0.0";
24−@@ -105,7 +105,7 @@ load_libcanberra_functions(void) {
15+@@ -34,10 +34,7 @@ init_x11_startup_notification(PyObject UNUSED *self, PyObject *args) {
16+ done = true;
2517
26− static void
27− load_libcanberra(void) {
28−- static const char* libname = "libcanberra.so";
29−+ static const char* libname = "@libcanberra@";
30− // some installs are missing the .so symlink, so try the full name
31− static const char* libname2 = "libcanberra.so.0";
32− static const char* libname3 = "libcanberra.so.0.2.5";
18+ const char* libnames[] = {
19+- "libstartup-notification-1.so",
20+- // some installs are missing the .so symlink, so try the full name
21+- "libstartup-notification-1.so.0",
22+- "libstartup-notification-1.so.0.0.0",
23++ "@libstartup_notification@",
24+ NULL
25+ };
26+ for (int i = 0; libnames[i]; i++) {
27+@@ -113,10 +110,7 @@ load_libcanberra(void) {
28+ if (done) return;
29+ done = true;
30+ const char* libnames[] = {
31+- "libcanberra.so",
32+- // some installs are missing the .so symlink, so try the full name
33+- "libcanberra.so.0",
34+- "libcanberra.so.0.2.5",
35++ "@libcanberra@",
36+ NULL
37+ };
38+ for (int i = 0; libnames[i]; i++) {