On Sun, Jun 07, 2026 at 06:20:09PM +0200, Matthieu Herrb wrote:
Lightly tested on amd63. I couldn't figure out how to run mlterm-fb on
the console, may be drop it ?
comments? ok ?
Follow-up : I found that the fb code only works with 540x480 pixels
displays. It was probably made for the Zaurus, back in the times...
So disable the fb mode and enable wayland instead. New diff. ok ?
Index: Makefile
===================================================================
RCS file: /local/cvs/ports/x11/mlterm/Makefile,v
diff -u -p -u -r1.69 Makefile
--- Makefile 16 Aug 2025 07:43:38 -0000 1.69
+++ Makefile 7 Jun 2026 17:03:52 -0000
@@ -1,9 +1,8 @@
COMMENT= color terminal emulator with unicode support
-DISTNAME= mlterm-3.8.3
-REVISION= 7
+DISTNAME= mlterm-3.9.4
-SHARED_LIBS+= mef 0.0 # 1.0
-SHARED_LIBS+= pobl 0.0 # 1.0
+SHARED_LIBS+= mef 1.0 # 3.1
+SHARED_LIBS+= pobl 1.0 # 2.1
CATEGORIES= x11
@@ -13,12 +12,14 @@ HOMEPAGE= https://mlterm.sourceforge.net
PERMIT_PACKAGE= Yes
WANTLIB += X11 Xcomposite Xcursor Xdamage Xext Xfixes Xft Xi
-WANTLIB += Xinerama Xrandr Xrender atk-1.0 c cairo expat ffi
-WANTLIB += fontconfig freetype fribidi gdk_pixbuf-2.0 gdk-x11-2.0
+WANTLIB += Xinerama Xrandr Xrender XRes atk-1.0 atk-bridge-2.0
+WANTLIB += atspi c cairo cairo-gobject dbus-1 epoll-shim epoxy expat ffi
+WANTLIB += fontconfig freetype fribidi gdk_pixbuf-2.0 gdk-3 gtk-3
WANTLIB += gio-2.0 glib-2.0 gmodule-2.0 gobject-2.0 graphite2
-WANTLIB += gtk-x11-2.0 harfbuzz iconv intl m pango-1.0
+WANTLIB += harfbuzz iconv intl m pango-1.0
WANTLIB += pangocairo-1.0 pangoft2-1.0 pcre2-8 pixman-1 png pthread
-WANTLIB += util xcb xcb-render xcb-shm z Xau Xdmcp jpeg
+WANTLIB += util wayland-client wayland-cursor wayland-egl xcb
+WANTLIB += xcb-render xcb-shm xkbcommon z Xau Xdmcp jpeg
WANTLIB += ${COMPILER_LIBCXX}
SITES= ${SITE_SOURCEFORGE:=mlterm/}
@@ -27,14 +28,18 @@ BUILD_DEPENDS= devel/gettext,-tools
LIB_DEPENDS= devel/fribidi \
devel/gettext,-runtime \
- x11/gtk+2
+ devel/pango \
+ graphics/gdk-pixbuf2 \
+ x11/dbus \
+ x11/gnome/at-spi2-core \
+ x11/gtk+3
FAKE_FLAGS= INSTALL_DATA="${INSTALL_DATA}" \
INSTALL_SCRIPT="${INSTALL_SCRIPT}" \
sysconfdir="${PREFIX}/share/examples"
-CONFIGURE_STYLE=autoconf
-AUTOCONF_VERSION=2.65
+CONFIGURE_STYLE=autoconf no-autoheader
+AUTOCONF_VERSION=2.69
CONFIGURE_ARGS= --disable-canna \
--disable-dl-ctl \
--disable-fcitx \
@@ -46,11 +51,13 @@ CONFIGURE_ARGS= --disable-canna \
--disable-ssh2 \
--disable-uim \
--disable-wnn \
- --with-gtk=2.0 \
- --with-gui=xlib,fb \
+ --with-gtk=3.0 \
+ --with-gui=wayland,xlib \
--with-imagelib=gdk-pixbuf2 \
--with-tools=mlclient,mlconfig,mlcc,mlterm-menu,mlimgloader,mlfc
-CONFIGURE_ENV= CPPFLAGS="-I${X11BASE}/include/freetype2"
+CONFIGURE_ENV= CPPFLAGS="-I${X11BASE}/include/freetype2
-I${LOCALBASE}/include" \
+ LDFLAGS="-L${LOCALBASE}/lib" \
+ INSTALL_OPT="-m 4755 -o root"
MAKE_ENV= LIBmef_VERSION=${LIBmef_VERSION} \
LIBpobl_VERSION=${LIBpobl_VERSION}
Index: distinfo
===================================================================
RCS file: /local/cvs/ports/x11/mlterm/distinfo,v
diff -u -p -u -r1.23 distinfo
--- distinfo 24 Sep 2017 07:30:21 -0000 1.23
+++ distinfo 7 Jun 2026 17:03:52 -0000
@@ -1,2 +1,2 @@
-SHA256 (mlterm-3.8.3.tar.gz) = zUvdsQvXhmJV3fRRkq3UhTwujEmzbfbpqdLydK8Y+e4=
-SIZE (mlterm-3.8.3.tar.gz) = 3850354
+SHA256 (mlterm-3.9.4.tar.gz) = Fx3kxPNEO8EhHMUd9cqg4IL/zdM6s84mG8Ckz+hdm14=
+SIZE (mlterm-3.9.4.tar.gz) = 4227568
Index: patches/patch-baselib_src_Makefile_in
===================================================================
RCS file: /local/cvs/ports/x11/mlterm/patches/patch-baselib_src_Makefile_in,v
diff -u -p -u -r1.2 patch-baselib_src_Makefile_in
--- patches/patch-baselib_src_Makefile_in 11 Mar 2022 20:16:46 -0000
1.2
+++ patches/patch-baselib_src_Makefile_in 7 Jun 2026 17:03:52 -0000
@@ -5,8 +5,8 @@ Index: baselib/src/Makefile.in
LIBNAME=libpobl
LIBNAME_DEB=libpobl_deb
--MAJOR = 1
--MINOR = 0
+-MAJOR = 2
+-MINOR = 1
+MAJOR = ${LIBpobl_VERSION:R}
+MINOR = ${LIBpobl_VERSION:E}
Index: patches/patch-configure_in
===================================================================
RCS file: /local/cvs/ports/x11/mlterm/patches/patch-configure_in,v
diff -u -p -u -r1.18 patch-configure_in
--- patches/patch-configure_in 11 Mar 2022 20:16:46 -0000 1.18
+++ patches/patch-configure_in 7 Jun 2026 17:03:52 -0000
@@ -1,47 +1,11 @@
-setuid root/setgid utmp are handled by PLIST
-
Do not enable VTE support if libvte is around
Index: configure.in
--- configure.in.orig
+++ configure.in
-@@ -652,15 +652,6 @@ else
- OT_LAYOUT_OBJ=hb.o
- fi
- fi
--
-- if test "$have_hb" != "yes"; then
-- AC_CHECK_PROG(libotf_config,libotf-config,yes)
-- if test "$libotf_config" = "yes" ; then
-- OT_LAYOUT_CFLAGS="`libotf-config --cflags`
-DUSE_OT_LAYOUT"
-- OT_LAYOUT_LIBS="`libotf-config --libs`"
-- OT_LAYOUT_OBJ=otf.o
-- fi
-- fi
- fi
-
- if test "$have_hb" = "yes" ; then
-@@ -807,44 +798,14 @@ AC_ARG_ENABLE(pty_helper,
- pty_helper=$enable_pty_helper)
- if test "$utmp" = "yes" -a "$pty_helper" != "yes" ; then
- UTMP_CFLAGS="-DUSE_UTMP"
-- has_utmp=`grep utmp /etc/group 2>/dev/null`
-- if test "$has_utmp" ; then
-- INSTALL_OPT="-m 2755 -g utmp"
-- else
-- INSTALL_OPT="-m 4755 -o root"
-- fi
--else
-- INSTALL_OPT="-m 755"
- fi
-
--if test "$gui" = "fb" ; then
-- INSTALL_OPT="-m 4755 -o root"
--fi
-+INSTALL_OPT="-m 0555 -s"
-
- AC_SUBST(UTMP_CFLAGS)
- AC_SUBST(INSTALL_OPT)
+@@ -1075,27 +1075,7 @@ AC_SUBST(MOSH_OCB_OBJ)
+ AC_SUBST(PROTOBUF_CFLAGS)
+ AC_SUBST(PROTOBUF_LIBS)
-if test "${have_gtk}" = "yes" ; then
- if test "${gtk_version}" = "3.0" ; then
@@ -66,5 +30,5 @@ Index: configure.in
-fi
+have_vte=no
- tools="mlclient,mlconfig,mlcc,mlterm-menu,mlimgloader,registobmp,mlfc"
- AC_ARG_WITH(tools,
+ if test "$image" = "yes"; then
+ tools="mlclient,mlconfig,mlcc,mlterm-menu,mlimgloader,registobmp,mlfc"
Index: patches/patch-encodefilter_src_Makefile_in
===================================================================
RCS file:
/local/cvs/ports/x11/mlterm/patches/patch-encodefilter_src_Makefile_in,v
diff -u -p -u -r1.2 patch-encodefilter_src_Makefile_in
--- patches/patch-encodefilter_src_Makefile_in 11 Mar 2022 20:16:46 -0000
1.2
+++ patches/patch-encodefilter_src_Makefile_in 7 Jun 2026 17:03:52 -0000
@@ -5,8 +5,8 @@ Index: encodefilter/src/Makefile.in
LIBNAME = libmef
LIBNAME_DEB = libmef_deb
--MAJOR = 1
--MINOR = 0
+-MAJOR = 3
+-MINOR = 1
+MAJOR = ${LIBmef_VERSION:R}
+MINOR = ${LIBmef_VERSION:E}
Index: patches/patch-uitoolkit_fb_ui_font_c
===================================================================
RCS file: patches/patch-uitoolkit_fb_ui_font_c
diff -N patches/patch-uitoolkit_fb_ui_font_c
--- patches/patch-uitoolkit_fb_ui_font_c 7 Feb 2023 21:32:29 -0000
1.3
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,21 +0,0 @@
-Index: uitoolkit/fb/ui_font.c
---- uitoolkit/fb/ui_font.c.orig
-+++ uitoolkit/fb/ui_font.c
-@@ -708,7 +708,7 @@ face_found:
- goto error;
- }
-
-- face->generic.data = ((int)face->generic.data) + 1; /* ref_count */
-+ face->generic.data = (void *)(((int)face->generic.data) + 1); /* ref_count
*/
-
- xfont->width_full =
- (face->max_advance_width * face->size->metrics.x_ppem +
face->units_per_EM - 1) /
-@@ -810,7 +810,7 @@ static void unload_ft(XFontStruct *xfont) {
- free(xfont->file);
-
- face = xfont->face;
-- face->generic.data = ((int)face->generic.data) - 1;
-+ face->generic.data = (void *)((int)face->generic.data - 1);
- if (!face->generic.data) {
- FT_Done_Face(xfont->face);
- }
Index: patches/patch-uitoolkit_fb_ui_window_c
===================================================================
RCS file: patches/patch-uitoolkit_fb_ui_window_c
diff -N patches/patch-uitoolkit_fb_ui_window_c
--- patches/patch-uitoolkit_fb_ui_window_c 7 Feb 2023 21:32:29 -0000
1.1
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,14 +0,0 @@
-Index: uitoolkit/fb/ui_window.c
---- uitoolkit/fb/ui_window.c.orig
-+++ uitoolkit/fb/ui_window.c
-@@ -23,8 +23,8 @@
- static ui_color_t black = {TP_COLOR, 0, 0, 0, 0};
- #endif
-
--#define ParentRelative (1L)
--#define DummyPixmap (2L)
-+#define ParentRelative ((Pixmap)1L)
-+#define DummyPixmap ((Pixmap)2L)
-
- /* XXX Check if win is input method window or not. */
- #define IS_IM_WINDOW(win) ((win)->disp->num_of_roots >= 2 && (win) ==
(win)->disp->roots[1])
Index: patches/patch-uitoolkit_libtype_ui_window_cairo_c
===================================================================
RCS file: patches/patch-uitoolkit_libtype_ui_window_cairo_c
diff -N patches/patch-uitoolkit_libtype_ui_window_cairo_c
--- patches/patch-uitoolkit_libtype_ui_window_cairo_c 7 Feb 2023 21:32:29
-0000 1.1
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,34 +0,0 @@
-Index: uitoolkit/libtype/ui_window_cairo.c
---- uitoolkit/libtype/ui_window_cairo.c.orig
-+++ uitoolkit/libtype/ui_window_cairo.c
-@@ -54,12 +54,12 @@ static int show_text(cairo_t *cr, cairo_scaled_font_t
- #endif
-
- #if CAIRO_VERSION_ENCODE(1, 4, 0) <= CAIRO_VERSION
-- if (cairo_get_user_data(cr, 1) != xfont)
-+ if (cairo_get_user_data(cr, (cairo_user_data_key_t *)1) != xfont)
- #endif
- {
- cairo_set_scaled_font(cr, xfont);
- #if CAIRO_VERSION_ENCODE(1, 4, 0) <= CAIRO_VERSION
-- cairo_set_user_data(cr, 1, xfont, NULL);
-+ cairo_set_user_data(cr, (cairo_user_data_key_t *)1, xfont, NULL);
- #endif
- }
-
-@@ -69,13 +69,13 @@ static int show_text(cairo_t *cr, cairo_scaled_font_t
- * default one
- * (black == 0).
- */
-- if ((u_long)cairo_get_user_data(cr, 2) != fg_color->pixel)
-+ if ((u_long)cairo_get_user_data(cr, (cairo_user_data_key_t *)2) !=
fg_color->pixel)
- #endif
- {
- cairo_set_source_rgba(cr, (double)fg_color->red / 255.0,
(double)fg_color->green / 255.0,
- (double)fg_color->blue / 255.0,
(double)fg_color->alpha / 255.0);
- #if CAIRO_VERSION_ENCODE(1, 4, 0) <= CAIRO_VERSION
-- cairo_set_user_data(cr, 2, fg_color->pixel, NULL);
-+ cairo_set_user_data(cr, (cairo_user_data_key_t *)2, (void
*)fg_color->pixel, NULL);
- #endif
- }
-
Index: patches/patch-uitoolkit_ui_screen_manager_c
===================================================================
RCS file: patches/patch-uitoolkit_ui_screen_manager_c
diff -N patches/patch-uitoolkit_ui_screen_manager_c
--- patches/patch-uitoolkit_ui_screen_manager_c 7 Feb 2023 21:32:29 -0000
1.1
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,12 +0,0 @@
-Index: uitoolkit/ui_screen_manager.c
---- uitoolkit/ui_screen_manager.c.orig
-+++ uitoolkit/ui_screen_manager.c
-@@ -593,7 +593,7 @@ static ui_screen_t *open_screen_intern(char *disp_name
- }
-
- if (!ui_display_show_root(disp, root, main_config.x, main_config.y,
main_config.geom_hint,
-- main_config.app_name,
main_config.parent_window)) {
-+ main_config.app_name,
(Window)main_config.parent_window)) {
- #ifdef DEBUG
- bl_warn_printf(BL_DEBUG_TAG " ui_display_show_root() failed.\n");
- #endif
Index: patches/patch-uitoolkit_wayland_ui_display_c
===================================================================
RCS file: patches/patch-uitoolkit_wayland_ui_display_c
diff -N patches/patch-uitoolkit_wayland_ui_display_c
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-uitoolkit_wayland_ui_display_c 7 Jun 2026 17:03:52
-0000
@@ -0,0 +1,14 @@
+OpenBSD doesn't have posix_fallocate
+
+Index: uitoolkit/wayland/ui_display.c
+--- uitoolkit/wayland/ui_display.c.orig
++++ uitoolkit/wayland/ui_display.c
+@@ -94,7 +94,7 @@ static int create_anonymous_file(off_t size) {
+ return -1;
+ }
+
+- if (posix_fallocate(fd, 0, size) != 0) {
++ if (ftruncate(fd, size) != 0) {
+ close(fd);
+ return -1;
+ }
Index: pkg/PLIST
===================================================================
RCS file: /local/cvs/ports/x11/mlterm/pkg/PLIST,v
diff -u -p -u -r1.17 PLIST
--- pkg/PLIST 16 Aug 2025 07:43:38 -0000 1.17
+++ pkg/PLIST 7 Jun 2026 17:03:52 -0000
@@ -7,9 +7,7 @@
@bin bin/mlterm
@mode
@group
-@mode 4555
-@bin bin/mlterm-fb
-@mode
+@bin bin/mlterm-wl
@comment lib/libmef.a
@comment lib/libmef.la
@lib lib/libmef.so.${LIBmef_VERSION}
@@ -35,13 +33,17 @@ lib/mlterm/
@so lib/mlterm/libathena.so
@comment lib/mlterm/libim-kbd-fb.a
@comment lib/mlterm/libim-kbd-fb.la
-@so lib/mlterm/libim-kbd-fb.so
+@static-lib lib/mlterm/libim-kbd-wl.a
+lib/mlterm/libim-kbd-wl.la
+@so lib/mlterm/libim-kbd-wl.so
@comment lib/mlterm/libim-kbd.a
@comment lib/mlterm/libim-kbd.la
@so lib/mlterm/libim-kbd.so
@comment lib/mlterm/libim-skk-fb.a
@comment lib/mlterm/libim-skk-fb.la
-@so lib/mlterm/libim-skk-fb.so
+@static-lib lib/mlterm/libim-skk-wl.a
+lib/mlterm/libim-skk-wl.la
+@so lib/mlterm/libim-skk-wl.so
@comment lib/mlterm/libim-skk.a
@comment lib/mlterm/libim-skk.la
@so lib/mlterm/libim-skk.so
@@ -69,10 +71,14 @@ lib/mlterm/
@comment lib/mlterm/libtype_xft.a
@comment lib/mlterm/libtype_xft.la
@so lib/mlterm/libtype_xft.so
+@static-lib lib/mlterm/libzmodem.a
+lib/mlterm/libzmodem.la
+@so lib/mlterm/libzmodem.so
libexec/mlterm/
@bin libexec/mlterm/mlconfig
@bin libexec/mlterm/mlimgloader
@bin libexec/mlterm/mlterm-menu
+@man man/man1/mlcc.1
@man man/man1/mlclient.1
@man man/man1/mlterm.1
share/examples/mlterm/
@@ -109,9 +115,6 @@ share/locale/ja/LC_MESSAGES/mlconfig.mo
share/locale/vi/LC_MESSAGES/mlconfig.mo
share/locale/zh_TW/LC_MESSAGES/mlconfig.mo
share/mlterm/
-share/mlterm/kbd/
-share/mlterm/kbd/kbd.six
-share/mlterm/kbd/pressed_kbd.six
share/mlterm/scrollbars/
share/mlterm/scrollbars/sample3/
share/mlterm/scrollbars/sample3/bg_body.png