1 AM_CPPFLAGS = -I$(top_srcdir)/include 2 3 EXTRA_DIST = run-ia64-test-dyn1 run-ptrace-mapper run-ptrace-misc \ 4 run-check-namespace run-coredump-unwind \ 5 run-coredump-unwind-mdi check-namespace.sh.in \ 6 Gtest-nomalloc.c 7 8 MAINTAINERCLEANFILES = Makefile.in 9 10 noinst_PROGRAMS_common = 11 check_PROGRAMS_common = test-proc-info test-static-link \ 12 test-strerror 13 check_SCRIPTS_common = run-check-namespace 14 15 if REMOTE_ONLY 16 check_SCRIPTS_cdep = 17 check_PROGRAMS_cdep = 18 noinst_PROGRAMS_cdep = $(noinst_PROGRAMS_common) 19 20 perf: 21 22 else 23 LIBUNWIND_local = $(top_builddir)/src/libunwind.la 24 if ARCH_IA64 25 noinst_PROGRAMS_arch = ia64-test-dyn1 26 check_SCRIPTS_arch = run-ia64-test-dyn1 27 check_PROGRAMS_arch = Gia64-test-stack Lia64-test-stack \ 28 Gia64-test-nat Lia64-test-nat \ 29 Gia64-test-rbs Lia64-test-rbs \ 30 Gia64-test-readonly Lia64-test-readonly \ 31 ia64-test-setjmp ia64-test-sig 32 else #!ARCH_IA64 33 if ARCH_PPC64 34 if USE_ALTIVEC 35 noinst_PROGRAMS_arch = ppc64-test-altivec 36 endif #USE_ALTIVEC 37 endif #ARCH_PPC64 38 endif #!ARCH_IA64 39 check_SCRIPTS_cdep = 40 check_PROGRAMS_cdep = Gtest-bt Ltest-bt Gtest-exc Ltest-exc \ 41 Gtest-init Ltest-init \ 42 Gtest-concurrent Ltest-concurrent \ 43 Gtest-resume-sig Ltest-resume-sig \ 44 Gtest-resume-sig-rt Ltest-resume-sig-rt \ 45 Gtest-dyn1 Ltest-dyn1 \ 46 Gtest-trace Ltest-trace \ 47 test-async-sig test-flush-cache test-init-remote \ 48 test-mem Ltest-varargs Ltest-nomalloc \ 49 Ltest-nocalloc Lrs-race 50 noinst_PROGRAMS_cdep = forker Gperf-simple Lperf-simple \ 51 Gperf-trace Lperf-trace 52 53 if BUILD_PTRACE 54 check_SCRIPTS_cdep += run-ptrace-mapper run-ptrace-misc 55 check_PROGRAMS_cdep += test-ptrace 56 noinst_PROGRAMS_cdep += mapper test-ptrace-misc 57 endif 58 59 if BUILD_SETJMP 60 check_PROGRAMS_cdep += test-setjmp 61 endif 62 63 if SUPPORT_CXX_EXCEPTIONS 64 check_PROGRAMS_cdep += Ltest-cxx-exceptions 65 endif 66 67 if OS_LINUX 68 if BUILD_COREDUMP 69 check_SCRIPTS_cdep += run-coredump-unwind 70 noinst_PROGRAMS_cdep += crasher test-coredump-unwind 71 72 if HAVE_LZMA 73 check_SCRIPTS_cdep += run-coredump-unwind-mdi 74 endif # HAVE_LZMA 75 endif # BUILD_COREDUMP 76 endif # OS_LINUX 77 78 perf: perf-startup Gperf-simple Lperf-simple Lperf-trace 79 @echo "########## Basic performance of generic libunwind:" 80 @./Gperf-simple 81 @echo "########## Basic performance of local-only libunwind:" 82 @./Lperf-simple 83 @echo "########## Performance of fast unwind:" 84 @./Lperf-trace 85 @echo "########## Startup overhead:" 86 @$(srcdir)/perf-startup @arch@ 87 88 endif 89 90 check_PROGRAMS = $(check_PROGRAMS_common) $(check_PROGRAMS_cdep) \ 91 $(check_PROGRAMS_arch) 92 check_SCRIPTS = $(check_SCRIPTS_common) $(check_SCRIPTS_cdep) \ 93 $(check_SCRIPTS_arch) 94 95 96 TESTS = $(check_PROGRAMS) $(check_SCRIPTS) 97 98 if !ARCH_IA64 99 XFAIL_TESTS = Gtest-dyn1 Ltest-dyn1 100 endif 101 102 noinst_PROGRAMS = $(noinst_PROGRAMS_common) $(noinst_PROGRAMS_cdep) \ 103 $(noinst_PROGRAMS_arch) 104 105 Lia64_test_readonly_SOURCES = Lia64-test-readonly.c ia64-test-readonly-asm.S 106 Gia64_test_readonly_SOURCES = Gia64-test-readonly.c ia64-test-readonly-asm.S 107 Lia64_test_stack_SOURCES = Lia64-test-stack.c ia64-test-stack-asm.S \ 108 ia64-test-stack.h 109 Gia64_test_stack_SOURCES = Gia64-test-stack.c ia64-test-stack-asm.S \ 110 ia64-test-stack.h 111 Lia64_test_rbs_SOURCES = Lia64-test-rbs.c ia64-test-rbs-asm.S ia64-test-rbs.h 112 Gia64_test_rbs_SOURCES = Gia64-test-rbs.c ia64-test-rbs-asm.S ia64-test-rbs.h 113 Lia64_test_nat_SOURCES = Lia64-test-nat.c ia64-test-nat-asm.S 114 Gia64_test_nat_SOURCES = Gia64-test-nat.c ia64-test-nat-asm.S 115 ia64_test_dyn1_SOURCES = ia64-test-dyn1.c ia64-dyn-asm.S flush-cache.S \ 116 flush-cache.h 117 ppc64_test_altivec_SOURCES = ppc64-test-altivec.c ppc64-test-altivec-utils.c 118 Gtest_init_SOURCES = Gtest-init.cxx 119 Ltest_init_SOURCES = Ltest-init.cxx 120 Ltest_cxx_exceptions_SOURCES = Ltest-cxx-exceptions.cxx 121 122 Gtest_dyn1_SOURCES = Gtest-dyn1.c flush-cache.S flush-cache.h 123 Ltest_dyn1_SOURCES = Ltest-dyn1.c flush-cache.S flush-cache.h 124 test_static_link_SOURCES = test-static-link-loc.c test-static-link-gen.c 125 test_static_link_LDFLAGS = -static 126 forker_LDFLAGS = -static 127 Gtest_bt_SOURCES = Gtest-bt.c ident.c 128 Ltest_bt_SOURCES = Ltest-bt.c ident.c 129 test_ptrace_misc_SOURCES = test-ptrace-misc.c ident.c 130 Ltest_nomalloc_SOURCES = Ltest-nomalloc.c 131 Ltest_nocalloc_SOURCES = Ltest-nocalloc.c 132 Gtest_trace_SOURCES = Gtest-trace.c ident.c 133 Ltest_trace_SOURCES = Ltest-trace.c ident.c 134 135 LIBUNWIND = $(top_builddir)/src/libunwind-$(arch).la 136 LIBUNWIND_ptrace = $(top_builddir)/src/libunwind-ptrace.la 137 LIBUNWIND_coredump = $(top_builddir)/src/libunwind-coredump.la 138 139 if USE_ELF32 140 LIBUNWIND_ELF = $(top_builddir)/src/libunwind-elf32.la 141 endif 142 if USE_ELF64 143 LIBUNWIND_ELF = $(top_builddir)/src/libunwind-elf64.la 144 endif 145 if USE_ELFXX 146 LIBUNWIND_ELF = $(top_builddir)/src/libunwind-elfxx.la 147 endif 148 149 LIBUNWIND_setjmp = $(top_builddir)/src/libunwind-setjmp.la \ 150 $(LIBUNWIND_ELF) $(LIBUNWIND) 151 152 test_async_sig_LDADD = $(LIBUNWIND_local) -lpthread 153 test_flush_cache_LDADD = $(LIBUNWIND_local) 154 test_init_remote_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) 155 test_mem_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) 156 test_ptrace_LDADD = $(LIBUNWIND_ptrace) $(LIBUNWIND) 157 test_proc_info_LDADD = $(LIBUNWIND) 158 test_static_link_LDADD = $(LIBUNWIND) 159 test_strerror_LDADD = $(LIBUNWIND) 160 Lrs_race_LDADD = $(LIBUNWIND_local) -lpthread 161 Ltest_varargs_LDADD = $(LIBUNWIND_local) 162 163 Gtest_bt_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) 164 Gtest_concurrent_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) -lpthread 165 Gtest_dyn1_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) 166 Gtest_exc_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) 167 Gtest_init_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) 168 Gtest_resume_sig_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) 169 Gtest_resume_sig_rt_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) 170 Gperf_simple_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) 171 Gtest_trace_LDADD=$(LIBUNWIND) $(LIBUNWIND_local) 172 Gperf_trace_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) 173 174 Ltest_bt_LDADD = $(LIBUNWIND_local) 175 Ltest_concurrent_LDADD = $(LIBUNWIND_local) -lpthread 176 Ltest_dyn1_LDADD = $(LIBUNWIND_local) 177 Ltest_exc_LDADD = $(LIBUNWIND_local) 178 Ltest_init_LDADD = $(LIBUNWIND_local) 179 Ltest_nomalloc_LDADD = $(LIBUNWIND_local) @DLLIB@ 180 Ltest_nocalloc_LDADD = $(LIBUNWIND_local) @DLLIB@ -lpthread 181 Ltest_resume_sig_LDADD = $(LIBUNWIND_local) 182 Ltest_resume_sig_rt_LDADD = $(LIBUNWIND_local) 183 Lperf_simple_LDADD = $(LIBUNWIND_local) 184 Ltest_trace_LDADD = $(LIBUNWIND_local) 185 Lperf_trace_LDADD = $(LIBUNWIND_local) 186 187 test_setjmp_LDADD = $(LIBUNWIND_setjmp) 188 ia64_test_setjmp_LDADD = $(LIBUNWIND_setjmp) 189 190 if BUILD_COREDUMP 191 test_coredump_unwind_LDADD = $(LIBUNWIND_coredump) $(LIBUNWIND) 192 endif 193 194 Gia64_test_nat_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) 195 Gia64_test_stack_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) 196 Gia64_test_rbs_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) 197 Gia64_test_readonly_LDADD = $(LIBUNWIND) $(LIBUNWIND_local) 198 Lia64_test_nat_LDADD = $(LIBUNWIND_local) 199 Lia64_test_stack_LDADD = $(LIBUNWIND_local) 200 Lia64_test_rbs_LDADD = $(LIBUNWIND_local) 201 Lia64_test_readonly_LDADD = $(LIBUNWIND_local) 202 ia64_test_dyn1_LDADD = $(LIBUNWIND) 203 ia64_test_sig_LDADD = $(LIBUNWIND) 204