]> git.pld-linux.org Git - packages/elfutils.git/blame - elfutils.spec
- disable backtrace-native-biarch test on x32:
[packages/elfutils.git] / elfutils.spec
CommitLineData
fb301307
JB
1#
2# Conditional build:
0f22fc8f 3%bcond_without tests # do not perform tests
fb301307 4#
7f09d52f 5Summary: A collection of utilities and DSOs to handle compiled objects
cc5b5c39 6Summary(pl.UTF-8): Zestaw narzędzi i bibliotek do obsługi skompilowanych obiektów
d5753979 7Name: elfutils
6d3fd36e
JB
8Version: 0.164
9Release: 1
3a5346c9 10License: GPL v2+ or LGPL v3+ (libraries), GPL v3+ (programs)
d5753979 11Group: Development/Tools
b68ac3ec 12Source0: https://fedorahosted.org/releases/e/l/elfutils/%{version}/%{name}-%{version}.tar.bz2
6d3fd36e 13# Source0-md5: 2e4536c1c48034f188a80789a59114d8
b1ad9ed4 14Patch0: %{name}-pl.po.patch
0937133b 15Patch1: %{name}-debian-manpages.patch
6d3fd36e 16Patch2: %{name}-awk.patch
df444565
JB
17Patch3: %{name}-align.patch
18Patch4: %{name}-paxflags.patch
19Patch5: %{name}-sparc.patch
20Patch6: %{name}-inline.patch
103cc6fb 21Patch7: %{name}-maps.patch
47d694b2 22URL: https://fedorahosted.org/elfutils/
61d61d68
JB
23BuildRequires: autoconf >= 2.63
24BuildRequires: automake >= 1:1.8
6d3fd36e
JB
25BuildRequires: gawk
26BuildRequires: gcc >= 6:4.3
9fb2ee6f 27BuildRequires: gettext-tools
6d3fd36e 28BuildRequires: glibc-devel >= 6:2.7
0937133b 29BuildRequires: perl-tools-pod
21429b83 30BuildRequires: rpmbuild(macros) >= 1.315
b1ad9ed4 31BuildRequires: sharutils
4a8c3342
JB
32%if %{with tests} && %(test -d /proc/self ; echo $?)
33# native test needs proc (for libdwfl -p PID to work)
34BuildRequires: MOUNTED_PROC
35%endif
fb301307 36Requires: %{name}-libelf = %{version}-%{release}
7f09d52f 37BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
ecbc8f89 38
dea0813b 39# fails to build with -Wl,-s
40%define filterout_ld (-Wl,)?-[sS] (-Wl,)?--strip.*
61d61d68
JB
41%if %{with tests} && 0%(echo %{rpmcflags} | grep -q '\<-g' ; echo $?)
42# tests require debug symbols
43%define specflags -g
44%endif
dea0813b 45
82cf832a 46%define programprefix eu-
ecbc8f89
AF
47
48%description
d5753979
AF
49Elfutils is a collection of utilities, including ld (a linker), nm
50(for listing symbols from object files), size (for listing the section
51sizes of an object or archive file), strip (for discarding symbols),
52readline (the see the raw ELF file structures), and elflint (to check
53for well-formed ELF files). Also included are numerous helper
54libraries which implement DWARF, ELF, and machine-specific ELF
ecbc8f89
AF
55handling.
56
13991385
JR
57%description -l pl.UTF-8
58Elfutils to zestaw narzędzi, składający się z ld (linkera), nm (do
59listowania symboli z plików obiektów), size (do listowania rozmiarów
60sekcji plików obiektów lub archiwów), strip (do usuwania symboli),
61readline (do oglądania surowych struktur plików ELF) oraz elflint (do
62sprawdzania poprawności plików ELF). Dołączone są także liczne
63biblioteki pomocnicze z zaimplementowaną obsługą DWARF, ELF i ELF
7f09d52f
JB
64specyficznych dla architektury.
65
ecbc8f89 66%package devel
7f09d52f 67Summary: Development part of libraries to handle compiled objects
cc5b5c39 68Summary(pl.UTF-8): Część programistyczna bibliotek do obsługi skompilowanych obiektów
7f09d52f 69Group: Development/Libraries
fb301307 70Requires: %{name} = %{version}-%{release}
d5753979 71Obsoletes: libelf-devel
ecbc8f89
AF
72
73%description devel
7f09d52f
JB
74The elfutils-devel package contains the development part of libraries
75to create applications for handling compiled objects. libelf allows
76you to access the internals of the ELF object file format, so you can
77see the different sections of an ELF file. libebl provides some
78higher-level ELF access functionality. libdwarf provides access to the
79DWARF debugging information. libasm provides a programmable assembler
ecbc8f89
AF
80interface.
81
13991385
JR
82%description devel -l pl.UTF-8
83Pakiet elfutils-devel zawiera część programistyczną bibliotek do
84tworzenia aplikacji obsługujących skompilowane obiekty. libelf pozwala
85na dostęp do wnętrzności formatu pliku obiektowego ELF, co pozwala na
86oglądanie różnych sekcji pliku ELF. libebl udostępnia funkcjonalność
87dostępu do plików ELF trochę wyższego poziomu. libdwarf pozwala na
88dostęp do informacji DWARF służących do odpluskwiania. libasm
89udostępnia programowalny interfejs asemblera.
7f09d52f 90
ecbc8f89 91%package libelf
7f09d52f 92Summary: Library to read and write ELF files
cc5b5c39 93Summary(pl.UTF-8): Biblioteki do odczytu i zapisu plików ELF
7f09d52f 94Group: Libraries
e21fb8cd 95#Obsoletes: libelf
ecbc8f89
AF
96
97%description libelf
98The elfutils-libelf package provides a DSO which allows reading and
d5753979
AF
99writing ELF files on a high level. Third party programs depend on this
100package to read internals of ELF files. The programs of the elfutils
101package use it also to generate new ELF files.
ecbc8f89 102
13991385
JR
103%description libelf -l pl.UTF-8
104Pakiet elfutils-libelf udostępnia bibliotekę dzieloną, która pozwala
105na wysokopoziomowe czytanie i zapisywanie plików ELF. Inne programy
106wymagają tego pakietu, aby odczytywać zawartość plików ELF. Programy z
107pakietu elfutils używają jej także do generowania nowych plików ELF.
7f09d52f 108
2a18e913 109%package static
7f09d52f 110Summary: Static libraries to handle compiled objects
cc5b5c39 111Summary(pl.UTF-8): Statyczne biblioteki do obsługi skompilowanych obiektów
7f09d52f 112Group: Development/Libraries
fb301307 113Requires: %{name}-devel = %{version}-%{release}
9da385b9 114Obsoletes: libelf-static
2a18e913
AF
115
116%description static
117The elfutils-static package contains the static libraries to create
118applications for handling compiled objects. libelf allows you to
119access the internals of the ELF object file format, so you can see the
120different sections of an ELF file. libebl provides some higher-level
121ELF access functionality. libdwarf provides access to the DWARF
122debugging information. libasm provides a programmable assembler
123interface.
124
13991385 125%description static -l pl.UTF-8
7f09d52f 126Pakiet elfutils-static zawiera statyczne biblioteki do tworzenia
13991385
JR
127aplikacji obsługujących skompilowane obiekty. libelf pozwala na dostęp
128do wnętrzności formatu pliku obiektowego ELF, co pozwala na oglądanie
129różnych sekcji pliku ELF. libebl udostępnia funkcjonalność dostępu do
130plików ELF trochę wyższego poziomu. libdwarf pozwala na dostęp do
131informacji DWARF służących do odpluskwiania. libasm udostępnia
7f09d52f 132programowalny interfejs asemblera.
2a18e913 133
ecbc8f89
AF
134%prep
135%setup -q
10cca083 136%patch0 -p1
0937133b 137%patch1 -p1
5d5c3b33 138%patch2 -p1
30cc8b05
JR
139%patch3 -p1
140%patch4 -p1
f1d8205d 141%patch5 -p1
3dfc27e9 142%patch6 -p1
103cc6fb 143%patch7 -p1
d748a5ee 144
f2c7e483 145%{__rm} po/stamp-po
ecbc8f89 146
6d3fd36e 147# temporarily disable failing tests (depending or arch)
d68cdcb9
JB
148%ifarch x32
149%{__sed} -i -e 's/run-backtrace-native-biarch.sh//' tests/Makefile.am
150%endif
80e874f2 151
ecbc8f89 152%build
30cc8b05 153#%%{__gettextize}
0f5a32a6 154%{__aclocal} -I m4
d5753979 155%{__autoheader}
d5753979 156%{__autoconf}
d748a5ee 157%{__automake}
d5753979 158%configure \
6d3fd36e 159 --disable-silent-rules \
96e6dfc1 160 --disable-werror \
e33ecb8e 161 --program-prefix=%{programprefix}
ecbc8f89 162
fb301307
JB
163# make check depends on test-nlist not stripped
164%{__perl} -pi -e 's/^(LDFLAGS =.*)-s/$1/' tests/Makefile
165
b1ad9ed4 166%{__make}
0937133b 167%{__make} -C debian/man
d748a5ee 168
6771db41 169%if %{with tests}
80e874f2
JB
170# some tests rely on English messages
171LC_ALL=C \
6771db41
JB
172%{__make} -C tests check
173%endif
0937133b 174
ecbc8f89 175%install
d5753979 176rm -rf $RPM_BUILD_ROOT
30cc8b05 177install -d $RPM_BUILD_ROOT{%{_mandir}/man1,/%{_lib}}
ecbc8f89 178
d5753979 179%{__make} install \
668f585d 180 DESTDIR=$RPM_BUILD_ROOT
ecbc8f89 181
0937133b 182install debian/man/*.1 $RPM_BUILD_ROOT%{_mandir}/man1
ecbc8f89 183
6d3fd36e 184%{__mv} $RPM_BUILD_ROOT%{_libdir}/{libelf-*.so,libelf.so.*} $RPM_BUILD_ROOT/%{_lib}
668f585d 185ln -sf /%{_lib}/$(basename $RPM_BUILD_ROOT/%{_lib}/libelf-*.so) \
6d3fd36e 186 $RPM_BUILD_ROOT%{_libdir}/libelf.so
30cc8b05 187
9a404d6e 188%find_lang %{name}
ecbc8f89
AF
189
190%clean
0937133b 191rm -rf $RPM_BUILD_ROOT
ecbc8f89 192
7f09d52f
JB
193%post -p /sbin/ldconfig
194%postun -p /sbin/ldconfig
ecbc8f89 195
7f09d52f
JB
196%post libelf -p /sbin/ldconfig
197%postun libelf -p /sbin/ldconfig
ecbc8f89 198
d748a5ee 199%files
d5753979 200%defattr(644,root,root,755)
3a5346c9 201%doc AUTHORS CONTRIBUTING ChangeLog NEWS NOTES README THANKS TODO
668f585d 202%attr(755,root,root) %{_bindir}/eu-*
0937133b 203%attr(755,root,root) %{_libdir}/libasm-*.so
b68ac3ec 204%attr(755,root,root) %ghost %{_libdir}/libasm.so.1
0937133b 205%attr(755,root,root) %{_libdir}/libdw-*.so
b68ac3ec 206%attr(755,root,root) %ghost %{_libdir}/libdw.so.1
ecbc8f89 207%dir %{_libdir}/elfutils
2a18e913 208%attr(755,root,root) %{_libdir}/elfutils/lib*.so
668f585d 209%{_mandir}/man1/eu-*.1*
ecbc8f89
AF
210
211%files devel
d5753979 212%defattr(644,root,root,755)
0937133b
JB
213%attr(755,root,root) %{_libdir}/libasm.so
214%attr(755,root,root) %{_libdir}/libdw.so
0937133b
JB
215%attr(755,root,root) %{_libdir}/libelf.so
216%{_libdir}/libebl.a
668f585d
JB
217%{_includedir}/elfutils
218%{_includedir}/dwarf.h
219%{_includedir}/gelf.h
220%{_includedir}/libelf.h
221%{_includedir}/nlist.h
ecbc8f89 222
d748a5ee 223%files libelf -f %{name}.lang
d5753979 224%defattr(644,root,root,755)
30cc8b05 225%attr(755,root,root) /%{_lib}/libelf-*.so
b68ac3ec 226%attr(755,root,root) %ghost /%{_lib}/libelf.so.1
2a18e913
AF
227
228%files static
229%defattr(644,root,root,755)
0937133b
JB
230%{_libdir}/libasm.a
231%{_libdir}/libdw.a
0937133b 232%{_libdir}/libelf.a
This page took 0.127071 seconds and 4 git commands to generate.