public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
From: "Richard Rauch" <rrauch@itrgmbh.de>
To: <ecos-discuss@ecos.sourceware.org>
Subject: [ECOS] Doubts regarding atexit()
Date: Thu, 26 Feb 2015 13:42:00 -0000	[thread overview]
Message-ID: <00c001d051ca$18c71bd0$4a555370$@itrgmbh.de> (raw)

Hello,

I have doubts/questions regarding atexit().

Actually eCos comes with an own atexit handler within ISO C library support.

But I am not sure, if this implementation is really linked instead of standard gcc implementation.

I tested with a gnu toolchain, which has no atexit implementation in his libgcc.a library.

When I am generating eCos and the eCos tests, I get the linker error messages:

... /lib\extras.o: In function `__static_initialization_and_destruction_0':
... /ecos/packages/io/fileio/current/src/misc.cxx:103: undefined reference to `__aeabi_atexit'

My linker options already includes "-nostdlib", bit this seems not to be sufficient for atexit issue.

When I add compiler option "-fno-use-cxa-atexit", everything will be generated.

Who could explain, how this works in detail. Seems there are different definitions of atexit in libraries and in eCos. How I can ensure, that the right one is used.
A further question: the compiler or linker is replacing somehow the atexit calls with calls to __aeabi_atexit. How this is working.

Many Thanks

Richard



--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

                 reply	other threads:[~2015-02-26 13:42 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='00c001d051ca$18c71bd0$4a555370$@itrgmbh.de' \
    --to=rrauch@itrgmbh.de \
    --cc=ecos-discuss@ecos.sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).