Implement fmal, some fma bugfixes
[glibc.git] / sysdeps / i386 / Makefile
blobef45ce6e78bde5e6b76522f8a3d7102b8bfaadd3
1 # The mpn functions need a #define for asm syntax flavor.
2 # Every i386 port in use uses gas syntax (I think).
3 asm-CPPFLAGS += -DGAS_SYNTAX
5 # The i386 `long double' is a distinct type we support.
6 long-double-fcts = yes
8 ifeq ($(subdir),csu)
9 # On i686 we must avoid generating the trampoline functions generated
10 # to get the GOT pointer.
11 CFLAGS-initfini.s += -march=i386 -mtune=i386
12 endif
14 ifeq ($(subdir),gmon)
15 sysdep_routines += i386-mcount
16 endif
18 ifeq ($(subdir),elf)
19 CFLAGS-rtld.c += -Wno-uninitialized -Wno-unused
20 CFLAGS-dl-load.c += -Wno-unused
21 CFLAGS-dl-reloc.c += -Wno-unused
22 endif
24 ifeq ($(subdir),debug)
25 CFLAGS-backtrace.c += -fexceptions
26 endif
28 # Most of the glibc routines don't ever call user defined callbacks
29 # nor use any FPU or SSE* and as such don't need bigger %esp alignment
30 # than 4 bytes.
31 # Lots of routines in math will use FPU, so make math subdir an exception
32 # here.
33 ifeq ($(subdir),math)
34 sysdep-CFLAGS += -mpreferred-stack-boundary=4
35 else
36 ifeq ($(subdir),csu)
37 sysdep-CFLAGS += -mpreferred-stack-boundary=4
38 else
39 sysdep-CFLAGS += -mpreferred-stack-boundary=2
40 # Likewise, any function which calls user callbacks
41 uses-callbacks += -mpreferred-stack-boundary=4
42 # Likewise, any stack alignment tests
43 stack-align-test-flags += -malign-double -mpreferred-stack-boundary=4
44 endif
45 endif
47 # And a couple of other routines
48 ifeq ($(subdir),stdlib)
49 CFLAGS-exit.c += -mpreferred-stack-boundary=4
50 endif
51 ifeq ($(subdir),elf)
52 CFLAGS-dl-init.c += -mpreferred-stack-boundary=4
53 CFLAGS-dl-fini.c += -mpreferred-stack-boundary=4
54 CFLAGS-dl-open.c += -mpreferred-stack-boundary=4
55 CFLAGS-dl-close.c += -mpreferred-stack-boundary=4
56 CFLAGS-dl-error.c += -mpreferred-stack-boundary=4
57 endif
58 ifeq ($(subdir),dlfcn)
59 CFLAGS-dlopen.c += -mpreferred-stack-boundary=4
60 CFLAGS-dlopenold.c += -mpreferred-stack-boundary=4
61 CFLAGS-dlclose.c += -mpreferred-stack-boundary=4
62 CFLAGS-dlerror.c += -mpreferred-stack-boundary=4
63 endif
65 ifneq (,$(filter -mno-tls-direct-seg-refs,$(CFLAGS)))
66 defines += -DNO_TLS_DIRECT_SEG_REFS
67 endif
69 ifeq ($(subdir),elf)
70 sysdep-dl-routines += tlsdesc dl-tlsdesc
71 sysdep_routines += tlsdesc dl-tlsdesc
72 sysdep-rtld-routines += tlsdesc dl-tlsdesc
73 endif
75 ifeq ($(subdir),csu)
76 gen-as-const-headers += tlsdesc.sym
77 endif