On Fri, 21 Feb 2003, David Dawes wrote: > >> >The setjmp/longjmp fix in > >> > xc/programs/Xserver/hw/xfree86/loader/xf86sym.c > >> >and xc/programs/Xserver/hw/xfree86/xf86cfg/loadmod.c > >> >doesn't compile in > >> > RedHat 6.2 egcs-2.91.66
> >> >It works fine with > >> > Red Hat 7.3 gcc 2.96 > >> >and > >> > Red Hat 8.0 gcc (GCC) 3.2 20020903 (Red Hat Linux 8.0 3.2-7) > >> It looks like RH 6.2 and earlier (i.e. glibc before 2.2) uses a macro for > >> setjmp(): > >> extern int __sigsetjmp __P ((jmp_buf __env, int __savemask)); > >> #ifndef __FAVOR_BSD > >> /* Set ENV to the current position and return 0, not saving the signal mask. > >> This is just like `sigsetjmp (ENV, 0)'. > >> The ISO C standard says `setjmp' is a macro. */ > >> # define setjmp(env) __sigsetjmp ((env), 0) > >> #else > >> /* We are in 4.3 BSD-compatibility mode in which `setjmp' > >> saves the signal mask like `sigsetjmp (ENV, 1)'. */ > >> # define setjmp(env) __sigsetjmp ((env), 1) > >> #endif /* Favor BSD. */ > >> Harbison & Steele also refers to "the macro setjump" and "the function > >> longjmp". > >> This certainly complicates things. > >> A couple of possibilities: > >> 1. Include <setjmp.h> directly into modules that need it, ensure that the > >> necessary (platform-specific) entry points are exported, and accept that > >> modules that use it are not OS-neutral. > >> 2. Provide aliases for the actual functions uses on the platforms we support, > >> and come up with a macro for xf86setjmp() that calls the correct one in > >> the correct way, probably by first querying a function in the core > >> server for which way to use. > >Just another data point: libGLU compilation on such systems fails also. > libGLU builds OK on the RH 6.2 system I've been looking into this with. > It does do some things with setjmp (using inlined functions). How? I have been unable to get libGLU to compile on a system that #define's setjmp & friends as macros. > We don't build libGLU for libc5-based systems, but I don't have access to > one (RH 4.2, is one I think -- anyone have a CD image for RH 4.2? I don't > see one on RH's ftp site.). I am the one that removed libGLU from libc5 builds. That was a while ago now. I have a libc5 system. I haven't updated it (CVS-wise) since this change made the problem more noticeable. I will, obviously, need to soon though. Marc. +----------------------------------+-----------------------------------+ | Marc Aurele La France | work: 1-780-492-9310 | | Computing and Network Services | fax: 1-780-492-1729 | | 352 General Services Building | email: [EMAIL PROTECTED] | | University of Alberta +-----------------------------------+ | Edmonton, Alberta | | | T6G 2H1 | Standard disclaimers apply | | CANADA | | +----------------------------------+-----------------------------------+ XFree86 Core Team member. ATI driver and X server internals. _______________________________________________ Devel mailing list [EMAIL PROTECTED] http://XFree86.Org/mailman/listinfo/devel
