Merge pull request #74874 from Luflosi/fix-kitty-lib

kitty: fix loading of library
This commit is contained in:
Maximilian Bosch 2019-12-07 17:48:48 +01:00 committed by GitHub
commit 6bd93d58d5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 24 additions and 12 deletions

View File

@ -64,9 +64,12 @@ buildPythonApplication rec {
outputs = [ "out" "terminfo" ];
patches = [
./fix-paths.patch
] ++ stdenv.lib.optionals stdenv.isLinux [
(substituteAll {
src = ./fix-paths.patch;
src = ./library-paths.patch;
libstartup_notification = "${libstartup_notification}/lib/libstartup-notification-1.so";
libcanberra = "${libcanberra}/lib/libcanberra.so";
})
] ++ stdenv.lib.optionals stdenv.isDarwin [
./no-lto.patch

View File

@ -1,14 +1,3 @@
--- a/kitty/desktop.c
+++ b/kitty/desktop.c
@@ -30,7 +30,7 @@
static PyObject*
init_x11_startup_notification(PyObject UNUSED *self, PyObject *args) {
static bool done = false;
- static const char* libname = "libstartup-notification-1.so";
+ static const char* libname = "@libstartup_notification@";
// some installs are missing the .so symlink, so try the full name
static const char* libname2 = "libstartup-notification-1.so.0";
--- a/docs/Makefile
+++ b/docs/Makefile
@@ -3,7 +3,7 @@

View File

@ -0,0 +1,20 @@
--- a/kitty/desktop.c
+++ b/kitty/desktop.c
@@ -30,7 +30,7 @@
static PyObject*
init_x11_startup_notification(PyObject UNUSED *self, PyObject *args) {
static bool done = false;
- static const char* libname = "libstartup-notification-1.so";
+ static const char* libname = "@libstartup_notification@";
// some installs are missing the .so symlink, so try the full name
static const char* libname2 = "libstartup-notification-1.so.0";
static const char* libname3 = "libstartup-notification-1.so.0.0.0";
@@ -105,7 +105,7 @@ load_libcanberra_functions(void) {
static void
load_libcanberra(void) {
- static const char* libname = "libcanberra.so";
+ static const char* libname = "@libcanberra@";
// some installs are missing the .so symlink, so try the full name
static const char* libname2 = "libcanberra.so.0";
static const char* libname3 = "libcanberra.so.0.2.5";