pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/textproc/nbsed/files



Module Name:    pkgsrc
Committed By:   js
Date:           Sun Mar 31 13:31:41 UTC 2024

Modified Files:
        pkgsrc/textproc/nbsed/files: config.h.in configure configure.ac
            process.c

Log Message:
textproc/nbsed: Check for wcwidth

This fixes the bootstrap on QNX.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 pkgsrc/textproc/nbsed/files/config.h.in
cvs rdiff -u -r1.10 -r1.11 pkgsrc/textproc/nbsed/files/configure \
    pkgsrc/textproc/nbsed/files/process.c
cvs rdiff -u -r1.11 -r1.12 pkgsrc/textproc/nbsed/files/configure.ac

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/textproc/nbsed/files/config.h.in
diff -u pkgsrc/textproc/nbsed/files/config.h.in:1.8 pkgsrc/textproc/nbsed/files/config.h.in:1.9
--- pkgsrc/textproc/nbsed/files/config.h.in:1.8 Tue Mar 12 16:45:07 2024
+++ pkgsrc/textproc/nbsed/files/config.h.in     Sun Mar 31 13:31:41 2024
@@ -100,6 +100,9 @@
 /* Define to 1 if you have the <wctype.h> header file. */
 #undef HAVE_WCTYPE_H
 
+/* Define to 1 if you have the 'wcwidth' function. */
+#undef HAVE_WCWIDTH
+
 /* Define to the address where bug reports for this package should be sent. */
 #undef PACKAGE_BUGREPORT
 

Index: pkgsrc/textproc/nbsed/files/configure
diff -u pkgsrc/textproc/nbsed/files/configure:1.10 pkgsrc/textproc/nbsed/files/configure:1.11
--- pkgsrc/textproc/nbsed/files/configure:1.10  Tue Mar 12 16:45:07 2024
+++ pkgsrc/textproc/nbsed/files/configure       Sun Mar 31 13:31:41 2024
@@ -4090,6 +4090,13 @@ then :
 
 fi
 
+ac_fn_c_check_func "$LINENO" "wcwidth" "ac_cv_func_wcwidth"
+if test "x$ac_cv_func_wcwidth" = xyes
+then :
+  printf "%s\n" "#define HAVE_WCWIDTH 1" >>confdefs.h
+
+fi
+
 
 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working REG_STARTEND" >&5
 printf %s "checking for working REG_STARTEND... " >&6; }
Index: pkgsrc/textproc/nbsed/files/process.c
diff -u pkgsrc/textproc/nbsed/files/process.c:1.10 pkgsrc/textproc/nbsed/files/process.c:1.11
--- pkgsrc/textproc/nbsed/files/process.c:1.10  Tue Mar 12 16:45:07 2024
+++ pkgsrc/textproc/nbsed/files/process.c       Sun Mar 31 13:31:41 2024
@@ -1,4 +1,4 @@
-/*     $NetBSD: process.c,v 1.10 2024/03/12 16:45:07 christos Exp $    */
+/*     $NetBSD: process.c,v 1.11 2024/03/31 13:31:41 js Exp $  */
 
 /*-
  * Copyright (c) 1992 Diomidis Spinellis.
@@ -44,7 +44,7 @@
 #if HAVE_SYS_CDEFS_H
 #include <sys/cdefs.h>
 #endif
-__RCSID("$NetBSD: process.c,v 1.10 2024/03/12 16:45:07 christos Exp $");
+__RCSID("$NetBSD: process.c,v 1.11 2024/03/31 13:31:41 js Exp $");
 #ifdef __FBSDID
 __FBSDID("$FreeBSD: head/usr.bin/sed/process.c 192732 2009-05-25 06:45:33Z brian $");
 #endif
@@ -671,7 +671,11 @@ lputs(char *s, size_t len)
                        fputc('\n', outfile);
                        col = 0;
                } else if (iswprint(wc)) {
+#ifdef HAVE_WCWIDTH
                        width = (size_t)wcwidth(wc);
+#else
+                       width = 1;
+#endif
                        if (col + width >= termwidth) {
                                fprintf(outfile, "\\\n");
                                col = 0;

Index: pkgsrc/textproc/nbsed/files/configure.ac
diff -u pkgsrc/textproc/nbsed/files/configure.ac:1.11 pkgsrc/textproc/nbsed/files/configure.ac:1.12
--- pkgsrc/textproc/nbsed/files/configure.ac:1.11       Tue Mar 12 16:45:07 2024
+++ pkgsrc/textproc/nbsed/files/configure.ac    Sun Mar 31 13:31:41 2024
@@ -1,4 +1,4 @@
-dnl $Id: configure.ac,v 1.11 2024/03/12 16:45:07 christos Exp $
+dnl $Id: configure.ac,v 1.12 2024/03/31 13:31:41 js Exp $
 dnl Process this file with autoconf to produce a configure script.
 AC_PREREQ([2.72])
 AC_INIT([sed],[20040821],[agc%NetBSD.org@localhost])
@@ -33,6 +33,7 @@ dnl Check for functions
 AC_CHECK_FUNCS(regcomp)
 AC_CHECK_FUNCS(regexec)
 AC_CHECK_FUNCS(memcpy)
+AC_CHECK_FUNCS(wcwidth)
 
 AC_MSG_CHECKING([for working REG_STARTEND])
 AC_RUN_IFELSE([AC_LANG_SOURCE([[



Home | Main Index | Thread Index | Old Index