GDCM selects randomly from installed OpenJPEG versions
Cross-platform DICOM implementation
Brought to you by:
malat
Hello Matheu,
the CMake/FindOpenJPEG.cmake selects the version to compile against based on the include file name only. If e.g. openjpeg v1.5.2 and v2.1.0 are installed with dev-files then which version is used is only determined by the order in the file system in which the corresponding sub-directories are listed. This is a problem on distributions like Gentoo, where no separate dev and lib packages exist. See also.
Also note that in this FindOpenJPEG.cmake the openjpeg version is fixed to the 1.X series, because of the given library name.
I'll think of a patch, unless you beat me to it.
Best,
Gert
well... the actual real solution is that libopenjp2-7-dev conflicts with libopenjpeg-dev
hum nevermind... let's say that behavior by default is to pick the highest version first. So 2.1 should be found first (before 1.5.x).
Is 2.1 already supported?
At some point I did support some kind of 2.x API, so I would say yes ... feel free to report another bug if compilation fails (cant remember from top of my head, but I suspect from your message that it does not).
Considering that you didn't close [bugs:#356] yet, I'd guess it doesn't.
Regarding the issue at hand, the guy who reported it provided a fix (patch attached) by using pkg-config and pinning it to use libopenjpeg1.
Related
Bugs:
#356Last edit: Gert Wollny 2016-03-23
should we really care of libopenjpeg 1.x anymore now ?
I don't think so, but I remember another patch I sent for another issue where you insisted that it shoud be backward compatible.
Not sure what this means...anyway applied as-is.
[release 5cf6bf9] Bug #376 GDCM selects randomly from installed OpenJPEG versions
Author: Gert Wollny gw.fossdev@gmail.com
1 file changed, 10 insertions(+), 1 deletion(-)