diff --git a/x11-wm/mangowc/Makefile b/x11-wm/mangowc/Makefile index b607a0c04fe4..65fa539338f3 100644 --- a/x11-wm/mangowc/Makefile +++ b/x11-wm/mangowc/Makefile @@ -1,61 +1,63 @@ PORTNAME= mangowc -DISTVERSION= 0.12.2 +DISTVERSION= 0.12.3 PORTREVISION= 0 CATEGORIES= x11-wm MAINTAINER= nivit@FreeBSD.org COMMENT= Lightweight, high-performance Wayland compositor built on dwl WWW= https://mangowc.vercel.app LICENSE= CC0-1.0 GPLv3 MIT LICENSE_COMB= multi LICENSE_FILE_CC0-1.0= ${WRKSRC}/LICENSE.tinywl LICENSE_FILE_GPLv3= ${WRKSRC}/LICENSE.dwl LICENSE_FILE_MIT= ${WRKSRC}/LICENSE.wlroots BUILD_DEPENDS= hwdata>=0.399:misc/hwdata \ wayland-protocols>=1.24:graphics/wayland-protocols LIB_DEPENDS= libdisplay-info.so:sysutils/libdisplay-info \ libdrm.so:graphics/libdrm \ libevdev.so:devel/libevdev \ libinput.so:x11/libinput \ libjson-c.so:devel/json-c \ libliftoff.so:graphics/libliftoff \ libpcre2-8.so:devel/pcre2 \ libpixman-1.so:x11/pixman \ libscenefx-0.4.so:x11-toolkits/scenefx04 \ libseat.so:sysutils/seatd \ libudev.so:devel/libudev-devd \ libwayland-egl.so:graphics/wayland \ libwlroots-0.19.so:x11-toolkits/wlroots019 \ libxcb-icccm.so:x11/xcb-util-wm \ libxcb.so:x11/libxcb \ libxkbcommon.so:x11/libxkbcommon RUN_DEPENDS= hwdata>=0.399:misc/hwdata \ Xwayland:x11-servers/xwayland USES= meson pkgconfig USE_GITHUB= yes GH_ACCOUNT= DreamMaoMao +MESON_ARGS= -Dsysconfdir=${PREFIX}/etc + SUB_FILES= pkg-message PLIST_FILES= bin/mango \ bin/mmsg \ "@sample etc/mango/config.conf.sample" \ share/wayland-sessions/mango.desktop post-patch: # Fix C flags # https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=275328 @${REINPLACE_CMD} -e 's/_POSIX_C_SOURCE=200809L/_XOPEN_SOURCE=700/' \ ${WRKSRC}/meson.build # Install a sample copy of configuration file post-install: @${CP} ${WRKSRC}/config.conf \ ${STAGEDIR}${PREFIX}/etc/mango/config.conf.sample .include diff --git a/x11-wm/mangowc/distinfo b/x11-wm/mangowc/distinfo index b0fcae1646ab..3d9de9852898 100644 --- a/x11-wm/mangowc/distinfo +++ b/x11-wm/mangowc/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1770975720 -SHA256 (DreamMaoMao-mangowc-0.12.2_GH0.tar.gz) = b2e6d0cad2eb4a18e0098c45f5f961a81ddd8b37027bd61c25b5e24473c62d66 -SIZE (DreamMaoMao-mangowc-0.12.2_GH0.tar.gz) = 414227 +TIMESTAMP = 1771427762 +SHA256 (DreamMaoMao-mangowc-0.12.3_GH0.tar.gz) = 140b1b625e56034c1f042f850364bba7d0c630fea027459eb44fe46c37bcd0f6 +SIZE (DreamMaoMao-mangowc-0.12.3_GH0.tar.gz) = 415574 diff --git a/x11-wm/mangowc/files/patch-meson.build b/x11-wm/mangowc/files/patch-meson.build new file mode 100644 index 000000000000..69f9787894de --- /dev/null +++ b/x11-wm/mangowc/files/patch-meson.build @@ -0,0 +1,30 @@ +--- meson.build.orig 2026-02-18 05:26:24 UTC ++++ meson.build +@@ -12,12 +12,16 @@ endif + endif + endif + ++osname = build_machine.system() ++ + prefix = get_option('prefix') + sysconfdir = get_option('sysconfdir') + + # 如果 sysconfdir 以 prefix 开头,去掉 prefix +-if sysconfdir.startswith(prefix) and not is_nixos +- sysconfdir = sysconfdir.substring(prefix.length()) ++if sysconfdir.startswith(prefix) and not is_nixos and osname != 'freebsd' ++ # this fails with: Unknown method "length" in object <[OptionStringHolder] holds [OptionString] ++ # sysconfdir = sysconfdir.substring(prefix.length()) ++ sysconfdir = sysconfdir.replace(prefix, '') + # 确保 sysconfdir 是绝对路径 + if not sysconfdir.startswith('/') + sysconfdir = '/' + sysconfdir +@@ -72,7 +76,7 @@ c_args = [ + '-DWLR_USE_UNSTABLE', + '-D_POSIX_C_SOURCE=200809L', + '-DVERSION="@0@"'.format(version_with_hash), +- '-DSYSCONFDIR="@0@"'.format('/etc'), ++ '-DSYSCONFDIR="@0@"'.format(sysconfdir), + ] + + # 仅在 debug 选项启用时添加调试参数