File icc-examin.spec of Package icc-examin

#
# spec file for package icc-examin
#
# Copyright (c) 2016 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/
#


%define pixmapdir       %{_datadir}/pixmaps
%define desktopdir      %{_datadir}/applications
Name:           icc-examin
Version:        0.56
Release:        0
Summary:        ICC profile viewer and colour visualisation
License:        (GPL-2.0+ and SUSE-FLTK) and BSD-2-Clause
Group:          Productivity/Graphics/Other
Url:            http://www.oyranos.org/icc-examin
Source:         %{name}_%{version}.orig.tar.bz2
Obsoletes:      icc_examin <= 0.54
Provides:       icc_examin == %{version}
BuildRequires:  desktop-file-utils
BuildRequires:  fltk-devel
%if 0%{?centos_version} == 0
BuildRequires:  ftgl-devel
%endif
BuildRequires:  gcc-c++
BuildRequires:  gettext
BuildRequires:  libjpeg-devel
BuildRequires:  liboyranos-devel
BuildRequires:  libpng-devel
BuildRequires:  libtiff-devel
BuildRequires:  libtool
BuildRequires:  libxml2-devel
BuildRequires:  pkgconfig
BuildRequires:  shared-mime-info
Requires:       oyranos
Requires:       oyranos-monitor
Requires:       oyranos-profile-graph
Requires:       oyranos-ui-fltk
%if 0%{?suse_version}
Recommends:     oyranos-qcmsevents
BuildRequires:  Mesa-devel
BuildRequires:  expat
BuildRequires:  fontconfig-devel
BuildRequires:  freetype2-devel
BuildRequires:  gcc-c++
BuildRequires:  gettext-devel
BuildRequires:  libXcm-devel
BuildRequires:  libjpeg-devel
BuildRequires:  liblcms-devel
BuildRequires:  libpng-devel
BuildRequires:  pkgconfig
BuildRequires:  update-desktop-files
BuildRequires:  xdg-utils
BuildRequires:  xorg-x11-libX11-devel
BuildRequires:  xorg-x11-libXext-devel
BuildRequires:  xorg-x11-libXpm-devel
BuildRequires:  xorg-x11-libXrender-devel
BuildRequires:  zlib-devel
Recommends:     freefont
Recommends:     %{name}-lang
%endif
%if 0%{?suse_version}
BuildRequires:  pkgconfig(glu)
%endif
%if 0%{?fedora_version} > 0
BuildRequires:  Mesa
BuildRequires:  Mesa-devel
BuildRequires:  fltk
BuildRequires:  fltk-devel
BuildRequires:  fltk-fluid
BuildRequires:  libXmu-devel
BuildRequires:  libXpm-devel
BuildRequires:  libXxf86vm-devel
BuildRequires:  libqt4-devel
BuildRequires:  xdg-utils
BuildRequires:  xorg-x11-Mesa-devel
BuildRequires:  xorg-x11-devel
%endif

%if 0%{?rhel_version} >= 600
BuildRequires:  Mesa
BuildRequires:  Mesa-devel
BuildRequires:  fltk
BuildRequires:  fltk-devel
BuildRequires:  fltk-fluid
BuildRequires:  libXmu-devel
BuildRequires:  libXpm-devel
BuildRequires:  libXxf86vm-devel
BuildRequires:  libqt4-devel
BuildRequires:  xorg-x11-Mesa-devel
%endif

%if 0%{?centos_version} >= 600
BuildRequires:  Mesa
BuildRequires:  Mesa-devel
BuildRequires:  fltk
BuildRequires:  fltk-devel
BuildRequires:  fltk-fluid
BuildRequires:  libXmu-devel
BuildRequires:  libXpm-devel
BuildRequires:  libXxf86vm-devel
BuildRequires:  libqt4-devel
BuildRequires:  xorg-x11-Mesa-devel
%endif

%description
ICC Examin is a small utility (unix name: iccexamin) for the
purpose of watching the internals of ICC profiles, measurement
data (CGATS), colour samples (named colour profiles), gamut
visualisations (vrml), video card gamma tables (Xorg/XFree86/osX).

%if 0%{?suse_version}
%lang_package
%endif

%prep
%setup -q

%build
%configure
make %{?_smp_mflags} || make

%install
make DESTDIR=%{buildroot} install %{?_smp_mflags}
%find_lang icc-examin       # generate a special file list
%if 0%{?suse_version} > 1010
find %{buildroot} -type f -name "*.ttf" -delete -print
%suse_update_desktop_file -n  iccexamin # some openSUSE magic
%endif

%post
update-mime-database %{_datadir}/mime/

%postun
update-mime-database %{_datadir}/mime/

%files -f %{name}.lang
%defattr(-, root, root)
%doc AUTHORS COPYING ChangeLog.md README.md
%{_bindir}/iccexamin
%{desktopdir}/iccexamin.desktop
%{pixmapdir}/iccexamin.png
%dir %{pixmapdir}/hicolor
%dir %{pixmapdir}/hicolor/scalable
%{pixmapdir}/hicolor/scalable/iccexamin.svg
%if 0%{?suse_version} < 1010
%{_datadir}/fonts/FreeSans.ttf
%endif
%{_mandir}/man1/iccexamin.*

%changelog
openSUSE Build Service is sponsored by