File xclass.spec of Package xclass

#
# spec file for package xclass
#
# Copyright (c) 2014 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:           xclass
Version:        0.9.2
Release:        0
Summary:        Library for Uniform Presentation of fvwm95 Programs
License:        GPL-2.0+ and LGPL-2.1+
Group:          System/Libraries
Url:            http://xclass.sourceforge.net/
Source:         %{name}-%{version}.tar.bz2
Patch0:         %{name}-%{version}-configs.patch
Patch1:         %{name}-%{version}-gcc-3.1.patch
Patch2:         %{name}-%{version}-gcc-4.0.patch
Patch3:         %{name}-%{version}-gcc-4.1.patch
BuildRequires:  autoconf
BuildRequires:  gcc-c++
BuildRequires:  pkgconfig(gl)
BuildRequires:  pkgconfig(x11)
BuildRequires:  pkgconfig(xext)
BuildRequires:  pkgconfig(xpm)
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
This package contains a library for uniform presentation of fvwm95
programs.

%package devel
Summary:        Library for Uniform Presentation of fvwm95 Programs - development files
License:        LGPL-2.1+
Group:          System/Libraries
Requires:       %{name} = %{version}
Requires:       libstdc++-devel
Requires:       pkgconfig
Requires:       pkgconfig(gl)
Requires:       pkgconfig(x11)
Requires:       pkgconfig(xpm)

%description devel
This package contains development files for xclass library.

%prep
%setup -q
%patch0 -p1
%patch1 -p1
%patch2
%patch3

%build
autoconf
%configure --enable-debug=no
make %{?_smp_mflags} shared
make %{?_smp_mflags} all

%install
mv lib/libxclass/icons/*.xpm icons/
make DESTDIR=%{buildroot} install %{?_smp_mflags}
make DESTDIR=%{buildroot} install_shared
install -m 644 include/xclass/XCconfig.h %{buildroot}%{_includedir}/XCconfig.h

%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig

%files
%defattr(-,root,root)
%doc %{_defaultdocdir}/%{name}/
%config %{_sysconfdir}/xclassrc
%{_datadir}/xclass/
%{_libdir}/libxclass.so.*

%files devel
%defattr(-,root,root)
%{_bindir}/xc-config
%{_includedir}/XCconfig.h
%{_includedir}/xclass/
%exclude %{_libdir}/libxclass.a
%{_libdir}/libxclass.so

%changelog
openSUSE Build Service is sponsored by