Re: egcs, glibc

Dmitry Yaitskov (dima@interlog.com)
Fri, 10 Apr 1998 12:30:24 -0400


On Friday, Apr 10, Patpong Wetyanon (pat@ksc.net.th) spake thusly:
> On Thu, 9 Apr 1998, Khimenko Victor wrote:
>
> > 9-Apr-98 10:40 you wrote:
> > > Hi folks,
> > > This is a little off topic but I have seen quite a few messages here
> > > about egcs and glibc affecting kernel compiles, so here goes.
> > glibc coould not affect kernel compilation -- kernel does not use lib or glibc...
> > If course broken glibc (or libc) could broke compiler but this VERY rare
> > cases. new binutils, gcc (egcs, pgcc, etc.) could affect compilation (especially
> > for APM support), but most parts written in C are safe. I am using pgcc for
> > last two month (currently 1.0.2 -- I not dislike snapshots) for all compilations
> > including kernel compilations... Latest kernels 2.0.33+ & 2.1.89+ in most cases
> > could be compiled without any troubles by gcc 2.8.x, egcs 1.0.x or pgcc 1.0.x...
> I don't agree. I compiled 2.0.33+p7 with gcc 2.8.1 ,-m pentium with no problem
> but i can not run X after boot it . It has no problem with the gcc 2.7.... but
> when compile 2.1.94 it is OK. I have no problem util change to use gcc 2.8.1
> Does the egcs or pgcc has the same problems ?

It's an RTFM - see FAQ on www.xfree86.org (search for libc - it's
somewhere nearby). Just replace arch/i386/kernel/ioport.c from 2.0.33
with one from a recent 2.1.* kernel (I used one from '92 and it worked
fine).

To the original poster: I recently (about a week ago) went through the
process of upgrading my system (slackware) from 2.0.33/libc5/gcc 2.7.*
to 2.1.9*/glibc2/gcc 2.8.1 (in reverse order as a matter of fact). Not
everything went smoothly, but actually I had to resort to booting in
single-user mode only once... Eventually most of the stuff got
straightened out, and right now it all works, well, more or less. The
biggest problem was (and still is) to get, recompile and properly
install all the utilities that used libc5 so that they'd use
glibc2. Some things are available in binary glibc2 form, but lots of
things need to be compiled unless you go with a glibc2-based
distribution (e.g. redhat 5) - but I didn't. Also, many vital progs,
if you compile and install them yourself, install by default in
/usr/local/... while the system actually needs them in /.... Which was
a pain (for me) to weed out. And sometimes I got situations when a
prog was linked against *both* libc5 and glibc2 (via another library -
e.g. ncurses) - and that does *not* work. So have your boot/root disks
ready.

-- 
Cheers,
 -Dima.

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu