2008-07-24 Dan Nicolaescu <dann@ics.uci.edu>
+ * m/amdx86-64.h (HAVE_LIB64_DIR): Consolidate ifdefs.
+ * m/alpha.h (TEXT_END):
+ * m/ibmrs6000.h (TEXT_END):
+ * m/macppc.h (TEXT_END):
+ * s/darwin.h (TEXT_END):
+ * s/msdos.h (TEXT_END): Remove, unused.
+ * s/gnu-linux.h (BSD_PGRPS): Add a comment.
+ * s/cygwin.h: Remove comment.
+
* ecrt0.c (NODOT_GLOBAL_START): Remove code, unused.
(DOT_GLOBAL_START): Remove conditional, redundant for CRT0_DUMMIES.
* m/intel386.h (DOT_GLOBAL_START):
#define NO_TERMIO
#if defined (GNU_LINUX) || defined (__NetBSD__) || defined (__OpenBSD__)
-# define TEXT_END ({ extern int _etext; &_etext; })
# ifndef __ELF__
# define COFF
# endif /* notdef __ELF__ */
#undef LIB_STANDARD
#else /* !__OpenBSD__ && !__FreeBSD__ && !__NetBSD__ && !SOLARIS2 */
-
-#undef START_FILES
-#ifdef HAVE_LIB64_DIR
-#define START_FILES pre-crt0.o /usr/lib64/crt1.o /usr/lib64/crti.o
-#else
-#define START_FILES pre-crt0.o /usr/lib/crt1.o /usr/lib/crti.o
-#endif
-
/* The duplicate -lgcc is intentional in the definition of LIB_STANDARD.
The reason is that some functions in libgcc.a call functions from libc.a,
and some libc.a functions need functions from libgcc.a. Since most
versions of ld are one-pass linkers, we need to mention -lgcc twice,
or else we risk getting unresolved externals. */
+#undef START_FILES
#undef LIB_STANDARD
#ifdef HAVE_LIB64_DIR
+#define START_FILES pre-crt0.o /usr/lib64/crt1.o /usr/lib64/crti.o
#define LIB_STANDARD -lgcc -lc -lgcc /usr/lib64/crtn.o
#else
+#define START_FILES pre-crt0.o /usr/lib/crt1.o /usr/lib/crti.o
#define LIB_STANDARD -lgcc -lc -lgcc /usr/lib/crtn.o
#endif
#ifndef USG5_4
#define TEXT_START 0x10000000
-#define TEXT_END 0
#define DATA_START 0x20000000
#define WORDS_BIG_ENDIAN
#define DATA_SEG_BITS 0x20000000
#define LOAD_AVE_CVT(x) (int) (((double) (x)) * 100.0 / FSCALE)
-#if defined (GNU_LINUX) || defined (__NetBSD__) || defined (__OpenBSD__)
-# define TEXT_END ({ extern int _etext; &_etext; })
-#endif
-
#if (defined (__NetBSD__) || defined (__OpenBSD__)) && defined (__ELF__)
#define HAVE_TEXT_START
#endif
#define TERMINFO
#define HAVE_SOCKETS
-/* Xaw3d causes problems -- might have been fixed by NARROWPROTO
- above, but I haven't tried it */
-/*#undef HAVE_XAW3D*/
/* vfork() interacts badly with setsid(), causing ptys to fail to
change their controlling terminal */
/* start_of_text isn't actually used, so make it compile without error. */
#define TEXT_START (0)
-/* This seems to be right for end_of_text, but it may not be used anyway. */
-#define TEXT_END get_etext()
-
/* Definitions for how to compile & link. */
/* Link in the Carbon or AppKit lib. */
/* Use BSD process groups, but use setpgid() instead of setpgrp() to
actually set a process group. */
-
+/* Interesting: only GNU/Linux defines this, but the BSDs do not... */
#define BSD_PGRPS
#define NARROWPROTO 1
#define DATA_START (&etext + 1)
#define TEXT_START &start
-#define TEXT_END &etext
#define _NAIVE_DOS_REGS