This is the mail archive of the crossgcc@cygnus.com mailing list for the crossgcc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

NT Cross Linux compiler



Thanks for all the suggestions on how to go about creating an NT cross
compiler for Linux.  I think I have a handle on what to do based on the
information everyone gave and/or pointed me to.  I am still having some
problem, so hopefully someone can tell me what I'm doing wrong or what is
causing this problem:

I placed the cygwin distribution (20.1) on my Linux machine and untarred it,
creating a src directory.  Using Mumit Khan's instructions, I then created a
CROSS directory in the same directory as src, cd'd into it and ran:

../src/configure --prefix=/usr/local/cygb20 --target=i686-cygwin32 -v
The configure script seemed to run ok, except for printing out this initial
warning:

*** This configuration is not supported in the following subdirectories:
     target-libgloss gdb tcl tk expect itcl tix
    (Any other directories should still work fine.)

then I ran:

make > make.log 2>&1

Then make runs for a while and then eventually dies with this message:

gcc -DHAVE_CONFIG_H -DLIBDIR=\"/usr/local/cygb20/lib\"
-DINCLUDEDIR=\"/usr/local/cygb20/include\" -c -I. -I../../src/make
-I../../src/make/glob \
       -g -O2 ../../src/make/arscan.c -o arscan.o
../../src/make/arscan.c:444: warning: preprocessing directive not recognized
within macro arg
../../src/make/arscan.c:444: warning: preprocessing directive not recognized
within macro arg
../../src/make/arscan.c:444: warning: preprocessing directive not recognized
within macro arg
../../src/make/arscan.c: In function `ar_name_equal':
../../src/make/arscan.c:439: undefined or invalid # directive
../../src/make/arscan.c:441: undefined or invalid # directive
../../src/make/arscan.c:442: parse error before `2'
../../src/make/arscan.c:443: undefined or invalid # directive
../../src/make/arscan.c:444: parse error before `#'
../../src/make/arscan.c:444: `cray' undeclared (first use in this function)
../../src/make/arscan.c:444: (Each undeclared identifier is reported only
once
../../src/make/arscan.c:444: for each function it appears in.)
../../src/make/arscan.c:444: parse error before `1'
../../src/make/arscan.c:444: parse error before `#'
../../src/make/arscan.c:444: parse error before `1'
../../src/make/arscan.c:444: parse error before `)'
../../src/make/arscan.c:444: `__s1_len' undeclared (first use in this
function)
../../src/make/arscan.c:444: `__s2_len' undeclared (first use in this
function)
../../src/make/arscan.c:444: parse error before `)'
../../src/make/arscan.c: At top level:
../../src/make/arscan.c:448: parse error before `&&'
../../src/make/arscan.c:448: warning: data definition has no type or storage
class
../../src/make/arscan.c:448: parse error before `}'
../../src/make/arscan.c:448: conflicting declarations of `__result'
../../src/make/arscan.c:448: `__result' previously declared here
../../src/make/arscan.c:448: `name' undeclared here (not in a function)
../../src/make/arscan.c:448: `__s2' undeclared here (not in a function)
../../src/make/arscan.c:448: initializer element is not constant
../../src/make/arscan.c:448: parse error before `if'
../../src/make/arscan.c:448: conflicting declarations of `__result'
../../src/make/arscan.c:448: `__result' previously defined here
../../src/make/arscan.c:448: warning: data definition has no type or storage
class
../../src/make/arscan.c:448: parse error before `}'
../../src/make/arscan.c:448: warning: data definition has no type or storage
class
../../src/make/arscan.c:448: parse error before `}'
../../src/make/arscan.c:448: redefinition of `__result'
../../src/make/arscan.c:448: `__result' previously defined here
../../src/make/arscan.c:448: `__s1' undeclared here (not in a function)
../../src/make/arscan.c:448: `mem' undeclared here (not in a function)
../../src/make/arscan.c:448: initializer element is not constant
../../src/make/arscan.c:448: parse error before `if'
../../src/make/arscan.c:448: conflicting declarations of `__result'
../../src/make/arscan.c:448: `__result' previously defined here
../../src/make/arscan.c:448: warning: data definition has no type or storage
class
../../src/make/arscan.c:448: parse error before `}'
make[1]: *** [arscan.o] Error 1
make[1]: Leaving directory `/root/downloads/CROSS/make'
make: *** [all-make] Error 2

I looked at the offending code and on the surface it looks ok to me:

      return !strncmp (name, mem,
		       sizeof (hdr.ar_name) - 
#if !defined (__hpux) && !defined (cray)
		       1
#else
		       2
#endif /* !__hpux && !cray */
		       );
#endif

Line #444 is the line containing just: );

I am running on a RedHat Linux 6.0 system, using this version of gcc:

Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/specs
gcc version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release)

Any idea why this is complaining?

Thanks,
Curt
_______________________________________________
New CrossGCC FAQ: http://www.objsw.com/CrossGCC
_______________________________________________
To remove yourself from the crossgcc list, send
mail to crossgcc-request@cygnus.com with the
text 'unsubscribe' (without the quotes) in the
body of the message.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]