PR middle-end/20297
[official-gcc.git] / libffi / Makefile.am
blob89a2426b32d90956abde5cdfc9ea86f3e132fc2f
1 ## Process this with automake to create Makefile.in
3 AUTOMAKE_OPTIONS = foreign subdir-objects
4 ACLOCAL_AMFLAGS = -I ..
6 SUBDIRS = include testsuite
8 EXTRA_DIST = LICENSE ChangeLog.v1 \
9         src/alpha/ffi.c src/alpha/osf.S src/alpha/ffitarget.h \
10         src/arm/ffi.c src/arm/sysv.S src/arm/ffitarget.h \
11         src/cris/ffi.c src/cris/sysv.S src/cris/ffitarget.h \
12         src/mips/ffi.c src/mips/n32.S src/mips/o32.S \
13         src/mips/ffitarget.h \
14         src/m32r/ffi.c src/m32r/sysv.S src/m32r/ffitarget.h \
15         src/m68k/ffi.c src/m68k/sysv.S src/m68k/ffitarget.h \
16         src/powerpc/ffi.c src/powerpc/sysv.S \
17         src/powerpc/linux64.S src/powerpc/linux64_closure.S \
18         src/powerpc/ppc_closure.S src/powerpc/asm.h \
19         src/powerpc/aix.S src/powerpc/darwin.S \
20         src/powerpc/aix_closure.S src/powerpc/darwin_closure.S \
21         src/powerpc/ffi_darwin.c src/powerpc/ffitarget.h \
22         src/s390/ffi.c src/s390/sysv.S src/s390/ffitarget.h \
23         src/sh/ffi.c src/sh/sysv.S src/sh/ffitarget.h \
24         src/sh64/ffi.c src/sh64/sysv.S src/sh64/ffitarget.h \
25         src/sparc/v8.S src/sparc/v9.S src/sparc/ffitarget.h \
26         src/sparc/ffi.c \
27         src/x86/ffi.c src/x86/sysv.S src/x86/win32.S \
28         src/x86/ffi64.c src/x86/unix64.S src/x86/ffitarget.h \
29         src/pa/ffi.c src/pa/linux.S src/frv/eabi.S src/frv/ffitarget.h
31 ## ################################################################
34 ## This section is for make and multilib madness.
37 # Work around what appears to be a GNU make bug handling MAKEFLAGS
38 # values defined in terms of make variables, as is the case for CC and
39 # friends when we are called from the top level Makefile.
40 AM_MAKEFLAGS = \
41         "AR_FLAGS=$(AR_FLAGS)" \
42         "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
43         "CFLAGS=$(CFLAGS)" \
44         "CXXFLAGS=$(CXXFLAGS)" \
45         "CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
46         "CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \
47         "INSTALL=$(INSTALL)" \
48         "INSTALL_DATA=$(INSTALL_DATA)" \
49         "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
50         "INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \
51         "JC1FLAGS=$(JC1FLAGS)" \
52         "LDFLAGS=$(LDFLAGS)" \
53         "LIBCFLAGS=$(LIBCFLAGS)" \
54         "LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)" \
55         "MAKE=$(MAKE)" \
56         "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)" \
57         "PICFLAG=$(PICFLAG)" \
58         "PICFLAG_FOR_TARGET=$(PICFLAG_FOR_TARGET)" \
59         "RUNTESTFLAGS=$(RUNTESTFLAGS)" \
60         "SHELL=$(SHELL)" \
61         "exec_prefix=$(exec_prefix)" \
62         "infodir=$(infodir)" \
63         "libdir=$(libdir)" \
64         "prefix=$(prefix)" \
65         "AR=$(AR)" \
66         "AS=$(AS)" \
67         "CC=$(CC)" \
68         "CXX=$(CXX)" \
69         "LD=$(LD)" \
70         "NM=$(NM)" \
71         "RANLIB=$(RANLIB)" \
72         "DESTDIR=$(DESTDIR)"
74 MAKEOVERRIDES=
76 toolexeclib_LTLIBRARIES = libffi.la
77 noinst_LTLIBRARIES = libffi_convenience.la
79 libffi_la_SOURCES = src/debug.c src/prep_cif.c src/types.c \
80                 src/raw_api.c src/java_raw_api.c
82 nodist_libffi_la_SOURCES =
84 if MIPS_IRIX
85 nodist_libffi_la_SOURCES += src/mips/ffi.c src/mips/o32.S src/mips/n32.S
86 endif
87 if MIPS_LINUX
88 nodist_libffi_la_SOURCES += src/mips/ffi.c src/mips/o32.S
89 endif
90 if X86
91 nodist_libffi_la_SOURCES += src/x86/ffi.c src/x86/sysv.S
92 endif
93 if X86_WIN32
94 nodist_libffi_la_SOURCES += src/x86/ffi.c src/x86/win32.S
95 endif
96 if SPARC
97 nodist_libffi_la_SOURCES += src/sparc/ffi.c src/sparc/v8.S src/sparc/v9.S
98 endif
99 if ALPHA
100 nodist_libffi_la_SOURCES += src/alpha/ffi.c src/alpha/osf.S
101 endif
102 if IA64
103 nodist_libffi_la_SOURCES += src/ia64/ffi.c src/ia64/unix.S
104 endif
105 if M32R
106 nodist_libffi_la_SOURCES += src/m32r/sysv.S src/m32r/ffi.c
107 endif
108 if M68K
109 nodist_libffi_la_SOURCES += src/m68k/ffi.c src/m68k/sysv.S
110 endif
111 if POWERPC
112 nodist_libffi_la_SOURCES += src/powerpc/ffi.c src/powerpc/sysv.S src/powerpc/ppc_closure.S src/powerpc/linux64.S src/powerpc/linux64_closure.S
113 endif
114 if POWERPC_AIX
115 nodist_libffi_la_SOURCES += src/powerpc/ffi_darwin.c src/powerpc/aix.S src/powerpc/aix_closure.S
116 endif
117 if POWERPC_DARWIN
118 nodist_libffi_la_SOURCES += src/powerpc/ffi_darwin.c src/powerpc/darwin.S src/powerpc/darwin_closure.S
119 endif
120 if POWERPC_FREEBSD
121 nodist_libffi_la_SOURCES += src/powerpc/ffi.c src/powerpc/sysv.S src/powerpc/ppc_closure.S
122 endif
123 if ARM
124 nodist_libffi_la_SOURCES += src/arm/sysv.S src/arm/ffi.c
125 endif
126 if LIBFFI_CRIS
127 nodist_libffi_la_SOURCES += src/cris/sysv.S src/cris/ffi.c
128 endif
129 if FRV
130 nodist_libffi_la_SOURCES += src/frv/eabi.S src/frv/ffi.c
131 endif
132 if S390
133 nodist_libffi_la_SOURCES += src/s390/sysv.S src/s390/ffi.c
134 endif
135 if X86_64
136 nodist_libffi_la_SOURCES += src/x86/ffi64.c src/x86/unix64.S src/x86/ffi.c src/x86/sysv.S
137 endif
138 if SH
139 nodist_libffi_la_SOURCES += src/sh/sysv.S src/sh/ffi.c
140 endif
141 if SH64
142 nodist_libffi_la_SOURCES += src/sh64/sysv.S src/sh64/ffi.c
143 endif
144 if PA
145 nodist_libffi_la_SOURCES += src/pa/linux.S src/pa/ffi.c
146 endif
148 libffi_convenience_la_SOURCES = $(libffi_la_SOURCES)
149 nodist_libffi_convenience_la_SOURCES = $(nodist_libffi_la_SOURCES)
151 AM_CFLAGS = -Wall -g -fexceptions
153 libffi_la_LDFLAGS = -version-info `grep -v '^\#' $(srcdir)/libtool-version`
155 AM_CPPFLAGS = -I. -I$(top_srcdir)/include -Iinclude -I$(top_srcdir)/src
156 AM_CCASFLAGS = $(AM_CPPFLAGS)