diff --git a/x11-wm/hyprland/Makefile b/x11-wm/hyprland/Makefile index ab6ee6a4098c..54494abcb24b 100644 --- a/x11-wm/hyprland/Makefile +++ b/x11-wm/hyprland/Makefile @@ -1,109 +1,102 @@ PORTNAME= hyprland DISTVERSIONPREFIX= v -DISTVERSION= 0.42.0 -PORTREVISION= 2 +DISTVERSION= 0.43.0 CATEGORIES= x11-wm wayland -PATCH_SITES= https://github.com/${GH_ACCOUNT}/${GH_PROJECT}/commit/ -PATCHFILES+= 4fdc0d55e4b4.patch:-p1 # https://github.com/hyprwm/Hyprland/issues/6842 -PATCHFILES+= 118d4e1001d5.patch:-p1 # https://github.com/hyprwm/Hyprland/pull/7281 -PATCHFILES+= ff3f41c9a5d1.patch:-p1 # https://github.com/hyprwm/Hyprland/pull/7626 -PATCHFILES+= 89fa6a6a66e6.patch:-p1 # https://github.com/hyprwm/Hyprland/pull/7626 - 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= evdev-proto>0:devel/evdev-proto \ hyprwayland-scanner>=0.3.10:devel/hyprwayland-scanner \ tomlplusplus>0:devel/tomlplusplus \ wayland-protocols>=1.35:graphics/wayland-protocols LIB_DEPENDS= libhyprlang.so:devel/hyprlang \ libhyprutils.so:devel/hyprutils \ libdrm.so:graphics/libdrm \ libwayland-server.so:graphics/wayland \ libuuid.so:misc/e2fsprogs-libuuid \ libaquamarine.so:x11-toolkits/aquamarine \ libhyprcursor.so:x11/hyprcursor \ libinput.so:x11/libinput \ libxkbcommon.so:x11/libxkbcommon USES= cmake compiler:c++11-lib gl gnome pkgconfig xorg USE_GITHUB= yes USE_GL= egl gbm opengl USE_GNOME= cairo pango USE_XORG= pixman xcursor GH_ACCOUNT= hyprwm GH_PROJECT= Hyprland GH_TUPLE= hyprwm:hyprland-protocols:v0.2-5-ge06482e:hyprland_protocols/subprojects/hyprland-protocols \ canihavesomecoffee:udis86:1.7.2-186-g5336633:udis86/subprojects/udis86 CMAKE_ON= NO_SYSTEMD LDFLAGS+= -Wl,--as-needed # GL, pango deps # Generated by "make update-hash" for commit_pins in hyprpm.toml -GH_HASH= 9a09eac79b85c846e3a865a9078a3f8ff65a9259 +GH_HASH= 0f594732b063a90d44df8c5d402d658f27471dfe # XXX Drop after FreeBSD 14.0 EOL around 2024-10-01 .if exists(/usr/lib/libc++.so) && !exists(/usr/include/c++/v1/__format/write_escaped.h) CXXFLAGS+= -fexperimental-library .endif # XXX Drop after FreeBSD 13.4 EOL around 2026-01-31 # https://cgit.freebsd.org/src/commit/?id=af93fea71038 .if !exists(/usr/include/sys/timerfd.h) LIB_DEPENDS+= libepoll-shim.so:devel/libepoll-shim .endif OPTIONS_DEFINE= X11 OPTIONS_DEFAULT=X11 X11_USE= XORG=xcb X11_LIB_DEPENDS= libxcb-errors.so:x11/xcb-util-errors \ libxcb-icccm.so:x11/xcb-util-wm X11_CMAKE_BOOL_OFF= NO_XWAYLAND post-patch: # Extract (snapshot) version from the port instead of CMakeLists.txt @${REINPLACE_CMD} -i .nogit \ -e '/^HASH/s/=.*/=${GH_HASH}/' \ -e '/^BRANCH/s/=.*/=main/' \ -e '/^MESSAGE/s/=.*/="?"/' \ -e "/^DATE/s/=.*/=\"$$(date -ur $$(${AWK} \ '/TIMESTAMP/ { print $$3 }' ${DISTINFO_FILE}))\"/" \ -e '/^DIRTY/s/=.*/=portbld/' \ -e '/^TAG/s/=.*/=${DISTVERSIONFULL}/' \ -e '/^COMMITS/s/=.*/="?"/' \ ${WRKSRC}/scripts/generateVersion.sh # Respect consolekit2 as XDG_RUNTIME_DIR fallback @${REINPLACE_CMD} 's,/run/user,/var&,' \ ${WRKSRC}/hyprctl/main.cpp \ ${WRKSRC}/src/Compositor.cpp # Respect PREFIX for wallpapers @${REINPLACE_CMD} 's,/usr/share,${DATADIR:H},' \ ${WRKSRC}/src/render/OpenGL.cpp # XXX Replace linprocfs(4) with sysctl(3) @${REINPLACE_CMD} -e 's,/proc,${LINUXBASE}&,g' \ ${WRKSRC}/src/desktop/Window.cpp \ ${WRKSRC}/src/plugins/HookSystem.cpp post-install: # Plugin API installs all headers (no private vs. public) @(cd ${STAGEDIR}${PREFIX} && ${FIND} include/${PORTNAME} ! -type d) >>${TMPPLIST} update-hash: # https://docs.github.com/en/rest/commits/commits#get-a-commit # Pretend to be curl(1) for pretty-printed JSON to help parse with sed(1) @${REINPLACE_CMD} -i '' -e "/^GH_HASH=/s/=.*/= $$(\ ${SETENV} HTTP_USER_AGENT=curl ${FETCH_CMD} -qo- \ https://api.github.com/repos/${GH_ACCOUNT}/${GH_PROJECT}/commits/${GH_TAGNAME} | \ ${SED} -n '/sha/ { s/.*\"\([0-9a-f]\{40\}\).*/\1/p; q; }' \ )/" \ ${.CURDIR}/Makefile .include # XXX Work around !target(makesum) makesum: update-hash diff --git a/x11-wm/hyprland/distinfo b/x11-wm/hyprland/distinfo index 03e903516a1b..7c9f78600b93 100644 --- a/x11-wm/hyprland/distinfo +++ b/x11-wm/hyprland/distinfo @@ -1,15 +1,7 @@ -TIMESTAMP = 1723058230 -SHA256 (hyprwm-Hyprland-v0.42.0_GH0.tar.gz) = 70f67725c7a1745d0287a954790f323e75519a1a188a3bf4b21fd968be3f5e4a -SIZE (hyprwm-Hyprland-v0.42.0_GH0.tar.gz) = 48049320 +TIMESTAMP = 1725814101 +SHA256 (hyprwm-Hyprland-v0.43.0_GH0.tar.gz) = af9e4a3da2ea3d164a226d14a14c477ff47ea1e384d7fe20733f9dd64543943c +SIZE (hyprwm-Hyprland-v0.43.0_GH0.tar.gz) = 48216815 SHA256 (hyprwm-hyprland-protocols-v0.2-5-ge06482e_GH0.tar.gz) = 05055f71e1f08496320bab54daa190f2fafec1a0e019af244edf1d37cdbf9b8a SIZE (hyprwm-hyprland-protocols-v0.2-5-ge06482e_GH0.tar.gz) = 7424 SHA256 (canihavesomecoffee-udis86-1.7.2-186-g5336633_GH0.tar.gz) = 69aff959179ff6247b375b92e797221dbd8e078eabbf1366280b0532617e7fb8 SIZE (canihavesomecoffee-udis86-1.7.2-186-g5336633_GH0.tar.gz) = 116938 -SHA256 (4fdc0d55e4b4.patch) = 1f3e4cf9c33a37683127feca287318a5532eff95fdaa1a5b87aad8aaca1aa220 -SIZE (4fdc0d55e4b4.patch) = 970 -SHA256 (118d4e1001d5.patch) = 6dd03c7d36d1c06d9254ba0f8adacb299bff670a11647be81d05a77fa2be2503 -SIZE (118d4e1001d5.patch) = 768 -SHA256 (ff3f41c9a5d1.patch) = 942e5271c07c853ced50584179ffc89ee7a1e0269fed0c661e371be34b5dac58 -SIZE (ff3f41c9a5d1.patch) = 727 -SHA256 (89fa6a6a66e6.patch) = 2e3bc9a15a4de383976c41d3a0c80e3c44dc181adedf1ec843a867eb26c0a027 -SIZE (89fa6a6a66e6.patch) = 1103 diff --git a/x11-wm/hyprland/files/patch-libc++16 b/x11-wm/hyprland/files/patch-libc++16 index 52303c71d65d..2d1e3f7602f7 100644 --- a/x11-wm/hyprland/files/patch-libc++16 +++ b/x11-wm/hyprland/files/patch-libc++16 @@ -1,35 +1,35 @@ Drop after FreeBSD 14.0 EOL around 2024-09-30 In file included from ../src/pch/pch.hpp:1: In file included from ../src/Compositor.hpp:7: In file included from ../src/defines.hpp:2: ../src/debug/Log.hpp:58:35: error: call to consteval function 'std::basic_format_string>> &>::basic_format_string' is not a constant expression logMsg += std::format("[{}] ", hms); ^ /usr/include/c++/v1/__format/format_functions.h:341:46: note: initializer of '__types_' is not a constant expression _Context{__types_.data(), __handles_.data(), sizeof...(_Args)}); ^ ../src/debug/Log.hpp:58:35: note: in call to 'basic_format_string("[{}] ")' logMsg += std::format("[{}] ", hms); ^ /usr/include/c++/v1/__format/format_functions.h:353:63: note: declared here static constexpr array<__format::__arg_t, sizeof...(_Args)> __types_{ ^ ---- src/debug/Log.hpp.orig 2024-06-05 16:30:46.000000000 +0000 +--- src/debug/Log.hpp.orig 2024-08-30 15:37:52 UTC +++ src/debug/Log.hpp -@@ -51,11 +51,12 @@ namespace Debug { - #ifndef _LIBCPP_VERSION - const auto zt = std::chrono::zoned_time{std::chrono::current_zone(), std::chrono::system_clock::now()}; - const auto hms = std::chrono::hh_mm_ss{zt.get_local_time() - std::chrono::floor(zt.get_local_time())}; +@@ -58,11 +58,12 @@ namespace Debug { + static auto current_zone = std::chrono::current_zone(); + const auto zt = std::chrono::zoned_time{current_zone, std::chrono::system_clock::now()}; + const auto hms = std::chrono::hh_mm_ss{zt.get_local_time() - std::chrono::floor(zt.get_local_time())}; + logMsg += std::format("[{}] ", hms); #else // TODO: current clang 17 does not support `zoned_time`, remove this once clang 19 is ready - const auto hms = std::chrono::hh_mm_ss{std::chrono::system_clock::now() - std::chrono::floor(std::chrono::system_clock::now())}; + auto c = std::chrono::hh_mm_ss{std::chrono::system_clock::now() - std::chrono::floor(std::chrono::system_clock::now())}; + logMsg += std::format("{:%H}:{:%M}:{:%S}", c.hours(), c.minutes(), c.subseconds()); #endif - logMsg += std::format("[{}] ", hms); } // no need for try {} catch {} because std::format_string ensures that vformat never throw std::format_error diff --git a/x11-wm/hyprland/files/patch-libc++17 b/x11-wm/hyprland/files/patch-libc++17 new file mode 100644 index 000000000000..f40126f4eebf --- /dev/null +++ b/x11-wm/hyprland/files/patch-libc++17 @@ -0,0 +1,19 @@ +Drop after FreeBSD 13.3 EOL around 2025-07-01 + +../src/debug/Log.cpp:13:26: error: no member named 'native_handle' in 'std::ofstream' + 13 | auto handle = logOfs.native_handle(); + | ~~~~~~ ^ + +--- src/debug/Log.cpp.orig 2024-08-18 21:21:59 UTC ++++ src/debug/Log.cpp +@@ -10,8 +10,10 @@ void Debug::init(const std::string& IS) { + void Debug::init(const std::string& IS) { + logFile = IS + (ISDEBUG ? "/hyprlandd.log" : "/hyprland.log"); + logOfs.open(logFile, std::ios::out | std::ios::app); ++#if !defined(_LIBCPP_VERSION) || _LIBCPP_VERSION >= 180100 + auto handle = logOfs.native_handle(); + fcntl(handle, F_SETFD, FD_CLOEXEC); ++#endif + } + + void Debug::close() { diff --git a/x11-wm/hyprland/pkg-plist b/x11-wm/hyprland/pkg-plist index 656c69cb7ef6..418529e3c0eb 100644 --- a/x11-wm/hyprland/pkg-plist +++ b/x11-wm/hyprland/pkg-plist @@ -1,19 +1,21 @@ bin/Hyprland bin/hyprctl bin/hyprland bin/hyprpm share/bash-completion/completions/hyprctl share/bash-completion/completions/hyprpm share/fish/vendor_completions.d/hyprctl.fish share/fish/vendor_completions.d/hyprpm.fish share/hypr/hyprland.conf +share/hypr/lockdead.png +share/hypr/lockdead2.png share/hypr/wall0.png share/hypr/wall1.png share/hypr/wall2.png share/man/man1/Hyprland.1.gz share/man/man1/hyprctl.1.gz share/pkgconfig/hyprland.pc share/wayland-sessions/hyprland.desktop share/xdg-desktop-portal/hyprland-portals.conf share/zsh/site-functions/_hyprctl share/zsh/site-functions/_hyprpm