MantisBT - CMake |
| View Issue Details |
|
| ID | Project | Category | View Status | Date Submitted | Last Update |
| 0014164 | CMake | CMake | public | 2013-05-22 13:25 | 2016-06-10 14:31 |
|
| Reporter | Stefan Roettger | |
| Assigned To | Mathieu Malaterre | |
| Priority | normal | Severity | major | Reproducibility | always |
| Status | closed | Resolution | moved | |
| Platform | Apple Mac | OS | OS X | OS Version | 10.4.10 |
| Product Version | CMake 2.8.11 | |
| Target Version | | Fixed in Version | | |
|
| Summary | 0014164: missing library in cmake-2.8/Modules/FindDCMTK.cmake |
| Description | The FindDCMTK module finds various libs as part of DCTMK. The module finds all those in a for loop:
foreach(lib
dcmdata
dcmimage
dcmimgle
dcmjpeg
dcmnet
dcmpstat
dcmqrdb
dcmsign
dcmsr
dcmtls
ijg12
ijg16
ijg8
ofstd)
This loop is missing the "oflog" lib. oflog depends on ofstd, so it should read:
foreach(lib
dcmdata
dcmimage
dcmimgle
dcmjpeg
dcmnet
dcmpstat
dcmqrdb
dcmsign
dcmsr
dcmtls
ijg12
ijg16
ijg8
oflog
ofstd)
|
| Steps To Reproduce | linkage against dcmtk 3.6.0 fails.
|
| Additional Information | An example project that depends on dcmtk is available at http://code.google.com/p/vvv/source/browse/#svn%2Fviewer%2Fqtv3 [^]
This one works because I added the linkage with dcmtk manually. I mean, adding -loflog to the linker line manually solves the problem.
Using find_package(DCMTK) and linking against DCMTK_LIBRARIES does result in unresolved symbols because oflog is not part of DCMTK_LIBRARIES (yet ;-).
|
| Tags | No tags attached. |
| Relationships | |
| Attached Files | |
|
| Issue History |
| Date Modified | Username | Field | Change |
| 2013-05-22 13:25 | Stefan Roettger | New Issue | |
| 2013-05-22 13:30 | Brad King | Assigned To | => Mathieu Malaterre |
| 2013-05-22 13:30 | Brad King | Status | new => assigned |
| 2013-05-22 13:39 | Jean-Christophe Fillion-Robin | Note Added: 0033112 | |
| 2013-05-22 13:45 | Brad King | Note Added: 0033113 | |
| 2013-05-22 15:23 | Jean-Christophe Fillion-Robin | Note Added: 0033114 | |
| 2013-05-24 19:33 | Stefan Roettger | Note Added: 0033131 | |
| 2016-06-10 14:28 | Kitware Robot | Note Added: 0042287 | |
| 2016-06-10 14:28 | Kitware Robot | Status | assigned => resolved |
| 2016-06-10 14:28 | Kitware Robot | Resolution | open => moved |
| 2016-06-10 14:31 | Kitware Robot | Status | resolved => closed |
|
Notes |
|
|
(0033112)
|
|
Jean-Christophe Fillion-Robin
|
|
2013-05-22 13:39
|
|
For reference: An updated version of the FindDCMTK.cmake module is available here: https://github.com/commontk/CTK/blob/master/Utilities/CMake/FindDCMTK.cmake [^]
It has been updated to be able to find the library associated with the latest version of DCMTK. Not DCMKT has been CMake'ified, it is also able to find libraries associated with a build or install tree of DCMTK.
I am sure it would be helpful if you could check that this updated module works within your application. |
|
|
|
(0033113)
|
|
Brad King
|
|
2013-05-22 13:45
|
|
|
|
|
(0033114)
|
|
Jean-Christophe Fillion-Robin
|
|
2013-05-22 15:23
|
|
|
|
|
(0033131)
|
|
Stefan Roettger
|
|
2013-05-24 19:33
|
|
As Jean-Christophe Fillion-Robin suggested I tried the updated cmake module.
This one includes the oflog library. Hence, it worked for my project. Good!
There are few quirks remaining, though. Those most likely have to be resolved upstream, but I do not know who is responsible, so I post it here hoping that somebody forwards it ;-)
1) dcmtk installs to /usr/local by default (at least on my mac when running "make install") but it does not find dcmtk at that standard location, because it inconsistently assumes the standard location to be /usr, which is odd. The work-around is to set DCMTK_DIR to /usr/local. Then find_package(DCMTK) works out-of-the-box.
It would be better to locate dcmtk in standard directories like /usr _AND_ /usr/local if DCMTK_DIR is _NOT_ set.
2) I have to define HAVE_CONFIG_H manually. Otherwise I was not able to make my application compile with dcmtk. I do not see a sound reason why a library should require such a define when using a plain standard installation. It should be working without that! That's like a car with pedals swapped.
3) While the new dcmtk cmake module works, the packaged cmake module in cmake 2.8.11 is broken for sure. I'd suggest to either remove it completely from the cmake package or just add "oflog" to the loop to fix it until it is replaced with the new upstream version. Otherwise there will be other developers wasting time on finding out that it won't work with the actual dctmk version.
Thanks for your help and the quick replies!
Stefan |
|
|
|
(0042287)
|
|
Kitware Robot
|
|
2016-06-10 14:28
|
|
Resolving issue as `moved`.
This issue tracker is no longer used. Further discussion of this issue may take place in the current CMake Issues page linked in the banner at the top of this page. |
|