[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
C++ ctors, cdtest.exe, printf and termios oh my!
- Date: Thu, 5 Aug 1999 14:49:17 -0700 (PDT)
- From: tonya at ece.ubc.ca (Tony R. Ambardar)
- Subject: C++ ctors, cdtest.exe, printf and termios oh my!
On Thu, 5 Aug 1999 joel at OARcorp.com wrote:
> On Thu, 5 Aug 1999, Tony R. Ambardar wrote:
>
> > This is what I originally suspected. However, I believe Rosimildo and Erik
> > have both successfully run cdtest.exe using interrupt-driven console I/O.
> > Hence my confusion...
> >
> > Is this true, Erik, Rosimildo?
>
> I may be out on a limb here but they use the video card for output which
> is not interrupt driven. The interrupts are for keyboard input.
>
True for the pc386 BSP; Erik's i386ex BSP uses serial I/O for the console
however.
> Thus I am backing up a bit. I don't think this is your problem. :(
>
> This looks like it could be the same problem I am dealing with on the
> sparc/erc32. Thanks to Erik I, I am able to give you the following
> advice. :)
>
> You need to have the .init/.fini sections in your linkcmds, bsp_specs must
> reference crti, crtn, crtbegin, and crtend, and -DUSE_INIT_FINI must be in
> the Makefile.in in the startup directory.
>
Already done that. As I said, exceptions and global ctors/dtor work for me
when I don't use interrupt I/O. I suspect you were right in the first
place. Otherwise, I am happy that C++ stuff works properly for me.
By the way, I think there should be conditional code (checking
USE_INIT_FINI) in either main.c or boot_card.c that calls "atexit(_fini)"
and "_init()". This seems to be missing from the last snapshot.
Tony
____________________________________________________________
/ \
| Tony R. Ambardar | Department of Electrical & |
| M.Sc., M.Eng. | Computer Engineering |
| Email: tonya at ece.ubc.ca | University of British Columbia |
| Ph: (604) 822-2872 | 2356 Main Mall, Vancouver B.C. |
| Fax:(604) 822-5949 | V6T 1Z4 CANADA |
\____________________________________________________________/