diff --git a/x11-toolkits/wlroots-devel/Makefile b/x11-toolkits/wlroots-devel/Makefile index 55f697dfe8e1..bfe0f3800aa4 100644 --- a/x11-toolkits/wlroots-devel/Makefile +++ b/x11-toolkits/wlroots-devel/Makefile @@ -1,86 +1,86 @@ PORTNAME= wlroots -DISTVERSION= 0.16.0-623 +DISTVERSION= 0.16.0-643 DISTVERSIONSUFFIX= -g${GL_COMMIT:C/(.{12}).*/\1/} CATEGORIES= x11-toolkits PKGNAMESUFFIX= -devel PATCH_SITES+= https://github.com/swaywm/${GL_PROJECT}/commit/:github PATCHFILES+= 10f80a8f1bb2.patch:-p1:github # https://gitlab.freedesktop.org/wlroots/wlroots/-/merge_requests/2064 PATCHFILES+= 3196c73d487f.patch:-p1:github # https://gitlab.freedesktop.org/wlroots/wlroots/-/merge_requests/2064 PATCH_SITES+= ${GL_SITE}/${GL_ACCOUNT}/${GL_PROJECT}/-/commit/ MAINTAINER= jbeich@FreeBSD.org COMMENT= Modular Wayland compositor library (development snapshot) WWW= https://gitlab.freedesktop.org/wlroots/wlroots LICENSE= MIT LICENSE_FILE= ${WRKSRC}/LICENSE BUILD_DEPENDS= wayland-protocols>=1.31:graphics/wayland-protocols LIB_DEPENDS= libdrm.so:graphics/libdrm \ libwayland-server.so:graphics/wayland \ libxkbcommon.so:x11/libxkbcommon USES= compiler:c11 gl meson pkgconfig xorg USE_GITLAB= yes USE_GL= gbm USE_XORG= pixman USE_LDCONFIG= yes GL_SITE= https://gitlab.freedesktop.org -GL_COMMIT= bbd53b3b46312840f1e699c7a8c49ccadfc438b4 +GL_COMMIT= 214df8eda07d18b032abfcf525c8344e077c0c7e MESON_ARGS= -Dexamples=false -Dbackends=${BACKENDS:ts,} -Drenderers=${RENDERERS:ts,} .ifdef PKGNAMESUFFIX PORTSCOUT= ignore:1 PREFIX= ${LOCALBASE}/${PKGBASE} # avoid conflict with the default MESON_ARGS+= -Ddatadir="${LOCALBASE}/share" .endif OPTIONS_DEFINE= DRM OPENGL VULKAN X11 OPTIONS_DEFAULT=DRM OPENGL VULKAN X11 OPTIONS_SUB= yes DRM_DESC= KMS console support DRM_BUILD_DEPENDS= hwdata>0:misc/hwdata DRM_LIB_DEPENDS= libudev.so:devel/libudev-devd \ libliftoff.so:graphics/libliftoff \ libdisplay-info.so:sysutils/libdisplay-info \ libseat.so:sysutils/seatd \ libinput.so:x11/libinput DRM_MESON_ENABLED= session DRM_VARS= BACKENDS+="drm libinput" OPENGL_RUN_DEPENDS= mesa-dri>0:graphics/mesa-dri OPENGL_USE= GL=egl,glesv2 OPENGL_VARS= RENDERERS+=gles2 VULKAN_DESC= Vulkan renderer VULKAN_BUILD_DEPENDS= glslangValidator:graphics/glslang \ vulkan-headers>0:graphics/vulkan-headers VULKAN_LIB_DEPENDS= libvulkan.so:graphics/vulkan-loader VULKAN_RUN_DEPENDS= mesa-dri>0:graphics/mesa-dri VULKAN_VARS= RENDERERS+=vulkan X11_LIB_DEPENDS= libxcb-errors.so:x11/xcb-util-errors \ libxcb-render-util.so:x11/xcb-util-renderutil \ libxcb-icccm.so:x11/xcb-util-wm X11_BUILD_DEPENDS= evdev-proto>0:devel/evdev-proto \ xwayland-devel>0:x11-servers/xwayland-devel X11_RUN_DEPENDS= xwayland-devel>0:x11-servers/xwayland-devel X11_USE= XORG=xcb X11_MESON_ENABLED= xwayland X11_VARS= BACKENDS+=x11 post-patch: # Extract (snapshot) version from the port instead of meson.build @${REINPLACE_CMD} "/STR/s/meson.project_version()/'${DISTVERSIONFULL}'/" \ ${WRKSRC}/include/wlr/meson.build # XXX Drop after FreeBSD 12.4 EOL around 2023-12-31 # https://cgit.freebsd.org/src/commit/?id=d7535fb3e3cb @if [ ${OPSYS} = FreeBSD -a ${OSVERSION} -lt 1300515 ]; then \ ${REINPLACE_CMD} -e '/POSIX/s/199309/200112/' \ ${WRKSRC}/render/gles2/pass.c \ ${WRKSRC}/render/gles2/renderer.c; \ fi .include diff --git a/x11-toolkits/wlroots-devel/distinfo b/x11-toolkits/wlroots-devel/distinfo index fa482b06b1c7..bda10a53af3a 100644 --- a/x11-toolkits/wlroots-devel/distinfo +++ b/x11-toolkits/wlroots-devel/distinfo @@ -1,7 +1,7 @@ -TIMESTAMP = 1688220330 -SHA256 (wlroots-wlroots-bbd53b3b46312840f1e699c7a8c49ccadfc438b4_GL0.tar.gz) = d4ab00b07639478569a2118119921575e8e11db94be6495f8e6ed2194c436ce7 -SIZE (wlroots-wlroots-bbd53b3b46312840f1e699c7a8c49ccadfc438b4_GL0.tar.gz) = 631453 +TIMESTAMP = 1688370414 +SHA256 (wlroots-wlroots-214df8eda07d18b032abfcf525c8344e077c0c7e_GL0.tar.gz) = 42f1ea360ac5aa24ff7f6af55d6b1542e5406438300dc13d8c8ef630d79e89c5 +SIZE (wlroots-wlroots-214df8eda07d18b032abfcf525c8344e077c0c7e_GL0.tar.gz) = 631599 SHA256 (10f80a8f1bb2.patch) = ca65f8eecf32e7364d5ba43cd9ee91060710a6fb8392892c86ad71e4f2a4c0b5 SIZE (10f80a8f1bb2.patch) = 6097 SHA256 (3196c73d487f.patch) = 69c6bc4658852bb45a24b129f625a7faaed8035dab0d79c388ae74d650beacdc SIZE (3196c73d487f.patch) = 4243 diff --git a/x11-wm/hyprland/Makefile b/x11-wm/hyprland/Makefile index 869a838aed92..b52673d17ec9 100644 --- a/x11-wm/hyprland/Makefile +++ b/x11-wm/hyprland/Makefile @@ -1,112 +1,112 @@ PORTNAME= hyprland DISTVERSIONPREFIX= v DISTVERSION= 0.26.0 -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES= x11-wm wayland PATCH_SITES= https://github.com/${GH_ACCOUNT}/${GH_PROJECT}/commit/ PATCHFILES+= 147e96237006.patch:-p1 # wlroots 0.17 PATCHFILES+= c5a7202cd9a4.patch:-p1 # wlroots 0.17 PATCHFILES+= 10db5a4fdbb0.patch:-p1 # wlroots 0.17 PATCHFILES+= fbabb105c342.patch:-p1 # wlroots 0.17 MAINTAINER= jbeich@FreeBSD.org COMMENT= Dynamic tiling Wayland compositor that doesn't sacrifice on its looks #' WWW= https://hyprland.org/ LICENSE= BSD3CLAUSE LICENSE_FILE= ${WRKSRC}/LICENSE BUILD_DEPENDS= cmake:devel/cmake-core \ evdev-proto>0:devel/evdev-proto \ wayland-protocols>=1.25:graphics/wayland-protocols \ wlroots>=0.16.0.529<0.17.0:x11-toolkits/wlroots LIB_DEPENDS= libwayland-server.so:graphics/wayland \ libwlroots.so:x11-toolkits/wlroots \ libinput.so:x11/libinput \ libxkbcommon.so:x11/libxkbcommon USES= compiler:c++11-lib gl gnome meson pkgconfig xorg USE_GITHUB= yes USE_GL= egl opengl USE_GNOME= cairo pango USE_XORG= pixman GH_ACCOUNT= hyprwm GH_PROJECT= Hyprland GH_TUPLE= hyprwm:hyprland-protocols:4d29e48:hyprland_protocols/subprojects/hyprland-protocols \ canihavesomecoffee:udis86:1.7.2-186-g5336633:udis86/subprojects/udis86 MESON_ARGS= -Dsystemd=disabled OPTIONS_DEFINE= X11 OPTIONS_DEFAULT=X11 X11_USE= XORG=xcb X11_MESON_ENABLED= xwayland post-extract: .if defined(PATCHFILES) && ${PATCHFILES:M147e96237006*} # Pretend to be a regular file for vendor patch to apply as is @${RMDIR} ${WRKSRC}/subprojects/wlroots @${ECHO_CMD} "Subproject commit 6668c822b3bf58ca5af5d370ef03b075be3e4d27" \ >${WRKSRC}/subprojects/wlroots .endif post-patch: # Extract (snapshot) version from the port instead of meson.build @${REINPLACE_CMD} -i .nogit -e "/GIT_BRANCH/s/run_command.*/'main'/" \ -e "/GIT_COMMIT_HASH/s/run_command.*/'${DISTVERSIONFULL}'/" \ -e "/GIT_COMMIT_MESSAGE/d" \ -e "/GIT_DIRTY/s/run_command.*/'portbld'/" \ -e "/version.*jq/s/run_command.*/'${DISTVERSIONFULL}',/" \ ${WRKSRC}/meson.build # Respect PREFIX for wallpapers @${REINPLACE_CMD} 's,/usr/share,${DATADIR:H},' \ ${WRKSRC}/src/render/OpenGL.cpp # Respect LOCALBASE for xdg-desktop-portal-hyprland installation @${REINPLACE_CMD} 's,/usr/share,${LOCALBASE}/share,g' \ ${WRKSRC}/src/Compositor.cpp .ifdef GH_TUPLE post-configure: @${REINPLACE_CMD} 's/meson install/& \ --skip-subprojects/' ${BUILD_WRKSRC}/build.ninja .endif post-install: # Plugin API installs all headers (no private vs. public) @(cd ${STAGEDIR}${PREFIX} && ${FIND} include/${PORTNAME} ! -type d) >>${TMPPLIST} # XXX Drop after FreeBSD 13.2 EOL around 2024-05-01 (don't forget distinfo) .if ${CXX} == c++ && exists(/usr/lib/libc++.so) .if !exists(/usr/include/c++/v1/__ranges/as_rvalue_view.h) || make(makesum) || make(fetch) USES+= llvm:min=16,build PATH:= ${LLVM_PREFIX}/bin:${PATH} # XXX _CMAKE_TOOLCHAIN_SUFFIX vs. devel/llvm* CC= clang${LLVM_VERSION} CXX= clang++${LLVM_VERSION} CPP= clang-cpp${LLVM_VERSION} CONFIGURE_ENV+= CC="${CC}" CXX="${CXX}" CPP="${CPP}" CMAKE_BIN= ${LOCALBASE}/bin/cmake # XXX Move into separate port and standardize via USES GH_TUPLE+= llvm:llvm-project:llvmorg-16.0.1:libcxx CXXFLAGS+= -nostdinc++ -isystem${WRKDIR}/libcxx_prefix/include/c++/v1 # Don't link against new libc++ as it's not necessary #LDFLAGS+= -nostdlib++ -L${WRKDIR}/libcxx_prefix/lib -l:libc++.a -lcxxrt pre-configure: bundled-libcxx bundled-libcxx: @${SETENV} ${CONFIGURE_ENV} ${CMAKE_BIN} ${CMAKE_ARGS} \ -DLIBCXX_INCLUDE_BENCHMARKS:BOOL=OFF \ -DCMAKE_INSTALL_PREFIX:PATH=${WRKDIR}/libcxx_prefix \ -B ${WRKDIR}/libcxx_build -S ${WRKSRC_libcxx}/libcxx @${DO_MAKE_BUILD:NDESTDIR*} install -C ${WRKDIR}/libcxx_build .endif .endif # exists(/usr/lib/libc++.so) .include "${.CURDIR:H:H}/x11-toolkits/wlroots-devel/override.mk" post-patch: wlroots-devel-patch wlroots-devel-patch: # Prefer headers (used by ) from wlroots-devel @${REINPLACE_CMD} -i .devel "/subdirs/s|''|'../wlroots-devel/include', &|" \ ${WRKSRC}/meson.build .include diff --git a/x11-wm/hyprland/files/patch-wlroots-0.17 b/x11-wm/hyprland/files/patch-wlroots-0.17 new file mode 100644 index 000000000000..526c8fbc4031 --- /dev/null +++ b/x11-wm/hyprland/files/patch-wlroots-0.17 @@ -0,0 +1,120 @@ +Apply https://github.com/swaywm/sway/commit/6f1a3b6652b9 + +../src/Compositor.cpp:461:5: error: use of undeclared identifier 'wlr_xcursor_manager_set_cursor_image'; did you mean 'wlr_xcursor_manager_get_xcursor'? + wlr_xcursor_manager_set_cursor_image(m_sWLRXCursorMgr, "left_ptr", m_sWLRCursor); + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +../src/render/Renderer.cpp:1898:17: error: use of undeclared identifier 'wlr_xcursor_manager_set_cursor_image'; did you mean 'wlr_xcursor_manager_get_xcursor'? + wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "left_ptr", g_pCompositor->m_sWLRCursor); + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +../src/managers/input/InputManager.cpp:295:21: error: use of undeclared identifier 'wlr_xcursor_manager_set_cursor_image'; did you mean 'wlr_xcursor_manager_get_xcursor'? + wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "crosshair", g_pCompositor->m_sWLRCursor); + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +../src/managers/input/InputManager.cpp:297:21: error: use of undeclared identifier 'wlr_xcursor_manager_set_cursor_image'; did you mean 'wlr_xcursor_manager_get_xcursor'? + wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "left_ptr", g_pCompositor->m_sWLRCursor); + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +../src/managers/input/InputManager.cpp:470:9: error: use of undeclared identifier 'wlr_xcursor_manager_set_cursor_image'; did you mean 'wlr_xcursor_manager_get_xcursor'? + wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "crosshair", g_pCompositor->m_sWLRCursor); + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +../src/managers/input/InputManager.cpp:496:13: error: use of undeclared identifier 'wlr_xcursor_manager_set_cursor_image'; did you mean 'wlr_xcursor_manager_get_xcursor'? + wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "left_ptr", g_pCompositor->m_sWLRCursor); + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +../src/managers/input/InputManager.cpp:508:13: error: use of undeclared identifier 'wlr_xcursor_manager_set_cursor_image'; did you mean 'wlr_xcursor_manager_get_xcursor'? + wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "crosshair", g_pCompositor->m_sWLRCursor); + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +../src/managers/input/InputManager.cpp:1431:5: error: use of undeclared identifier 'wlr_xcursor_manager_set_cursor_image'; did you mean 'wlr_xcursor_manager_get_xcursor'? + wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, name.c_str(), g_pCompositor->m_sWLRCursor); + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +../src/managers/input/InputManager.cpp:1441:9: error: use of undeclared identifier 'wlr_xcursor_manager_set_cursor_image'; did you mean 'wlr_xcursor_manager_get_xcursor'? + wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "left_ptr", g_pCompositor->m_sWLRCursor); + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +--- src/Compositor.cpp.orig 2023-07-11 02:50:09 UTC ++++ src/Compositor.cpp +@@ -458,7 +458,7 @@ void CCompositor::startCompositor() { + throw std::runtime_error("The backend could not start!"); + } + +- wlr_xcursor_manager_set_cursor_image(m_sWLRXCursorMgr, "left_ptr", m_sWLRCursor); ++ wlr_cursor_set_xcursor(m_sWLRCursor, m_sWLRXCursorMgr, "left_ptr"); + + #ifdef USES_SYSTEMD + if (sd_booted() > 0) +--- src/managers/input/InputManager.cpp.orig 2023-05-29 17:17:38 UTC ++++ src/managers/input/InputManager.cpp +@@ -292,9 +292,9 @@ void CInputManager::mouseMoveUnified(uint32_t time, bo + if (g_pHyprRenderer->m_bHasARenderedCursor) { + // TODO: maybe wrap? + if (m_ecbClickBehavior == CLICKMODE_KILL) +- wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "crosshair", g_pCompositor->m_sWLRCursor); ++ wlr_cursor_set_xcursor(g_pCompositor->m_sWLRCursor, g_pCompositor->m_sWLRXCursorMgr, "crosshair"); + else +- wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "left_ptr", g_pCompositor->m_sWLRCursor); ++ wlr_cursor_set_xcursor(g_pCompositor->m_sWLRCursor, g_pCompositor->m_sWLRXCursorMgr, "left_ptr"); + } + + m_bEmptyFocusCursorSet = true; +@@ -361,7 +361,7 @@ void CInputManager::mouseMoveUnified(uint32_t time, bo + // if (!m_bCursorImageOverridden) { + // if (!VECINRECT(m_vLastCursorPosFloored, pFoundWindow->m_vRealPosition.vec().x, pFoundWindow->m_vRealPosition.vec().y, + // pFoundWindow->m_vRealPosition.vec().x + pFoundWindow->m_vRealSize.vec().x, pFoundWindow->m_vRealPosition.vec().y + pFoundWindow->m_vRealSize.vec().y)) { +- // wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "left_ptr", g_pCompositor->m_sWLRCursor); ++ // wlr_cursor_set_xcursor(g_pCompositor->m_sWLRCursor, g_pCompositor->m_sWLRXCursorMgr, "left_ptr"); + // cursorSurfaceInfo.bUsed = false; + // } else if (!cursorSurfaceInfo.bUsed) { + // cursorSurfaceInfo.bUsed = true; +@@ -467,7 +467,7 @@ void CInputManager::processMouseRequest(wlr_seat_point + } + + if (m_ecbClickBehavior == CLICKMODE_KILL) { +- wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "crosshair", g_pCompositor->m_sWLRCursor); ++ wlr_cursor_set_xcursor(g_pCompositor->m_sWLRCursor, g_pCompositor->m_sWLRXCursorMgr, "crosshair"); + return; + } + +@@ -493,7 +493,7 @@ void CInputManager::setClickMode(eClickBehaviorMode mo + case CLICKMODE_DEFAULT: + Debug::log(LOG, "SetClickMode: DEFAULT"); + m_ecbClickBehavior = CLICKMODE_DEFAULT; +- wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "left_ptr", g_pCompositor->m_sWLRCursor); ++ wlr_cursor_set_xcursor(g_pCompositor->m_sWLRCursor, g_pCompositor->m_sWLRXCursorMgr, "left_ptr"); + break; + + case CLICKMODE_KILL: +@@ -505,7 +505,7 @@ void CInputManager::setClickMode(eClickBehaviorMode mo + refocus(); + + // set cursor +- wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "crosshair", g_pCompositor->m_sWLRCursor); ++ wlr_cursor_set_xcursor(g_pCompositor->m_sWLRCursor, g_pCompositor->m_sWLRXCursorMgr, "crosshair"); + break; + default: break; + } +@@ -1428,7 +1428,7 @@ void CInputManager::setCursorImageUntilUnset(std::stri + } + + void CInputManager::setCursorImageUntilUnset(std::string name) { +- wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, name.c_str(), g_pCompositor->m_sWLRCursor); ++ wlr_cursor_set_xcursor(g_pCompositor->m_sWLRCursor, g_pCompositor->m_sWLRXCursorMgr, name.c_str()); + m_bCursorImageOverridden = true; + } + +@@ -1438,7 +1438,7 @@ void CInputManager::unsetCursorImage() { + + m_bCursorImageOverridden = false; + if (!g_pHyprRenderer->m_bWindowRequestedCursorHide) +- wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "left_ptr", g_pCompositor->m_sWLRCursor); ++ wlr_cursor_set_xcursor(g_pCompositor->m_sWLRCursor, g_pCompositor->m_sWLRXCursorMgr, "left_ptr"); + } + + std::string CInputManager::deviceNameToInternalString(std::string in) { +--- src/render/Renderer.cpp.orig 2023-07-11 02:50:09 UTC ++++ src/render/Renderer.cpp +@@ -1895,7 +1895,7 @@ void CHyprRenderer::ensureCursorRenderingMode() { + m_bHasARenderedCursor = true; + + if (!m_bWindowRequestedCursorHide) +- wlr_xcursor_manager_set_cursor_image(g_pCompositor->m_sWLRXCursorMgr, "left_ptr", g_pCompositor->m_sWLRCursor); ++ wlr_cursor_set_xcursor(g_pCompositor->m_sWLRCursor, g_pCompositor->m_sWLRXCursorMgr, "left_ptr"); + + Debug::log(LOG, "Showing the cursor (timeout)"); +