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: Vin Shelton
Subject: Re: Undefined symbols in diffutils-2.8.2 on Solaris 5.5.1
Date: Wed, 12 Jun 2002 08:58:18 -0400

Yes, the fix worked for me.

Thanks,
  Vin

Paul Eggert <address@hidden> writes:
>> From: Vin Shelton <address@hidden>
>> Date: 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)
>
> Thanks for the bug report.  Please try this patch.
>
> 2002-06-11  Paul Eggert  <address@hidden>
>
>       * lib/fnmatch.c, lib/fnmatch_loop.c (WIDE_CHAR_SUPPORT):
>       New macro.  Use it uniformly instead of
>       (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
>       It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
>       reported by Vin Shelton.
>
> ===================================================================
> RCS file: lib/RCS/fnmatch.c,v
> retrieving revision 1.2
> retrieving revision 1.3
> diff -pu -r1.2 -r1.3
> --- lib/fnmatch.c     2002/06/11 05:53:54     1.2
> +++ lib/fnmatch.c     2002/06/12 06:06:47     1.3
> @@ -63,9 +63,11 @@ char *alloca ();
>  # include <stdlib.h>
>  #endif
>  
> +#define WIDE_CHAR_SUPPORT (HAVE_WCTYPE_H && HAVE_WCHAR_H && HAVE_BTOWC)
> +
>  /* For platform which support the ISO C amendement 1 functionality we
>     support user defined character classes.  */
> -#if defined _LIBC || (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H)
> +#if defined _LIBC || WIDE_CHAR_SUPPORT
>  /* Solaris 2.5 has a bug: <wchar.h> must be included before <wctype.h>.  */
>  # include <wchar.h>
>  # include <wctype.h>
> @@ -133,7 +135,7 @@ extern int fnmatch (const char *pattern,
>  
>  # define STREQ(s1, s2) ((strcmp (s1, s2) == 0))
>  
> -# if defined _LIBC || (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H)
> +# if defined _LIBC || WIDE_CHAR_SUPPORT
>  /* The GNU C library provides support for user-defined character classes
>     and the functions from ISO C amendement 1.  */
>  #  ifdef CHARCLASS_NAME_MAX
> ===================================================================
> RCS file: lib/RCS/fnmatch_loop.c,v
> retrieving revision 1.2
> retrieving revision 1.3
> diff -pu -r1.2 -r1.3
> --- lib/fnmatch_loop.c        2002/06/11 06:06:32     1.2
> +++ lib/fnmatch_loop.c        2002/06/12 06:06:47     1.3
> @@ -248,7 +248,7 @@ FCT (pattern, string, string_end, no_lea
>                   /* Leave room for the null.  */
>                   CHAR str[CHAR_CLASS_MAX_LENGTH + 1];
>                   size_t c1 = 0;
> -#if defined _LIBC || (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H)
> +#if defined _LIBC || WIDE_CHAR_SUPPORT
>                   wctype_t wt;
>  #endif
>                   const CHAR *startp = p;
> @@ -278,7 +278,7 @@ FCT (pattern, string, string_end, no_lea
>                     }
>                   str[c1] = L('\0');
>  
> -#if defined _LIBC || (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H)
> +#if defined _LIBC || WIDE_CHAR_SUPPORT
>                   wt = IS_CHAR_CLASS (str);
>                   if (wt == 0)
>                     /* Invalid character class name.  */
>

-- 
In a minute there is time
For decisions and revisions which a minute will reverse.         T.S. Eliot
[URL: http://www.cs.amherst.edu/~ccm/prufrock.html]



reply via email to

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