diff options
author | Jeff Johnston <jjohnstn@redhat.com> | 2010-06-08 18:44:14 +0000 |
---|---|---|
committer | Jeff Johnston <jjohnstn@redhat.com> | 2010-06-08 18:44:14 +0000 |
commit | 58d6976a6e8cf1af0cf2747d5b8caa05eb765487 (patch) | |
tree | 55c09d25adf7f8c38319ae98ebc73b139d7b33be /newlib/libc/stdlib | |
parent | b7d3e6d7d23d74a3b99e3a55a8d982d382f3930f (diff) | |
download | cygnal-58d6976a6e8cf1af0cf2747d5b8caa05eb765487.tar.gz cygnal-58d6976a6e8cf1af0cf2747d5b8caa05eb765487.tar.bz2 cygnal-58d6976a6e8cf1af0cf2747d5b8caa05eb765487.zip |
2010-06-08 Jeff Johnston <jjohnstn@redhat.com>
* configure.in: Add test for enable-newlib-register-fini
to set the _WANT_REGISTER_FINI flag.
* configure: Regenerated.
* Makefile.in: Ditto.
* newlib.hin: Add _WANT_REGISTER_FINI flag.
* libc/stdlib/__call_atexit.c: Add test for
_WANT_REGISTER_FINI to enable the register_fini function.
Diffstat (limited to 'newlib/libc/stdlib')
-rw-r--r-- | newlib/libc/stdlib/__call_atexit.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/newlib/libc/stdlib/__call_atexit.c b/newlib/libc/stdlib/__call_atexit.c index c99b2744e..4c4506343 100644 --- a/newlib/libc/stdlib/__call_atexit.c +++ b/newlib/libc/stdlib/__call_atexit.c @@ -15,6 +15,8 @@ void free(void *) _ATTRIBUTE((__weak__)); extern _LOCK_RECURSIVE_T __atexit_lock; #endif +#ifdef _WANT_REGISTER_FINI + /* If "__libc_fini" is defined, finalizers (either "__libc_fini_array", or "_fini", as appropriate) will be run after all user-specified atexit handlers. For example, you can define @@ -51,6 +53,8 @@ register_fini(void) } } +#endif /* _WANT_REGISTER_FINI */ + /* * Call registered exit handlers. If D is null then all handlers are called, * otherwise only the handlers from that DSO are called. |