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]

Some newbie questions


Pardon me for the simplistic questions, but I'm a bit green in this 
area.  I've spent the last couple days scanning the archives (BTW, where 
are the latest?  The ones I found only seemed to go to last July), and 
I've read the Cygnus FAQ, but I still have some unanswered questions.

I set up gcc 2.7.2.1 about a year ago to do some simplistic 68040 
cross-development (small hardware test programs).  It wasn't quite 
installed right, but it was good enough.  Now I'd like to use it for 
real development on a 68360 system, but I'm running into a few problems.  
I'm using the BDM port on the '360, through an HP E3458A probe, with the 
SDS SingleStep debugger.

1.  In my previous uses, I ran into the problem of main calling __main, 
which couldn't be found; since my code was very simple, I just stubbed 
it out.  I've now found that __main is in libgcc.a, but I have to 
explicitly link to it.  Is this right?

2.  Linking in libgcc then required _exit and _cleanup.  I stubbed 
_cleanup and made _exit an infinite loop.  Does this make sense?

3.  I wanted to use rand() (I *believe* I'm using newlib-1.7.0).  For 
some reason, this requires sbrk().  I don't feel comfortable stubbing 
this, but I considered just having it return -1 and setting errno to 
ENOMEM (which the man page says it should do on error).  Any ideas?

4.  I can't get SingleStep to recognize the debugging information.  I 
generate coff with -g, convert it to IEEE with objcopy, and then to 
SDS's format with fromieee.  But all I can display is disassembled code.  
Anyone else have experience with SDS? (I did see a thread about this in 
the archive, but it didn't look like it was completely answered; I'd 
call SDS, but I imagine they'd just try to sell me their compiler).

5.  I've seen reference to remote debugging with gdb.  Is this possible 
via the BDM on the '360?

Thanks.  I'm sure I'll have more questions in the coming weeks.
--
John A. Breen
jab3@hotmail.com


______________________________________________________
Get Your Private, Free Email at http://www.hotmail.com