This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


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

mips cross, initializing global variables


I've managed to compile a cross compiler that generates mips code on a
RedHat x86 system. I use obj-copy to convert the code to S3 format and can
then run it on a mips based evaluation board.

My problem is this:

The global variables (or whatever it's called in C - I mean those declared 
outside of a function) can not be initialized when they are declared. I
have to initialize them explicitly in assignstatements later on.

Do you have any idea why this is?

It's not the end of the world if I can't solve this problem (since I can
always start the program by initializing all the global variables), but it
is kind of a nuisance.

I'd greatly appreciate some help.

Thank U.

/Per Fransson



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