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