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