Commit 036cfb36 by Alexandre Oliva Committed by Alexandre Oliva

crtstuff.c (CRT_CALL_STATIC_FUNCTION): Define default.

* crtstuff.c (CRT_CALL_STATIC_FUNCTION): Define default.
(fini_dummy, init_dummy): Use it.

From-SVN: r35971
parent c2e20542
Fri Aug 25 04:21:13 2000 Alexandre Oliva <aoliva@redhat.com>
* crtstuff.c (CRT_CALL_STATIC_FUNCTION): Define default.
(fini_dummy, init_dummy): Use it.
Fri 25-Aug-2000 08:03:27 BST Neil Booth <NeilB@earthling.net> Fri 25-Aug-2000 08:03:27 BST Neil Booth <NeilB@earthling.net>
* cpplex.c (is_macro_disabled): Caller has already checked * cpplex.c (is_macro_disabled): Caller has already checked
......
...@@ -62,6 +62,10 @@ Boston, MA 02111-1307, USA. */ ...@@ -62,6 +62,10 @@ Boston, MA 02111-1307, USA. */
#include "defaults.h" #include "defaults.h"
#include "frame.h" #include "frame.h"
#ifndef CRT_CALL_STATIC_FUNCTION
# define CRT_CALL_STATIC_FUNCTION(func) func ()
#endif
/* We do not want to add the weak attribute to the declarations of these /* We do not want to add the weak attribute to the declarations of these
routines in frame.h because that will cause the definition of these routines in frame.h because that will cause the definition of these
symbols to be weak as well. symbols to be weak as well.
...@@ -213,7 +217,7 @@ static void __attribute__ ((__unused__)) ...@@ -213,7 +217,7 @@ static void __attribute__ ((__unused__))
fini_dummy (void) fini_dummy (void)
{ {
asm (FINI_SECTION_ASM_OP); asm (FINI_SECTION_ASM_OP);
__do_global_dtors_aux (); CRT_CALL_STATIC_FUNCTION (__do_global_dtors_aux);
#ifdef FORCE_FINI_SECTION_ALIGN #ifdef FORCE_FINI_SECTION_ALIGN
FORCE_FINI_SECTION_ALIGN; FORCE_FINI_SECTION_ALIGN;
#endif #endif
...@@ -237,7 +241,7 @@ static void __attribute__ ((__unused__)) ...@@ -237,7 +241,7 @@ static void __attribute__ ((__unused__))
init_dummy (void) init_dummy (void)
{ {
asm (INIT_SECTION_ASM_OP); asm (INIT_SECTION_ASM_OP);
frame_dummy (); CRT_CALL_STATIC_FUNCTION (frame_dummy);
#ifdef FORCE_INIT_SECTION_ALIGN #ifdef FORCE_INIT_SECTION_ALIGN
FORCE_INIT_SECTION_ALIGN; FORCE_INIT_SECTION_ALIGN;
#endif #endif
...@@ -402,7 +406,7 @@ static void __attribute__ ((__unused__)) ...@@ -402,7 +406,7 @@ static void __attribute__ ((__unused__))
init_dummy (void) init_dummy (void)
{ {
asm (INIT_SECTION_ASM_OP); asm (INIT_SECTION_ASM_OP);
__do_global_ctors_aux (); CRT_CALL_STATIC_FUNCTION (__do_global_ctors_aux);
#ifdef FORCE_INIT_SECTION_ALIGN #ifdef FORCE_INIT_SECTION_ALIGN
FORCE_INIT_SECTION_ALIGN; FORCE_INIT_SECTION_ALIGN;
#endif #endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment