mirror of
https://github.com/hyprwm/Hyprland
synced 2024-11-22 21:45:58 +01:00
Nix: fix nvidia patch for dual gpu system
* this fix it most important for laptops with dgpu * remove post patch line wlroots.nix Signed-off-by: Gonçalo Duarte <gonegrier.duarte@gmail.com>
This commit is contained in:
parent
8e04a80e60
commit
12cb109137
2 changed files with 13 additions and 9 deletions
|
@ -1,3 +1,16 @@
|
||||||
|
diff --git a/render/gles2/renderer.c b/render/gles2/renderer.c
|
||||||
|
index 9fe934f7..9662d4ee 100644
|
||||||
|
--- a/render/gles2/renderer.c
|
||||||
|
+++ b/render/gles2/renderer.c
|
||||||
|
@@ -176,7 +176,7 @@ static bool gles2_bind_buffer(struct wlr_renderer *wlr_renderer,
|
||||||
|
assert(wlr_egl_is_current(renderer->egl));
|
||||||
|
|
||||||
|
push_gles2_debug(renderer);
|
||||||
|
- glFlush();
|
||||||
|
+ glFinish();
|
||||||
|
glBindFramebuffer(GL_FRAMEBUFFER, 0);
|
||||||
|
pop_gles2_debug(renderer);
|
||||||
|
|
||||||
diff --git a/types/output/render.c b/types/output/render.c
|
diff --git a/types/output/render.c b/types/output/render.c
|
||||||
index 2e38919a..97f78608 100644
|
index 2e38919a..97f78608 100644
|
||||||
--- a/types/output/render.c
|
--- a/types/output/render.c
|
||||||
|
|
|
@ -46,15 +46,6 @@ assert (lib.assertMsg (hidpiXWayland -> enableXWayland) ''
|
||||||
++ (lib.optionals nvidiaPatches [
|
++ (lib.optionals nvidiaPatches [
|
||||||
./patches/wlroots-nvidia.patch
|
./patches/wlroots-nvidia.patch
|
||||||
]);
|
]);
|
||||||
postPatch =
|
|
||||||
(old.postPatch or "")
|
|
||||||
+ (
|
|
||||||
if nvidiaPatches
|
|
||||||
then ''
|
|
||||||
substituteInPlace render/gles2/renderer.c --replace "glFlush();" "glFinish();"
|
|
||||||
''
|
|
||||||
else ""
|
|
||||||
);
|
|
||||||
buildInputs = old.buildInputs ++ [hwdata libliftoff libdisplay-info];
|
buildInputs = old.buildInputs ++ [hwdata libliftoff libdisplay-info];
|
||||||
|
|
||||||
NIX_CFLAGS_COMPILE = toString [
|
NIX_CFLAGS_COMPILE = toString [
|
||||||
|
|
Loading…
Reference in a new issue