Skip to content

Commit

Permalink
fix(overlays): remove glfw overlay
Browse files Browse the repository at this point in the history
  • Loading branch information
zakuciael committed Jun 30, 2024
1 parent 4e3f84b commit e42c013
Showing 1 changed file with 15 additions and 15 deletions.
30 changes: 15 additions & 15 deletions overlays/imhex.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,24 +2,24 @@
with lib; {
# Adds fixes for https://github.com/NixOS/nixpkgs/issues/309532
unstable = singleton (final: prev: {
# TODO: Remove when this https://github.com/NixOS/nixpkgs/pull/323510 is merged to upstream
glfw3 = prev.glfw3.overrideAttrs (prevAttrs: let
inherit (prev) stdenv libxkbcommon libdecor wayland;
in {
postPatch = optionalString stdenv.isLinux ''
substituteInPlace src/wl_init.c \
--replace-fail "libxkbcommon.so.0" "${getLib libxkbcommon}/lib/libxkbcommon.so.0" \
--replace-fail "libdecor-0.so.0" "${getLib libdecor}/lib/libdecor-0.so.0" \
--replace-fail "libwayland-client.so.0" "${getLib wayland}/lib/libwayland-client.so.0" \
--replace-fail "libwayland-cursor.so.0" "${getLib wayland}/lib/libwayland-cursor.so.0" \
--replace-fail "libwayland-egl.so.1" "${getLib wayland}/lib/libwayland-egl.so.1"
'';
});

# TODO: Remove when this https://github.com/NixOS/nixpkgs/pull/323501 is merged to upstream
imhex = prev.imhex.overrideAttrs (prevAttrs: let
inherit (prev) fetchFromGitHub;

# TODO: Remove when this https://github.com/NixOS/nixpkgs/pull/323510 is merged to upstream
glfw3-patched = prev.glfw3.overrideAttrs (prevAttrs: let
inherit (prev) stdenv libxkbcommon libdecor wayland;
in {
postPatch = optionalString stdenv.isLinux ''
substituteInPlace src/wl_init.c \
--replace-fail "libxkbcommon.so.0" "${getLib libxkbcommon}/lib/libxkbcommon.so.0" \
--replace-fail "libdecor-0.so.0" "${getLib libdecor}/lib/libdecor-0.so.0" \
--replace-fail "libwayland-client.so.0" "${getLib wayland}/lib/libwayland-client.so.0" \
--replace-fail "libwayland-cursor.so.0" "${getLib wayland}/lib/libwayland-cursor.so.0" \
--replace-fail "libwayland-egl.so.1" "${getLib wayland}/lib/libwayland-egl.so.1"
'';
});

version = "1.35.3";
patterns_version = "1.35.3";

Expand Down Expand Up @@ -58,7 +58,7 @@ with lib; {
dbus
file
fmt_8
final.glfw3
glfw3-patched
gtk3
jansson
libGLU
Expand Down

0 comments on commit e42c013

Please sign in to comment.