From f920c5c61718f945704c2843a30afba15a75736d Mon Sep 17 00:00:00 2001 From: naddy Date: Wed, 10 Jun 2026 21:52:04 +0000 Subject: [PATCH] japanese/kterm: build fixes for llvm22; from Yozo TODA --- japanese/kterm/Makefile | 2 +- japanese/kterm/patches/patch-screen_c | 38 ++++++++++++++++++++++++--- 2 files changed, 36 insertions(+), 4 deletions(-) diff --git a/japanese/kterm/Makefile b/japanese/kterm/Makefile index dc6e9689375..526cdd5d6db 100644 --- a/japanese/kterm/Makefile +++ b/japanese/kterm/Makefile @@ -3,7 +3,7 @@ COMMENT= Japanese-capable xterm VERSION= 6.2.0 DISTNAME= kterm-${VERSION} PKGNAME= ja-kterm-${VERSION} -REVISION= 9 +REVISION= 10 CATEGORIES= japanese x11 SITES= ${SITE_XCONTRIB:=applications/} diff --git a/japanese/kterm/patches/patch-screen_c b/japanese/kterm/patches/patch-screen_c index 0a349ecec65..a9289d1b8d6 100644 --- a/japanese/kterm/patches/patch-screen_c +++ b/japanese/kterm/patches/patch-screen_c @@ -1,6 +1,25 @@ ---- screen.c.orig Fri Apr 28 14:22:37 2017 -+++ screen.c Fri Apr 28 14:23:27 2017 -@@ -245,6 +245,7 @@ Reallocate(sbuf, sbufaddr, nrow, ncol, oldrow, oldcol) +Index: screen.c +--- screen.c.orig ++++ screen.c +@@ -32,6 +32,7 @@ + #include "error.h" + #include "data.h" + ++#include + #include + #include + #if defined(SVR4) || defined(hpux) +@@ -46,9 +47,6 @@ + #include + #endif + +-extern Char *calloc(), *malloc(), *realloc(); +-extern void free(); +- + ScrnBuf Allocate (nrow, ncol, addr) + /* + allocates memory for a 2-dimensional array of chars and returns a pointer +@@ -245,6 +243,7 @@ Reallocate(sbuf, sbufaddr, nrow, ncol, oldrow, oldcol) #endif /* !KTERM */ } @@ -8,3 +27,16 @@ #ifdef KTERM ScreenWrite (screen, str, flags, gset, length) #else /* !KTERM */ +@@ -912,10 +911,10 @@ ScreenResize (screen, width, height, flags) + /* swap buffer pointers back to make all this hair work */ + SwitchBufPtrs(screen); + if (screen->altbuf) +- (void) Reallocate(&screen->altbuf, (Char **)&screen->abuf_address, ++ (void) Reallocate(&screen->altbuf, (Bchr **)&screen->abuf_address, + rows, cols, screen->max_row + 1, screen->max_col + 1); + move_down_by = Reallocate(&screen->allbuf, +- (Char **)&screen->sbuf_address, ++ (Bchr **)&screen->sbuf_address, + rows + savelines, cols, + screen->max_row + 1 + savelines, + screen->max_col + 1);