File xbase.spec of Package xbase

#
# spec file for package xbase
#
# Copyright (c) 2015 SUSE LINUX 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:           xbase
Version:        2.0.0
Release:        0
Summary:        XBase Compatible C++ Class Library
License:        LGPL-2.1+
Group:          Productivity/Databases/Tools
Url:            http://linux.techass.com/projects/xdb/#downloads
Source0:        http://prdownloads.sourceforge.net/xdb/%{name}-%{version}.tar.gz
Patch1:         %{name}-%{version}-makefiles.patch
Patch2:         %{name}-%{version}-gcc41fix.patch
Patch3:         %{name}-%{version}-iostream_h.patch
Patch4:         %{name}-%{version}-array-del.patch
Patch5:         %{name}-%{version}-gcc47.patch
Patch6:         xbase-automake-1.13.patch
BuildRequires:  autoconf
BuildRequires:  automake
BuildRequires:  doxygen
BuildRequires:  gcc-c++
BuildRequires:  libtool
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
This is an XBase (dBase and FoxPro, for example) compatible C++ class
library.

This package contains header files, a library, some command line tools,
and developer documentation.

%package devel
Summary:        Developmnet files for XBase Compatible C++ Class Library
Group:          Development/Libraries/C and C++
Requires:       %{name} = %{version}
Requires:       libstdc++-devel
Provides:       xbase:%{_includedir}/xbase/dbf.h

%description devel
This is an XBase (dBase and FoxPro, for example) compatible C++ class
library.

This package contains header files and development files.

%package doc
Summary:        Developer documentation for XBase Compatible C++ Class Library
Group:          Productivity/Databases/Tools
Requires:       %{name} = %{version}
Provides:       xbase:%{_docdir}/xbase-doc/html/classes.html

%description doc
Developer documentation for XBase (dBase and FoxPro, for example)
compatible C++ class library.

This package contains header files, a library, some command line tools,
and developer documentation.

%prep
%setup -q
%patch1
%patch2
%patch3
%patch4
%patch5 -p1
%patch6 -p1

%build
autoreconf -fiv
%configure --disable-static --with-pic
make %{?_smp_mflags}

%install
make DESTDIR="$RPM_BUILD_ROOT" install
mv %{buildroot}%{_bindir}/zap %{buildroot}%{_bindir}/xbase-zap
find %{buildroot} -type f -name "*.la" -delete -print

%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig

%files
%defattr(-,root,root)
%doc AUTHORS TODO COPYING README NEWS
%{_bindir}/*
%{_libdir}/libxbase*.so.*

%files devel
%defattr(-,root,root)
%{_libdir}/libxbase.so
%{_includedir}/xbase

%files doc
%defattr(-,root,root)
%doc docs/html

%changelog
openSUSE Build Service is sponsored by