File libarea.spec of Package libarea
#
# spec file for package libarea
#
# Copyright (c) 2013 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/
#
%define soname 0
Name: libarea
Version: 0.1.0
Release: 0
Summary: Area C++ class with a Python module
License: GPL-2.0
Group: Development/Libraries/C and C++
Url: http://code.google.com/p/libarea/
Source0: libarea.tar.bz2
# PATCH-MISSING-TAG -- See http://wiki.opensuse.org/openSUSE:Packaging_Patches_guidelines
Patch0: python-include-dir.patch
# PATCH-MISSING-TAG -- See http://wiki.opensuse.org/openSUSE:Packaging_Patches_guidelines
Patch1: python-2.7.patch
# PATCH-MISSING-TAG -- See http://wiki.opensuse.org/openSUSE:Packaging_Patches_guidelines
Patch2: libname.patch
# PATCH-MISSING-TAG -- See http://wiki.opensuse.org/openSUSE:Packaging_Patches_guidelines
Patch3: libarea-gcc43.patch
BuildRequires: gcc
BuildRequires: gcc-c++
BuildRequires: make
BuildRequires: python-devel
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
Derived from the kbool library written by
Klaas Holwerda http://boolean.klaasholwerda.nl/bool.html
This project has a CArea class with functions
like CArea::Offset(double inwards value).
%package -n %{name}%{soname}
Summary: Area C++ class with a Python module
Group: Development/Libraries/C and C++
%description -n %{name}%{soname}
Derived from the kbool library written by
Klaas Holwerda http://boolean.klaasholwerda.nl/bool.html
This project has a CArea class with functions
like CArea::Offset(double inwards value).
%package devel
Summary: Area C++ class with a Python module
Group: Development/Libraries/C and C++
Requires: %{name}%{soname} = %{version}
%description devel
Derived from the kbool library written by
Klaas Holwerda http://boolean.klaasholwerda.nl/bool.html
This project has a CArea class with functions
like CArea::Offset(double inwards value).
%prep
%setup -q -n libarea
%patch0 -p1
%if 0%{?suse_version} >= 1110
%patch1 -p1
%endif
%patch2 -p1
%patch3 -p1
%build
make %{?_smp_mflags}
%install
mkdir -p %{buildroot}/%{_libdir}
cp libarea.so.0.1.0 %{buildroot}/%{_libdir}/
ln -s %{_libdir}/libarea.so.0.1.0 %{buildroot}/%{_libdir}/libarea.so
ln -s %{_libdir}/libarea.so.0.1.0 %{buildroot}/%{_libdir}/libarea.so.0
%post -n %{name}%{soname} -p /sbin/ldconfig
%postun -n %{name}%{soname} -p /sbin/ldconfig
%files -n %{name}%{soname}
%defattr(-,root,root)
%{_libdir}/libarea.so.0*
%files devel
%defattr(-,root,root)
%{_libdir}/libarea.so
%changelog