aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRichard Kenner <kenner@gcc.gnu.org>1995-04-02 07:54:18 -0400
committerRichard Kenner <kenner@gcc.gnu.org>1995-04-02 07:54:18 -0400
commit5a57ced09ea6d8e944c5417258cc80503d8e5aa0 (patch)
treeb63510d77b3bbe86f0ad4ea0d3da8a50a1dda646 /gcc
parent293c9fdd723d5264c4f2a16bd2072c4952504a91 (diff)
downloadgcc-5a57ced09ea6d8e944c5417258cc80503d8e5aa0.zip
gcc-5a57ced09ea6d8e944c5417258cc80503d8e5aa0.tar.gz
gcc-5a57ced09ea6d8e944c5417258cc80503d8e5aa0.tar.bz2
(RETURN_POPS_ARGS, ENCODE_SECTION_INFO): Call chain_member_purpose, not chain_member_value.
(RETURN_POPS_ARGS, ENCODE_SECTION_INFO): Call chain_member_purpose, not chain_member_value. (ASM_FILE_START, LIB_SPEC): Move to here. From-SVN: r9290
Diffstat (limited to 'gcc')
-rw-r--r--gcc/config/i386/win-nt.h36
1 files changed, 31 insertions, 5 deletions
diff --git a/gcc/config/i386/win-nt.h b/gcc/config/i386/win-nt.h
index e44a501..3b2d8c3 100644
--- a/gcc/config/i386/win-nt.h
+++ b/gcc/config/i386/win-nt.h
@@ -42,9 +42,9 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
: \
( \
((FUNDECL && (TREE_CODE_CLASS (TREE_CODE (FUNDECL)) == 'd') ? \
- chain_member_value (get_identifier ("stdcall"), \
- DECL_MACHINE_ATTRIBUTES (FUNDECL) \
- ) : 0 \
+ chain_member_purpose (get_identifier ("stdcall"), \
+ DECL_MACHINE_ATTRIBUTES (FUNDECL) \
+ ) : 0 \
) \
) \
&& \
@@ -154,8 +154,8 @@ do \
|| ! TREE_PUBLIC (DECL)); \
} \
if (TREE_CODE (DECL) == FUNCTION_DECL) \
- if (chain_member_value (get_identifier ("stdcall"), \
- DECL_MACHINE_ATTRIBUTES (DECL))) \
+ if (chain_member_purpose (get_identifier ("stdcall"), \
+ DECL_MACHINE_ATTRIBUTES (DECL))) \
XEXP (DECL_RTL (DECL), 0) = \
gen_rtx (SYMBOL_REF, Pmode, gen_stdcall_suffix (DECL)); \
} \
@@ -172,5 +172,31 @@ while (0)
&& ((get_identifier("stdcall") == name) \
|| (get_identifier("cdecl") == name))
+/* The global __fltused is necessary to cause the printf/scanf routines
+ for outputting/inputting floating point numbers to be loaded. Since this
+ is kind of hard to detect, we just do it all the time. */
+
+#ifdef ASM_FILE_START
+#undef ASM_FILE_START
+#endif
+#define ASM_FILE_START(FILE) \
+ do { fprintf (FILE, "\t.file\t"); \
+ output_quoted_string (FILE, dump_base_name); \
+ fprintf (FILE, "\n"); \
+ fprintf (FILE, ".global\t__fltused\n"); \
+ } while (0)
+
+/* if the switch "-mwindows" is passed to ld, then specify to the Microsoft
+ linker the proper switches and libraries to build a graphical program */
+
+#undef LIB_SPEC
+#define LIB_SPEC "%{mwindows:-subsystem:windows -entry:WinMainCRTStartup \
+ USER32.LIB GDI32.LIB COMDLG32.LIB WINSPOOL.LIB} \
+ %{!mwindows:-subsystem:console -entry:mainCRTStartup} \
+ %{mcrtmt:OLDNAMES.LIB LIBCMT.LIB KERNEL32.LIB ADVAPI32.LIB} \
+ %{!mcrtmt:OLDNAMES.LIB LIBC.LIB KERNEL32.LIB ADVAPI32.LIB} \
+ %{g:-debugtype:coff -debug:full} \
+ %{v}"
+
#include "winnt/winnt.h"