2008-10-14 02:26:42 +02:00
|
|
|
#
|
2011-05-02 11:57:50 +02:00
|
|
|
# spec file for package elfutils
|
2008-10-14 02:26:42 +02:00
|
|
|
#
|
2014-01-29 20:02:33 +01:00
|
|
|
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
2008-10-14 02:26:42 +02:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
2012-03-15 19:50:54 +01:00
|
|
|
|
2008-10-14 02:26:42 +02:00
|
|
|
Name: elfutils
|
2014-01-29 20:02:33 +01:00
|
|
|
Version: 0.158
|
2011-12-01 16:53:06 +01:00
|
|
|
Release: 0
|
2008-11-03 01:01:23 +01:00
|
|
|
Summary: Higher-level library to access ELF
|
2012-09-20 15:33:18 +02:00
|
|
|
License: SUSE-GPL-2.0-with-OSI-exception
|
2014-11-25 08:35:02 +01:00
|
|
|
Group: Development/Tools/Building
|
|
|
|
Url: http://fedorahosted.org/elfutils/
|
|
|
|
|
|
|
|
#Git-Clone: git://git.fedorahosted.org/git/elfutils
|
2013-03-26 16:42:03 +01:00
|
|
|
Source: https://fedorahosted.org/releases/e/l/%{name}/%{version}/%{name}-%{version}.tar.bz2
|
2011-04-28 16:06:03 +02:00
|
|
|
Source1: README-BEFORE-ADDING-PATCHES
|
2010-02-10 12:24:02 +01:00
|
|
|
Source2: baselibs.conf
|
2014-09-02 18:05:23 +02:00
|
|
|
Source3: %{name}.changes
|
2013-11-14 19:19:54 +01:00
|
|
|
Patch1: https://fedorahosted.org/releases/e/l/%{name}/%{version}/elfutils-portability.patch
|
|
|
|
Patch2: https://fedorahosted.org/releases/e/l/%{name}/%{version}/elfutils-robustify.patch
|
2008-10-14 02:26:42 +02:00
|
|
|
Patch3: elfutils-no-po-test-build.diff
|
2010-05-25 10:29:40 +02:00
|
|
|
Patch4: libebl-prototype-fix.diff
|
|
|
|
Patch5: elfutils-uninitialized.diff
|
|
|
|
Patch6: elfutils-0.137-dwarf-header-check-fix.diff
|
2010-09-17 20:47:03 +02:00
|
|
|
Patch7: elfutils-0.148-dont-crash.diff
|
2012-03-15 19:50:54 +01:00
|
|
|
Patch8: elfutils-revert-portability-scanf.patch
|
2014-04-17 00:27:28 +02:00
|
|
|
Patch9: elfutils-check-for-overflow-before-calling-malloc-to-uncompress-data.patch
|
2008-10-14 02:26:42 +02:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
2011-12-01 16:53:06 +01:00
|
|
|
BuildRequires: bison
|
|
|
|
BuildRequires: flex
|
|
|
|
BuildRequires: libbz2-devel
|
|
|
|
BuildRequires: xz-devel
|
|
|
|
BuildRequires: zlib-devel
|
2008-10-14 02:26:42 +02:00
|
|
|
|
|
|
|
%description
|
2008-11-03 01:01:23 +01:00
|
|
|
This package provides a higher-level library to access ELF files. This
|
|
|
|
is a part of elfutils package.
|
2008-10-14 02:26:42 +02:00
|
|
|
|
|
|
|
%package -n libasm1
|
|
|
|
Summary: A collection of utilities and DSOs to handle compiled objects
|
2014-11-25 08:35:02 +01:00
|
|
|
Group: System/Libraries
|
2008-10-14 02:26:42 +02:00
|
|
|
|
|
|
|
%description -n libasm1
|
|
|
|
Elfutils is a collection of utilities, including ld (a linker), nm (for
|
|
|
|
listing symbols from object files), size (for listing the section sizes
|
|
|
|
of an object or archive file), strip (for discarding symbols), readline
|
|
|
|
(the see the raw ELF file structures), and elflint (to check for
|
|
|
|
well-formed ELF files). Also included are numerous helper libraries
|
|
|
|
which implement DWARF, ELF, and machine-specific ELF handling.
|
|
|
|
|
|
|
|
%package -n libasm-devel
|
|
|
|
Summary: A collection of utilities and DSOs to handle compiled objects
|
2014-11-25 08:35:02 +01:00
|
|
|
Group: Development/Libraries/C and C++
|
2012-05-31 10:51:10 +02:00
|
|
|
Requires: glibc-devel
|
|
|
|
Requires: libasm1 = %{version}
|
2008-10-14 02:26:42 +02:00
|
|
|
|
|
|
|
%description -n libasm-devel
|
|
|
|
Elfutils is a collection of utilities, including ld (a linker), nm (for
|
|
|
|
listing symbols from object files), size (for listing the section sizes
|
|
|
|
of an object or archive file), strip (for discarding symbols), readline
|
|
|
|
(the see the raw ELF file structures), and elflint (to check for
|
|
|
|
well-formed ELF files). Also included are numerous helper libraries
|
|
|
|
which implement DWARF, ELF, and machine-specific ELF handling.
|
|
|
|
|
|
|
|
%package -n libebl1
|
|
|
|
Summary: A collection of utilities and DSOs to handle compiled objects
|
2014-11-25 08:35:02 +01:00
|
|
|
Group: System/Libraries
|
2008-10-14 02:26:42 +02:00
|
|
|
Provides: libebl = %{version}
|
|
|
|
Obsoletes: libebl < %{version}
|
|
|
|
|
|
|
|
%description -n libebl1
|
|
|
|
Elfutils is a collection of utilities, including ld (a linker), nm (for
|
|
|
|
listing symbols from object files), size (for listing the section sizes
|
|
|
|
of an object or archive file), strip (for discarding symbols), readline
|
|
|
|
(the see the raw ELF file structures), and elflint (to check for
|
|
|
|
well-formed ELF files). Also included are numerous helper libraries
|
|
|
|
which implement DWARF, ELF, and machine-specific ELF handling.
|
|
|
|
|
|
|
|
%package -n libebl-devel
|
|
|
|
Summary: Include Files and Libraries mandatory for Development
|
|
|
|
Group: Development/Libraries/C and C++
|
2012-05-31 10:51:10 +02:00
|
|
|
Requires: glibc-devel
|
|
|
|
Requires: libdw-devel = %{version}
|
|
|
|
Requires: libebl1 = %{version}
|
2008-10-14 02:26:42 +02:00
|
|
|
|
|
|
|
%description -n libebl-devel
|
|
|
|
This package contains all necessary include files and libraries needed
|
|
|
|
to develop applications that require these.
|
|
|
|
|
|
|
|
%package -n libelf1
|
|
|
|
Summary: Library to read and write ELF files
|
2012-05-31 10:51:10 +02:00
|
|
|
Group: System/Libraries
|
2008-10-14 02:26:42 +02:00
|
|
|
|
|
|
|
%description -n libelf1
|
2011-05-31 22:41:31 +02:00
|
|
|
This package provides a high-level library to read and write ELF files.
|
2008-10-14 02:26:42 +02:00
|
|
|
This is a part of elfutils package.
|
|
|
|
|
|
|
|
%package -n libelf-devel
|
|
|
|
Summary: Include Files and Libraries mandatory for Development
|
|
|
|
Group: Development/Libraries/C and C++
|
2012-05-31 10:51:10 +02:00
|
|
|
Requires: glibc-devel
|
|
|
|
Requires: libelf1 = %{version}
|
2008-10-14 02:26:42 +02:00
|
|
|
Conflicts: libelf0-devel
|
|
|
|
|
|
|
|
%description -n libelf-devel
|
|
|
|
This package contains all necessary include files and libraries needed
|
|
|
|
to develop applications that require these.
|
|
|
|
|
|
|
|
%package -n libdw1
|
|
|
|
Summary: Library to access DWARF debugging information
|
2012-05-31 10:51:10 +02:00
|
|
|
Group: System/Libraries
|
2008-10-14 02:26:42 +02:00
|
|
|
|
|
|
|
%description -n libdw1
|
2011-05-31 22:41:31 +02:00
|
|
|
This package provides a high-level library to access the DWARF debugging
|
2008-10-14 02:26:42 +02:00
|
|
|
information. This is a part of elfutils package.
|
|
|
|
|
|
|
|
%package -n libdw-devel
|
2009-02-19 18:07:55 +01:00
|
|
|
Summary: Include Files and Libraries mandatory for Development
|
2008-10-14 02:26:42 +02:00
|
|
|
Group: Development/Libraries/C and C++
|
2012-05-31 10:51:10 +02:00
|
|
|
Requires: glibc-devel
|
|
|
|
Requires: libdw1 = %{version}
|
2009-02-19 18:07:55 +01:00
|
|
|
Requires: libelf-devel = %{version}
|
2008-10-14 02:26:42 +02:00
|
|
|
|
|
|
|
%description -n libdw-devel
|
|
|
|
This package contains all necessary include files and libraries needed
|
|
|
|
to develop applications that require these.
|
|
|
|
|
|
|
|
%prep
|
2014-11-25 08:35:02 +01:00
|
|
|
%setup -q
|
2008-10-14 02:26:42 +02:00
|
|
|
%patch1 -p1
|
2010-05-25 10:29:40 +02:00
|
|
|
%patch2 -p1
|
|
|
|
%patch3 -p1
|
|
|
|
%patch4 -p1
|
|
|
|
%patch5 -p1
|
|
|
|
%patch6 -p1
|
2010-09-17 20:47:03 +02:00
|
|
|
%patch7 -p1
|
2012-03-15 19:50:54 +01:00
|
|
|
%patch8 -p1 -R
|
2014-04-17 00:27:28 +02:00
|
|
|
%patch9 -p1
|
2008-10-14 02:26:42 +02:00
|
|
|
|
|
|
|
%build
|
2011-05-25 02:25:57 +02:00
|
|
|
# Change DATE/TIME macros to use last change time of elfutils.changes
|
|
|
|
# See http://lists.opensuse.org/opensuse-factory/2011-05/msg00304.html
|
2011-05-25 02:21:47 +02:00
|
|
|
modified="$(sed -n '/^----/n;s/ - .*$//;p;q' "%{_sourcedir}/%{name}.changes")"
|
|
|
|
DATE="\"$(date -d "${modified}" "+%%b %%e %%Y")\""
|
|
|
|
TIME="\"$(date -d "${modified}" "+%%R")\""
|
|
|
|
find . -type f -regex ".*\.c\|.*\.cpp\|.*\.h" -exec sed -i "s/__DATE__/${DATE}/g;s/__TIME__/${TIME}/g" {} +
|
2014-03-24 07:20:48 +01:00
|
|
|
%ifarch %sparc
|
|
|
|
# Small PIC model not sufficient
|
|
|
|
export CFLAGS="%optflags -fPIC"
|
|
|
|
%endif
|
2008-10-14 02:26:42 +02:00
|
|
|
%configure --program-prefix=eu-
|
2010-07-22 11:19:45 +02:00
|
|
|
make %{?_smp_mflags}
|
2008-10-14 02:26:42 +02:00
|
|
|
|
|
|
|
%install
|
|
|
|
make DESTDIR=$RPM_BUILD_ROOT install
|
|
|
|
# remove unneeded files
|
|
|
|
rm -f $RPM_BUILD_ROOT%{_libdir}/*.la
|
2010-05-25 10:29:40 +02:00
|
|
|
ls -lR $RPM_BUILD_ROOT%{_libdir}/libelf*
|
2008-10-14 02:26:42 +02:00
|
|
|
|
2009-02-19 18:07:55 +01:00
|
|
|
%post -n libebl1 -p /sbin/ldconfig
|
|
|
|
|
2008-10-14 02:26:42 +02:00
|
|
|
%post -n libelf1 -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%post -n libdw1 -p /sbin/ldconfig
|
|
|
|
|
2009-02-19 18:07:55 +01:00
|
|
|
%postun -n libebl1 -p /sbin/ldconfig
|
|
|
|
|
2008-10-14 02:26:42 +02:00
|
|
|
%postun -n libelf1 -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%postun -n libdw1 -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
2012-11-29 13:05:16 +01:00
|
|
|
%doc AUTHORS ChangeLog COPYING NEWS NOTES README THANKS TODO
|
2008-10-14 02:26:42 +02:00
|
|
|
%{_bindir}/*
|
|
|
|
|
|
|
|
%files -n libasm1
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_libdir}/libasm.so.*
|
|
|
|
%{_libdir}/libasm-%{version}.so
|
|
|
|
|
|
|
|
%files -n libasm-devel
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_libdir}/libasm.so
|
|
|
|
%{_libdir}/libasm.a
|
|
|
|
%dir %{_includedir}/elfutils
|
|
|
|
%{_includedir}/elfutils/libasm.h
|
|
|
|
|
|
|
|
%files -n libebl1
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_libdir}/elfutils
|
|
|
|
|
|
|
|
%files -n libebl-devel
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_libdir}/libebl.a
|
|
|
|
%dir %{_includedir}/elfutils
|
|
|
|
%{_includedir}/elfutils/libebl.h
|
|
|
|
|
|
|
|
%files -n libelf1
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_libdir}/libelf.so.*
|
|
|
|
%{_libdir}/libelf-%{version}.so
|
|
|
|
|
|
|
|
%files -n libelf-devel
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_libdir}/libelf.so
|
|
|
|
%{_libdir}/libelf.a
|
|
|
|
%{_includedir}/libelf.h
|
|
|
|
%{_includedir}/gelf.h
|
|
|
|
%{_includedir}/nlist.h
|
|
|
|
%dir %{_includedir}/elfutils
|
|
|
|
%{_includedir}/elfutils/elf-knowledge.h
|
2009-02-19 18:07:55 +01:00
|
|
|
%{_includedir}/elfutils/version.h
|
2008-10-14 02:26:42 +02:00
|
|
|
|
|
|
|
%files -n libdw1
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_libdir}/libdw.so.*
|
|
|
|
%{_libdir}/libdw-%{version}.so
|
|
|
|
|
|
|
|
%files -n libdw-devel
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_libdir}/libdw.a
|
|
|
|
%{_libdir}/libdw.so
|
|
|
|
%{_includedir}/dwarf.h
|
|
|
|
%dir %{_includedir}/elfutils
|
|
|
|
%{_includedir}/elfutils/libdw.h
|
|
|
|
%{_includedir}/elfutils/libdwfl.h
|
|
|
|
|
|
|
|
%changelog
|