libunwind/libunwind.spec
2019-09-30 10:58:37 -04:00

103 lines
3.0 KiB
RPMSpec

Name: libunwind
Version: 1.3.1
Release: 2
Summary: Libunwind provides a C ABI to determine the call-chain of a program
License: BSD
URL: http://savannah.nongnu.org/projects/libunwind
Source: http://download-mirror.savannah.gnu.org/releases/libunwind/libunwind-%{version}.tar.gz
Patch1: libunwind-arm-default-to-exidx.patch
Patch6000: Don-t-check-if-the-memory-is-in-core-64.patch
Patch6001: dwarf-do-not-allocate-in-load_debug_frame-72.patch
Patch6002: Cleanup-remove-unused-variable.patch
Patch6003: Fix-race-conditions-in-validate_mem-via-atomics.patch
Patch6004: Optionally-use-a-thread-local-cache-for-valid-memory.patch
Patch6005: Also-define-NLGA-when-we-build-with-atomic-ops-80.patch
Patch6006: aarch-v2-aarch64-PLT-entry-recognition-fixes-86.patch
Patch6007: dwarf-Add-missing-opcodes-to-the-operands-table-in-G.patch
Patch6008: dwarf-Push-correct-CFA-onto-stack-for-dwarf-expressi.patch
ExclusiveArch: aarch64 %{ix86} x86_64
BuildRequires: automake libtool autoconf texlive-latex2man
%description
Libunwind defines a portable and efficient C programming interface (API) to
determine the call-chain of a program. The API additionally provides the means
to manipulate the preserved (callee-saved) state of each call-frame and to
resume execution at any point in the call-chain (non-local goto). The API
supports both local (same-process) and remote (across-process) operation.
%package devel
Summary: Development files for libunwind
Requires: libunwind = %{version}-%{release}
%description devel
This package contains development files for libunwind.
%package_help
%prep
%autosetup -n %{name}-%{version} -p1
%build
aclocal
libtoolize --force
autoheader
automake --add-missing
autoconf
%configure --enable-static --enable-shared --enable-setjmp=no
%make_build
%install
%make_install
%delete_la
# /usr/include/libunwind-ptrace.h
# [...] aren't really part of the libunwind API. They are implemented in
# a archive library called libunwind-ptrace.a.
mv -f $RPM_BUILD_ROOT%{_libdir}/libunwind-ptrace.a $RPM_BUILD_ROOT%{_libdir}/libunwind-ptrace.a-save
rm -f $RPM_BUILD_ROOT%{_libdir}/libunwind*.a
mv -f $RPM_BUILD_ROOT%{_libdir}/libunwind-ptrace.a-save $RPM_BUILD_ROOT%{_libdir}/libunwind-ptrace.a
rm -f $RPM_BUILD_ROOT%{_libdir}/libunwind-ptrace*.so*
# fix multilib conflicts
touch -r NEWS $RPM_BUILD_ROOT%{_includedir}/libunwind.h
%check
#make check may wrong
make check || true
%pre
%preun
%ldconfig_scriptlets
%files
%defattr(-,root,root)
%license COPYING
%{_libdir}/libunwind*.so.*
%files devel
%defattr(-,root,root)
%{_libdir}/pkgconfig/libunwind*.pc
# <unwind.h> does not get installed for REMOTE_ONLY targets - check it.
%{_includedir}/unwind.h
%{_includedir}/libunwind*.h
%{_libdir}/libunwind-ptrace.a
%{_libdir}/libunwind*.so
%files help
%defattr(-,root,root)
%doc README NEWS
%{_mandir}/*/*
%changelog
* Fri Sep 27 2019 openEuler Buildteam <buildteam@openeuler.org> - 1.3.1-2
- del unnecessary statement
* Mon Sep 2 2019 openEuler Buildteam <buildteam@openeuler.org> - 1.3.1-1
- Package init