summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authoruqs <uqs@FreeBSD.org>2010-03-05 13:28:05 +0000
committeruqs <uqs@FreeBSD.org>2010-03-05 13:28:05 +0000
commitb59a09ce7933da1dcf2be030f1a578a03364dd7a (patch)
tree1cf67b36dafa186824064443b20ee533818478da /lib
parent9b575d6cfa35359a26c022a0a266a114cda5a168 (diff)
downloadFreeBSD-src-b59a09ce7933da1dcf2be030f1a578a03364dd7a.zip
FreeBSD-src-b59a09ce7933da1dcf2be030f1a578a03364dd7a.tar.gz
Properly declare non-extern functions in crt1
Also move the declarations after __progname consistently to make the distinction clearer. Reviewed by: jmallett Approved by: ed (co-mentor)
Diffstat (limited to 'lib')
-rw-r--r--lib/csu/amd64/crt1.c3
-rw-r--r--lib/csu/arm/crt1.c3
-rw-r--r--lib/csu/mips/crt1.c2
-rw-r--r--lib/csu/powerpc/crt1.c5
-rw-r--r--lib/csu/sparc64/crt1.c5
5 files changed, 13 insertions, 5 deletions
diff --git a/lib/csu/amd64/crt1.c b/lib/csu/amd64/crt1.c
index 943b07b..3bc4809 100644
--- a/lib/csu/amd64/crt1.c
+++ b/lib/csu/amd64/crt1.c
@@ -43,7 +43,6 @@ typedef void (*fptr)(void);
extern void _fini(void);
extern void _init(void);
extern int main(int, char **, char **);
-extern void _start(char **, void (*)(void));
#ifdef GCRT
extern void _mcleanup(void);
@@ -55,6 +54,8 @@ extern int etext;
char **environ;
const char *__progname = "";
+void _start(char **, void (*)(void));
+
/* The entry function. */
void
_start(char **ap, void (*cleanup)(void))
diff --git a/lib/csu/arm/crt1.c b/lib/csu/arm/crt1.c
index 02af3c2..4319f17 100644
--- a/lib/csu/arm/crt1.c
+++ b/lib/csu/arm/crt1.c
@@ -74,6 +74,9 @@ char **environ;
const char *__progname = "";
struct ps_strings *__ps_strings;
+void __start(int, char **, char **, struct ps_strings *,
+ const struct Struct_Obj_Entry *, void (*)(void));
+
/* The entry function. */
__asm(" .text \n"
" .align 0 \n"
diff --git a/lib/csu/mips/crt1.c b/lib/csu/mips/crt1.c
index 39f110b..7409c28 100644
--- a/lib/csu/mips/crt1.c
+++ b/lib/csu/mips/crt1.c
@@ -66,6 +66,8 @@ extern int etext;
char **environ;
const char *__progname = "";
+void __start(char **, void (*)(void), struct Struct_Obj_Entry *, struct ps_strings *);
+
/* The entry function. */
void
__start(char **ap,
diff --git a/lib/csu/powerpc/crt1.c b/lib/csu/powerpc/crt1.c
index 080691c..3a2f6dd 100644
--- a/lib/csu/powerpc/crt1.c
+++ b/lib/csu/powerpc/crt1.c
@@ -59,8 +59,6 @@ extern int _DYNAMIC;
extern void _fini(void);
extern void _init(void);
extern int main(int, char **, char **);
-extern void _start(int, char **, char **, const struct Struct_Obj_Entry *,
- void (*)(void), struct ps_strings *);
#ifdef GCRT
extern void _mcleanup(void);
@@ -73,6 +71,9 @@ char **environ;
const char *__progname = "";
struct ps_strings *__ps_strings;
+void _start(int, char **, char **, const struct Struct_Obj_Entry *,
+ void (*)(void), struct ps_strings *);
+
/* The entry function. */
/*
* First 5 arguments are specified by the PowerPC SVR4 ABI.
diff --git a/lib/csu/sparc64/crt1.c b/lib/csu/sparc64/crt1.c
index 5d8e371..f27c59b 100644
--- a/lib/csu/sparc64/crt1.c
+++ b/lib/csu/sparc64/crt1.c
@@ -50,8 +50,6 @@ extern int _DYNAMIC;
extern void _fini(void);
extern void _init(void);
extern int main(int, char **, char **);
-extern void _start(char **, void (*)(void), struct Struct_Obj_Entry *,
- struct ps_strings *);
extern void __sparc_utrap_setup(void);
#ifdef GCRT
@@ -64,6 +62,9 @@ extern int etext;
char **environ;
const char *__progname = "";
+void _start(char **, void (*)(void), struct Struct_Obj_Entry *,
+ struct ps_strings *);
+
/* The entry function. */
/*
* %o0 holds ps_strings pointer.
OpenPOWER on IntegriCloud