valgrind/valgrind.spec
Dirk Mueller ed1ef981db - update to 3.6.0:
3.6.0 is a feature release with many significant improvements and the
  usual collection of bug fixes. See the NEWS file for details.

- apparently gcc-32bit does not exist on old code streams, but
  it seems to work without it as well

- disable building docs until I find a way to build them without
  network access

OBS-URL: https://build.opensuse.org/package/show/devel:tools/valgrind?expand=0&rev=20
2010-10-22 08:03:08 +00:00

179 lines
5.3 KiB
RPMSpec

#
# spec file for package valgrind (Version 3.5.90.svn11414)
#
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# 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/
#
Name: valgrind
BuildRequires: docbook-xsl-stylesheets docbook_4 gcc-c++ glibc-devel-32bit libxslt xorg-x11-devel
%ifarch x86_64 ppc64
BuildRequires: glibc-devel-32bit
%endif
Url: http://valgrind.org/
License: GPL v2 or later
Group: Development/Tools/Debuggers
Summary: Memory Management Debugger
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Version: 3.6.0
Release: 0.<RELEASE6>
Source0: %{name}-%{version}.tar.bz2
# svn di svn://svn.valgrind.org/valgrind/tags/VALGRIND_3_5_0 svn://svn.valgrind.org/valgrind/branches/VALGRIND_3_5_BRANCH > 3_5_BRANCH.diff
# svn di svn://svn.valgrind.org/vex/tags/VEX_3_5_0 svn://svn.valgrind.org/vex/branches/VEX_3_5_BRANCH > VEX_3_5_BRANCH.diff
Patch1: jit-register-unregister.diff
Patch2: deprecated.diff
Patch3: valgrind-3.5.90.svn11391-s390x-port.diff
%if %suse_version <= 1100
Provides: valgrind-devel = %version
%endif
Provides: callgrind = %version
Obsoletes: callgrind < %version
ExclusiveArch: %ix86 x86_64 ppc ppc64 s390x
%if %suse_version > 1100
%define building_docs 1
%else
%define building_docs 0
%endif
%description
Valgrind checks all memory operations in an application, like read,
write, malloc, new, free, and delete. Valgrind can find uses of
uninitialized memory, access to already freed memory, overflows,
illegal stack operations, memory leaks, and any illegal
new/malloc/free/delete commands. Another program in the package is
"cachegrind," a profiler based on the valgrind engine.
To use valgrind you should compile your application with "-g -O0"
compiler options. Afterwards you can use it with:
valgrind --tool=memcheck --sloppy-malloc=yes --leak-check=yes
--db-attach=yes my_application, for example.
More valgrind options can be listed via "valgrind --help". There is
also complete documentation in the /usr/share/doc/packages/valgrind/
directory. A debugged application runs slower and needs much more
memory, but is usually still usable. Valgrind is still in development,
but it has been successfully used to optimize several KDE applications.
Authors:
--------
Julian Seward <jseward@acm.org>
Cerion Armour-Brown
Jeremy Fitzhardinge
Tom Hughes
Nicholas Nethercote
Paul Mackerras
Dirk Mueller
Robert Walsh
%if %suse_version > 1100
%package devel
License: GPL v2 or later
Summary: Memory Management Debugger
Group: Development/Tools/Debuggers
Requires: %name = %version
%description devel
Valgrind checks all memory operations in an application, like read,
write, malloc, new, free, and delete. Valgrind can find uses of
uninitialized memory, access to already freed memory, overflows,
illegal stack operations, memory leaks, and any illegal
new/malloc/free/delete commands. Another program in the package is
"cachegrind," a profiler based on the valgrind engine.
To use valgrind you should compile your application with "-g -O0"
compiler options. Afterwards you can use it with:
valgrind --tool=memcheck --sloppy-malloc=yes --leak-check=yes
--db-attach=yes my_application, for example.
More valgrind options can be listed via "valgrind --help". There is
also complete documentation in the /usr/share/doc/packages/valgrind/
directory. A debugged application runs slower and needs much more
memory, but is usually still usable. Valgrind is still in development,
but it has been successfully used to optimize several KDE applications.
Authors:
--------
Julian Seward <jseward@acm.org>
Cerion Armour-Brown
Jeremy Fitzhardinge
Tom Hughes
Nicholas Nethercote
Paul Mackerras
Dirk Mueller
Robert Walsh
%endif
%prep
%setup -q -n %{name}-%{version}
cd VEX
cd ..
%patch1
%ifarch s390x
%patch3
%endif
# probably no longer needed, kept around already for a long time (2010-10-12)
#%patch2
%build
export CFLAGS="$RPM_OPT_FLAGS"
export CXXFLAGS="$RPM_OPT_FLAGS"
autoreconf -fi
export GDB=/usr/bin/gdb
%configure
make %{?jobs:-j%jobs}
%if %building_docs
pushd docs
#make all-docs
# building the docs needs network access at the moment :-(
make FAQ.txt man-pages html-docs
popd
%endif
%install
make DESTDIR=$RPM_BUILD_ROOT install
mkdir -p $RPM_BUILD_ROOT/usr/share/doc/packages
%if %building_docs
mv $RPM_BUILD_ROOT/usr/share/doc/valgrind $RPM_BUILD_ROOT/usr/share/doc/packages
%endif
%files
%defattr(-,root,root)
%doc README* NEWS AUTHORS COPYING COPYING.DOCS
/usr/bin/*
%_libdir/valgrind
%if %building_docs
%doc %_mandir/*/*
%endif
%if %suse_version > 1100
%files devel
%defattr(-,root,root)
%endif
/usr/include/valgrind
/usr/%_lib/pkgconfig/valgrind.pc
%changelog