2 # - package debuginfod.service
5 %bcond_without debuginfod # debuginfod server and client
6 %bcond_without tests # do not perform tests
8 Summary: A collection of utilities and DSOs to handle compiled objects
9 Summary(pl.UTF-8): Zestaw narzędzi i bibliotek do obsługi skompilowanych obiektów
13 License: GPL v2+ or LGPL v3+ (libraries), GPL v3+ (programs)
14 Group: Development/Tools
15 Source0: https://sourceware.org/elfutils/ftp/%{version}/%{name}-%{version}.tar.bz2
16 # Source0-md5: 5cfaa711a90cb670406cd495aeaa6030
17 Patch0: %{name}-pl.po.patch
18 Patch1: %{name}-debian-manpages.patch
19 Patch2: %{name}-awk.patch
20 Patch3: %{name}-align.patch
21 Patch4: %{name}-paxflags.patch
22 Patch5: %{name}-sparc.patch
23 Patch6: disable-tests.patch
24 URL: https://sourceware.org/elfutils/
25 BuildRequires: autoconf >= 2.63
26 BuildRequires: automake >= 1:1.11
27 %{?with_tests:BuildRequires: bsdtar}
28 BuildRequires: bzip2-devel
30 BuildRequires: gcc >= 6:4.3
31 BuildRequires: gettext-tools >= 0.19.6
32 BuildRequires: glibc-devel >= 6:2.7
33 BuildRequires: libstdc++-devel >= 6:4.7
34 BuildRequires: perl-tools-pod
35 BuildRequires: pkgconfig
36 BuildRequires: rpmbuild(macros) >= 1.527
37 BuildRequires: sharutils
38 BuildRequires: xz-devel
39 BuildRequires: zlib-devel
40 BuildRequires: zstd-devel >= 1.4.0
41 %if %{with tests} && %(test -d /proc/self ; echo $?)
42 # native test needs proc (for libdwfl -p PID to work)
43 BuildRequires: MOUNTED_PROC
45 %if %{with debuginfod}
46 BuildRequires: curl-devel >= 7.29.0
47 BuildRequires: libarchive-devel >= 3.1.2
48 BuildRequires: libmicrohttpd-devel >= 0.9.33
49 BuildRequires: sqlite3-devel >= 3.7.17
51 Requires: %{name}-libelf = %{version}-%{release}
52 Requires: zstd >= 1.4.0
53 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
55 # fails to build with -Wl,-s
56 %define filterout_ld (-Wl,)?-[sS] (-Wl,)?--strip.*
57 %if %{with tests} && 0%(echo %{rpmcflags} | grep -q '\<-g' ; echo $?)
58 # tests require debug symbols
62 %define programprefix eu-
65 Elfutils is a collection of utilities, including ld (a linker), nm
66 (for listing symbols from object files), size (for listing the section
67 sizes of an object or archive file), strip (for discarding symbols),
68 readline (the see the raw ELF file structures), and elflint (to check
69 for well-formed ELF files). Also included are numerous helper
70 libraries which implement DWARF, ELF, and machine-specific ELF
73 %description -l pl.UTF-8
74 Elfutils to zestaw narzędzi, składający się z ld (linkera), nm (do
75 listowania symboli z plików obiektów), size (do listowania rozmiarów
76 sekcji plików obiektów lub archiwów), strip (do usuwania symboli),
77 readline (do oglądania surowych struktur plików ELF) oraz elflint (do
78 sprawdzania poprawności plików ELF). Dołączone są także liczne
79 biblioteki pomocnicze z zaimplementowaną obsługą DWARF, ELF i ELF
80 specyficznych dla architektury.
83 Summary: Development part of libraries to handle compiled objects
84 Summary(pl.UTF-8): Część programistyczna bibliotek do obsługi skompilowanych obiektów
85 Group: Development/Libraries
86 Requires: %{name} = %{version}-%{release}
90 Requires: zstd-devel >= 1.4.0
91 Obsoletes: libelf-devel < 0.8.14
92 Obsoletes: libelf0-devel < 0.8.14
95 The elfutils-devel package contains the development part of libraries
96 to create applications for handling compiled objects. libelf allows
97 you to access the internals of the ELF object file format, so you can
98 see the different sections of an ELF file. libdw provides access to
99 the DWARF debugging information. libasm provides a programmable
102 %description devel -l pl.UTF-8
103 Pakiet elfutils-devel zawiera część programistyczną bibliotek do
104 tworzenia aplikacji obsługujących skompilowane obiekty. libelf pozwala
105 na dostęp do wnętrzności formatu pliku obiektowego ELF, co pozwala na
106 oglądanie różnych sekcji pliku ELF. libdw pozwala na dostęp do
107 informacji DWARF służących do odpluskwiania. libasm udostępnia
108 programowalny interfejs asemblera.
111 Summary: Library to read and write ELF files
112 Summary(pl.UTF-8): Biblioteki do odczytu i zapisu plików ELF
117 The elfutils-libelf package provides a DSO which allows reading and
118 writing ELF files on a high level. Third party programs depend on this
119 package to read internals of ELF files. The programs of the elfutils
120 package use it also to generate new ELF files.
122 %description libelf -l pl.UTF-8
123 Pakiet elfutils-libelf udostępnia bibliotekę dzieloną, która pozwala
124 na wysokopoziomowe czytanie i zapisywanie plików ELF. Inne programy
125 wymagają tego pakietu, aby odczytywać zawartość plików ELF. Programy z
126 pakietu elfutils używają jej także do generowania nowych plików ELF.
129 Summary: Static libraries to handle compiled objects
130 Summary(pl.UTF-8): Statyczne biblioteki do obsługi skompilowanych obiektów
131 Group: Development/Libraries
132 Requires: %{name}-devel = %{version}-%{release}
133 Requires: zstd >= 1.4.0
134 Obsoletes: libelf-static < 0.8.14
137 The elfutils-static package contains the static libraries to create
138 applications for handling compiled objects. libelf allows you to
139 access the internals of the ELF object file format, so you can see the
140 different sections of an ELF file. libdw provides access to the DWARF
141 debugging information. libasm provides a programmable assembler
144 %description static -l pl.UTF-8
145 Pakiet elfutils-static zawiera statyczne biblioteki do tworzenia
146 aplikacji obsługujących skompilowane obiekty. libelf pozwala na dostęp
147 do wnętrzności formatu pliku obiektowego ELF, co pozwala na oglądanie
148 różnych sekcji pliku ELF. libdw pozwala na dostęp do informacji DWARF
149 służących do odpluskwiania. libasm udostępnia programowalny interfejs
153 Summary: debuginfod server and client
154 Summary(pl.UTF-8): Serwer i klient debuginfod
156 Requires: %{name} = %{version}-%{release}
157 Requires: %{name}-debuginfod-libs = %{version}-%{release}
158 Requires: libarchive >= 3.1.2
159 Requires: libmicrohttpd >= 0.9.33
160 Requires: sqlite3-libs >= 3.7.17
162 %description debuginfod
163 debuginfod server and client.
165 %description debuginfod -l pl.UTF-8
166 Serwer i klient debuginfod.
168 %package debuginfod-libs
169 Summary: debuginfod library
170 Summary(pl.UTF-8): Biblioteka debuginfod
172 Requires: %{name}-libelf = %{version}-%{release}
173 Requires: curl-libs >= 7.29.0
174 Conflicts: elfutils-debuginfod < 0.187-3
176 %description debuginfod-libs
179 %description debuginfod-libs -l pl.UTF-8
180 Biblioteka debuginfod.
182 %package debuginfod-devel
183 Summary: Header file for debuginfod library
184 Summary(pl.UTF-8): Plik nagłówkowy biblioteki debuginfod
185 Group: Development/Libraries
186 Requires: %{name}-debuginfod-libs = %{version}-%{release}
187 Requires: %{name}-devel = %{version}-%{release}
189 %description debuginfod-devel
190 Header file for debuginfod library.
192 %description debuginfod-devel -l pl.UTF-8
193 Plik nagłówkowy biblioteki debuginfod.
207 # temporarily disable failing tests (depending on arch)
209 %{__sed} -i -e 's/run-backtrace-native-biarch.sh//' tests/Makefile.am
212 # make sure this is not even tried on arch it has no chance to run
214 %{__sed} -i -e 's/run-disasm-x86-64.sh//' tests/Makefile.am
224 --disable-silent-rules \
225 %{__enable_disable debuginfod} \
226 --program-prefix=%{programprefix}
228 # make check depends on test-nlist not stripped
229 %{__perl} -pi -e 's/^(LDFLAGS =.*)-s/$1/' tests/Makefile
232 %{__make} -C debian/man
235 # some tests rely on English messages
237 %{__make} -C tests check
241 rm -rf $RPM_BUILD_ROOT
242 install -d $RPM_BUILD_ROOT{%{_mandir}/man1,/%{_lib}}
245 DESTDIR=$RPM_BUILD_ROOT
247 install debian/man/*.1 $RPM_BUILD_ROOT%{_mandir}/man1
249 %{__mv} $RPM_BUILD_ROOT%{_libdir}/{libelf-*.so,libelf.so.*} $RPM_BUILD_ROOT/%{_lib}
250 ln -sf /%{_lib}/$(basename $RPM_BUILD_ROOT/%{_lib}/libelf-*.so) \
251 $RPM_BUILD_ROOT%{_libdir}/libelf.so
256 rm -rf $RPM_BUILD_ROOT
258 %post -p /sbin/ldconfig
259 %postun -p /sbin/ldconfig
261 %post libelf -p /sbin/ldconfig
262 %postun libelf -p /sbin/ldconfig
264 %post debuginfod-libs -p /sbin/ldconfig
265 %postun debuginfod-libs -p /sbin/ldconfig
268 %defattr(644,root,root,755)
269 %doc AUTHORS CONTRIBUTING ChangeLog NEWS NOTES README THANKS TODO
270 %attr(755,root,root) %{_bindir}/eu-*
271 %attr(755,root,root) %{_libdir}/libasm-*.so
272 %attr(755,root,root) %ghost %{_libdir}/libasm.so.1
273 %attr(755,root,root) %{_libdir}/libdw-*.so
274 %attr(755,root,root) %ghost %{_libdir}/libdw.so.1
275 %{_mandir}/man1/eu-*.1*
278 %defattr(644,root,root,755)
279 %attr(755,root,root) %{_libdir}/libasm.so
280 %attr(755,root,root) %{_libdir}/libdw.so
281 %attr(755,root,root) %{_libdir}/libelf.so
282 %{_includedir}/dwarf.h
283 %{_includedir}/gelf.h
284 %{_includedir}/libelf.h
285 %{_includedir}/nlist.h
286 %dir %{_includedir}/elfutils
287 %{_includedir}/elfutils/elf-knowledge.h
288 %{_includedir}/elfutils/known-dwarf.h
289 %{_includedir}/elfutils/libasm.h
290 %{_includedir}/elfutils/libdw.h
291 %{_includedir}/elfutils/libdwelf.h
292 %{_includedir}/elfutils/libdwfl.h
293 %{_includedir}/elfutils/version.h
294 %{_pkgconfigdir}/libdw.pc
295 %{_pkgconfigdir}/libelf.pc
296 %{_mandir}/man3/elf_begin.3*
297 %{_mandir}/man3/elf_clone.3*
298 %{_mandir}/man3/elf_getdata.3*
299 %{_mandir}/man3/elf_update.3*
301 %files libelf -f %{name}.lang
302 %defattr(644,root,root,755)
303 %attr(755,root,root) /%{_lib}/libelf-*.so
304 %attr(755,root,root) %ghost /%{_lib}/libelf.so.1
307 %defattr(644,root,root,755)
312 %if %{with debuginfod}
314 %defattr(644,root,root,755)
315 %attr(755,root,root) %{_bindir}/debuginfod
316 %attr(755,root,root) %{_bindir}/debuginfod-find
317 %{_mandir}/man1/debuginfod-find.1*
318 %{_mandir}/man7/debuginfod-client-config.7*
319 %{_mandir}/man8/debuginfod.8*
320 # uncomment after packaging debuginfod.service
321 #%{_mandir}/man8/debuginfod.service.8*
322 %attr(755,root,root) /etc/profile.d/debuginfod.sh
323 %attr(755,root,root) /etc/profile.d/debuginfod.csh
325 %files debuginfod-libs
326 %defattr(644,root,root,755)
327 %attr(755,root,root) %{_libdir}/libdebuginfod-*.so
328 %attr(755,root,root) %ghost %{_libdir}/libdebuginfod.so.1
330 %files debuginfod-devel
331 %defattr(644,root,root,755)
332 %attr(755,root,root) %{_libdir}/libdebuginfod.so
333 %{_includedir}/elfutils/debuginfod.h
334 %{_pkgconfigdir}/libdebuginfod.pc
335 %{_mandir}/man3/debuginfod_*.3*