bug-gnu-utils
[Top][All Lists]
Advanced

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

Re: Undefined symbols in diffutils-2.8.2 on Solaris 5.5.1


From: Stepan Kasal
Subject: Re: Undefined symbols in diffutils-2.8.2 on Solaris 5.5.1
Date: Wed, 12 Jun 2002 08:34:09 +0000 (UTC)
User-agent: slrn/0.9.6.2 (Linux)

> > Vin Shelton reported on Tue, 11 Jun 2002 14:24:16 -0400:
> > 
> > gcc  -g -O2   -o diff  analyze.o context.o diff.o dir.o ed.o ifdef.o io.o 
> > normal.o side.o util.o version.o ../lib/libdiffutils.a  -lposix4 
> > Undefined                   first referenced
> >  symbol                         in file
> > wctype                              ../lib/libdiffutils.a(fnmatch.o)
> > btowc                               ../lib/libdiffutils.a(fnmatch.o)
> > iswctype                            ../lib/libdiffutils.a(fnmatch.o)

Hallo,
        I've also looked at it.  I guess we shouldn't modify fnmatch*.c
since they seem to be copied directly from GNU libc source.

Paul, which approach do you like more?

Vin, could you please tell me whether the patch works?

Regards,
        Stepan Kasal

2002-06-12  Stepan Kasal  <address@hidden>

        * config.hin (HAVE_BTOWC):
        If we don't have btowc(), don't define any of HAVE_MBxxx, so that
        it's clear for everyone that MB support is off.
        This fixes a porting bug on Solaris 2.5.1 reported by Vin Shelton.

diff -urN diffutils-2.8.2.orig/config.hin diffutils-2.8.2/config.hin
--- diffutils-2.8.2.orig/config.hin     Tue Jun 11 14:02:51 2002
+++ diffutils-2.8.2/config.hin  Wed Jun 12 09:31:08 2002
@@ -216,6 +216,20 @@
 /* Define if you have the long long type. */
 #undef HAVE_LONG_LONG
 
+/* Currently, the obsolete function btowc() is a prerequisite for
+ * handling multibyte characters.
+ * Solaris 2.5 doesn't have btowc().
+ * To prevent confusion (fnmatch should not define HANDLE_MULTIBYTE),
+ * we omit other MB functions if we don'n have btowc().
+ *
+ * FIXME:
+ *  1) btowc() shouldn't be used;
+ *  2) if it is used, there should be a wrapper around mbtowc() ready
+ *     for systems without btowc()
+ * note: Solaris 2.5 requires library -lw for wctype() and iswctype()
+ */
+#ifdef HAVE_BTOWC
+
 /* Define to 1 if you have the `mblen' function. */
 #undef HAVE_MBLEN
 
@@ -230,6 +244,8 @@
 
 /* Define to 1 if <wchar.h> declares mbstate_t. */
 #undef HAVE_MBSTATE_T
+
+#endif /* HAVE_BTOWC */
 
 /* Define to 1 if you have the `memchr' function. */
 #undef HAVE_MEMCHR





reply via email to

[Prev in Thread] Current Thread [Next in Thread]