View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0002883 | Slicer4 | Core: Building (CMake, Superbuild) | public | 2013-01-24 05:43 | 2017-06-07 23:27 |
Reporter | jcfr | Assigned To | jcfr | ||
Priority | normal | Severity | minor | Reproducibility | have not tried |
Status | closed | Resolution | fixed | ||
Product Version | |||||
Target Version | Slicer 4.3.0 | Fixed in Version | Slicer 4.3.0 | ||
Summary | 0002883: Fix FindDCMTK.cmake provided by ITKv4 | ||||
Description | I also tried using CMake 2.8.10 and the error still occurs. Looking at the link line reported below [1], we can see that the path to the library "liboflog.a" and "libofstd.a" are incompelete. Indeed, these ones are referenced as: /lib/liboflog.a If I manually "fix" the command, the library "libITKIODCMTK-4.4.dylib" is successfully linked. There is probably an issue in either FindDCMTK.cmake, DCMTKConfig.cmake or in the way ITKv4 link the library libITKIODCMTK. Adding some message statement in the FindDCMTK.cmake bundled with ITKv4, it turns out that the library are incorrectly discovered at that level. Since on the system I am building, the following library exists: $ ls -als /lib This folder only contains these two libraries, I suspect that this folder has been created by mistake almost a year ago ... I just deleted the folder and the build seems to be continuing as expected. The problem didn't occur because the FindDCMTK.cmake available within CTK doesn't search that location. See https://github.com/commontk/CTK/blob/master/Utilities/CMake/FindDCMTK.cmake#L69-79 I would recommend that the version available in CTK is used in ITKv4 ... it has been fixed and optimized for now few years. DCMTK maintainers even contributed. See https://github.com/commontk/CTK/commits/master/Utilities/CMake/FindDCMTK.cmake @Steve: You have probably a similar issue on your workstation. Hth [1] $ make ITKIODCMTK/fast VERBOSE=1 | ||||
Tags | ITKv4 | ||||
From Hans: Kent: Please investigate the option of using FindDCMTK.cmake from the Slicer CTK package for ITK. I would recommend that the version available in CTK is used in ITKv4 ... it has been fixed and optimized for now few years. DCMTK maintainers even contributed. See https://github.com/commontk/CTK/commits/master/Utilities/CMake/FindDCMTK.cmake |
|
From Kent: So, I just spent a few hours on fixing the FindDCMTK.cmake from CTK to It worked, pretty much, as long as you only ever pointed CMake at an So to fix this, I had to go looking in the build directory for a Here's a fun fact: There are 4 versions of FindDCMTK.cmake in the ITK What's hilarious is that they're all different! To be fair one of the |
|
2013-01-24 11:18
|
From-kent-FindDCMTK.cmake (6,220 bytes) |
From Jc: Hi Kent, If I understand properly, you updated the one in CTK so that it could be integrated in ITKv4 to support both the discovery of DCMTK in an installed and a build tree. Is that correct ? Should the enclosed file be dropped as a replacement for "./Modules/ThirdParty/DCMTK/CMake/FindDCMTK.cmake" so that we test it ? Then, the idea would be to update "./Modules/ThirdParty/DCMTK/CMake/FindDCMTK.cmake". Let me know what you think ? I think that would be a good first step. We should then work all together to improve DCMTK, fix the one in CMake, etc ... Thanks |
|
Seems there are issue building some extension: http://slicer.cdash.org/viewBuildError.php?buildid=64053 For example: |
|
Kent Williams is working on patch in the InsightToolkit/DCMTK github that may remove the need for this. |
|
Fixed in r21772 |
|
Closing resolved issues that have not been updated in more than 3 months |
|
Fix committed to 2145-support-for-installing-extension-from-file branch. |
|
Slicer: 2145-support-for-installing-extension-from-file 3bcf451e 2013-02-24 00:16:35 Details Diff |
COMP: Update ITKv4 tag to ensure Slicer DCMTK libraries are used. Warning: Since the ITK version will now be 4.4 instead of 4.3. It is recommended that developers should make sure to remove "4.3" related library from their build tree. On macosx/linux, one way of removing the libraries would be: cd /path/to/Slicer-Superbuild/ITK-build rm -rf lib/*4.3* This commit intend to fix issue detailed in both Slicer issue 2883 and issue 2978. In a nutshell, a link error like the following was occurring: Linking CXX executable ../../../lib/Slicer-4.2/cli-modules/DTIimport /path/to/Slicer-build/ITKv4-build/lib/libITKIODCMTK-4.4.so.1: undefined reference to `OFFilename::OFFilename(char const*, bool)' /path/to/Slicer-build/ITKv4-build/lib/libITKIODCMTK-4.4.so.1: undefined reference to `OFFilename::~OFFilename()' collect2: error: ld returned 1 exit status make[5]: *** [lib/Slicer-4.2/cli-modules/DTIexport] Error 1 In that specific case, the CMakeCache of ITK build was referencing the wrong dcmdata library: DCMTK_dcmdata_LIBRARY:FILEPATH=/usr/lib/libdcmdata.so ... whereas it should have been: DCMTK_dcmdata_LIBRARY:FILEPATH=/path/to/Slicer-build/DCMTK-install/lib/libdcmdata.a ITK commit 31bc608a [1] updated Modules/ThirdParty/DCMTK/CMake/FindDCMTK.cmake so that default path are explicitly ignored when looking for DCMTK libraries. This will ensure that the DCMTK library built by Slicer will be used. The option NO_DEFAULT_PATH associated with the command "find_library" [2] is now used. Let's also note that the other "FindDCMTK.cmake" modules available in ITKv4 haven't been fixed and could lead to similar similar issue [3][4]. As of today, this is probably not an issue within Slicer. Indeed, ITK is not built with GDCM support and DCMTK seems not be used within VNL. (It means the associated DCMTK cmake files should probably be removed.) See http://www.na-mic.org/Bug/view.php?id=2883 and http://www.na-mic.org/Bug/view.php?id=2978 Fixes 0002883 and 0002978 [1] https://github.com/Kitware/ITK/commit/b9c473e241d46bc79d6750ffae73a112b0dcae7c [2] http://www.cmake.org/cmake/help/v2.8.10/cmake.html#command:find_library [3] ./Modules/ThirdParty/VNL/src/vxl/config/cmake/Modules/NewCMake/FindDCMTK.cmake [4] ./Modules/ThirdParty/GDCM/src/gdcm/CMake/FindDCMTK.cmake git-svn-id: http://svn.slicer.org/Slicer4/trunk@21772 3bd1e089-480b-0410-8dfb-8563597acbee |
||
mod - SuperBuild/External_ITKv4.cmake | Diff File |
Date Modified | Username | Field | Change |
---|---|---|---|
2013-01-24 05:43 | jcfr | New Issue | |
2013-01-24 05:43 | jcfr | Status | new => assigned |
2013-01-24 05:43 | jcfr | Assigned To | => jcfr |
2013-01-24 05:44 | jcfr | Note Added: 0007729 | |
2013-01-24 05:44 | jcfr | Assigned To | jcfr => hjmjohnson |
2013-01-24 05:44 | jcfr | Target Version | => Slicer 4.3.0 |
2013-01-24 05:44 | jcfr | Tag Attached: ITKv4 | |
2013-01-24 05:45 | jcfr | Relationship added | child of 0002007 |
2013-01-24 11:18 | jcfr | Note Added: 0007733 | |
2013-01-24 11:18 | jcfr | File Added: From-kent-FindDCMTK.cmake | |
2013-01-24 11:19 | jcfr | Note Added: 0007734 | |
2013-02-12 11:18 | jcfr | Note Added: 0007904 | |
2013-02-23 11:46 | hjmjohnson | Note Added: 0008016 | |
2013-02-23 11:54 | jcfr | Relationship added | related to 0002978 |
2013-02-23 19:22 | jcfr | Note Added: 0008021 | |
2013-02-23 19:22 | jcfr | Status | assigned => resolved |
2013-02-23 19:22 | jcfr | Fixed in Version | => Slicer 4.3.0 |
2013-02-23 19:22 | jcfr | Resolution | open => fixed |
2014-03-06 05:15 | jcfr | Note Added: 0011050 | |
2014-03-06 05:17 | jcfr | Status | resolved => closed |
2017-06-07 23:27 | jcfr | Changeset attached | => Slicer 2145-support-for-installing-extension-from-file 3bcf451e |
2017-06-07 23:27 | jcfr | Note Added: 0014654 | |
2017-06-07 23:27 | jcfr | Assigned To | hjmjohnson => jcfr |