Bug#165554: __ctype_b symbol no longer available?
At Sun, 20 Oct 2002 06:18:08 -0700,
Jeff Bailey wrote:
>
> On Sun, Oct 20, 2002 at 08:00:29PM +0900, Junichi Uekawa wrote:
>
> > /home/takuo/work/debian/ppxp-0.2001080415/lib/ppxp.c:473: undefined reference to `__ctype_b'
> > collect2: ld returned 1 exit status
> > make[3]: *** [ppxp-applet] Error 1
> > make[3]: Leaving directory `/tmp/buildd/ppxp-applet-0.8.1/src'
> > make[2]: *** [all-recursive] Error 1
> > make[2]: Leaving directory `/tmp/buildd/ppxp-applet-0.8.1'
>
> Can you provide a small sample program that shows how it's being used?
> Having a testcase will let me figure out whether or not the program is
> doing the right thing or not.
Build libfoo.a on libc6 2.2.5 from foo.c as follows:
% cat foo.c
#include <ctype.h>
int
foo(int c)
{
return isdigit(c);
}
% cc -o foo.o -c foo.c
% ar ruv libfoo.a foo.o
and copy libfoo.a to libc6 2.3.1 environment.
On libc6 2.3.1:
% cat bar.c
#include <stdio.h>
extern int foo(int c);
int
main(int argc, char *argv[])
{
printf("%d\n", foo(*argv[1]));
exit(0);
}
% cc -o bar bar.c libfoo.a
libfoo.a(foo.o)(.text+0xa): In function `foo':
: undefined reference to `__ctype_b'
collect2: ld returned 1 exit status
Of course, libfoo.a is rebuilt on libc6 2.3.1, there are no problem.
Thanks,
Fumitoshi UKAI
Reply to: