From b31d1d6a72f3d27f400fe6c0781a620780f2627e Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Mon, 8 May 2023 05:38:21 +0100 Subject: gentoo auto-resync : 08:05:2023 - 05:38:21 --- gui-wm/Manifest.gz | Bin 882 -> 1046 bytes gui-wm/hyprland/Manifest | 4 ++ gui-wm/hyprland/files/nvidia-0.25.0.patch | 43 +++++++++++++++ gui-wm/hyprland/hyprland-0.25.0.ebuild | 85 ++++++++++++++++++++++++++++++ gui-wm/hyprland/metadata.xml | 21 ++++++++ 5 files changed, 153 insertions(+) create mode 100644 gui-wm/hyprland/Manifest create mode 100644 gui-wm/hyprland/files/nvidia-0.25.0.patch create mode 100644 gui-wm/hyprland/hyprland-0.25.0.ebuild create mode 100644 gui-wm/hyprland/metadata.xml (limited to 'gui-wm') diff --git a/gui-wm/Manifest.gz b/gui-wm/Manifest.gz index 3dbda9c8b160..f4ce6d31b366 100644 Binary files a/gui-wm/Manifest.gz and b/gui-wm/Manifest.gz differ diff --git a/gui-wm/hyprland/Manifest b/gui-wm/hyprland/Manifest new file mode 100644 index 000000000000..1788c2d5fed5 --- /dev/null +++ b/gui-wm/hyprland/Manifest @@ -0,0 +1,4 @@ +AUX nvidia-0.25.0.patch 1394 BLAKE2B 95df2f6b82afb460a3e0a1769bb2abf41abcd76c564db3d43189fc9a617b92ae1de8422243f6624574d316187706d552439f47cc44bbcf3fa4f5fabd5d83b420 SHA512 5389d132e16c4dc7af3cdb48003ac7be8ae3760b6052d2edf637b3d645e2e85eda162353b245a848c5b9d218bfccfdfa987189d164444564d87a7048ec53f52d +DIST hyprland-0.25.0.gh.tar.gz 1510798 BLAKE2B c146c57e5142666ff76188e870ea4d2dd9613e25a1d2c3320dc222fbe62651975a40fffffe9cc936ced0e86f919534d7a6c94a8b1596f912c3ad9750a35e4f13 SHA512 84d12ef7bfb25e69c4a707a8ffc99ca23eb58e73630e3df1f134cb610c6206e42917f76b54db0cc6d10e7b929514cbac06dfc99feba8ff81aea0dc7fcb340450 +EBUILD hyprland-0.25.0.ebuild 1907 BLAKE2B 6d7afe19dc44cf7ca5daff7b1135e8be495eca9e1ee67a55ef9e80e9ad633c88908f1d027017510d9e6d96e9c0afad73bb69749216c20aa88fb57ea57d1d017d SHA512 a6eb284d5a674667c1d3e4aea62f0ff9f89a8ffeca084e0872d5cdcfd7e978a685ea1768d2a7479777b8e5a6b43e4edc642176fda6bf3909835484c0494c44cd +MISC metadata.xml 716 BLAKE2B fc5248c809b9b5bf1002e3d82ff80f595b8e613d09e5541f1a0151c3ea2c117376d25fa5a40c85d254533708d9eff5339bd329b42118e87ca49e22e55c0c5d7b SHA512 31252ced2546f3686f17259aabfe9273af14f7efaf3fa0bfb446c65c6d9478be3a23c531e0ac463f27fe1d50842f6f126f32e47a8a03a345306297e182952e98 diff --git a/gui-wm/hyprland/files/nvidia-0.25.0.patch b/gui-wm/hyprland/files/nvidia-0.25.0.patch new file mode 100644 index 000000000000..d9d2213607f4 --- /dev/null +++ b/gui-wm/hyprland/files/nvidia-0.25.0.patch @@ -0,0 +1,43 @@ +# From https://github.com/hyprwm/Hyprland/issues/2239#issuecomment-1536725235 +# This patch is recommended by the developer on systems running and Nvidia GPu +diff --git a/render/gles2/renderer.c b/render/gles2/renderer.c +index 6a86b183..823fc318 100644 +--- a/render/gles2/renderer.c ++++ b/render/gles2/renderer.c +@@ -165,7 +165,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 +index ed1afa4a..ddc730c7 100644 +--- a/types/output/render.c ++++ b/types/output/render.c +@@ -225,22 +225,7 @@ struct wlr_drm_format *output_pick_format(struct wlr_output *output, + } + + uint32_t wlr_output_preferred_read_format(struct wlr_output *output) { +- struct wlr_renderer *renderer = output->renderer; +- assert(renderer != NULL); +- +- if (!renderer->impl->preferred_read_format || !renderer->impl->read_pixels) { +- return DRM_FORMAT_INVALID; +- } +- +- if (!output_attach_back_buffer(output, &output->pending, NULL)) { +- return false; +- } +- +- uint32_t fmt = renderer->impl->preferred_read_format(renderer); +- +- output_clear_back_buffer(output); +- +- return fmt; ++ return DRM_FORMAT_XRGB8888; + } + + bool output_is_direct_scanout(struct wlr_output *output, diff --git a/gui-wm/hyprland/hyprland-0.25.0.ebuild b/gui-wm/hyprland/hyprland-0.25.0.ebuild new file mode 100644 index 000000000000..923882538f0e --- /dev/null +++ b/gui-wm/hyprland/hyprland-0.25.0.ebuild @@ -0,0 +1,85 @@ +# Copyright 2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit meson toolchain-funcs + +DESCRIPTION="A dynamic tiling Wayland compositor that doesn't sacrifice on its looks" +HOMEPAGE="https://github.com/hyprwm/Hyprland/releases" + +SRC_URI="https://github.com/hyprwm/${PN^}/releases/download/v${PV}/source-v${PV}.tar.gz -> ${PF}.gh.tar.gz" +S="${WORKDIR}/${PN}-source" + +KEYWORDS="~amd64" +LICENSE="BSD" +SLOT="0" +IUSE="X legacy-renderer systemd video_cards_nvidia" + +RDEPEND=" + app-misc/jq + dev-libs/libevdev + dev-libs/libinput + dev-libs/wayland + dev-libs/wayland-protocols + dev-util/glslang + dev-util/vulkan-headers + gui-libs/gtk-layer-shell + media-libs/libdisplay-info + media-libs/libglvnd[X?] + media-libs/mesa[gles2,wayland,X?] + media-libs/vulkan-loader + x11-base/xcb-proto + x11-libs/cairo + x11-libs/libdrm + x11-libs/libxkbcommon + x11-libs/pixman + x11-misc/xkeyboard-config + virtual/libudev + X? ( + gui-libs/wlroots[x11-backend] + x11-base/xwayland + x11-libs/libxcb + x11-libs/xcb-util-image + x11-libs/xcb-util-renderutil + x11-libs/xcb-util-wm + ) +" +DEPEND="${RDEPEND}" +BDEPEND=" + dev-libs/hyprland-protocols + dev-libs/libliftoff + >=dev-libs/wayland-1.22.0 + dev-vcs/git + >=gui-libs/wlroots-0.16.0[X?] +" + +src_prepare() { + STDLIBVER=$(echo '#include ' | $(tc-getCXX) -x c++ -dM -E - | \ + grep GLIBCXX_RELEASE | sed 's/.*\([1-9][0-9]\)/\1/') + if ! [[ ${STDLIBVER} -ge 12 ]]; then + die "Hyprland requires >=sys-devel/gcc-12.1.0 to build" + fi + + if use video_cards_nvidia; then + cd "${S}/subprojects/wlroots" || die + eapply "${FILESDIR}/nvidia-0.25.0.patch" + cd "${S}" || die + fi + + eapply_user +} + +src_configure() { + local emesonargs=( + $(meson_feature legacy-renderer legacy_renderer) + $(meson_feature X xwayland) + $(meson_feature systemd) + ) + + meson_src_configure +} + +src_install() { + meson_src_install --skip-subprojects wlroots +} diff --git a/gui-wm/hyprland/metadata.xml b/gui-wm/hyprland/metadata.xml new file mode 100644 index 000000000000..e894da71d007 --- /dev/null +++ b/gui-wm/hyprland/metadata.xml @@ -0,0 +1,21 @@ + + + + + julien@jroy.ca + Julien Roy + + + proxy-maint@gentoo.org + Proxy Maintainers + + + https://github.com/hyprwm/Hyprland/releases + https://wiki.hyprland.org/ + https://github.com/hyprwm/Hyprland/issues + hyprwm/Hyprland + + + Enable legacy renderer + + -- cgit v1.2.3