3 %bcond_without tests # do not perform tests
5 Summary: A collection of utilities and DSOs to handle compiled objects
6 Summary(pl.UTF-8): Zestaw narzędzi i bibliotek do obsługi skompilowanych obiektów
10 License: GPL v2 with OSL linking exception
11 Group: Development/Tools
12 Source0: https://fedorahosted.org/releases/e/l/elfutils/%{version}/%{name}-%{version}.tar.bz2
13 # Source0-md5: 289a146182bc29f0236eaa15d8ebdf98
14 Patch0: %{name}-pl.po.patch
15 Patch1: %{name}-debian-manpages.patch
16 Patch2: %{name}-portability.patch
17 Patch3: %{name}-robustify.patch
18 Patch4: %{name}-align.patch
19 Patch5: %{name}-paxflags.patch
20 Patch6: %{name}-sparc.patch
21 Patch7: %{name}-inline.patch
22 Patch8: %{name}-scanf.patch
23 Patch9: %{name}-strings_c.patch
24 Patch10: %{name}-upstream.patch
25 URL: https://fedorahosted.org/elfutils/
26 BuildRequires: autoconf >= 2.63
27 BuildRequires: automake >= 1:1.8
28 BuildRequires: gcc >= 5:3.4
29 BuildRequires: gettext-devel
30 %ifarch %{x8664} alpha ia64 ppc64 s390x sparc64
31 # PR*FAST{8,16} in <inttypes.h> were broken for 64-bit archs in older versions
32 # also needed for nanosecond timestamps on alpha
33 BuildRequires: glibc-devel >= 6:2.3.4
35 BuildRequires: perl-tools-pod
36 BuildRequires: rpmbuild(macros) >= 1.315
37 BuildRequires: sharutils
38 %if %{with tests} && %(test -d /proc/self ; echo $?)
39 # native test needs proc (for libdwfl -p PID to work)
40 BuildRequires: MOUNTED_PROC
42 Requires: %{name}-libelf = %{version}-%{release}
43 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
45 # fails to build with -Wl,-s
46 %define filterout_ld (-Wl,)?-[sS] (-Wl,)?--strip.*
47 %if %{with tests} && 0%(echo %{rpmcflags} | grep -q '\<-g' ; echo $?)
48 # tests require debug symbols
52 %define programprefix eu-
55 Elfutils is a collection of utilities, including ld (a linker), nm
56 (for listing symbols from object files), size (for listing the section
57 sizes of an object or archive file), strip (for discarding symbols),
58 readline (the see the raw ELF file structures), and elflint (to check
59 for well-formed ELF files). Also included are numerous helper
60 libraries which implement DWARF, ELF, and machine-specific ELF
63 %description -l pl.UTF-8
64 Elfutils to zestaw narzędzi, składający się z ld (linkera), nm (do
65 listowania symboli z plików obiektów), size (do listowania rozmiarów
66 sekcji plików obiektów lub archiwów), strip (do usuwania symboli),
67 readline (do oglądania surowych struktur plików ELF) oraz elflint (do
68 sprawdzania poprawności plików ELF). Dołączone są także liczne
69 biblioteki pomocnicze z zaimplementowaną obsługą DWARF, ELF i ELF
70 specyficznych dla architektury.
73 Summary: Development part of libraries to handle compiled objects
74 Summary(pl.UTF-8): Część programistyczna bibliotek do obsługi skompilowanych obiektów
75 Group: Development/Libraries
76 Requires: %{name} = %{version}-%{release}
77 Obsoletes: libelf-devel
80 The elfutils-devel package contains the development part of libraries
81 to create applications for handling compiled objects. libelf allows
82 you to access the internals of the ELF object file format, so you can
83 see the different sections of an ELF file. libebl provides some
84 higher-level ELF access functionality. libdwarf provides access to the
85 DWARF debugging information. libasm provides a programmable assembler
88 %description devel -l pl.UTF-8
89 Pakiet elfutils-devel zawiera część programistyczną bibliotek do
90 tworzenia aplikacji obsługujących skompilowane obiekty. libelf pozwala
91 na dostęp do wnętrzności formatu pliku obiektowego ELF, co pozwala na
92 oglądanie różnych sekcji pliku ELF. libebl udostępnia funkcjonalność
93 dostępu do plików ELF trochę wyższego poziomu. libdwarf pozwala na
94 dostęp do informacji DWARF służących do odpluskwiania. libasm
95 udostępnia programowalny interfejs asemblera.
98 Summary: Library to read and write ELF files
99 Summary(pl.UTF-8): Biblioteki do odczytu i zapisu plików ELF
104 The elfutils-libelf package provides a DSO which allows reading and
105 writing ELF files on a high level. Third party programs depend on this
106 package to read internals of ELF files. The programs of the elfutils
107 package use it also to generate new ELF files.
109 %description libelf -l pl.UTF-8
110 Pakiet elfutils-libelf udostępnia bibliotekę dzieloną, która pozwala
111 na wysokopoziomowe czytanie i zapisywanie plików ELF. Inne programy
112 wymagają tego pakietu, aby odczytywać zawartość plików ELF. Programy z
113 pakietu elfutils używają jej także do generowania nowych plików ELF.
116 Summary: Static libraries to handle compiled objects
117 Summary(pl.UTF-8): Statyczne biblioteki do obsługi skompilowanych obiektów
118 Group: Development/Libraries
119 Requires: %{name}-devel = %{version}-%{release}
120 Obsoletes: libelf-static
123 The elfutils-static package contains the static libraries to create
124 applications for handling compiled objects. libelf allows you to
125 access the internals of the ELF object file format, so you can see the
126 different sections of an ELF file. libebl provides some higher-level
127 ELF access functionality. libdwarf provides access to the DWARF
128 debugging information. libasm provides a programmable assembler
131 %description static -l pl.UTF-8
132 Pakiet elfutils-static zawiera statyczne biblioteki do tworzenia
133 aplikacji obsługujących skompilowane obiekty. libelf pozwala na dostęp
134 do wnętrzności formatu pliku obiektowego ELF, co pozwala na oglądanie
135 różnych sekcji pliku ELF. libebl udostępnia funkcjonalność dostępu do
136 plików ELF trochę wyższego poziomu. libdwarf pozwala na dostęp do
137 informacji DWARF służących do odpluskwiania. libasm udostępnia
138 programowalny interfejs asemblera.
156 # temporarily disable test failing on specific archs
158 %{__perl} -pi -e 's/run-elflint-self.sh//' tests/Makefile
169 --program-prefix=%{programprefix}
171 # make check depends on test-nlist not stripped
172 %{__perl} -pi -e 's/^(LDFLAGS =.*)-s/$1/' tests/Makefile
175 %{__make} -C debian/man
178 # some tests rely on English messages
180 %{__make} -C tests check
184 rm -rf $RPM_BUILD_ROOT
185 install -d $RPM_BUILD_ROOT{%{_mandir}/man1,/%{_lib}}
188 DESTDIR=$RPM_BUILD_ROOT
190 install debian/man/*.1 $RPM_BUILD_ROOT%{_mandir}/man1
192 mv $RPM_BUILD_ROOT%{_libdir}/{libelf-*.so,libelf.so.*} $RPM_BUILD_ROOT/%{_lib}
193 ln -sf /%{_lib}/$(basename $RPM_BUILD_ROOT/%{_lib}/libelf-*.so) \
194 $RPM_BUILD_ROOT%{_libdir}/libelf.so
199 rm -rf $RPM_BUILD_ROOT
201 %post -p /sbin/ldconfig
202 %postun -p /sbin/ldconfig
204 %post libelf -p /sbin/ldconfig
205 %postun libelf -p /sbin/ldconfig
208 %defattr(644,root,root,755)
209 %doc AUTHORS EXCEPTION NEWS NOTES README THANKS TODO
210 %attr(755,root,root) %{_bindir}/eu-*
211 %attr(755,root,root) %{_libdir}/libasm-*.so
212 %attr(755,root,root) %ghost %{_libdir}/libasm.so.1
213 %attr(755,root,root) %{_libdir}/libdw-*.so
214 %attr(755,root,root) %ghost %{_libdir}/libdw.so.1
215 %dir %{_libdir}/elfutils
216 %attr(755,root,root) %{_libdir}/elfutils/lib*.so
217 %{_mandir}/man1/eu-*.1*
220 %defattr(644,root,root,755)
221 %attr(755,root,root) %{_libdir}/libasm.so
222 %attr(755,root,root) %{_libdir}/libdw.so
223 %attr(755,root,root) %{_libdir}/libelf.so
225 %{_includedir}/elfutils
226 %{_includedir}/dwarf.h
227 %{_includedir}/gelf.h
228 %{_includedir}/libelf.h
229 %{_includedir}/nlist.h
231 %files libelf -f %{name}.lang
232 %defattr(644,root,root,755)
233 %attr(755,root,root) /%{_lib}/libelf-*.so
234 %attr(755,root,root) %ghost /%{_lib}/libelf.so.1
237 %defattr(644,root,root,755)