From: Stuart Henderson Subject: textproc/par: move i18n patch to a flavour To: Gregor Best Cc: ports Date: Sun, 8 Mar 2026 16:06:26 +0000 While testing par for some changes to pledge(), I saw unrelated crashes in some cases (for example "man ls | par") which I tracked down to the i18n patch. I'm wondering if it might be a good idea to move that away to a flavour. Any thoughts? Index: Makefile =================================================================== RCS file: /cvs/ports/textproc/Makefile,v diff -u -p -r1.857 Makefile --- Makefile 25 Feb 2026 12:04:28 -0000 1.857 +++ Makefile 8 Mar 2026 15:58:21 -0000 @@ -384,6 +384,7 @@ SUBDIR += palm-bookmarks SUBDIR += pandoc SUBDIR += par + SUBDIR += par,i18n SUBDIR += pastel SUBDIR += patchutils SUBDIR += pdf4tcl Index: par/Makefile =================================================================== RCS file: /cvs/ports/textproc/par/Makefile,v diff -u -p -r1.27 Makefile --- par/Makefile 8 Mar 2026 15:44:16 -0000 1.27 +++ par/Makefile 8 Mar 2026 15:58:21 -0000 @@ -3,7 +3,7 @@ COMMENT= paragraph reflow for email VERSION= 1.52 DISTNAME= Par${VERSION:S/.//} PKGNAME= par-${VERSION} -REVISION= 3 +REVISION= 4 CATEGORIES= textproc FIX_EXTRACT_PERMISSIONS=Yes @@ -18,8 +18,14 @@ PERMIT_PACKAGE= Yes # uses pledge() WANTLIB += c +FLAVORS = i18n +FLAVOR ?= + +.if ${FLAVOR:Mi18n} PATCHFILES= par_1.52-i18n.3.diff.gz PATCH_DIST_STRIP= -p1 +.endif +SUPDISTFILES= par_1.52-i18n.3.diff.gz ALL_TARGET= DEBUG_PACKAGES= ${BUILD_PACKAGES} Index: par/patches/patch-par_c =================================================================== RCS file: /cvs/ports/textproc/par/patches/patch-par_c,v diff -u -p -r1.1 patch-par_c --- par/patches/patch-par_c 11 Mar 2022 12:04:06 -0000 1.1 +++ par/patches/patch-par_c 8 Mar 2026 15:58:21 -0000 @@ -1,14 +1,14 @@ Index: par.c --- par.c.orig +++ par.c -@@ -20,6 +20,7 @@ - #include - #include - #include -+#include +@@ -14,6 +14,7 @@ + #include "buffer.h" /* Also includes . */ + #include "reformat.h" - #undef NULL - #define NULL ((void *) 0) ++#include + #include + #include + #include @@ -730,6 +731,13 @@ int main(int argc, const char * const *argv) /* Set the current locale from the environment: */ Index: par/pkg/DESCR =================================================================== RCS file: /cvs/ports/textproc/par/pkg/DESCR,v diff -u -p -r1.3 DESCR --- par/pkg/DESCR 15 Dec 2003 21:55:31 -0000 1.3 +++ par/pkg/DESCR 8 Mar 2026 15:58:21 -0000 @@ -13,3 +13,6 @@ paragraph as follows: If there are suffixes, spaces are inserted before them so that they all end in the same column. + +Flavour: + i18n - add a patch to support multibyte character sets