Hello,
I am trying to build cross linux -> cygwin compiler with pascal language enabled.
I am able to build complete gcc-3.3.1 with c,c++,objc,ada,f77,java and pascal-20030507 (the three patches to get gpc-20030507 working with gcc-3.3 applied) languages enabled.
The cross compiler fails under rts :
....
cd ../../gcc-3.3.1/gcc/p/rts && make -f Makefile.in srcdir=. GCC_VERSION="3.3.1" SHELL="/bin/sh" CFLAGS="-g -O2" PFLAGS="" AR="i686-pc-cygwin-ar" AR_FLAGS="rc" RANLIB="i686-pc-cygwin-ranlib" RANLIB_TEST="[ -f i686-pc-cygwin-ranlib ] || ( [ "i686-pc-linux-gnu" = "i686-pc-cygwin" ] && [ -f /usr/bin/ranlib -o -f /bin/ranlib ] )" RTSFLAGS="" DESTDIR="../.." generated-files make[2]: Entering directory `/home/dave/cygwin/gcc-3.3.1/gcc/p/rts' make[2]: Nothing to be done for `generated-files'. make[2]: Leaving directory `/home/dave/cygwin/gcc-3.3.1/gcc/p/rts' cd ../../gcc-3.3.1/gcc/p/rts && make -f Makefile.in srcdir=. GCC_VERSION="3.3.1" SHELL="/bin/sh" CFLAGS="-g -O2" PFLAGS="" AR="i686-pc-cygwin-ar" AR_FLAGS="rc" RANLIB="i686-pc-cygwin-ranlib" RANLIB_TEST="[ -f i686-pc-cygwin-ranlib ] || ( [ "i686-pc-linux-gnu" = "i686-pc-cygwin" ] && [ -f /usr/bin/ranlib -o -f /bin/ranlib ] )" RTSFLAGS="" DESTDIR="../.." generated-files make[2]: Entering directory `/home/dave/cygwin/gcc-3.3.1/gcc/p/rts' make[2]: Nothing to be done for `generated-files'. make[2]: Leaving directory `/home/dave/cygwin/gcc-3.3.1/gcc/p/rts' ../../gcc-3.3.1/gcc/p/script/mkdir-p p/rts src=`cd ../../gcc-3.3.1/gcc && pwd` && \ cd ./p/rts && \ CC="`echo /home/dave/cygwin/gcc-3.3.1-build/gcc/xgcc -B/home/dave/cygwin/gcc-3.3.1-build/gcc/ -B/home/dave/xcygwin-gcc-3.3.1-bin-2.14/i686-pc-cygwin/bin/ -B/home/dave/xcygwin-gcc-3.3.1-bin-2.14/i686-pc-cygwin/lib/ -isystem /home/dave/xcygwin-gcc-3.3.1-bin-2.14/i686-pc-cygwin/include' ' | sed -e 's,(-[BI])([^/][^:]),\1../../\2,g;s,^([^/][^:]*/),../../\1,'`" PC="`echo ./xgpc -B./' ' | sed -e 's,(-[BI])([^/][^:]),\1../../\2,g;s,^([^/][^:]*/),../../\1,'`" CONFIG_SITE=nonexisting-file \ $src/p/rts/configure --silent > /dev/null --srcdir=$src/p/rts \ `if [ x@with_shared@ = xyes ]; then echo '--with-shared'; fi` cd ./p/rts && make CC="`echo /home/dave/cygwin/gcc-3.3.1-build/gcc/xgcc -B/home/dave/cygwin/gcc-3.3.1-build/gcc/ -B/home/dave/xcygwin-gcc-3.3.1-bin-2.14/i686-pc-cygwin/bin/ -B/home/dave/xcygwin-gcc-3.3.1-bin-2.14/i686-pc-cygwin/lib/ -isystem /home/dave/xcygwin-gcc-3.3.1-bin-2.14/i686-pc-cygwin/include' ' | sed -e 's,(-[BI])([^/][^:]),\1../../\2,g;s,^([^/][^:]*/),../../\1,'`" PC="`echo ./xgpc -B./' ' | sed -e 's,(-[BI])([^/][^:]),\1../../\2,g;s,^([^/][^:]*/),../../\1,'`" GCC_VERSION="3.3.1" SHELL="/bin/sh" CFLAGS="-g -O2" PFLAGS="" AR="i686-pc-cygwin-ar" AR_FLAGS="rc" RANLIB="i686-pc-cygwin-ranlib" RANLIB_TEST="[ -f i686-pc-cygwin-ranlib ] || ( [ "i686-pc-linux-gnu" = "i686-pc-cygwin" ] && [ -f /usr/bin/ranlib -o -f /bin/ranlib ] )" RTSFLAGS="" DESTDIR="../.." all make[2]: Entering directory `/home/dave/cygwin/gcc-3.3.1-build/gcc/p/rts' echo '{ rts-config.inc. Generated automatically from rts-config.h. }'
rts-config.inc
sed -e 's,/*,{,g;s,*/,},g;s,^[ \t]*#(.*),{$\1},' rts-config.h >> rts-config.inc ../.././xgpc -B../.././ -I. -W -Wall -Wpointer-arith -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations -g -O2 --unit-path=/home/dave/cygwin/gcc-3.3.1/gcc/p/rts --automake --print-needed-options "/home/dave/cygwin/gcc-3.3.1/gcc/p/rts/endian.pas" 2> "needed-options" || true if grep -v '^--' "needed-options" > /dev/null; then echo "needed-options: `cat "needed-options"`" >&2; rm -f "needed-options"; false; else true; fi /home/dave/cygwin/gcc-3.3.1-build/gcc/xgcc -B/home/dave/cygwin/gcc-3.3.1-build/gcc/ -B/home/dave/xcygwin-gcc-3.3.1-bin-2.14/i686-pc-cygwin/bin/ -B/home/dave/xcygwin-gcc-3.3.1-bin-2.14/i686-pc-cygwin/lib/ -isystem /home/dave/xcygwin-gcc-3.3.1-bin-2.14/i686-pc-cygwin/include -c -I. -W -Wall -Wpointer-arith -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations -g -O2 /home/dave/cygwin/gcc-3.3.1/gcc/p/rts/rts.c /home/dave/cygwin/gcc-3.3.1/gcc/p/rts/rts.c:633: warning: `struct stat64' declared inside parameter list /home/dave/cygwin/gcc-3.3.1/gcc/p/rts/rts.c:633: warning: its scope is only this definition or declaration, which is probably not what you want /home/dave/cygwin/gcc-3.3.1/gcc/p/rts/rts.c:636: warning: `struct stat64' declared inside parameter list /home/dave/cygwin/gcc-3.3.1/gcc/p/rts/rts.c:639: warning: `struct stat64' declared inside parameter list /home/dave/cygwin/gcc-3.3.1/gcc/p/rts/rts.c: In function `_p_UnixTimeToTime': /home/dave/cygwin/gcc-3.3.1/gcc/p/rts/rts.c:1001: error: wrong type argument to unary minus make[2]: *** [rts.o] Error 1 make[2]: Leaving directory `/home/dave/cygwin/gcc-3.3.1-build/gcc/p/rts' make[1]: *** [pascal.rts] Error 2 make[1]: Leaving directory `/home/dave/cygwin/gcc-3.3.1-build/gcc' make: *** [all-gcc] Error 2
Gcc v. 3.3.1 is used as compiler :
gcc -v
Reading specs from /usr/local/gcc-3.3.1/lib/gcc-lib/i686-pc-linux-gnu/3.3.1/specs Configured with: ../gcc-3.3.1/configure --prefix=/usr/local/gcc-3.3.1 --enable-shared --enable-threads=posix --disable-checking --enable-long-long --enable-__cxa_atexit --enable-languages=c,c++,ada,f77,objc,java,pascal --with-system-zlib Thread model: posix gcc version 3.3.1
I am using binutils-2.14, cygwin-1.3.22-1 and w32api-2.3-1.
Configure for binutils :
../binutils-2.14/configure --prefix=/home/dave/xcygwin-gcc-3.3.1-bin-2.14 --target=i686-pc-cygwin
Configure for gcc :
../gcc-3.3.1/configure --prefix=/home/dave/xcygwin-gcc-3.3.1-bin-2.14 --with-gnu-as --with-gnu-ld --with-newlib --disable-nls --enable-sljl-exceptions --enable-languages=c,c++,objc,f77,pascal --with-headers=/home/dave/xcygwin-gcc-3.3.1-bin-2.14/include --target=i686-pc-cygwin
Any suggestions ?
Thanks,
David