2.9
[glibc/nacl-glibc.git] / sysdeps / powerpc / powerpc32 / Makefile
blob1d58a063d672deb98fc29e6ab9c34b83f20c4d3d
1 # Powerpc32 specific build options.
3 ifeq ($(with-fp),no)
4 +cflags += -msoft-float
5 sysdep-LDFLAGS += -msoft-float
6 endif
8 ifeq ($(subdir),misc)
9 sysdep_routines += gprsave0 gprrest0 gprsave1 gprrest1
10 endif
12 # On PPC, -fpic works until the GOT contains 32768 bytes, and possibly
13 # more depending on how clever the linker is. Each GOT entry takes 4 bytes,
14 # so that's at least 8192 entries. Since libc only uses about 2000 entries,
15 # we want to use -fpic, because this generates fewer relocs.
16 ifeq (yes,$(build-shared))
17 pic-ccflag = -fpic
18 endif
20 ifeq ($(subdir),csu)
21 ifneq ($(elf),no)
22 # The initfini generation code doesn't work in the presence of -fPIC, so
23 # we use -fpic instead which is much better.
24 CFLAGS-initfini.s += -fpic -O1
26 # There is no benefit to using sdata for these objects, and the user
27 # of the library should be able to control what goes into sdata.
28 CFLAGS-init.o = -G0
29 CFLAGS-gmon-start.o = -G0
30 endif
31 ifeq (yes,$(build-shared))
32 # Compatibility
33 ifeq (yes,$(have-protected))
34 CPPFLAGS-libgcc-compat.S = -DHAVE_DOT_HIDDEN
35 endif
36 sysdep_routines += libgcc-compat
37 shared-only-routines += libgcc-compat
38 endif
39 endif
41 ifeq ($(subdir),elf)
42 # extra shared linker files to link only into dl-allobjs.so
43 sysdep-rtld-routines += dl-start
44 endif