File libcppunit-1_12-0.spec of Package libcppunit-1_12-0

#
# spec file for package libcppunit-1_12-0 (Version 1.12.0)
#
# 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/
#

# norootforbuild


Name:           libcppunit-1_12-0
Provides:       cppunit = 1.10.2
Obsoletes:      cppunit <= 1.10.2
BuildRequires:  doxygen gcc-c++ pkgconfig update-desktop-files
Url:            http://sourceforge.net/projects/cppunit/
License:        LGPLv2.1+
Group:          Development/Libraries/C and C++
Summary:        C++ Port of the JUnit Testing Framework
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Version:        1.12.0
Release:        99
Source:         cppunit-%{version}.tar.bz2
Source1:        cppunit-devel.desktop
Patch:          cppunit.diff
Patch1:         cppunit-%{version}-quotefix.diff
Patch2:         cppunit_libdl.diff
AutoReqProv:    on

%description
CppUnit is the C++ port of the famous JUnit framework for unit testing.
Test output is in XML for automatic testing and GUI based for
supervised tests.



Authors:
--------
    Michael Feathers <mfeathers@objectmentor.com>
    Jerome Lacoste <lacostej@altern.org>
    E. Sommerlade <eric@sommerla.de>
    J.E. Hoffmann <je-h@gmx.net>
    Baptiste Lepilleur <gaiacrtn@free.fr> <blep@sourceforge.net>
    Bastiaan Bakker <bastiaan.bakker@lifeline.nl>
    Steve Robbins <smr99@sourceforge.net>

%package -n libcppunit-devel
License:        LGPLv2.1+
Summary:        Include Files and Libraries mandatory for Development
Group:          Development/Libraries/C and C++
Provides:       cppunit-devel = 1.10.2
Obsoletes:      cppunit-devel <= 1.10.2

%description -n libcppunit-devel
This package contains all necessary include files and libraries needed
to develop applications that require these.



Authors:
--------
    Michael Feathers <mfeathers@objectmentor.com>
    Jerome Lacoste <lacostej@altern.org>
    E. Sommerlade <eric@sommerla.de>
    J.E. Hoffmann <je-h@gmx.net>
    Baptiste Lepilleur <gaiacrtn@free.fr> <blep@sourceforge.net>
    Bastiaan Bakker <bastiaan.bakker@lifeline.nl>
    Steve Robbins <smr99@sourceforge.net>

%prep
%setup -q -n cppunit-%version
%patch
%patch1
%patch2 -p1
libtoolize --force
aclocal -I config
autoheader
automake -a
autoconf

%build
export CXXFLAGS="$RPM_OPT_FLAGS"
./configure          \
   --prefix=/usr/    \
   --libdir=%_libdir \
   --mandir=%_mandir \
   --enable-doxygen

%install
# This package failed when testing with -Wl,-as-needed being default.
# So we disable it here, if you want to retest, just delete this comment and the line below.
export SUSE_ASNEEDED=0
make DESTDIR=$RPM_BUILD_ROOT install
# this got also installed to %_defaultdocdir
rm -rf $RPM_BUILD_ROOT/usr/share/cppunit/html/
find $RPM_BUILD_ROOT/usr/include -type f | xargs chmod a-x
# install susehelp file
mkdir -p $RPM_BUILD_ROOT/usr/share/susehelp/meta/Development/Libraries/
install %SOURCE1 $RPM_BUILD_ROOT/usr/share/susehelp/meta/Development/Libraries/
%suse_update_desktop_file $RPM_BUILD_ROOT/usr/share/susehelp/meta/Development/Libraries/cppunit-devel.desktop

%clean
rm -rf $RPM_BUILD_ROOT

%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig

%files
%defattr(-,root,root)
%doc AUTHORS COPYING 
%_libdir/libcppunit*.so.*
/usr/share/cppunit

%files -n libcppunit-devel
%defattr(-,root,root,755)
%doc NEWS README THANKS ChangeLog
/usr/bin/DllPlugInTester
/usr/bin/cppunit-config
%_libdir/libcppunit*.so
%_libdir/libcppunit*a
%_libdir/pkgconfig/cppunit.pc
/usr/share/susehelp
/usr/include/*
%_mandir/*/*
/usr/share/aclocal/cppunit.m4
%doc doc/html/*

%changelog
openSUSE Build Service is sponsored by