libX11, libXfonts complain about no defines for 0_RDONLY I had to manually add an #include for fcntl.h to the individual source files causing the problems. For libXfonts: libXfont/src/fontfile/fileio.c For libX11: libX11/modules/im/ximcp/imLcIm.c I believe several other packages had problems as well. Build system: Slackware 12.2 GCC 4.2.4