File lcms.spec of Package lcms

#
# spec file for package lcms (Version 1.18a)
#
# Copyright (c) 2009 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:           lcms
BuildRequires:  gcc-c++ libtiff-devel python-devel swig
License:        MIT License (or similar)
Group:          Productivity/Graphics/Other
Summary:        Utilities for the Little CMS Engine
Url:            http://www.littlecms.com/
Version:        1.18a
Release:        1
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Source0:        %{name}-%{version}.tar.bz2
Patch:          lcms-endian.patch
Patch1:         lcms-strict-aliasing.patch
Patch2:         lcms-implicit-declaration.patch
# PATCH-FIX-SECURITY lcms-bnc521513.patch sbrabec@suse.cz -- Fix of incorrect CVE-2009-0793 security fix.
Patch3:         lcms-bnc521513.patch
# bug437293
%ifarch ppc64
Obsoletes:      liblcms-64bit
%endif
#
# Package name for <= 10.3 and <=SLE10:
Provides:       liblcms = %{version}
Obsoletes:      liblcms <= 1.16

%description
Little cms is a small speed optimized color management engine.



Authors:
--------
    Marti Maria <info@littlecms.com>

%package -n liblcms1
License:        MIT License (or similar)
Summary:        Libraries for the Little CMS Engine
Group:          System/Libraries
#workaround for wrong package naming
Provides:       liblcms0 = %{version}
Obsoletes:      liblcms0 <= %{version}
Requires:       %{name} = %{version}

%description -n liblcms1
Little cms is a small speed optimized color management engine.



Authors:
--------
    Marti Maria <info@littlecms.com>

%package -n liblcms-devel
License:        MIT License (or similar)
Summary:        Include Files and Libraries Mandatory for Development
Requires:       liblcms1 = %{version} glibc-devel
Group:          Development/Libraries/C and C++
# bug437293
%ifarch ppc64
Obsoletes:      liblcms-devel-64bit
%endif
#

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



Authors:
--------
    Marti Maria <info@littlecms.com>

%package -n python-lcms
License:        MIT License (or similar)
Summary:        Python Bindings for the Little CMS Engine
Group:          Development/Libraries/Python
%py_requires

%description -n python-lcms
Little cms is a small speed optimized color management engine.



Authors:
--------
    Marti Maria <info@littlecms.com>

%prep
%setup -q -n %{name}-1.18
%patch
%patch1
%patch2
%patch3 -p1
cp -a README.1ST README
chmod -x COPYING AUTHORS NEWS README doc/*.TXT

%build
autoreconf -f -i
cd python
./swig_lcms
cd ..
%configure\
	--disable-static\
	--with-python
make %{?jobs:-j%jobs}

%check
make %{?jobs:-j%jobs} check
#make utils

%install
%makeinstall
rm $RPM_BUILD_ROOT%{_libdir}/*.la $RPM_BUILD_ROOT%{py_sitedir}/_lcms.la

%clean
rm -rf $RPM_BUILD_ROOT

%post -n liblcms1 -p /sbin/ldconfig

%postun -n liblcms1 -p /sbin/ldconfig

%files
%defattr(-,root,root)
%doc COPYING AUTHORS NEWS README
%{_bindir}/*
%{_mandir}/man?/*.*

%files -n liblcms1
%defattr(-,root,root)
%{_libdir}/liblcms.so.1*

%files -n liblcms-devel
%defattr(-,root,root)
%doc doc/*.TXT
%{_includedir}/*.h
%{_libdir}/*.so
%{_libdir}/pkgconfig/*.pc

%files -n python-lcms
%defattr(-,root,root,-)
%{py_sitedir}/lcms.py*
%{py_sitedir}/_lcms.so

%changelog
openSUSE Build Service is sponsored by