Compare commits

..

No commits in common. "master" and "f26" have entirely different histories.
master ... f26

3 changed files with 57 additions and 103 deletions

2
.gitignore vendored
View File

@ -1 +1 @@
/strace-5.10.tar.xz
/strace-4.22.tar.xz

View File

@ -1 +1 @@
SHA512 (strace-5.10.tar.xz) = 1baa41b6d52f2e40e42a22850beee1ae278fafe712796694631898f06a7540d8f2c3fa70807e0062734f0976ebbd0824457c733ccda248f017c218387366ed48
SHA512 (strace-4.22.tar.xz) = 624c3f27921b6df2eb8ff409a35fa9153c4571cd5f703e6cac18f024bccd5ff4acb81f88ca33f81d1046d9718dec7b2705e8940e80bb8447ec3e62a6fd5f8350

View File

@ -1,49 +1,24 @@
Summary: Tracks and displays system calls associated with a running process
Name: strace
Version: 5.10
Version: 4.22
Release: 1%{?dist}
# The test suite is GPLv2+, all the rest is LGPLv2.1+.
License: LGPL-2.1+ and GPL-2.0+
# Some distros require Group tag to be present,
# some require Group tag to be absent,
# some do not care about Group tag at all,
# and we have to cater for all of them.
%if 0%{?fedora} < 28 && 0%{?centos} < 8 && 0%{?rhel} < 8 && 0%{?suse_version} < 1500
Group: Development%{?suse_version:/Tools}/Debuggers
%endif
License: BSD
Group: Development/Debuggers
URL: https://strace.io
%if 0%{?fedora} >= 12 || 0%{?centos} >= 6 || 0%{?rhel} >= 6 || 0%{?suse_version} >= 1200
Source: https://strace.io/files/%{version}/strace-%{version}.tar.xz
BuildRequires: xz
%else
Source: strace-%{version}.tar.gz
%endif
BuildRequires: gcc gzip
# Install Bluetooth headers for AF_BLUETOOTH sockets decoding.
%if 0%{?fedora} >= 18 || 0%{?centos} >= 6 || 0%{?rhel} >= 8 || 0%{?suse_version} >= 1200
BuildRequires: gcc
%if 0%{?fedora} >= 18 || 0%{?centos} >= 8 || 0%{?rhel} >= 8 || 0%{?suse_version} >= 1200
BuildRequires: pkgconfig(bluez)
%endif
# Install elfutils-devel or libdw-devel to enable strace -k option.
# Install binutils-devel to enable symbol demangling.
%if 0%{?fedora} >= 20 || 0%{?centos} >= 6 || 0%{?rhel} >= 6
%define buildrequires_stacktrace BuildRequires: elfutils-devel binutils-devel
%if 0%{?fedora} >= 20 || 0%{?centos} >= 8 || 0%{?rhel} >= 8 || 0%{?suse_version} >= 1300
%define buildrequires_libunwind_devel BuildRequires: libunwind-devel binutils-devel
%endif
%if 0%{?suse_version} >= 1100
%define buildrequires_stacktrace BuildRequires: libdw-devel binutils-devel
%ifarch x86_64
# for experimental -k option
%{?buildrequires_libunwind_devel}
%endif
%{?buildrequires_stacktrace}
# OBS compatibility
%define strace64_arches ppc64 sparc64
%{?!buildroot:BuildRoot: %_tmppath/buildroot-%name-%version-%release}
%define maybe_use_defattr %{?suse_version:%%defattr(-,root,root)}
# Fallback definitions for make_build/make_install macros
%{?!__make: %global __make %_bindir/make}
%{?!__install: %global __install %_bindir/install}
%{?!make_build: %global make_build %__make %{?_smp_mflags}}
%{?!make_install: %global make_install %__make install DESTDIR="%{?buildroot}" INSTALL="%__install -p"}
%description
The strace program intercepts and records the system calls called and
@ -55,11 +30,30 @@ purposes.
Install strace if you need a tool to track the system calls made and
received by a process.
%ifarch %{strace64_arches}
%package -n strace64
Summary: Tracks and displays system calls associated with a running process.
Group: Development/Debuggers
%description -n strace64
The strace program intercepts and records the system calls called and
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.
Install strace if you need a tool to track the system calls made and
received by a process.
This package provides the `strace64' program to trace 64-bit processes.
The `strace' program in the `strace' package is for 32-bit processes.
%endif
%prep
%setup -q
echo -n %version-%release > .tarball-version
echo -n 2020 > .year
echo -n 2020-11-29 > .strace.1.in.date
echo -n 2018 > .year
echo -n 2018-04-04 > .strace.1.in.date
%build
echo 'BEGIN OF BUILD ENVIRONMENT INFORMATION'
@ -68,91 +62,51 @@ 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 -)"
kver="$(echo -e '#include <linux/version.h>\nLINUX_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'
CFLAGS_FOR_BUILD="$RPM_OPT_FLAGS"; export CFLAGS_FOR_BUILD
%configure --enable-mpers=check
%make_build
make %{?_smp_mflags}
%install
%make_install
make DESTDIR=%{buildroot} install
# remove unpackaged files from the buildroot
rm -f %{buildroot}%{_bindir}/strace-graph
# some say uncompressed changelog files are too big
for f in ChangeLog ChangeLog-CVS; do
gzip -9n < "$f" > "$f".gz &
done
wait
%define copy64 ln
%if 0%{?rhel}
%if 0%{?rhel} < 6
%endif
%define copy64 cp -p
%endif
%ifarch %{strace64_arches}
%{copy64} %{buildroot}%{_bindir}/strace %{buildroot}%{_bindir}/strace64
%endif
%check
%{buildroot}%{_bindir}/strace -V
%make_build -k check VERBOSE=1
make %{?_smp_mflags} -k check VERBOSE=1
echo 'BEGIN OF TEST SUITE INFORMATION'
tail -n 99999 -- tests*/test-suite.log tests*/ksysent.gen.log
find tests* -type f -name '*.log' -print0 |
xargs -r0 grep -H '^KERNEL BUG:' -- ||:
tail -n 99999 -- tests*/test-suite.log tests*/ksysent.log
echo 'END OF TEST SUITE INFORMATION'
%files
%maybe_use_defattr
%doc CREDITS ChangeLog.gz ChangeLog-CVS.gz COPYING NEWS README
%{?suse_version:%defattr(-,root,root)}
%doc CREDITS ChangeLog ChangeLog-CVS COPYING NEWS README
%{_bindir}/strace
%{_bindir}/strace-log-merge
%{_mandir}/man1/*
%ifarch %{strace64_arches}
%files -n strace64
%{?suse_version:%defattr(-,root,root)}
%{_bindir}/strace64
%endif
%changelog
* Mon Dec 14 2020 Dmitry V. Levin <ldv@altlinux.org> - 5.10-1
- v5.9 -> v5.10.
* Thu Sep 24 2020 Dmitry V. Levin <ldv@altlinux.org> - 5.9-1
- v5.8 -> v5.9.
* Thu Aug 06 2020 Dmitry V. Levin <ldv@altlinux.org> - 5.8-1
- v5.7 -> v5.8.
* Mon Jun 01 2020 Dmitry V. Levin <ldv@altlinux.org> - 5.7-1
- v5.6 -> v5.7.
* Tue Apr 07 2020 Dmitry V. Levin <ldv@altlinux.org> - 5.6-1
- v5.5 -> v5.6.
* Thu Feb 06 2020 Dmitry V. Levin <ldv@altlinux.org> - 5.5-1
- v5.4 -> v5.5.
* Thu Nov 28 2019 Dmitry V. Levin <ldv@altlinux.org> - 5.4-1
- v5.3 -> v5.4.
* Wed Sep 25 2019 Dmitry V. Levin <ldv@altlinux.org> - 5.3-1
- v5.2 -> v5.3.
* Fri Jul 12 2019 Dmitry V. Levin <ldv@altlinux.org> - 5.2-1
- v5.1 -> v5.2.
* Wed May 22 2019 Dmitry V. Levin <ldv@altlinux.org> - 5.1-1
- v5.0 -> v5.1.
* Tue Mar 19 2019 Dmitry V. Levin <ldv@altlinux.org> - 5.0-1
- v4.26 -> v5.0 (resolves: #478419, #526740, #851457, #1609318,
#1610774, #1662936, #1676045).
* Wed Dec 26 2018 Dmitry V. Levin <ldv@altlinux.org> - 4.26-1
- v4.25 -> v4.26.
* Tue Oct 30 2018 Dmitry V. Levin <ldv@altlinux.org> - 4.25-1
- v4.24 -> v4.25.
* Tue Aug 14 2018 Dmitry V. Levin <ldv@altlinux.org> - 4.24-1
- v4.23 -> v4.24.
* Thu Jun 14 2018 Dmitry V. Levin <ldv@altlinux.org> - 4.23-1
- v4.22 -> v4.23.
- Enabled libdw backend for -k option (#1568647).
* Thu Apr 05 2018 Dmitry V. Levin <ldv@altlinux.org> - 4.22-1
- v4.21 -> v4.22.