git: 47630de0352f - main - x11/wayst: new port: Simple terminal emulator for Wayland and X11

From: Hiroki Tagato <tagattie_at_FreeBSD.org>
Date: Tue, 08 Jul 2025 07:49:19 UTC
The branch main has been updated by tagattie:

URL: https://cgit.FreeBSD.org/ports/commit/?id=47630de0352f5cfede00cf783efd13879a5e65ce

commit 47630de0352f5cfede00cf783efd13879a5e65ce
Author:     seafork <seafork@disroot.org>
AuthorDate: 2025-07-08 05:05:11 +0000
Commit:     Hiroki Tagato <tagattie@FreeBSD.org>
CommitDate: 2025-07-08 07:48:53 +0000

    x11/wayst: new port: Simple terminal emulator for Wayland and X11
    
    Simple terminal emulator for Wayland and X11 with OpenGL rendering and
    minimal dependencies.
    
    Features:
    - Unicode support
    - Text reflow
    - 24-bit colors
    - Dynamic colors
    - All text properties (squiggly underline, blinking, overline etc.)
    - Resizable font
    - Subpixel antialiasing
    - Mouse reporting
    - Scrollback
    - Mouse text selection
    - Clipboard
    - Configurable keybindings
    - Clickable links, OSC 8 links
    - Command history and marks
    - Terminal image protocol and sixel graphics (experimental)
    
    WWW: https://github.com/91861/wayst
    
    PR:             287986
    Reported by:    seafork <seafork@disroot.org> (new maintainer)
---
 x11/Makefile                   |  1 +
 x11/wayst/Makefile             | 44 ++++++++++++++++++++++++++++++++++++++++++
 x11/wayst/distinfo             |  3 +++
 x11/wayst/files/patch-Makefile | 32 ++++++++++++++++++++++++++++++
 x11/wayst/pkg-descr            | 19 ++++++++++++++++++
 5 files changed, 99 insertions(+)

diff --git a/x11/Makefile b/x11/Makefile
index 909e86fe9fbd..b80c571c7874 100644
--- a/x11/Makefile
+++ b/x11/Makefile
@@ -461,6 +461,7 @@
     SUBDIR += wayidle
     SUBDIR += wayland-logout
     SUBDIR += waylock
+    SUBDIR += wayst
     SUBDIR += wayout
     SUBDIR += wbar
     SUBDIR += wcm
diff --git a/x11/wayst/Makefile b/x11/wayst/Makefile
new file mode 100644
index 000000000000..fd6f59b42c75
--- /dev/null
+++ b/x11/wayst/Makefile
@@ -0,0 +1,44 @@
+PORTNAME=	wayst
+DISTVERSION=	g20250601
+CATEGORIES=	x11 wayland
+
+MAINTAINER=	seafork@disroot.org
+COMMENT=	Simple terminal emulator for Wayland and X11
+WWW=		https://github.com/91861/wayst
+
+LICENSE=	MIT
+LICENSE_FILE=	${WRKSRC}/LICENSE
+
+LIB_DEPENDS=	libfontconfig.so:x11-fonts/fontconfig \
+		libfreetype.so:print/freetype2 \
+		libutf8proc.so:textproc/utf8proc
+
+USES=		gl gmake pkgconfig
+
+USE_GITHUB=	yes
+GH_ACCOUNT=	91861
+GH_TAGNAME=	f5a6c22
+
+USE_GL=		egl gl
+
+PLIST_FILES=	bin/wayst
+
+OPTIONS_DEFAULT=	WAYLAND X11
+OPTIONS_MULTI=		BACKEND
+OPTIONS_MULTI_BACKEND=	WAYLAND X11
+
+WAYLAND_DESC=	Use Wayland as the windowing protocol
+X11_DESC=	Use X11 as the windowing protocol
+
+WAYLAND_LIB_DEPENDS=	libwayland-client.so:graphics/wayland \
+			libxkbcommon.so:x11/libxkbcommon
+WAYLAND_MAKE_ARGS=	window_protocol+="wayland"
+
+X11_USES=	xorg
+X11_USE=	XORG=x11,xrandr,xrender
+X11_MAKE_ARGS=	window_protocol+="x11"
+
+post-install:
+	@${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/wayst
+
+.include <bsd.port.mk>
diff --git a/x11/wayst/distinfo b/x11/wayst/distinfo
new file mode 100644
index 000000000000..ffce1159779b
--- /dev/null
+++ b/x11/wayst/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1751717366
+SHA256 (91861-wayst-g20250601-f5a6c22_GH0.tar.gz) = b6aab52d875b814b6b629daa8653a860ac382bc0a415f0d4fa502f3927f2b370
+SIZE (91861-wayst-g20250601-f5a6c22_GH0.tar.gz) = 623207
diff --git a/x11/wayst/files/patch-Makefile b/x11/wayst/files/patch-Makefile
new file mode 100644
index 000000000000..8dcdc7a9ce79
--- /dev/null
+++ b/x11/wayst/files/patch-Makefile
@@ -0,0 +1,32 @@
+--- Makefile.orig	2025-06-01 11:32:46 UTC
++++ Makefile
+@@ -1,5 +1,5 @@ EXEC = wayst
+ EXEC = wayst
+-INSTALL_DIR = /usr/local/bin
++PREFIX ?= /usr/local/bin
+ 
+ ARGS =
+ 
+@@ -37,8 +37,7 @@ else
+ 	CFLAGS = -std=c18 -MD -fshort-enums
+ 	LDFLAGS =
+ else
+-	CFLAGS = -std=c18 -MD -O2 -mtune=generic -ffast-math -fshort-enums -flto=auto
+-	LDFLAGS = -O2 -flto=auto
++	CFLAGS += -std=c18 -MD
+ endif
+ 
+ ifeq ($(libutf8proc),off)
+@@ -102,10 +101,10 @@ install:
+ 	$(RM) -f $(EXEC) $(OBJ) $(OBJ:.o=.d)
+ 
+ install:
+-	cp $(EXEC) $(INSTALL_DIR)/
++	cp $(EXEC) $(DESTDIR)$(PREFIX)/bin/$(EXEC)
+ 
+ uninstall:
+-	$(RM) $(INSTALL_DIR)/$(EXEC)
++	$(RM) $(DESTDIR)$(PREFIX)/$(EXEC)
+ 
+ -include $(OBJ:.o=.d)
+ 
diff --git a/x11/wayst/pkg-descr b/x11/wayst/pkg-descr
new file mode 100644
index 000000000000..f44456fe72d4
--- /dev/null
+++ b/x11/wayst/pkg-descr
@@ -0,0 +1,19 @@
+Simple terminal emulator for Wayland and X11 with OpenGL rendering and
+minimal dependencies.
+
+# Features
+- Unicode support
+- Text reflow
+- 24-bit colors
+- Dynamic colors
+- All text properties (squiggly underline, blinking, overline etc.)
+- Resizable font
+- Subpixel antialiasing
+- Mouse reporting
+- Scrollback
+- Mouse text selection
+- Clipboard
+- Configurable keybindings
+- Clickable links, OSC 8 links
+- Command history and marks
+- Terminal image protocol and sixel graphics (experimental)