Ubuntu

Completely replace lcms1 by lcms2 in Ubuntu

Reported by Till Kamppeter on 2011-11-02
28
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Enblend
Medium
Christoph Spiel
Inkscape
High
Jon A. Cruz
Wine
Fix Released
Wishlist
digiKam
Fix Released
Medium
cups-filters (Ubuntu)
High
Till Kamppeter
dcraw (Ubuntu)
Medium
Unassigned
digikam (Ubuntu)
Medium
Rohan Garg
enblend (Ubuntu)
Medium
Unassigned
enblend-enfuse (Ubuntu)
Medium
Unassigned
f-spot (Ubuntu)
Medium
Unassigned
geeqie (Ubuntu)
Medium
Unassigned
gimp (Ubuntu)
Medium
Unassigned
imagemagick (Ubuntu)
Medium
broucaries
inkscape (Ubuntu)
Medium
Canonical Desktop Team
lcms (Ubuntu)
Medium
Unassigned
libkdcraw (Ubuntu)
Medium
Philip Muškovac
libmng (Ubuntu)
Medium
Unassigned
libraw (Ubuntu)
Medium
Chris Halse Rogers
openjdk-6 (Ubuntu)
Medium
Unassigned
poppler (Ubuntu)
Medium
Canonical Desktop Team
python-imaging (Ubuntu)
Medium
Unassigned
rawstudio (Ubuntu)
Medium
Unassigned
scribus (Ubuntu)
Medium
Unassigned
shotwell (Ubuntu)
Low
Canonical Desktop Team
ufraw (Ubuntu)
Medium
Unassigned
wine1.4 (Ubuntu)
Low
Unassigned
xsane (Ubuntu)
Medium
Unassigned

Bug Description

Many packages in Ubuntu use the liblcms1 library (source package lcms). This library is discontinued upstream and replaced by liblcms2. Due to this, bugs in liblcms1 are not fixed any more upstream and important improvements in color reproduction and safety against crashes are not done. Therefore we should remove lcms1 and migrate all programs using it to lcms2.

Launchpad doesn't usually scale to track transitions like these. Please see a tracker instead:
http://people.canonical.com/~ubuntu-archive/transitions/lcms2.html

While running 'configure' I see these lines in its screen output:

    154 checking lcms.h usability... no
    155 checking lcms.h presence... no
    156 checking for lcms.h... no
    157 checking lcms/lcms.h usability... no
    158 checking lcms/lcms.h presence... no
    159 checking for lcms/lcms.h... no
.

According to http://sourceforge.net/projects/lcms/files/ at the moment the latest tarball is lcms2-2.0a.tar.gz and its header files (when installed) are:

"
sergei@amdam2:~/junk> ls -ltr /mnt/sdb8/sergei/AFSWD_debug/install/lcms-2.0/include/
total 117
-rw-r--r-- 1 qemu users 24622 2010-07-05 03:59 lcms2_plugin.h
-rw-r--r-- 1 qemu users 91214 2010-07-05 03:59 lcms2.h
sergei@amdam2:~/junk>
".

I.e. configure should check for version 2.0 or later and check existence of 'lcms2.h' rather than 'lcms.h' file.

Which distributions include lcms2?

(In reply to comment #1)
> Which distributions include lcms2?

As far as I could tell, no distribution carries lcms2 in a primary package repository, although Fedora seems to have it in updates-candidate and Gentoo carries an ebuild marked as testing.

Then this is not a bug at all, at the most just an enhancement request.

(In reply to comment #1)
> Which distributions include lcms2?

I have no idea and I don't care. I build and install everything I need in the directories I want, which are not system directories. From time to time I upgrade packages versions.

So, less than a month ago I discovered the new lcms version and upgraded.

(In reply to comment #3)
> Then this is not a bug at all, at the most just an enhancement request.

Maybe.

But then I see a chicken-egg problem. A distro can't start supporting 'lcms2' because 'wine' doesn't support it and 'wine' won't support 'lcms2' because no distro includes it.

(In reply to comment #5)
> But then I see a chicken-egg problem. A distro can't start supporting 'lcms2'
> because 'wine' doesn't support it and 'wine' won't support 'lcms2' because no
> distro includes it.

Not really. Distributions don't care what version of packages Wine supports.
Besides, there are many other projects that use lcms.

> But then I see a chicken-egg problem. A distro can't start supporting 'lcms2'
> because 'wine' doesn't support it and 'wine' won't support 'lcms2' because no
> distro includes it.

lcms2 can be installed alongside lcms1 exactly for this reason.

(In reply to comment #7)
> > But then I see a chicken-egg problem. A distro can't start supporting 'lcms2'
> > because 'wine' doesn't support it and 'wine' won't support 'lcms2' because no
> > distro includes it.
>
> lcms2 can be installed alongside lcms1 exactly for this reason.

I know. And my environment can cope with it. Other packages which use 'lcms' silently accepted 'lcms2', so other than for 'wine' I have no need to keep both versions.

Probably in half year the issue will become relevant for 'wine'.

Created attachment 36970
initial support

Work in progress, but not sure when I'll pick it up, so leaving here for now in case someone else wants to finish it.

29 comments hidden view all 109 comments
Till Kamppeter (till-kamppeter) wrote :

Packages concerned are both in Main and Universe, nost important are naturally the ones in Main. With them being migrated we can at least demote lcms to Universe.

Changed in inkscape (Ubuntu):
assignee: nobody → Alex Valavanis (valavanisalex)
importance: Undecided → Medium
status: New → In Progress
Till Kamppeter (till-kamppeter) wrote :

cups itself does not use lcms, but the add-on filter pdftoraster does. The upstream author of the filter is informed.

Changed in cups (Ubuntu):
importance: Undecided → High
milestone: none → precise-alpha-1
status: New → In Progress
Adam Dingle (adam-yorba) wrote :

Shotwell itself does not use lcms; it uses libraw, which depends on lcms1 in Ubuntu. Note that libraw 0.13.8 (present in Oneiric) can build using either lcms1 or lcms2. So to solve this particular dependency I suspect that you only need to update your libraw packaging to build using lcms2. You might also consider updating Precise to the latest libraw (0.14.3) while you're at it.

Till Kamppeter (till-kamppeter) wrote :

Adam, on my system there is shotwell installed but no libraw and I really cannot find such a library. Are you sure that there is a libraw? Where is it, or what is its correct name?

Adam Dingle (adam-yorba) wrote :

Till: Yes, there really is a libraw. :) You're not seeing it because on Ubuntu Shotwell is built using libraw as a static library, so libraw is compiled into the Shotwell executable. It would be nice to use a shared library instead, but we can't do that at the moment because libraw.so currently lives inside libraw-dev, which we can't expect end users to install. Instead, libraw.so should be broken out into a separate package. I've created a separate Launchpad ticket for this issue: #885645.

Alex Valavanis (valavanisalex) wrote :

Source changes are needed for Inkscape for build to succeed with lcms2, so I have forwarded this upstream

tags: added: build
Alex Valavanis (valavanisalex) wrote :

Unassigning myself for Inkscape (Ubuntu) for now. I'll hopefully come back to this when I have had more time to read the API.

Changed in inkscape (Ubuntu):
assignee: Alex Valavanis (valavanisalex) → nobody
status: In Progress → Triaged
Adam Dingle (adam-yorba) wrote :

I was mistaken: the libraw shared library is available in an Ubuntu package today ('libraw2'). We should build Shotwell to use this shared library and depend on this package. I've ticketed that as #890372.

Adam Dingle (adam-yorba) wrote :

...and we also need libraw itself to link to lcms2 rather than lcms1. I've ticketed that as bug #890379.

Martin Pitt (pitti) on 2011-11-16
Changed in cups (Ubuntu):
assignee: nobody → Till Kamppeter (till-kamppeter)
Changed in libraw (Ubuntu):
assignee: nobody → Chris Halse Rogers (raof)
Martin Pitt (pitti) on 2011-11-16
Changed in poppler (Ubuntu):
assignee: nobody → Canonical Desktop Team (canonical-desktop-team)
Changed in shotwell (Ubuntu):
assignee: nobody → Chris Halse Rogers (raof)
Martin Pitt (pitti) on 2011-11-16
Changed in shotwell (Ubuntu):
assignee: Chris Halse Rogers (raof) → Canonical Desktop Team (canonical-desktop-team)
Changed in dcraw (Ubuntu):
assignee: nobody → Chris Halse Rogers (raof)
Martin Pitt (pitti) on 2011-11-16
Changed in inkscape (Ubuntu):
assignee: nobody → Canonical Desktop Team (canonical-desktop-team)
Martin Pitt (pitti) wrote :

Synced libraw 0.14.0-1 from Debian which uses lcms2 now.

Changed in libraw (Ubuntu):
status: New → Fix Released
Changed in shotwell (Ubuntu):
importance: Undecided → Low
status: New → Fix Released
Dave Walker (davewalker) on 2011-12-01
Changed in cups (Ubuntu):
milestone: precise-alpha-1 → precise-alpha-2
Christoph Spiel (cspiel) wrote :

I have a working patch in my local repository.

The Enblend team is discussing the problems arising from
LCMS V2's "unbounded mode" and how to best dodge them.

Changed in enblend:
assignee: nobody → Christoph Spiel (cspiel)
importance: Undecided → Medium
status: New → In Progress
B Bobo (yout-bobo123) on 2011-12-29
tags: added: precise
Christoph Spiel (cspiel) wrote :

Fixed in rev d0828152af73.

Changed in enblend:
status: In Progress → Fix Committed

New unstable version will have this fix in debian. For now in experimental. Wait for release team

Changed in imagemagick (Ubuntu):
assignee: nobody → broucaries (roucaries-bastien+bugs)
status: New → Fix Released

Please revert to in progress....

Martin Pitt (pitti) on 2012-01-19
Changed in imagemagick (Ubuntu):
status: Fix Released → In Progress
Martin Pitt (pitti) wrote :

Upstream patch/mail about poppler lcms2 conversion:

  http://<email address hidden>/msg06258.html

Seems lcms2 is a slight performance regression. Let's see how this develops upstream.

Changed in poppler (Ubuntu):
status: New → Triaged
Bryce Harrington (bryce) on 2012-01-20
Changed in inkscape:
importance: Undecided → High

pitti, they talk about only 5-10 % performance loss in Poppler, but for getting a much less crashing, more reliable, and maintained CM library, I would accept this performance loss. So I think I should add Otani-san's patch for further testing to Precise's package of Poppler.

Otani-san, thank you very much for the patch. I will try it out on Ubuntu's Poppler. 5-10 % performance loss is not much for the gain of stability and reliability. It should get applied.

Albert, I also highly recommend to apply this patch upstream, as using a more stable, maintained library is much more important then having 5-10 % better performance.

Changed in poppler (Ubuntu):
importance: Undecided → Medium
milestone: none → precise-alpha-2
status: Triaged → In Progress
Changed in poppler (Ubuntu):
status: In Progress → Fix Committed
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package poppler - 0.18.3-0ubuntu2

---------------
poppler (0.18.3-0ubuntu2) precise; urgency=low

  * debian/patches/poppler-lcm2.patch: Ported Poppler from liblcms1 which is
    not maintained any more upstream to the up-to-date liblcms2. Thanks to
    Koji Otani for the patch (LP: #885324).
  * debian/control: Build-depend on liblcms2-dev and not on liblcms-dev any
    more.
 -- Till Kamppeter <email address hidden> Fri, 20 Jan 2012 09:25:18 +0100

Changed in poppler (Ubuntu):
status: Fix Committed → Fix Released

For the migration of CUPS I got a patch from Koji Otani now which I am currently applying upstream to the new cups-filters packge (see https://blueprints.launchpad.net/ubuntu/+spec/desktop-p-new-cups-filters-package). As this is not yet packaged for Ubuntu I cannot move the "cups" task to "cups-filters" yet.

dino99 (9d9) wrote :

Wine1.2 & wine1.3 are affected too.

libcms2 patch for cups-filters is applied and committed upstream now.

Otani-san, thanks for your patch!

10 comments hidden view all 109 comments

It seems this is no longer a mere enhancement request and needs some escalation in priority - liblcms1 is deprecated upstream, not receiving fixes, and is being slated for removal from distributions. See, for instance, https://bugs.launchpad.net/ubuntu/+source/lcms/+bug/885324

Changed in lcms:
importance: Unknown → Wishlist
status: Unknown → Confirmed
no longer affects: lcms

(In reply to comment #10)
> It seems this is no longer a mere enhancement request and needs some escalation
> in priority - liblcms1 is deprecated upstream, not receiving fixes, and is
> being slated for removal from distributions. See, for instance,
> https://bugs.launchpad.net/ubuntu/+source/lcms/+bug/885324

When will liblcms1 be removed from which distributions? How about 32-bit
versions of liblcms2 for current 64-bit distros? I doubt we want to support
both version 1 and version 2 of liblcms in Wine.

On Ubuntu, we'd like to migrate everything away from liblcms1 by 12.04, which means this would need to be done in the 1.4 timetable.

At a distro level, supporting 32-on-64 lcms2 is just as easy as lcms1. On Ubuntu 12.04, for instance, it's already multiarched and you can just apt-get install liblcms2-2:i386. So I'd expect it to be quite available.

(In reply to comment #12)
> On Ubuntu, we'd like to migrate everything away from liblcms1 by 12.04, which
> means this would need to be done in the 1.4 timetable.
>
> At a distro level, supporting 32-on-64 lcms2 is just as easy as lcms1. On
> Ubuntu 12.04, for instance, it's already multiarched and you can just apt-get
> install liblcms2-2:i386. So I'd expect it to be quite available.

Sure, but I asked about *current* distro versions. Without a reasonable
transition period Wine is forced to support both versions of liblcms.

Fair enough, but without supporting both versions for a bit we will _never_ be able to migrate and will end up using a deprecated unsupported library forever.

To answer your question as far as Ubuntu goes, 11.10, 11.04, 10.10, and 10.04 rely on ia32-libs, so in order to support them I'll have to update the ia32-libs in the PPA to include liblcms2 (this isn't hard).

Changed in wine:
importance: Unknown → Wishlist
status: Unknown → Confirmed
Albert Astals Cid (aacid) wrote :

As poppler maintainer i want to mention that this is not going to happen upstream anytime soon unless the huge regressions in speed (some files go to 0.5 sec in rendering to 5 sec) are fixed in lcms2.

The file where rendering with Poppler/lcms2 gets significantly slower is altona_technical_1v2_x3.pdf on http://www.eci.org/doku.php?id=es:downloads It also gets significantly slower when rendering with GhostScript/lcms2 on Precise (compared to Ghostscript/lcms1 on Oneiric).

Poppler/lcms2 performance issue reported to lcms upstream:

https://github.com/mm2/Little-CMS/issues/2

Martin Pitt (pitti) on 2012-01-24
Changed in inkscape (Ubuntu):
milestone: none → ubuntu-12.04-beta-2
Martin Pitt (pitti) on 2012-01-30
Changed in cups (Ubuntu):
milestone: precise-alpha-2 → ubuntu-12.04-beta-1
affects: cups (Ubuntu) → cups-filters (Ubuntu)
Changed in cups-filters (Ubuntu):
status: In Progress → Fix Released
Martin Pitt (pitti) on 2012-01-30
Changed in cups-filters (Ubuntu):
milestone: ubuntu-12.04-beta-1 → precise-alpha-2
Changed in inkscape:
assignee: nobody → Jon A. Cruz (jon-joncruz)
status: New → In Progress
Jon A. Cruz (jon-joncruz) wrote :

Fixed in revision #10969.

Changed in inkscape:
milestone: none → 0.49
status: In Progress → Fix Committed
Changed in inkscape:
status: Fix Committed → In Progress
Philip Muškovac (yofel) on 2012-02-14
Changed in libkdcraw (Ubuntu):
assignee: nobody → Philip Muškovac (yofel)
Philip Muškovac (yofel) on 2012-02-14
Changed in kdegraphics (Ubuntu):
status: New → Invalid
Philip Muškovac (yofel) on 2012-02-14
Changed in digikam (Ubuntu):
assignee: nobody → Philip Muškovac (yofel)
status: New → In Progress
Changed in libkdcraw (Ubuntu):
status: New → In Progress
Changed in inkscape:
status: In Progress → Fix Committed
Philip Muškovac (yofel) on 2012-02-14
Changed in digikam (Ubuntu):
status: In Progress → Triaged
Changed in digikam:
importance: Unknown → Medium
status: Unknown → New
Changed in inkscape:
milestone: 0.49 → 0.48.3
Ted Gould (ted) on 2012-02-15
Changed in inkscape:
status: Fix Committed → Fix Released
Changed in digikam:
status: New → Fix Released
Changed in inkscape (Ubuntu):
status: Triaged → Fix Released
Martin Pitt (pitti) on 2012-02-24
Changed in dcraw (Ubuntu):
milestone: none → ubuntu-12.04-beta-2
no longer affects: wine1.2 (Ubuntu)
affects: wine1.3 (Ubuntu) → wine1.4 (Ubuntu)
Changed in wine1.4 (Ubuntu):
status: New → Triaged
Changed in dcraw (Ubuntu):
milestone: ubuntu-12.04-beta-2 → none
Martin Pitt (pitti) on 2012-02-24
Changed in inkscape (Ubuntu):
status: Fix Released → Triaged
Martin Pitt (pitti) on 2012-02-24
Changed in dcraw (Ubuntu):
assignee: Chris Halse Rogers (raof) → nobody
Philip Muškovac (yofel) on 2012-02-25
Changed in libkdcraw (Ubuntu):
status: In Progress → Fix Committed
Changed in wine1.4 (Ubuntu):
importance: Undecided → Low
Changed in digikam:
status: Fix Released → Unknown
29 comments hidden view all 109 comments

(In reply to comment #12)
> Ananta,
>
> thanks for feedback. I think Francesco need to see if lcms2 support compile and
> work fine under windows.
>
> For libkdcraw (bug 290157), i'm sure than libraw authors have already tested
> lcms2 support everywhere...
>
> Gilles Caulier

When running cmake on digikam-sc with lcms2, I get 2 errors.

1. When cmake examines the requirements of libkdcraw:

CMake Warning at extra/libkdcraw/CMakeLists.txt:110 (FIND_PACKAGE):
  Could not find module FindLCMS2.cmake or a configuration file for package
  LCMS2.

  Adjust CMAKE_MODULE_PATH to find FindLCMS2.cmake or set LCMS2_DIR to the
  directory containing a CMake configuration file for LCMS2. The file will
  have one of the following names:

    LCMS2Config.cmake
    lcms2-config.cmake

I do not get this problem when running cmake on libkdcraw. Also, if I copy FindLCMS2.cmake from digikam-sc/extra/libkdcraw/cmake/modules to digikam-sc/cmake/modules then it finds lcms2. How should CMakeLists.txt be adjusted to use the FindLCMS2.cmake from libkdcraw? Or, should it be permanently copied to digikam-sc/cmake/modules?

2. digikam cannot find lcms2 because there is no pkg-config, as Francesco expected:

CMake Error at r:/share/apps/cmake/modules/FindPkgConfig.cmake:323 (message):
  pkg-config tool not found
Call Stack (most recent call first):
  r:/share/apps/cmake/modules/FindPkgConfig.cmake:337 (_pkg_check_modules_internal)
  core/CMakeLists.txt:171 (pkg_check_modules)

Maybe use FindLCMS2.cmake from libkdcraw, or a similar technique as it uses for WIN32?

Git commit 712e983ff995bbcc59cb3da1f067238d95fa862a by Gilles Caulier.
Committed on 29/02/2012 at 14:34.
Pushed by cgilles into branch 'master'.

Add missing LCMS version 2 cmake detection script. It's the same than libkdcraw.

Laurent, it must be fine to factorize this script in kdelibs. I know that krita use lcms2 too...
Note there is already a cmake script to detect LCMS version 1 which is very different. Of course,
if this script can be patch to support version 1 and version 2, it will be great.

CCMAIL: <email address hidden>

A +72 -0 cmake/modules/FindLCMS2.cmake

http://commits.kde.org/digikam/712e983ff995bbcc59cb3da1f067238d95fa862a

Ananta,

I add LCMS2 detection script to digiKam (it's the same than Libkdcraw).

It work better now ?

Gilles Caulier

(In reply to comment #15)
> I add LCMS2 detection script to digiKam (it's the same than Libkdcraw).
>
> It work better now ?

It works for libkdcraw as expected when building digikam-sc, but digiKam still can't compile because the method of detection that Francesco used does not use FindLCMS2.cmake, so either digiKam's CMakeFile.txt needs to be modified to use FindLCMS2.cmake or relevent code from the .cmake needs to be ported.

Also, if both lcms1 and lcms2 are on a system, libkdcraw will automatically build using lcms2. However, digiKam will only build with lcms2 support if -DENABLE_LCMS2=1. Would having libkdcraw built agains lcms2 but digiKam built against lcms1 be a problem? If so, it would be useful if the -DENABLE_LCMS2 can be toggled for libkdcraw as well (such that configuring this option for digikam-sc would cause it to apply to libkdcraw as well). Of course, if everything works fine with them built against different version of lcms, then that isn't a problem I guess, but it is slightly unexpected from a build perspective.

> It works for libkdcraw as expected when building digikam-sc...

Ah. For me it doesn't work :

-- Starting CMake configuration for: libkdcraw
CMake Warning at extra/libkdcraw/CMakeLists.txt:110 (FIND_PACKAGE):
  Could not find module FindLCMS2.cmake or a configuration file for package
  LCMS2.

  Adjust CMAKE_MODULE_PATH to find FindLCMS2.cmake or set LCMS2_DIR to the
  directory containing a CMake configuration file for LCMS2. The file will
  have one of the following names:

    LCMS2Config.cmake
    lcms2-config.cmake

Of course i cleaned previous cmake cache before... Strange...

lcms2 is of course installed on my computer :

[gilles@localhost include]$ pwd
/usr/include
[gilles@localhost include]$ ls -al *lcms*
-rw-r--r-- 1 root root 93522 janv. 28 14:37 lcms2.h
-rw-r--r-- 1 root root 24728 janv. 28 14:37 lcms2_plugin.h
-rw-r--r-- 1 root root 78034 janv. 18 2011 lcms.h

[gilles@localhost lib64]$ pwd
/usr/lib64
[gilles@localhost lib64]$ ls -al *lcms*
lrwxrwxrwx 1 root root 17 janv. 28 14:55 liblcms2.so -> liblcms2.so.2.0.3*
lrwxrwxrwx 1 root root 17 janv. 28 14:55 liblcms2.so.2 -> liblcms2.so.2.0.3*
-rwxr-xr-x 1 root root 320296 janv. 28 14:37 liblcms2.so.2.0.3*

Gilles

Git commit 1fc2bf3f97baa3a37a8b3ae0df987528efcff4d1 by Gilles Caulier.
Committed on 01/03/2012 at 15:23.
Pushed by cgilles into branch 'master'.

don't overwrite cmake variable to detect LCMS2 script. Just append path as well to existing one.

M +1 -1 CMakeLists.txt

http://commits.kde.org/libkdcraw/1fc2bf3f97baa3a37a8b3ae0df987528efcff4d1

Git commit 5c250eab9929c03896cb132cf845bc313ba15345 by Gilles Caulier.
Committed on 01/03/2012 at 23:10.
Pushed by cgilles into branch 'master'.

use same logic than digiKam to compile and link with lcms2 or lcms1 shared lib. Use ENABLE_LCMS2 bool option with cmake to turn on lcms2 support, else lcms1 is used.

M +36 -16 CMakeLists.txt

http://commits.kde.org/libkdcraw/5c250eab9929c03896cb132cf845bc313ba15345

Ananta,

libkdcraw and digiKam use the same logic to compile against lcms2. The same cmake option is used for digiKam core and libkdcraw : ENABLE_LCMS2.

Please, try under windows if all is fine, and report...

Gilles Caulier

(In reply to comment #20)
> Ananta,
>
> libkdcraw and digiKam use the same logic to compile against lcms2. The same
> cmake option is used for digiKam core and libkdcraw : ENABLE_LCMS2.
>
> Please, try under windows if all is fine, and report...
>
> Gilles Caulier

For the record previously both lcms1 and lcms2 were linked, this worked under linux but could have not on other arches.
Gilles thanks for managing this, I'll kinda away from keybord 'till next week

No problem Francesco.

I checked with LDD, and digiKam and libkdcraw are properly linked with lcms2, or lcms1, not with both at the same time.

I see a pending problem on my computer : The lcms2 includes path passed to cmake to compile digiKam/libkdcraw is empty. I don't know why. It must be filled by lcms2 detection script. Variable is LCMS2_INCLUDE_DIR.

I print it here in lead cmake script :

https://projects.kde.org/projects/extragear/graphics/digikam/repository/revisions/master/entry/CMakeLists.txt#L173

Can you confirm this ?

Gilles Caulier

(In reply to comment #22)
> No problem Francesco.
>
> I checked with LDD, and digiKam and libkdcraw are properly linked with lcms2,
> or lcms1, not with both at the same time.
>
> I see a pending problem on my computer : The lcms2 includes path passed to
> cmake to compile digiKam/libkdcraw is empty. I don't know why. It must be
> filled by lcms2 detection script. Variable is LCMS2_INCLUDE_DIR.
>
> I print it here in lead cmake script :
>
> https://projects.kde.org/projects/extragear/graphics/digikam/repository/revisions/master/entry/CMakeLists.txt#L173
>
> Can you confirm this ?

confirmed, but lcms2.h is into /usr/include/, which is the canonical path for includes, maybe the variable is empty if the header is in that default path.

from `cmake --help-command FIND_PATH`:
<<If nothing is found, the result will be <VAR>-NOTFOUND,>>
not empty

on the other hand

`grep LCMS2_INCLUDE CMakeCache.txt`
LCMS2_INCLUDEDIR:INTERNAL=/usr/include
LCMS2_INCLUDE_DIRS:INTERNAL=

and show that LCMS2_INCLUDEDIR has indeed the correct path.

Hum perhaps LCMS2 find script need to be updated from Krita. I copied it from KOffice.

I ask to Laurent Montel if we can factorize it to kdelibs in the future, to prevent duplicates.

Gilles Caulier

(In reply to comment #20)
> libkdcraw and digiKam use the same logic to compile against lcms2. The same
> cmake option is used for digiKam core and libkdcraw : ENABLE_LCMS2.
>
> Please, try under windows if all is fine, and report...

Gilles,

PKG_CHECK_MODULES was still being used, so I switched to FindLCMS2.cmake instead and committed the change (forgot to CC this bug, sorry). Works fine on Windows now. I think this may also fix the problem you mention in comment #22?

-Ananta

Changed in inkscape (Ubuntu):
status: Triaged → Fix Released

Git commit 2d36b980995d744f9cbe9c36125386d700ba6136 by Ananta Palani.
Committed on 02/03/2012 at 14:50.
Pushed by palani into branch 'master'.

Use FindLCMS2.cmake instead of PKG_CHECK_MODULES which doesn't work on Windows

M +6 -6 CMakeLists.txt

http://commits.kde.org/digikam/2d36b980995d744f9cbe9c36125386d700ba6136

Git commit 13308aec86a8e02322e063c2190aed2f9e0b21c8 by Ananta Palani.
Committed on 02/03/2012 at 14:51.
Pushed by palani into branch 'master'.

Use FindLCMS2.cmake instead of PKG_CHECK_MODULES which doesn't work on Windows

M +5 -5 CMakeLists.txt

http://commits.kde.org/libkdcraw/13308aec86a8e02322e063c2190aed2f9e0b21c8

Cmake configuration trace is different between libkdcraw and digiKam :

-- -------------------------------------------------------------------------
-- Starting CMake configuration for: libkdcraw
-- Check for LCMS2 availability...
-- Found JPEG: /usr/lib64/libjpeg.so
-- Try OpenMP C flag = [-fopenmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Success
-- Try OpenMP CXX flag = [-fopenmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Success
-- Found OpenMP: -fopenmp

...

---------------------------------------------------------------------------
-- Starting CMake configuration for: digikam
-- Found Jasper: /usr/lib64/libjasper.so
-- Check for Kdcraw library in local sub-folder...
...
-- Check for LCMS2 availability...
-- checking for module 'lcms2'
-- found lcms2, version 2.3
-- Found LCMS2: lcms2
-- Identified libjpeg version: 80+
-- Found MySQL server executable at: /usr/sbin/mysqld
-- Found MySQL install_db executable at: /usr/bin/mysql_install_db
...

Why ?

Gilles Caulier

Note : I started cmake configuration script with "-DENABLE_LCMS2=on"

Gilles

(In reply to comment #29)
> Note : I started cmake configuration script with "-DENABLE_LCMS2=on"
>
> Gilles

Strange, works fine for me, either together (digikam-sc) or separately (libkdcraw, digikam). Here is separately:

-- Starting CMake configuration for: libkdcraw
...
-- Check for LCMS2 availability...
-- Found lcms version 2.03, c:/kderoot/lib/lcms-2.lib
-- Found LCMS2: c:/kderoot/lib/lcms-2.lib c:/kderoot/include

-- Found JPEG: c:/kderoot/lib/jpeg.lib
-- Try OpenMP C flag = [-fopenmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Failed
-- Try OpenMP C flag = [/openmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Success
-- Try OpenMP CXX flag = [-fopenmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Failed
-- Try OpenMP CXX flag = [/openmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Success
-- Found OpenMP: /openmp

----------------------------------------

-- Starting CMake configuration for: digikam
...
-- Check for LCMS2 availability...
-- Found lcms version 2.03, c:/kderoot/lib/lcms-2.lib
-- Found LCMS2: c:/kderoot/lib/lcms-2.lib c:/kderoot/include

-- Try OpenMP C flag = [-fopenmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Failed
-- Try OpenMP C flag = [/openmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Success
-- Try OpenMP CXX flag = [-fopenmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Failed
-- Try OpenMP CXX flag = [/openmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Success
-- Found OpenMP: /openmp

Git commit b0cfc14a4dad0bd137fdf8d9493c378dbecca652 by Ananta Palani.
Committed on 03/03/2012 at 08:11.
Pushed by palani into branch 'master'.

Give libkdcraw cmake modules preference over pre-existing ones.

M +1 -1 CMakeLists.txt

http://commits.kde.org/libkdcraw/b0cfc14a4dad0bd137fdf8d9493c378dbecca652

Gilles,

Could you have another version of FindLCMS2.cmake on your system somewhere? Your 'found' message does not look consistent with the file included in libkdcraw/digikam:

Found lcms version ${LCMS2_MAJOR_VERSION}.${LCMS2_MINOR_VERSION}, ${LCMS2_LIBRARIES}

so maybe cmake is using the wrong one? The commit I just made may fix your problem regardless.

-Ananta

No other lcms2 cmake find script is on my computer.

I updated my local git and cleaned cmake cache. trace is better :

-- Starting CMake configuration for: libkdcraw
-- Check for LCMS2 availability...
-- checking for module 'lcms2'
-- found lcms2, version 2.3
-- Found lcms version 2.03, /usr/lib64/liblcms2.so
-- Found LCMS2: /usr/lib64/liblcms2.so /usr/include
-- Found JPEG: /usr/lib64/libjpeg.so
-- Try OpenMP C flag = [-fopenmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Success
-- Try OpenMP CXX flag = [-fopenmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Success
-- Found OpenMP: -fopenmp

-----------------------------------------------------------------------------
-- The following external packages were located on your system.
-- This installation will have the extra features provided by these packages.
-----------------------------------------------------------------------------
   * LCMS2 - A small-footprint color management engine
   * libjpeg - JPEG image format support

...

-- Starting CMake configuration for: digikam
-- Found Jasper: /usr/lib64/libjasper.so
-- Check for Kdcraw library in local sub-folder...
-- Found Kdcraw library in local sub-folder: /mnt/data/Devel/GIT/2.x/extra/libkdcraw
-- Check Kexiv2 library in local sub-folder...
-- Found Kexiv2 library in local sub-folder: /mnt/data/Devel/GIT/2.x/extra/libkexiv2
-- Check Kipi library in local sub-folder...
-- Found Kipi library in local sub-folder: /mnt/data/Devel/GIT/2.x/extra/libkipi
-- Check Kface library in local sub-folder...
-- Found Kface library in local sub-folder: /mnt/data/Devel/GIT/2.x/extra/libkface
-- Check for KGeoMap library in local sub-folder...
-- Found KGeoMap library in local sub-folder: /mnt/data/Devel/GIT/2.x/extra/libkgeomap
-- checking for module 'libpgf'
-- package 'libpgf' not found
-- Could NOT find any working clapack installation
-- Check for LCMS2 availability...
-- Found lcms version 2.03, /usr/lib64/liblcms2.so
-- Found LCMS2: /usr/lib64/liblcms2.so /usr/include
-- Identified libjpeg version: 80+
-- Found MySQL server executable at: /usr/sbin/mysqld
...

i need to check OSX now...

Gilles Caulier

Work fine under MACOSX :

-- ----------------------------------------------------------------------------------
-- Starting CMake configuration for: libkdcraw
-- Check for LCMS2 availability...
-- checking for module 'lcms2'
-- found lcms2, version 2.2
-- Found lcms version 2.02, /opt/local/lib/liblcms2.dylib
-- Found LCMS2: /opt/local/lib/liblcms2.dylib /opt/local/include
-- Found JPEG: /opt/local/lib/libjpeg.dylib

-----------------------------------------------------------------------------
-- The following external packages were located on your system.
-- This installation will have the extra features provided by these packages.
-----------------------------------------------------------------------------
   * LCMS2 - A small-footprint color management engine
   * libjpeg - JPEG image format support

...

-- ----------------------------------------------------------------------------------
-- Starting CMake configuration for: digikam
-- Found Jasper: /opt/local/lib/libjasper.dylib
-- Check for Kdcraw library in local sub-folder...
-- Found Kdcraw library in local sub-folder: /Users/gilles/Devel/2.x/extra/libkdcraw
-- Check Kexiv2 library in local sub-folder...
-- Found Kexiv2 library in local sub-folder: /Users/gilles/Devel/2.x/extra/libkexiv2
-- Check Kipi library in local sub-folder...
-- Found Kipi library in local sub-folder: /Users/gilles/Devel/2.x/extra/libkipi
-- Check Kface library in local sub-folder...
-- Found Kface library in local sub-folder: /Users/gilles/Devel/2.x/extra/libkface
-- Check for KGeoMap library in local sub-folder...
-- Found KGeoMap library in local sub-folder: /Users/gilles/Devel/2.x/extra/libkgeomap
-- checking for module 'libpgf'
-- package 'libpgf' not found
-- Found clapack includes: /System/Library/Frameworks/vecLib.framework/Headers
-- Found clapack library: /usr/lib/libclapack.dylib
-- Check for LCMS2 availability...
-- Found lcms version 2.02, /opt/local/lib/liblcms2.dylib
-- Found LCMS2: /opt/local/lib/liblcms2.dylib /opt/local/include
-- Identified libjpeg version: 80+
...

Gilles Caulier

All compile fine under MACOSX through macport :

[ 56%] Building C object core/digikam/CMakeFiles/digikamcore.dir/__/libs/3rdparty/clapack/lsame.c.o
[ 57%] Building C object core/digikam/CMakeFiles/digikamcore.dir/__/libs/3rdparty/clapack/sfe.c.o
[ 57%] Building C object core/digikam/CMakeFiles/digikamcore.dir/__/libs/3rdparty/clapack/util.c.o
[ 57%] Building C object core/digikam/CMakeFiles/digikamcore.dir/__/libs/3rdparty/clapack/xerbla.c.o
[ 57%] Building CXX object core/digikam/CMakeFiles/digikamcore.dir/__/libs/dklcms/digikam-lcms.cpp.o
[ 57%] Building CXX object core/digikam/CMakeFiles/digikamcore.dir/__/libs/dimg/filters/dimgbuiltinfilter.cpp.o
[ 57%] Building CXX object core/digikam/CMakeFiles/digikamcore.dir/__/libs/dimg/filters/dimgthreadedfilter.cpp.o
[ 57%] Building CXX object core/digikam/CMakeFiles/digikamcore.dir/__/libs/dimg/filters/dimgfiltermanager.cpp.o

I close this file now...

Gilles Caulier

Changed in libkdcraw (Ubuntu):
status: Fix Committed → Fix Released
Rohan Garg (rohangarg) on 2012-06-07
Changed in digikam (Ubuntu):
assignee: Philip Muškovac (yofel) → Rohan Garg (rohangarg)
status: Triaged → In Progress
Changed in digikam (Ubuntu):
status: In Progress → Fix Released
Changed in digikam:
status: Unknown → Fix Released

Under debian build with newer version

Changed in imagemagick (Ubuntu):
status: In Progress → Fix Committed

This is fixed upstream in enblend-enfuse 4.1.

Micah Gersten (micahg) wrote :

Was already fixed in quantal

Changed in imagemagick (Ubuntu):
status: Fix Committed → Fix Released
tmodes (tmodes) on 2013-02-20
Changed in enblend:
status: Fix Committed → Fix Released
Philip Muškovac (yofel) on 2013-03-07
no longer affects: kdegraphics (Ubuntu)
dino99 (9d9) on 2013-04-26
tags: added: raring saucy

I send a patch to add support for lcms2 with a fallback to lcms v1:
http://source.winehq.org/patches/data/96110

As info for distribution support for lcms2:
Ubuntu 11.10 has liblcms2-2 as a "main" package (section libs).

--
By by ... Detlef

Detlef (winspool) wrote :

(In reply to comment #15)
> I send a patch to add support for lcms2 with a fallback to lcms v1:
> http://source.winehq.org/patches/data/96110

BUG: The patch was still using the includes for lcms v1
     To fix compilation while using lcms2.h,
     add a #include <icc34.h> after the #include <lcms2.h>
     (icc34.h comes with the liblcms v1 dev package)

I prepare a better patch in the near future.

--
By by .. Detlef

B Bobo (yout-bobo123) on 2013-05-22
Changed in f-spot (Ubuntu):
status: New → Confirmed

Fixed by d40c91262b91f72c44151a1481a77acfe71ba044.

Changed in wine:
status: Confirmed → Fix Released

Closing bugs fixed in 1.7.0.

Roadmap says:

# future plans:
# 2.7 will compile against lcms2 by default but lcms1 will stay as a fallback
# 2.8 will support lcms2 only, probably ENABLE_LCMS2 will be removed too
# unless we decide to support another color managment library

Any plan to make lcms2 the default now, if both are found?

Changed in f-spot (Ubuntu):
status: Confirmed → Triaged
Changed in dcraw (Ubuntu):
importance: Undecided → Medium
Changed in digikam (Ubuntu):
importance: Undecided → Medium
Changed in enblend (Ubuntu):
importance: Undecided → Medium
Changed in enblend-enfuse (Ubuntu):
importance: Undecided → Medium
Changed in f-spot (Ubuntu):
importance: Undecided → Medium
Changed in geeqie (Ubuntu):
importance: Undecided → Medium
Changed in gimp (Ubuntu):
importance: Undecided → Medium
Changed in imagemagick (Ubuntu):
importance: Undecided → Medium
Changed in lcms (Ubuntu):
importance: Undecided → Medium
Changed in libkdcraw (Ubuntu):
importance: Undecided → Medium
Changed in libmng (Ubuntu):
importance: Undecided → Medium
Changed in libraw (Ubuntu):
importance: Undecided → Medium
Changed in openjdk-6 (Ubuntu):
importance: Undecided → Medium
Changed in python-imaging (Ubuntu):
importance: Undecided → Medium
Changed in rawstudio (Ubuntu):
importance: Undecided → Medium
Changed in scribus (Ubuntu):
importance: Undecided → Medium
Changed in ufraw (Ubuntu):
importance: Undecided → Medium
Changed in xsane (Ubuntu):
importance: Undecided → Medium
Thomas Hotz (thotz) on 2013-09-22
Changed in gimp (Ubuntu):
status: New → Confirmed
Changed in gimp (Ubuntu):
status: Confirmed → Triaged
Rolf Leggewie (r0lf) on 2013-10-27
description: updated
Dimitri John Ledkov (xnox) wrote :

It's best to use transition tracker:
http://people.canonical.com/~ubuntu-archive/transitions/lcms2.html

It shows proper dependencies rounds & rathers information based on the archive state across both source and binary packages across all architectures.

description: updated
Matthias Klose (doko) wrote :

libmng using lcms2 uploaded to trusty

Changed in libmng (Ubuntu):
status: New → Fix Released
Matthias Klose (doko) wrote :

gimp fixed in trusty

Changed in gimp (Ubuntu):
status: Triaged → Fix Released
Matthias Klose (doko) wrote :

python-imaging/pillow fixed in trusty

Changed in python-imaging (Ubuntu):
status: New → Fix Released
Matthias Klose (doko) wrote :

openjdk-6 doesn't have this dependency anymore

Changed in openjdk-6 (Ubuntu):
status: New → Fix Released

Nominating for 1.6.2 so I can put it into Ubuntu 14.04 LTS and Wine won't be the only package still using old lcms.

Removing 1.6.x milestone from bugs included in 1.6.2.

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package enblend-enfuse - 4.1.2+dfsg-2ubuntu1

---------------
enblend-enfuse (4.1.2+dfsg-2ubuntu1) trusty; urgency=medium

  * Merge from Debian, remaining changes:
    - Build-depend on libglew-dev rather than libglew1.5-dev | libglew1.4-dev
      | libglew-dev.
    - Build using -O1 on arm
 -- Jackson Doak <email address hidden> Wed, 22 Jan 2014 06:23:44 +1100

Changed in enblend-enfuse (Ubuntu):
status: New → Fix Released
Displaying first 40 and last 40 comments. View all 109 comments or add a comment.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.