Репозиторий Sisyphus
Последнее обновление: 18 сентября 2019 | Пакетов: 17444 | Посещений: 15116301
en ru br
Репозитории ALT
S:5.2-alt1
5.1: 4.5.19-alt2
4.1: 4.5.16-alt5
4.0: 4.5.16-alt4
3.0: 4.5.12-alt3
+updates:4.5.13-alt2
www.altlinux.org/Changes

Группа :: Разработка/Отладчики
Пакет: strace

 Главная   Изменения   Спек   Патчи   Sources   Загрузить   Gear   Bugs and FR  Repocop 

Name: strace
Version: 5.1
Release: alt1

Summary: Tracks and displays system calls associated with a running process
# The test suite is GPLv2+, all the rest is LGPLv2.1+.
License: LGPL-2.1-or-later and GPL-2.0-or-later
Group: Development/Debuggers
Url: https://strace.io

# http://git.altlinux.org/gears/s/strace.git

Source: %name-%version-%release.tar

# due to use of deprecated -k option

Conflicts: rpm-utils <= 0:0.9.11-alt1

# for -k option

BuildRequires: libdw-devel binutils-devel
# for test suite
%{?!_without_check:%{?!_disable_check:BuildRequires: /proc}}

# The default is --enable-mpers=yes, but

# some architectures may need --enable-mpers=check instead.
%define mpers_check %nil
%define architectures_need_mpers_check aarch64
%ifarch %architectures_need_mpers_check
%define mpers_check --enable-mpers=check
%endif

%package utils
Summary: Processes strace output and displays a graph of invoked subprocesses
Group: Development/Debuggers
BuildArch: noarch
Requires: %name = %version-%release

%description
The strace program intercepts and records the system calls called and
the signals received by a running process.  strace can print a record of
each system call, its arguments and its return value.  strace is useful
for diagnosing problems and debugging, as well as for instructional
purposes.

%description utils
The strace-graph Perl script processes strace -f output and displays
a graph of invoked subprocesses.  It is useful for finding out what
complex commands do.

%prep
%setup -n %name-%version-%release
echo -n %version-%release > .tarball-version
echo -n 2019 > .year
date +%%Y-%%m-%%d > .strace.1.in.date

%build
echo 'BEGIN OF BUILD ENVIRONMENT INFORMATION'
uname -a |head -1
libc="$(ldd /bin/sh |sed -n 's|^[^/]*\(/[^ ]*/libc\.so[^ ]*\).*|\1|p' |head -1)"
$libc |head -1
file -L /bin/sh
gcc --version |head -1
ld --version |head -1
kver="$(printf '%%s\n%%s\n' '#include <linux/version.h>' 'LINUX_VERSION_CODE' | gcc -E -P -)"
printf 'kernel-headers %%s.%%s.%%s\n' $(($kver/65536)) $(($kver/256%%256)) $(($kver%%256))
echo 'END OF BUILD ENVIRONMENT INFORMATION'

./bootstrap -sv
mkdir build
cd build
%define _configure_script ../configure
CFLAGS_FOR_BUILD="$RPM_OPT_FLAGS"; export CFLAGS_FOR_BUILD
%configure --enable-gcc-Werror %mpers_check #--enable-maintainer-mode
%make_build

%install
%makeinstall_std -C build
%set_verify_elf_method strict

%check
%buildroot%_bindir/strace -V
export SLEEP_A_BIT='sleep 0.5' VERBOSE=1
%make_build -k check -C build VERBOSE=1

echo 'BEGIN OF TEST SUITE INFORMATION'
tail -n 99999 -- build/tests*/test-suite*.log build/tests*/ksysent.log
find build/tests* -type f -name '*.log' -print0 |
xargs -r0 grep -H '^KERNEL BUG:' -- ||:
echo 'END OF TEST SUITE INFORMATION'

%files
%_bindir/strace
%_bindir/strace-log-merge
%_mandir/man?/*
%doc COPYING CREDITS NEWS README README-linux-ptrace

%files utils
%_bindir/strace-graph

%changelog

Полный changelog можно просмотреть здесь

 
дизайн и разработка: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
текущий майнтейнер: Michael Shigorin