diff options
author | Jason Merrill <merrill@gnu.org> | 1994-09-10 00:34:51 +0000 |
---|---|---|
committer | Jason Merrill <merrill@gnu.org> | 1994-09-10 00:34:51 +0000 |
commit | e2fd1d94b86c820b496041a6faa2870806d09a6e (patch) | |
tree | b7cafca4104c344d41a6ac0c359fe8e77d5c78f9 /gcc | |
parent | 5419023491bd53ac0c1afb4c311c93247b5100f2 (diff) | |
download | gcc-e2fd1d94b86c820b496041a6faa2870806d09a6e.zip gcc-e2fd1d94b86c820b496041a6faa2870806d09a6e.tar.gz gcc-e2fd1d94b86c820b496041a6faa2870806d09a6e.tar.bz2 |
(expand_main_function): Don't call __main if
HAS_INIT_SECTION is defined.
From-SVN: r8067
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/function.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/gcc/function.c b/gcc/function.c index 9efbc41..7d2e433 100644 --- a/gcc/function.c +++ b/gcc/function.c @@ -4700,6 +4700,11 @@ mark_varargs () /* Expand a call to __main at the beginning of a possible main function. */ +#if defined(INIT_SECTION_ASM_OP) && !defined(INVOKE__main) +#undef HAS_INIT_SECTION +#define HAS_INIT_SECTION +#endif + void expand_main_function () { @@ -4707,10 +4712,10 @@ expand_main_function () { /* The zero below avoids a possible parse error */ 0; -#if !defined (INIT_SECTION_ASM_OP) || defined (INVOKE__main) +#if !defined (HAS_INIT_SECTION) emit_library_call (gen_rtx (SYMBOL_REF, Pmode, NAME__MAIN), 0, VOIDmode, 0); -#endif /* not INIT_SECTION_ASM_OP or INVOKE__main */ +#endif /* not HAS_INIT_SECTION */ } } |