sda@edc.UUCP (Stephen Ayers) (08/10/90)
In order to get every drop of performance from our Sun-3's I would like to compile X11 with GNU gcc. It looks straight forward. Just change sun.cf & site.def, right? There must be more to it.. I defined HasGcc in both those files and run into a number of problems. It tries to build shared libraries using gcc. I forced shared libraries off and was able to build the server & client entirely with gcc. When I run the new server it is unable to locate any screens on my 3/60. (operation not supported on socket, ioctl inappropriate for device) Recompiling all of X with Sun's cc works fine. BTW, I have patches 1-14 installed. gcc is 1.37.1. I'm sure I'm not the first person to try this :-) Is there any magic I have missed? Thanks in advance! -- Stephen Ayers Atex European Development Centre, A Kodak Company sda@epps.kodak.com | {sun,uunet,kodak}!atexnet!sda | ..!uknet!edc!sda +44 506 41 6778
mouse@LARRY.MCRCIM.MCGILL.EDU (08/11/90)
> [... X11 with GNU gcc ...] I forced shared libraries off and was > able to build the server & client entirely with gcc. When I run the > new server it is unable to locate any screens on my 3/60. (operation > not supported on socket, ioctl inappropriate for device) > I'm sure I'm not the first person to try this :-) Is there any magic > I have missed? (If this isn't a FAQ, it should be! This is about the third case of this problem in a row I've seen here.) Almost certainly, gcc's fixincludes script wasn't run, was run wrong, is broken, or had its generated include files damaged afterwards. In short, your gcc include files are broken, and nothing using ioctls will work right. To test this theory, create a little test file (foo.c, say) with these two lines in it #include <sys/ioctl.h> SIOCGIFCONF and run it through cc -E and gcc -E. Compare the last line of output between the two; on a working system they will be identical (in a functional sense - irrelevant differences such as whitespace can be ignored). Most likely you will find that the gcc output has an 'x' where the cc output has an 'i' instead. Until you can get your include files into a state where the above test works, you haven't much hope of making gcc-built binaries of anything using ioctls (such as the X server) work. der Mouse old: mcgill-vision!mouse new: mouse@larry.mcrcim.mcgill.edu