Blob Blame Raw

# Building the extra print profiles requires colprof, +4Gb of RAM and
# quite a lot of time. Don't enable this for test builds.
%define enable_print_profiles 0

# SANE is pretty insane when it comes to handling devices, and we get AVCs
# popping up all over the place.
%define enable_sane 0

# Don't build the print profiles for secondary architectures on the
# logic that these are probably not doing press proofing or editing
# in different CMYK spaces
%ifarch %{ix86} x86_64
%define build_print_profiles %{?enable_print_profiles}
%define build_print_profiles 0

Summary:   Color daemon
Name:      colord
Version:   0.1.34
Release:   1%{?dist}
License:   GPLv2+ and LGPLv2+

BuildRequires: dbus-devel
BuildRequires: docbook-utils
BuildRequires: gettext
BuildRequires: glib2-devel
BuildRequires: intltool
BuildRequires: systemd-devel
BuildRequires: lcms2-devel >= 2.2
BuildRequires: libgudev1-devel
BuildRequires: polkit-devel >= 0.103
BuildRequires: sqlite-devel
BuildRequires: gobject-introspection-devel
BuildRequires: vala-tools
BuildRequires: libgusb-devel
BuildRequires: gtk-doc
BuildRequires: color-filesystem
%if !0%{?rhel}
BuildRequires: bash-completion
%if 0%{?build_print_profiles}
BuildRequires: argyllcms

# for SANE support
%if 0%{?enable_sane}
BuildRequires: sane-backends-devel
BuildRequires: dbus-devel

Requires: color-filesystem
Requires: systemd-units
Requires(pre): shadow-utils

# Self-obsoletes to fix the multilib upgrade path
Obsoletes: colord < 0.1.27-3

# obsolete separate profiles package
Obsoletes: shared-color-profiles <= 0.1.6-2
Provides: shared-color-profiles

colord is a low level system activated daemon that maps color devices
to color profiles in the system context.

%package libs
Summary: Color daemon library

%description libs
colord is a low level system activated daemon that maps color devices
to color profiles in the system context.

%package devel
Summary: Development package for %{name}
Requires: %{name} = %{version}-%{release}
Requires: %{name}-libs = %{version}-%{release}
Obsoletes: colorhug-client-devel <= 0.1.13

%description devel
Files for development with %{name}.

%package devel-docs
Summary: Developer documentation package for %{name}
Requires: %{name} = %{version}-%{release}
BuildArch: noarch

%description devel-docs
Documentation for development with %{name}.

%package extra-profiles
Summary: More color profiles for color management that are less commonly used
Requires: %{name} = %{version}-%{release}
BuildArch: noarch

# obsolete separate profiles package
Obsoletes: shared-color-profiles-extra <= 0.1.6-2
Provides: shared-color-profiles-extra

%description extra-profiles
More color profiles for color management that are less commonly used.
This may be useful for CMYK soft-proofing or for extra device support.

%setup -q

# we can't use _hardened_build here, see
export CFLAGS='-fPIC %optflags'
export LDFLAGS='-pie -Wl,-z,now -Wl,-z,relro'

# Set ~2 GiB limit so that colprof is forced to work in chunks when
# generating the print profile rather than trying to allocate a 3.1 GiB
# chunk of RAM to put the entire B-to-A tables in.
ulimit -Sv 2000000
%configure \
        --with-daemon-user=colord \
        --enable-gtk-doc \
        --enable-vala \
%if 0%{?build_print_profiles}
        --enable-print-profiles \
        --disable-print-profiles \
%if 0%{?enable_sane}
        --enable-sane \
        --disable-static \
        --disable-rpath \
        --disable-examples \
        --disable-silent-rules \

make %{?_smp_mflags}


# Remove static libs and libtool archives.
find %{buildroot} -name '*.la' -exec rm -f {} ';'
find %{buildroot} -name '*.a' -exec rm -f {} ';'

# databases
touch $RPM_BUILD_ROOT%{_localstatedir}/lib/colord/mapping.db
touch $RPM_BUILD_ROOT%{_localstatedir}/lib/colord/storage.db

%find_lang %{name}

getent group colord >/dev/null || groupadd -r colord
getent passwd colord >/dev/null || \
    useradd -r -g colord -d /var/lib/colord -s /sbin/nologin \
    -c "User for colord" colord
exit 0

glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || :
%systemd_post colord.service

%systemd_preun colord.service

glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || :
%systemd_postun colord.service

%files -f %{name}.lang
%attr(755,colord,colord) %dir %{_localstatedir}/lib/colord
%attr(755,colord,colord) %dir %{_localstatedir}/lib/colord/icc
%if !0%{?rhel}
%config %{_sysconfdir}/colord.conf
%verify(not size md5 mtime) %attr(-,colord,colord) %{_localstatedir}/lib/colord/*.db

# session helper

# sane helper
%if 0%{?enable_sane}

# common colorspaces
%dir %{_icccolordir}/colord

# so we can display at least something in the default dropdown
%if 0%{?build_print_profiles}

# monitor test profiles

# named color profiles

%files libs

%files extra-profiles
%if 0%{?build_print_profiles}

# other colorspaces not often used

# other named color profiles not generally useful

%files devel

%files devel-docs
%dir %{_datadir}/gtk-doc/html/colord

* Wed May 01 2013 Richard Hughes <> 0.1.34-1
- New upstream version
- Add a ICC transform object for simple RGB conversions
- Add a warning for RGB profiles with unlikely whitepoint values
- Add Qt DBus annotations
- Allow clients to call org.freedesktop.DBus.Peer
- Correct a lot more company names when creating devices
- Do not automatically add EDID profiles with warnings to devices
- Increase the delay between patches in the session-helper
- Install the bash completion support into /usr

* Wed Apr 24 2013 Václav Pavlín <> - 0.1.33-2
- Add new systemd macros (#856659)

* Tue Apr 16 2013 Richard Hughes <> 0.1.33-1
- New upstream version
- Add some translated profile descriptions for the CMYK profiles
- Add the FOGRA45L and FOGRA47L CMYK and eciRGBv1 profiles
- Check the generated CCMX matrix for invalid data
- Do not print a warning if the DBus property does not exist
- Ensure mbstowcs() has an LC_CTYPE of 'en_US.UTF-8'
- Always write C-locale floating point values in IT8 files
- Initialize the value of the CCMX matrix
- Never promote localized v2 ICC profiles to v4
- Rename ISOnewspaper26 to IFRA26S_2004_newsprint

* Thu Mar 28 2013 Richard Hughes <> 0.1.32-1
- New upstream version
- Add a new tool 'cd-iccdump' that can dump V4 and V2 profiles
- Add translated descriptions to the ICC profiles

* Mon Mar 18 2013 Richard Hughes <> 0.1.31-1
- New upstream version
- Calculate the display calibration based on the Lab and target display gamma
- Interpolate the gamma data to the VCGT size using Akima
- Add some more display vendor names to the display fixup table
- Fix the argyll sensor driver when using the ColorMunki Smile
- Fix the gamut warning to check primaries wider than CIERGB and ProPhoto
- Move the private sensor libraries out of the pure lib space

* Mon Feb 18 2013 Richard Hughes <> 0.1.30-1
- New upstream version
- Append -private to the driver libraries as they have no headers installed
- Do not show duplicate profiles when icc-profiles-openicc is installed
- Speed up the daemon loading and use less I/O at startup

* Mon Feb 04 2013 Richard Hughes <> 0.1.29-1
- New upstream version
- Add a --verbose and --version argument to colormgr
- Add DTP94 native sensor support
- Allow profiles to have a 'score' which affects the standard space
- Change the Adobe RGB description to be 'Compatible with Adobe RGB (1998)'
- Detect profiles from and and add metadata
- Do not auto-add profiles due to device-id metadata if they have been removed
- Ensure profiles with MAPPING_device_id get auto-added to devices
- Install various helper libraries for access to hardware
- Set the additional 'OwnerCmdline' metadata on each device

* Fri Jan 18 2013 Richard Hughes <> 0.1.28-2
- Backport some fixes from upstream for gnome-settings-daemon.

* Wed Jan 16 2013 Richard Hughes <> 0.1.28-1
- New upstream version
- Add some default GSetting schema values for the calibration helper
- Add the sensor images as metadata on the D-Bus interface
- Quit the session helper if the device or sensor was not found

* Mon Jan 14 2013 Richard Hughes <> 0.1.27-4
- Add BR systemd-devel so the seat tracking stuff works
- Build with full compiler output
- Do not build the profiles in parallel, backported from upstream
- Limit the memory allocation to 2GiB when building profiles
- Do not attempt to build the print profiles on ARM or PPC hardware

* Fri Jan 11 2013 Kalev Lember <> 0.1.27-3
- Added self-obsoletes to 'colord' subpackage to fix the multilib upgrade path

* Thu Jan 10 2013 Kalev Lember <> 0.1.27-2
- Split out libcolord to colord-libs subpackage, so that the daemon package
  doesn't get multilibbed

* Tue Jan 08 2013 Richard Hughes <> 0.1.27-1
- New upstream version
- Add some more calibration attach images
- Import shared-color-profiles into colord
- Install a header with all the session helper defines

* Mon Jan  7 2013 Matthias Clasen <> 0.1.26-2
- Enable hardened build

* Wed Dec 19 2012 Richard Hughes <> 0.1.26-1
- New upstream version
- Add a session helper that can be used to calibrate the screen
- Add some defines for the Spyder4 display colorimeter
- Add support for reading and writing .cal files to CdIt8
- Add the ability to 'disable' a device from a color POV
- Create ICCv2 profiles when using cd-create-profile
- Use enumerated error values in the client library
- Use spotread when there is no native sensor driver

* Mon Nov 26 2012 Richard Hughes <> 0.1.25-1
- New upstream version
- Add a create-standard-space sub-command to cd-create-profile
- Add a profile metadata key of 'License'
- Add a set-version command to the cd-fix-profile command line tool
- Create linear vcgt tables when using create-x11-gamma
- Fix GetStandardSpace so it can actually work
- Move the named color examples to shared-color-profiles

* Wed Nov 21 2012 Richard Hughes <> 0.1.24-2
- Apply a patch from upstream so we can use cd-fix-profile in
  situations without D-Bus.

* Fri Oct 26 2012 Richard Hughes <> 0.1.24-1
- New upstream version
- Fix a critical warning when user tries to dump a non-icc file
- Remove libsane support and rely only on udev for scanner information
- Set the seat for devices created in the session and from udev

* Wed Aug 29 2012 Richard Hughes <> 0.1.23-1
- New upstream version
- Assorted documentation fixes
- Do not try to add duplicate sysfs devices

* Wed Jul 18 2012 Fedora Release Engineering <> - 0.1.22-2
- Rebuilt for

* Wed Jun 27 2012 Richard Hughes <> 0.1.22-1
- New upstream version
- Split out colord-gtk to a new sub-project to prevent a dep loop
- Add many generic introspection type arguments
- Check any files in /usr/share/color/icc have the content type
- Do not create the same object paths if two sensors are plugged in
- Fix the udev rules entry for the i1Display3

* Tue May 22 2012 Richard Hughes <> 0.1.21-1
- New upstream version
- Do not install any parts of colord-sane if --disable-sane is specified
- Fix InstallSystemWide() by not writing a private file
- Save the CCMX and ITx files to be compatible with argyllcms
- The ColorHug has a new VID and PID

* Wed May 09 2012 Richard Hughes <> 0.1.20-1
- New upstream version
- Add a sensor-set-options command to the colormgr tool
- Add the concept of 'options' on each color sensor device
- Enable gtk-doc in the default distro build

* Tue Apr 17 2012 Richard Hughes <> 0.1.19-1
- New upstream version
- Add a user suffix to the object path of user-created devices and profiles

* Thu Mar 29 2012 Richard Hughes <> 0.1.18-2
- Disable PrivateNetwork=1 as it breaks sensor hotplug.

* Thu Mar 15 2012 Richard Hughes <> 0.1.18-1
- New upstream version
- Add a Manager.CreateProfileWithFd() method for QtDBus
- Split out the SANE support into it's own process
- Fix a small leak when creating devices and profiles in clients
- Fix cd-fix-profile to add and remove metadata entries
- Install per-machine profiles in /var/lib/colord/icc

* Wed Feb 22 2012 Richard Hughes <> 0.1.17-1
- New upstream version
- Add an LED sample type
- Add PrivateNetwork and PrivateTmp to the systemd service file
- Fix InstallSystemWide() when running as the colord user

* Fri Jan 20 2012 Matthias Clasen <> - 0.1.16-4
- Fix some obvious bugs

* Tue Jan 17 2012 Richard Hughes <> 0.1.16-1
- New upstream version
- Now runs as a colord user rather than as root.
- Support more ICC metadata keys
- Install a systemd service file
- Support 2nd generation Huey hardware

* Thu Jan 12 2012 Fedora Release Engineering <> - 0.1.15-2
- Rebuilt for

* Sat Nov 26 2011 Richard Hughes <> 0.1.15-1
- New upstream version
- This release fixes an important security bug: CVE-2011-4349.
- Do not crash the daemon if adding the device to the db failed
- Fix a memory leak when getting properties from a device

* Tue Nov 01 2011 Richard Hughes <> 0.1.14-1
- New upstream version
- Remove upstreamed patches

* Mon Oct 03 2011 Richard Hughes <> 0.1.13-1
- New upstream version
- Ensure uid 0 can always create devices and profiles
- Reduce the CPU load of clients when assigning profiles

* Tue Aug 30 2011 Richard Hughes <> 0.1.12-1
- New upstream version

* Mon Aug 01 2011 Richard Hughes <> 0.1.11-2
- Remove the sedding libtool's internals as it breaks
  generation of the GObject Introspection data.

* Mon Aug 01 2011 Richard Hughes <> 0.1.11-1
- New upstream version

* Wed Jul 06 2011 Richard Hughes <> 0.1.10-1
- New upstream version

* Mon Jun 13 2011 Richard Hughes <> 0.1.9-1
- New upstream version

* Thu Jun 02 2011 Richard Hughes <> 0.1.8-1
- New upstream version
- Add a webcam device kind
- Add a timestamp when making profiles default
- Add support for reading and writing ICC profile metadata
- Allow the client to pass file descriptors out of band to CreateProfile
- Prettify the device vendor and model names
- Split out the sensors into runtime-loadable shared objects
- Provide some GIO async variants for the methods in CdClient
- Ensure GPhoto2 devices get added to the device list

* Fri May 06 2011 Richard Hughes <> 0.1.7-1
- New upstream version.
- Create /var/lib/colord at buildtime not runtime for SELinux
- Ensure profiles with embedded profile checksums are parsed correctly
- Move the colorimeter rules to be run before 70-acl.rules
- Stop watching the client when the sensor is finalized
- Ensure the source is destroyed when we unref CdUsb to prevent a crash
- Only enable the volume mount tracking when searching volumes

* Tue Apr 26 2011 Richard Hughes <> 0.1.6-2
- Own /var/lib/colord and /var/lib/colord/*.db

* Sun Apr 24 2011 Richard Hughes <> 0.1.6-1
- New upstream version.

* Thu Mar 31 2011 Richard Hughes <> 0.1.5-1
- New upstream version.

* Wed Mar 09 2011 Richard Hughes <> 0.1.4-1
- New upstream version.

* Mon Feb 28 2011 Richard Hughes <> 0.1.3-1
- New upstream version.

* Tue Feb 08 2011 Fedora Release Engineering <> - 0.1.1-3
- Rebuilt for

* Fri Jan 28 2011 Richard Hughes <> 0.1.1-2
- Rebuild in the vain hope koji isn't broken today.

* Wed Jan 26 2011 Richard Hughes <> 0.1.1-1
- New upstream version.

* Thu Jan 13 2011 Richard Hughes <> 0.1.0-1
- Initial version for Fedora package review.