[oe] xserver-xorg, PATH_MAX and limits.h
Tom Kirkpatrick
tom at settopsolutions.com
Wed Nov 1 00:24:46 UTC 2006
When trying to use an external toolchain (built with meta-
toolchain.bb) to compile xserver-xorg, I get an error about PATH_MAX
being undeclared (see below)...for some reason, the limits.h with
this define in it is not being picked up... as you can see, my cross-
toolchain include directory has been included with -I/usr/local/i586/
oe/i586-stv-linux/include. The limits.h file exists at /usr/local/
i586/oe/i586-stv-linux/include/limits.h and also at /usr/local/i586/
oe/i586-stv-linux/include/linux/limits.h. It is this second file
which has PATH_MAX defined, and this is not being included by gcc. If
I alter PsFonts.c like so
--- xorg-server-X11R7.1-1.1.0/Xprint/ps/PsFonts.c 2005-07-07
03:47:06.000000000 +0100
+++ xorg-server-X11R7.1-1.1.0-PATCHED/Xprint/ps/PsFonts.c
2006-11-01 00:12:23.000000000 +0000
@@ -89,7 +89,7 @@
#include "Ps.h"
#include <ctype.h>
-#include <limits.h>
+#include <linux/limits.h>
#include <sys/stat.h>
then it compiles OK but I'm not sure if this is actually a problem
with xserver-xorg, or if it's a problem with the toolchain, and
therefore with the *-cross-sdk/meta-toolchain stuff in general. Would
this patch be an acceptable fix, or is this likely to just break
things more?
| ccache i586-stv-linux-gcc-3.4.4 -march=c3 -mtune=c3 -
DHAVE_CONFIG_H -I. -I/home/tom/stv/oe-stv/build/tmp-stv-via-c3/work/
i586-stv-linux/xserver-xorg-X11R7.1-1.1.0-r0/xorg-server-
X11R7.1-1.1.0/Xprint/ps -I../../include -I../../include -I../../
include -I../../include -I../../include -I../../include -I../../
include -I../../include -I/home/tom/stv/oe-stv/build/tmp-stv-via-c3/
work/i586-stv-linux/xserver-xorg-X11R7.1-1.1.0-r0/xorg-server-
X11R7.1-1.1.0/Xprint -I/home/tom/stv/oe-stv/build/tmp-stv-via-c3/work/
i586-stv-linux/xserver-xorg-X11R7.1-1.1.0-r0/xorg-server-
X11R7.1-1.1.0/cfb -I/home/tom/stv/oe-stv/build/tmp-stv-via-c3/work/
i586-stv-linux/xserver-xorg-X11R7.1-1.1.0-r0/xorg-server-
X11R7.1-1.1.0/mfb -isystem/home/tom/stv/oe-stv/build/tmp-stv-via-c3/
staging/i586-stv-linux/include -I/usr/local/i586/oe/i586-stv-linux/
include -DXFree86Server -DHAVE_DIX_CONFIG_H -I/home/tom/stv/oe-stv/
build/tmp-stv-via-c3/staging/i586-stv-linux/include -
D_XP_PRINT_SERVER_ -DPSZ=8 -DXP_PSTEXT -Wall -Wpointer-arith -Wstrict-
prototypes -Wmissing-prototypes -Wmissing-declarations -Wnested-
externs -fno-strict-aliasing -D_BSD_SOURCE -DHAS_FCHOWN -
DHAS_STICKY_DIR_BIT -I/home/tom/stv/oe-stv/build/tmp-stv-via-c3/
staging/i586-stv-linux/include -I/home/tom/stv/oe-stv/build/tmp-stv-
via-c3/staging/i586-stv-linux/include/X11/Xtrans -I/home/tom/stv/oe-
stv/build/tmp-stv-via-c3/work/i586-stv-linux/xserver-xorg-
X11R7.1-1.1.0-r0/xorg-server-X11R7.1-1.1.0/include -I../../include -I/
home/tom/stv/oe-stv/build/tmp-stv-via-c3/work/i586-stv-linux/xserver-
xorg-X11R7.1-1.1.0-r0/xorg-server-X11R7.1-1.1.0/Xext -I/home/tom/stv/
oe-stv/build/tmp-stv-via-c3/work/i586-stv-linux/xserver-xorg-
X11R7.1-1.1.0-r0/xorg-server-X11R7.1-1.1.0/composite -I/home/tom/stv/
oe-stv/build/tmp-stv-via-c3/work/i586-stv-linux/xserver-xorg-
X11R7.1-1.1.0-r0/xorg-server-X11R7.1-1.1.0/damageext -I/home/tom/stv/
oe-stv/build/tmp-stv-via-c3/work/i586-stv-linux/xserver-xorg-
X11R7.1-1.1.0-r0/xorg-server-X11R7.1-1.1.0/xfixes -I/home/tom/stv/oe-
stv/build/tmp-stv-via-c3/work/i586-stv-linux/xserver-xorg-
X11R7.1-1.1.0-r0/xorg-server-X11R7.1-1.1.0/Xi -I/home/tom/stv/oe-stv/
build/tmp-stv-via-c3/work/i586-stv-linux/xserver-xorg-X11R7.1-1.1.0-
r0/xorg-server-X11R7.1-1.1.0/mi -I/home/tom/stv/oe-stv/build/tmp-stv-
via-c3/work/i586-stv-linux/xserver-xorg-X11R7.1-1.1.0-r0/xorg-server-
X11R7.1-1.1.0/miext/shadow -I/home/tom/stv/oe-stv/build/tmp-stv-via-
c3/work/i586-stv-linux/xserver-xorg-X11R7.1-1.1.0-r0/xorg-server-
X11R7.1-1.1.0/miext/damage -I/home/tom/stv/oe-stv/build/tmp-stv-via-
c3/work/i586-stv-linux/xserver-xorg-X11R7.1-1.1.0-r0/xorg-server-
X11R7.1-1.1.0/render -I/home/tom/stv/oe-stv/build/tmp-stv-via-c3/work/
i586-stv-linux/xserver-xorg-X11R7.1-1.1.0-r0/xorg-server-
X11R7.1-1.1.0/randr -I/home/tom/stv/oe-stv/build/tmp-stv-via-c3/work/
i586-stv-linux/xserver-xorg-X11R7.1-1.1.0-r0/xorg-server-
X11R7.1-1.1.0/fb -isystem/home/tom/stv/oe-stv/build/tmp-stv-via-c3/
staging/i586-stv-linux/include -I/usr/local/i586/oe/i586-stv-linux/
include -O -g -MT PsFonts.lo -MD -MP -MF .deps/PsFonts.Tpo -c
PsFonts.c -fPIC -DPIC -o .libs/PsFonts.o
| PsFonts.c: In function `getFontFilename':
| PsFonts.c:292: error: `PATH_MAX' undeclared (first use in this
function)
| PsFonts.c:292: error: (Each undeclared identifier is reported only
once
| PsFonts.c:292: error: for each function it appears in.)
| PsFonts.c:343: warning: unused variable `full_font_file_path'
| PsFonts.c:289: warning: unused variable `count'
| PsFonts.c:289: warning: unused variable `i'
| PsFonts.c:289: warning: unused variable `status'
| PsFonts.c:291: warning: unused variable `end'
| PsFonts.c:292: warning: unused variable `font_dir_fname'
| PsFonts.c:293: warning: unused variable `font_file_fname'
| PsFonts.c: In function `PsCreateFontTypeInfoRec':
| PsFonts.c:595: warning: unused variable `psname'
| make[2]: *** [PsFonts.lo] Error 1
| make[2]: Leaving directory `/home/tom/stv/oe-stv/build/tmp-stv-via-
c3/work/i586-stv-linux/xserver-xorg-X11R7.1-1.1.0-r0/xorg-server-
X11R7.1-1.1.0/Xprint/ps'
| make[1]: *** [all-recursive] Error 1
| make[1]: Leaving directory `/home/tom/stv/oe-stv/build/tmp-stv-via-
c3/work/i586-stv-linux/xserver-xorg-X11R7.1-1.1.0-r0/xorg-server-
X11R7.1-1.1.0/Xprint'
| make: *** [all-recursive] Error 1
| FATAL: oe_runmake failed
NOTE: Task failed: /home/tom/stv/oe-stv/build/tmp-stv-via-c3/work/
i586-stv-linux/xserver-xorg-X11R7.1-1.1.0-r0/temp/log.do_compile.9219
NOTE: package xserver-xorg-X11R7.1-1.1.0-r0: task do_compile: failed
More information about the Openembedded-devel
mailing list