forked from Percona-Lab/patchelf-packaging
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpatchelf.spec
51 lines (42 loc) · 1.14 KB
/
patchelf.spec
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
Summary: A utility for patching ELF binaries
Name: patchelf
Version: @PACKAGE_VERSION@
Release: @RPM_RELEASE@%{?dist}
Epoch: 1
License: GPL
Group: Development/Tools
URL: http://nixos.org/patchelf.html
Source0: %{name}-%{version}.tar.gz
Patch0: increase_size_to_work_with_debug_binaries.patch
Patch1: mark_phdrs_synced_with_sections.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-buildroot
Prefix: /usr
%description
PatchELF is a simple utility for modifing existing ELF executables and
libraries. It can change the dynamic loader ("ELF interpreter") of
executables and change the RPATH of executables and libraries.
%prep
%setup -q
%patch0 -p1
%patch1 -p1
%build
%if 0%{?rhel} == 6
sed -i "s: serial-tests::g" configure.ac
%endif
./bootstrap.sh
./configure --prefix=%{_prefix}
make
make check
%install
rm -rf $RPM_BUILD_ROOT
make DESTDIR=$RPM_BUILD_ROOT install
# rpmbuild automatically strips... strip $RPM_BUILD_ROOT/%%{_bindir}/* || true
%clean
rm -rf $RPM_BUILD_ROOT
%files
%{_bindir}/patchelf
%doc %{_docdir}/patchelf/README.md
%{_mandir}/man1/patchelf.1.gz
%changelog
* Wed May 27 2020 Illia Pshonkin <illia.pshonkin@percona.com>
- Packaging for 0.10