# Flags to use when compiling test programs.
libbacktrace_TEST_CFLAGS = $(EXTRA_FLAGS) $(WARN_FLAGS) -g
-if HAVE_DSYMUTIL
+if USE_DSYMUTIL
%.dSYM: %
$(DSYMUTIL) $<
-endif HAVE_DSYMUTIL
+endif USE_DSYMUTIL
if NATIVE
check_LTLIBRARIES = libbacktrace_alloc.la
TESTS += allocfail.sh
-if HAVE_DSYMUTIL
+if USE_DSYMUTIL
check_DATA += allocfail.dSYM
-endif HAVE_DSYMUTIL
+endif USE_DSYMUTIL
if HAVE_ELF
if HAVE_OBJCOPY_DEBUGLINK
BUILDTESTS += btest
-if HAVE_DSYMUTIL
+if USE_DSYMUTIL
check_DATA += btest.dSYM
-endif HAVE_DSYMUTIL
+endif USE_DSYMUTIL
if HAVE_ELF
BUILDTESTS += btest_alloc
-if HAVE_DSYMUTIL
+if USE_DSYMUTIL
check_DATA += btest_alloc.dSYM
-endif HAVE_DSYMUTIL
+endif USE_DSYMUTIL
if HAVE_DWZ
BUILDTESTS += stest
-if HAVE_DSYMUTIL
+if USE_DSYMUTIL
check_DATA += stest.dSYM
-endif HAVE_DSYMUTIL
+endif USE_DSYMUTIL
stest_alloc_SOURCES = $(stest_SOURCES)
stest_alloc_CFLAGS = $(libbacktrace_TEST_CFLAGS)
BUILDTESTS += stest_alloc
-if HAVE_DSYMUTIL
+if USE_DSYMUTIL
check_DATA += stest_alloc.dSYM
-endif HAVE_DSYMUTIL
+endif USE_DSYMUTIL
if HAVE_ELF
BUILDTESTS += edtest
-if HAVE_DSYMUTIL
+if USE_DSYMUTIL
check_DATA += edtest.dSYM
-endif HAVE_DSYMUTIL
+endif USE_DSYMUTIL
edtest_alloc_SOURCES = $(edtest_SOURCES)
edtest_alloc_CFLAGS = $(libbacktrace_TEST_CFLAGS)
edtest_alloc_LDADD = libbacktrace_alloc.la
-if HAVE_DSYMUTIL
+if USE_DSYMUTIL
check_DATA += edtest_alloc.dSYM
-endif HAVE_DSYMUTIL
+endif USE_DSYMUTIL
BUILDTESTS += edtest_alloc
ttest_CFLAGS = $(libbacktrace_TEST_CFLAGS) -pthread
ttest_LDADD = libbacktrace.la
-if HAVE_DSYMUTIL
+if USE_DSYMUTIL
check_DATA += ttest.dSYM
-endif HAVE_DSYMUTIL
+endif USE_DSYMUTIL
BUILDTESTS += ttest_alloc
ttest_alloc_CFLAGS = $(ttest_CFLAGS)
ttest_alloc_LDADD = libbacktrace_alloc.la
-if HAVE_DSYMUTIL
+if USE_DSYMUTIL
check_DATA += ttest_alloc.dSYM
-endif HAVE_DSYMUTIL
+endif USE_DSYMUTIL
endif HAVE_PTHREAD
BUILDTESTS += dwarf5
-if HAVE_DSYMUTIL
+if USE_DSYMUTIL
check_DATA += dwarf5.dSYM
-endif HAVE_DSYMUTIL
+endif USE_DSYMUTIL
dwarf5_alloc_SOURCES = $(dwarf5_SOURCES)
dwarf5_alloc_CFLAGS = $(dwarf5_CFLAGS)
BUILDTESTS += dwarf5_alloc
-if HAVE_DSYMUTIL
+if USE_DSYMUTIL
check_DATA += dwarf5_alloc.dSYM
-endif HAVE_DSYMUTIL
+endif USE_DSYMUTIL
endif
@NATIVE_TRUE@ test_unknown unittest unittest_alloc btest
@NATIVE_TRUE@am__append_3 = allocfail
@NATIVE_TRUE@am__append_4 = allocfail.sh
-@HAVE_DSYMUTIL_TRUE@@NATIVE_TRUE@am__append_5 = allocfail.dSYM \
-@HAVE_DSYMUTIL_TRUE@@NATIVE_TRUE@ btest.dSYM btest_alloc.dSYM \
-@HAVE_DSYMUTIL_TRUE@@NATIVE_TRUE@ stest.dSYM stest_alloc.dSYM \
-@HAVE_DSYMUTIL_TRUE@@NATIVE_TRUE@ edtest.dSYM edtest_alloc.dSYM
+@NATIVE_TRUE@@USE_DSYMUTIL_TRUE@am__append_5 = allocfail.dSYM \
+@NATIVE_TRUE@@USE_DSYMUTIL_TRUE@ btest.dSYM btest_alloc.dSYM \
+@NATIVE_TRUE@@USE_DSYMUTIL_TRUE@ stest.dSYM stest_alloc.dSYM \
+@NATIVE_TRUE@@USE_DSYMUTIL_TRUE@ edtest.dSYM edtest_alloc.dSYM
@HAVE_ELF_TRUE@@HAVE_OBJCOPY_DEBUGLINK_TRUE@@NATIVE_TRUE@am__append_6 = b2test
@HAVE_ELF_TRUE@@HAVE_OBJCOPY_DEBUGLINK_TRUE@@NATIVE_TRUE@am__append_7 = b2test_buildid
@HAVE_DWZ_TRUE@@HAVE_ELF_TRUE@@HAVE_OBJCOPY_DEBUGLINK_TRUE@@NATIVE_TRUE@am__append_8 = b3test
@HAVE_ELF_TRUE@@NATIVE_TRUE@am__append_16 = ztest ztest_alloc
@NATIVE_TRUE@am__append_17 = edtest edtest_alloc
@HAVE_PTHREAD_TRUE@@NATIVE_TRUE@am__append_18 = ttest ttest_alloc
-@HAVE_DSYMUTIL_TRUE@@HAVE_PTHREAD_TRUE@@NATIVE_TRUE@am__append_19 = ttest.dSYM \
-@HAVE_DSYMUTIL_TRUE@@HAVE_PTHREAD_TRUE@@NATIVE_TRUE@ ttest_alloc.dSYM
+@HAVE_PTHREAD_TRUE@@NATIVE_TRUE@@USE_DSYMUTIL_TRUE@am__append_19 = \
+@HAVE_PTHREAD_TRUE@@NATIVE_TRUE@@USE_DSYMUTIL_TRUE@ ttest.dSYM \
+@HAVE_PTHREAD_TRUE@@NATIVE_TRUE@@USE_DSYMUTIL_TRUE@ ttest_alloc.dSYM
@HAVE_OBJCOPY_DEBUGLINK_TRUE@@NATIVE_TRUE@am__append_20 = btest_gnudebuglink
@HAVE_COMPRESSED_DEBUG_TRUE@@NATIVE_TRUE@am__append_21 = ctestg ctesta \
@HAVE_COMPRESSED_DEBUG_TRUE@@NATIVE_TRUE@ ctestg_alloc \
@HAVE_COMPRESSED_DEBUG_TRUE@@NATIVE_TRUE@ ctesta_alloc
@HAVE_DWARF5_TRUE@@NATIVE_TRUE@am__append_22 = dwarf5 dwarf5_alloc
-@HAVE_DSYMUTIL_TRUE@@HAVE_DWARF5_TRUE@@NATIVE_TRUE@am__append_23 = dwarf5.dSYM \
-@HAVE_DSYMUTIL_TRUE@@HAVE_DWARF5_TRUE@@NATIVE_TRUE@ dwarf5_alloc.dSYM
+@HAVE_DWARF5_TRUE@@NATIVE_TRUE@@USE_DSYMUTIL_TRUE@am__append_23 = \
+@HAVE_DWARF5_TRUE@@NATIVE_TRUE@@USE_DSYMUTIL_TRUE@ dwarf5.dSYM \
+@HAVE_DWARF5_TRUE@@NATIVE_TRUE@@USE_DSYMUTIL_TRUE@ dwarf5_alloc.dSYM
@NATIVE_TRUE@am__append_24 = mtest
@HAVE_MINIDEBUG_TRUE@@NATIVE_TRUE@am__append_25 = mtest_minidebug
@HAVE_ELF_TRUE@@HAVE_LIBLZMA_TRUE@am__append_26 = -llzma
.PRECIOUS: Makefile
-@HAVE_DSYMUTIL_TRUE@%.dSYM: %
-@HAVE_DSYMUTIL_TRUE@ $(DSYMUTIL) $<
+@USE_DSYMUTIL_TRUE@%.dSYM: %
+@USE_DSYMUTIL_TRUE@ $(DSYMUTIL) $<
@HAVE_ELF_TRUE@@HAVE_OBJCOPY_DEBUGLINK_TRUE@@NATIVE_TRUE@elf_for_test.c: elf.c
@HAVE_ELF_TRUE@@HAVE_OBJCOPY_DEBUGLINK_TRUE@@NATIVE_TRUE@ SEARCH='^#define SYSTEM_BUILD_ID_DIR.*$$'; \
HAVE_XZ_FALSE
HAVE_XZ_TRUE
XZ
-HAVE_DSYMUTIL_FALSE
-HAVE_DSYMUTIL_TRUE
+USE_DSYMUTIL_FALSE
+USE_DSYMUTIL_TRUE
HAVE_OBJCOPY_DEBUGLINK_FALSE
HAVE_OBJCOPY_DEBUGLINK_TRUE
READELF
fi
- if test -n "${DSYMUTIL}"; then
- HAVE_DSYMUTIL_TRUE=
- HAVE_DSYMUTIL_FALSE='#'
+ if test -n "${DSYMUTIL}" -a "$FORMAT_FILE" = "macho.lo"; then
+ USE_DSYMUTIL_TRUE=
+ USE_DSYMUTIL_FALSE='#'
else
- HAVE_DSYMUTIL_TRUE='#'
- HAVE_DSYMUTIL_FALSE=
+ USE_DSYMUTIL_TRUE='#'
+ USE_DSYMUTIL_FALSE=
fi
as_fn_error $? "conditional \"HAVE_OBJCOPY_DEBUGLINK\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5
fi
-if test -z "${HAVE_DSYMUTIL_TRUE}" && test -z "${HAVE_DSYMUTIL_FALSE}"; then
- as_fn_error $? "conditional \"HAVE_DSYMUTIL\" was never defined.
+if test -z "${USE_DSYMUTIL_TRUE}" && test -z "${USE_DSYMUTIL_FALSE}"; then
+ as_fn_error $? "conditional \"USE_DSYMUTIL\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5
fi
if test -z "${HAVE_XZ_TRUE}" && test -z "${HAVE_XZ_FALSE}"; then
AC_ARG_VAR(DSYMUTIL, [location of dsymutil])
AC_CHECK_PROG(DSYMUTIL, dsymutil, dsymutil)
-AM_CONDITIONAL(HAVE_DSYMUTIL, test -n "${DSYMUTIL}")
+AM_CONDITIONAL(USE_DSYMUTIL, test -n "${DSYMUTIL}" -a "$FORMAT_FILE" = "macho.lo")
AC_ARG_VAR(NM, [location of nm])
AC_CHECK_PROG(NM, nm, nm)