OSDN Git Service

f169c4fe83b2bc96a5f0bdaef527355e955da5e3
[pf3gnuchains/gcc-fork.git] / boehm-gc / Makefile.am
1 ## Process this file with automake to produce Makefile.in.
2
3 ## FIXME: `make dist' in this directory will not currently work.  Many
4 ## files that should be in the distribution are not mentioned in this
5 ## Makefile.am.
6
7 target_noncanonical=@target_noncanonical@
8
9 AUTOMAKE_OPTIONS = cygnus
10
11 SUBDIRS = include
12
13 # Multilib support variables.
14 MULTISRCTOP =
15 MULTIBUILDTOP =
16 MULTIDIRS =
17 MULTISUBDIR =
18 MULTIDO = true
19 MULTICLEAN = true
20
21 noinst_LTLIBRARIES = libgcjgc.la libgcjgc_convenience.la
22
23 if POWERPC_DARWIN
24 asm_libgc_sources = powerpc_darwin_mach_dep.s
25 else
26 asm_libgc_sources = 
27 endif
28
29 GC_SOURCES = allchblk.c alloc.c blacklst.c checksums.c dbg_mlc.c \
30 dyn_load.c finalize.c gc_dlopen.c gcj_mlc.c headers.c aix_irix_threads.c \
31 malloc.c mallocx.c mark.c mark_rts.c misc.c new_hblk.c \
32 obj_map.c os_dep.c pcr_interface.c ptr_chck.c real_malloc.c reclaim.c \
33 solaris_pthreads.c solaris_threads.c specific.c stubborn.c typd_mlc.c \
34 backgraph.c win32_threads.c \
35 pthread_support.c pthread_stop_world.c darwin_stop_world.c \
36 $(asm_libgc_sources)
37
38 EXTRA_GC_SOURCES = alpha_mach_dep.S \
39 mips_sgi_mach_dep.s mips_ultrix_mach_dep.s powerpc_darwin_mach_dep.s \
40 rs6000_mach_dep.s sparc_mach_dep.S sparc_netbsd_mach_dep.s \
41 sparc_sunos4_mach_dep.s ia64_save_regs_in_stack.s
42
43 libgcjgc_la_SOURCES = $(GC_SOURCES)
44 libgcjgc_convenience_la_SOURCES = $(GC_SOURCES)
45 EXTRA_libgcjgc_la_SOURCES = $(EXTRA_GC_SOURCES)
46 EXTRA_libgcjgc_convenience_la_SOURCES = $(EXTRA_GC_SOURCES)
47
48 # Include THREADLIBS here to ensure that the correct versions of
49 # linuxthread semaphore functions get linked:
50 libgcjgc_la_LIBADD = @addobjs@ $(THREADLIBS)
51 libgcjgc_la_DEPENDENCIES = @addobjs@
52 libgcjgc_la_LDFLAGS = -version-info 1:1:0 -rpath $(toolexeclibdir)
53
54 libgcjgc_convenience_la_LIBADD = @addobjs@
55 libgcjgc_convenience_la_DEPENDENCIES = @addobjs@
56
57 AM_CXXFLAGS = @GC_CFLAGS@
58 AM_CFLAGS = @GC_CFLAGS@
59
60 check_PROGRAMS = gctest
61 # The following hack produces a warning from automake, but we need it in order 
62 # to build a file from a subdirectory. FIXME.
63 test.o: tests/test.c
64         $(COMPILE) -c $(srcdir)/tests/test.c
65 #       Using $< in the above seems to fail with the HP/UX on Itanium make.
66
67 gctest_OBJECTS = test.o
68 gctest_LDADD = ./libgcjgc.la $(THREADLIBS) $(EXTRA_TEST_LIBS)
69 gctest_LDFLAGS = -shared-libgcc
70 TESTS_ENVIRONMENT = LD_LIBRARY_PATH=../../$(MULTIBUILDTOP)gcc
71 TESTS = gctest
72
73 ## FIXME: relies on internal code generated by automake.
74 all_objs = @addobjs@ $(libgcjgc_la_OBJECTS)
75 $(all_objs) : include/private/gcconfig.h include/private/gc_priv.h \
76 include/private/gc_hdrs.h include/gc.h include/gc_gcj.h \
77 include/gc_pthread_redirects.h include/gc_config_macros.h \
78 include/gc_mark.h @addincludes@
79
80 ## FIXME: we shouldn't have to do this, but automake forces us to.
81 .s.lo:
82 ## We use -Wp,-P to strip #line directives.  Irix `as' chokes on
83 ## these.
84         $(LTCOMPILE) -Wp,-P -x assembler-with-cpp -c $<
85
86 ## We have our own definition of LTCOMPILE because we want to use our
87 ## CFLAGS, not those passed in from the top level make.
88 LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(INCLUDES) \
89         $(AM_CPPFLAGS) $(CPPFLAGS) \
90         $(AM_CFLAGS) $(MY_CFLAGS) $(GC_CFLAGS) 
91 LINK = $(LIBTOOL) --mode=link $(CC) $(AM_CFLAGS) $(MY_CFLAGS) $(LDFLAGS) -o $@
92
93 AM_CFLAGS = @GC_CFLAGS@
94
95 # Work around what appears to be a GNU make bug handling MAKEFLAGS
96 # values defined in terms of make variables, as is the case for CC and
97 # friends when we are called from the top level Makefile.
98 AM_MAKEFLAGS = \
99         "AR_FLAGS=$(AR_FLAGS)" \
100         "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
101         "CFLAGS=$(CFLAGS)" \
102         "CXXFLAGS=$(CXXFLAGS)" \
103         "CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
104         "CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \
105         "INSTALL=$(INSTALL)" \
106         "INSTALL_DATA=$(INSTALL_DATA)" \
107         "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
108         "INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \
109         "LDFLAGS=$(LDFLAGS)" \
110         "LIBCFLAGS=$(LIBCFLAGS)" \
111         "LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)" \
112         "MAKE=$(MAKE)" \
113         "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)" \
114         "PICFLAG=$(PICFLAG)" \
115         "PICFLAG_FOR_TARGET=$(PICFLAG_FOR_TARGET)" \
116         "SHELL=$(SHELL)" \
117         "EXPECT=$(EXPECT)" \
118         "RUNTEST=$(RUNTEST)" \
119         "RUNTESTFLAGS=$(RUNTESTFLAGS)" \
120         "exec_prefix=$(exec_prefix)" \
121         "infodir=$(infodir)" \
122         "libdir=$(libdir)" \
123         "prefix=$(prefix)" \
124         "tooldir=$(tooldir)" \
125         "AR=$(AR)" \
126         "AS=$(AS)" \
127         "CC=$(CC)" \
128         "CXX=$(CXX)" \
129         "LD=$(LD)" \
130         "LIBCFLAGS=$(LIBCFLAGS)" \
131         "NM=$(NM)" \
132         "PICFLAG=$(PICFLAG)" \
133         "RANLIB=$(RANLIB)" \
134         "DESTDIR=$(DESTDIR)"
135
136 CONFIG_STATUS_DEPENDENCIES = $(srcdir)/configure.host
137
138 # Multilib support.
139 .PHONY: all-multi mostlyclean-multi clean-multi distclean-multi \
140         maintainer-clean-multi
141
142 all-am: all-multi
143 install-am: install-multi
144 mostlyclean-am: mostlyclean-multi
145 clean-am: clean-multi
146 distclean-am: distclean-multi
147 maintainer-clean-am: maintainer-clean-multi
148
149 all-multi:
150         : $(MAKE) ; exec $(MULTIDO) $(AM_MAKEFLAGS) DO=all multi-do
151 install-multi:
152         $(MULTIDO) $(AM_MAKEFLAGS) DO=install multi-do
153 mostlyclean-multi:
154         $(MULTICLEAN) $(AM_MAKEFLAGS) DO=mostlyclean multi-clean
155 clean-multi:
156         $(MULTICLEAN) $(AM_MAKEFLAGS) DO=clean multi-clean
157 distclean-multi:
158         $(MULTICLEAN) $(AM_MAKEFLAGS) DO=distclean multi-clean
159 maintainer-clean-multi:
160         $(MULTICLEAN) $(AM_MAKEFLAGS) DO=maintainer-clean multi-clean
161
162 MAKEOVERRIDES=