about summary refs log tree commit diff
path: root/sysdeps/mips/elf/start.S
diff options
context:
space:
mode:
authorAndreas Jaeger <aj@suse.de>2002-03-02 13:14:40 +0000
committerAndreas Jaeger <aj@suse.de>2002-03-02 13:14:40 +0000
commit05d01ed7650507688cae541339767cdf954f9e67 (patch)
tree72c39339aef0001a064b033f6eedf6904ebf9ffe /sysdeps/mips/elf/start.S
parent0e25633a77e781524aa3dc50a19cf790d144f85b (diff)
downloadglibc-05d01ed7650507688cae541339767cdf954f9e67.tar.gz
glibc-05d01ed7650507688cae541339767cdf954f9e67.tar.xz
glibc-05d01ed7650507688cae541339767cdf954f9e67.zip
Added initialization of GP (to _gp) if compiled non-PIC.
Diffstat (limited to 'sysdeps/mips/elf/start.S')
-rw-r--r--sysdeps/mips/elf/start.S4
1 files changed, 3 insertions, 1 deletions
diff --git a/sysdeps/mips/elf/start.S b/sysdeps/mips/elf/start.S
index e129930505..01908e28db 100644
--- a/sysdeps/mips/elf/start.S
+++ b/sysdeps/mips/elf/start.S
@@ -1,5 +1,5 @@
 /* Startup code compliant to the ELF Mips ABI.
-   Copyright (C) 1995, 1997, 2000, 2001 Free Software Foundation, Inc.
+   Copyright (C) 1995, 1997, 2000, 2001, 2002 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -71,6 +71,8 @@
 ENTRY_POINT:
 #ifdef __PIC__
 	SET_GP
+#else
+	la $28, _gp		/* Setup GP correctly if we're non-PIC.  */
 #endif
 	move $31, $0