Skip to content

Commit

Permalink
glfw: add missing substitutions in glfw3
Browse files Browse the repository at this point in the history
This fixes the same issue that #276228 addressed, but in the regular
edition instead.
  • Loading branch information
someplaceguy committed Jun 30, 2024
1 parent cd66028 commit 543efca
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions pkgs/development/libraries/glfw/3.x.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
, libGL, libXrandr, libXinerama, libXcursor, libX11, libXi, libXext
, Carbon, Cocoa, Kernel, OpenGL, fixDarwinDylibNames
, extra-cmake-modules, wayland
, wayland-scanner, wayland-protocols, libxkbcommon
, wayland-scanner, wayland-protocols, libxkbcommon, libdecor
}:

stdenv.mkDerivation rec {
Expand Down Expand Up @@ -50,7 +50,11 @@ stdenv.mkDerivation rec {

postPatch = lib.optionalString stdenv.isLinux ''
substituteInPlace src/wl_init.c \
--replace "libxkbcommon.so.0" "${lib.getLib libxkbcommon}/lib/libxkbcommon.so.0"
--replace-fail "libxkbcommon.so.0" "${lib.getLib libxkbcommon}/lib/libxkbcommon.so.0" \
--replace-fail "libdecor-0.so.0" "${lib.getLib libdecor}/lib/libdecor-0.so.0" \
--replace-fail "libwayland-client.so.0" "${lib.getLib wayland}/lib/libwayland-client.so.0" \
--replace-fail "libwayland-cursor.so.0" "${lib.getLib wayland}/lib/libwayland-cursor.so.0" \
--replace-fail "libwayland-egl.so.1" "${lib.getLib wayland}/lib/libwayland-egl.so.1"
'';

# glfw may dlopen libwayland-client.so:
Expand Down

0 comments on commit 543efca

Please sign in to comment.