summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDale Rahn <drahn@cvs.openbsd.org>2003-08-25 17:59:43 +0000
committerDale Rahn <drahn@cvs.openbsd.org>2003-08-25 17:59:43 +0000
commitccdf72b6046905b3635e15484f81dd20b7c85f7b (patch)
tree3a6453a9a1b071e78858a7079c7a4edcc727416c
parent929d7c4322d68ec2ef963a43fdba732f42679ad9 (diff)
Define both _start and __start in crt0, all of the other architectures do.
-rw-r--r--lib/csu/alpha/crt0.c7
-rw-r--r--lib/csu/powerpc/crt0.c5
2 files changed, 9 insertions, 3 deletions
diff --git a/lib/csu/alpha/crt0.c b/lib/csu/alpha/crt0.c
index 34fd45e1b67..345941a8eda 100644
--- a/lib/csu/alpha/crt0.c
+++ b/lib/csu/alpha/crt0.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: crt0.c,v 1.8 2003/02/28 18:05:51 deraadt Exp $ */
+/* $OpenBSD: crt0.c,v 1.9 2003/08/25 17:59:42 drahn Exp $ */
/* $NetBSD: crt0.c,v 1.1 1996/09/12 16:59:02 cgd Exp $ */
/*
* Copyright (c) 1995 Christopher G. Demetriou
@@ -32,7 +32,7 @@
*/
#if defined(LIBC_SCCS) && !defined(lint)
-static char rcsid[] = "$OpenBSD: crt0.c,v 1.8 2003/02/28 18:05:51 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: crt0.c,v 1.9 2003/08/25 17:59:42 drahn Exp $";
#endif /* LIBC_SCCS and not lint */
#include <stdlib.h>
@@ -50,6 +50,9 @@ extern void _mcleanup(void);
extern unsigned char _etext, _eprol;
#endif /* MCRT0 */
+__asm(".globl _start");
+__asm(".type _start@function");
+__asm("_start = __start");
void
__start(sp, cleanup, obj)
char **sp;
diff --git a/lib/csu/powerpc/crt0.c b/lib/csu/powerpc/crt0.c
index 4bfd73b5c2c..901ba23dbc0 100644
--- a/lib/csu/powerpc/crt0.c
+++ b/lib/csu/powerpc/crt0.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: crt0.c,v 1.2 2003/02/28 18:05:51 deraadt Exp $ */
+/* $OpenBSD: crt0.c,v 1.3 2003/08/25 17:59:42 drahn Exp $ */
/* $NetBSD: crt0.c,v 1.1 1996/09/12 16:59:02 cgd Exp $ */
/*
* Copyright (c) 1995 Christopher G. Demetriou
@@ -46,6 +46,9 @@ extern unsigned char _etext, _eprol;
static inline char * _strrchr(const char *p, char ch);
+__asm(".globl __start");
+__asm(".type __start@function");
+__asm("__start = _start");
void
_start(int argc, char **argv, char **envp, void *aux, void (*cleanup)(void))
{