This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: new elf loader library
- To: Adam Agnew <agnew at missl dot cs dot umd dot edu>
- Subject: [ECOS] Re: new elf loader library
- From: Jonathan Larmour <jlarmour at redhat dot com>
- Date: Fri, 05 Oct 2001 16:49:41 +0100
- Cc: ecos-discuss at sources dot redhat dot com, msalter at redhat dot com,bdpayne at cs dot umd dot edu
- Organization: Red Hat UK Ltd.
- References: <Pine.BSF.4.33.0110051138400.61286-100000@www.missl.cs.umd.edu>
Adam Agnew wrote:
>
> This is probably a tragically stupid question, but all the same it has the
> two of us here kind of stumped. We'd like to use the new elf loader class:
> loader.hxx, but it's bubblewrapped in #ifdef __cplusplus. We're including
> it from our modified redboot's load.c . Is there a way we can do this? If
> we can't, it means we'll need to reproduce the code in strict c, which is
> a waste. Any help anyone could provide is of course greatly appreciated.
> We've seen that in your example of using the loader, the class instances
> have been commented out, is there a reason why?
Two choices. Either:
1) provide a .c API that wraps the cxx function, which is itself a .cxx
file. You only need to use a few of the functions in loader.hxx. That C API
interface can probably be kept in the loader package rather than redboot.
2) in load.c call a function (supplied in a .cxx file within redboot) to do
all the real work.
Jifl
--
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
Maybe this world is another planet's Hell -Aldous Huxley || Opinions==mine