2013-06-06 01:53:30 +02:00
|
|
|
################################################################################
|
2002-05-23 21:21:23 +02:00
|
|
|
#
|
|
|
|
# strace
|
|
|
|
#
|
2013-06-06 01:53:30 +02:00
|
|
|
################################################################################
|
2002-05-23 21:21:23 +02:00
|
|
|
|
2019-04-30 17:49:39 +02:00
|
|
|
STRACE_VERSION = 5.0
|
2012-09-28 00:43:16 +02:00
|
|
|
STRACE_SOURCE = strace-$(STRACE_VERSION).tar.xz
|
2018-03-25 20:40:39 +02:00
|
|
|
STRACE_SITE = https://strace.io/files/$(STRACE_VERSION)
|
2019-01-04 16:46:27 +01:00
|
|
|
STRACE_LICENSE = LGPL-2.1+
|
|
|
|
STRACE_LICENSE_FILES = COPYING LGPL-2.1-or-later
|
2018-03-25 20:40:39 +02:00
|
|
|
STRACE_CONF_OPTS = --enable-mpers=check
|
2016-11-12 16:30:12 +01:00
|
|
|
|
2018-05-10 17:42:12 +02:00
|
|
|
# strace bundle some kernel headers to build libmpers, this mixes userspace
|
|
|
|
# headers and kernel headers which break the build with musl.
|
|
|
|
# The stddef.h from gcc is used instead of the one from musl.
|
|
|
|
ifeq ($(BR2_TOOLCHAIN_USES_MUSL),y)
|
|
|
|
STRACE_CONF_OPTS += st_cv_m32_mpers=no \
|
|
|
|
st_cv_mx32_mpers=no
|
|
|
|
endif
|
|
|
|
|
2018-02-25 19:34:14 +01:00
|
|
|
ifeq ($(BR2_PACKAGE_LIBUNWIND),y)
|
|
|
|
STRACE_DEPENDENCIES += libunwind
|
|
|
|
STRACE_CONF_OPTS += --with-libunwind
|
|
|
|
else
|
|
|
|
STRACE_CONF_OPTS += --without-libunwind
|
|
|
|
endif
|
|
|
|
|
2018-02-25 19:34:15 +01:00
|
|
|
# Demangling symbols in stack trace needs libunwind and libiberty.
|
|
|
|
ifeq ($(BR2_PACKAGE_BINUTILS)$(BR2_PACKAGE_LIBUNWIND),yy)
|
|
|
|
STRACE_DEPENDENCIES += binutils
|
|
|
|
STRACE_CONF_OPTS += --with-libiberty=check
|
|
|
|
else
|
|
|
|
STRACE_CONF_OPTS += --without-libiberty
|
|
|
|
endif
|
|
|
|
|
2018-11-27 11:16:56 +01:00
|
|
|
ifeq ($(BR2_PACKAGE_PERL),)
|
2010-09-02 00:16:19 +02:00
|
|
|
define STRACE_REMOVE_STRACE_GRAPH
|
2008-08-04 21:07:41 +02:00
|
|
|
rm -f $(TARGET_DIR)/usr/bin/strace-graph
|
2010-09-02 00:16:19 +02:00
|
|
|
endef
|
|
|
|
|
|
|
|
STRACE_POST_INSTALL_TARGET_HOOKS += STRACE_REMOVE_STRACE_GRAPH
|
2018-11-27 11:16:56 +01:00
|
|
|
endif
|
2010-09-02 00:16:19 +02:00
|
|
|
|
2012-07-03 00:07:32 +02:00
|
|
|
$(eval $(autotools-package))
|