DICOM @ OFFIS

Discussion Forum for OFFIS DICOM Tools - For registration, send email with desired user name to the OFFIS DICOM team
It is currently Tue, 2017-11-21, 09:01

All times are UTC + 1 hour




Post new topic Reply to topic  [ 5 posts ] 
Author Message
PostPosted: Fri, 2017-09-08, 02:17 
Offline

Joined: Thu, 2017-09-07, 07:42
Posts: 2
Hi, I'm migrating old dcmtk codes to the latest version 3.6.2. The old dcmtk can be built with xlC 12, but when build the new one, i got losts of error. Seems dcmtk 3.6.2 adds some new things to support C++11 which is not supported by xlC.
And i have no clue how to avoid this error by changing dcmtk code.
The detailed build error is:
[ 51%] Building CXX object dcmsr/libsrc/CMakeFiles/dcmsr_obj.dir/dsrcitem.cc.o
"dcmtk-3.6.2/ofstd/include/dcmtk/ofstd/ofutil.h", line 148.37: 1540-0300 (S) The "private" member "class OFrvalue_storage<class DSRDocumentTreeNode *,0>::type" cannot be accessed.
"dcmtk-3.6.2/ofstd/include/dcmtk/ofstd/ofutil.h", line 281.7: 1540-0700 (I) The previous message was produced while processing "struct OFrvalue<DSRDocumentTreeNode *>".
"dcmtk-3.6.2/ofstd/include/dcmtk/ofstd/ofutil.h", line 148.37: 1540-0300 (S) The "private" member "class OFrvalue_storage<bool,0>::type" cannot be accessed.
"dcmtk-3.6.2/ofstd/include/dcmtk/ofstd/ofutil.h", line 281.7: 1540-0700 (I) The previous message was produced while processing "struct OFrvalue<bool>".
make[2]: *** [dcmsr/libsrc/CMakeFiles/dcmsr_obj.dir/dsrcitem.cc.o] Error 1
make[1]: *** [dcmsr/libsrc/CMakeFiles/dcmsr_obj.dir/all] Error 2
make: *** [all] Error 2

Any help is appreciated.


Top
 Profile  
 
PostPosted: Fri, 2017-09-08, 08:25 
Offline
DCMTK Developer

Joined: Tue, 2011-05-03, 14:38
Posts: 1874
Location: Oldenburg, Germany
As far as I can see, the problem is related to the OFswap() function that is implemented in "ofutils.h" (as a fallback solution for std::swap() in case C++11 support is not available or not enabled). Did you already try to enable C++11 support (in the CMake configuration) and re-compile?

By the way, we haven't tested AIX for this DCMTK release (version 3.6.2) as this OS was not available to us anymore. See INSTALL file for a list of supported (i.e. tested) systems.


Top
 Profile  
 
PostPosted: Fri, 2017-09-08, 10:30 
Offline
OFFIS DICOM Team
OFFIS DICOM Team

Joined: Mon, 2014-03-03, 09:51
Posts: 216
Location: Oldenburg, Germany
To me it looks (at the first glance) like the compiler does not correctly apply the default public access rights to type members of structs, try adding 'public:' in lines 62 and 86 and see if the compliler understands that.


Top
 Profile  
 
PostPosted: Mon, 2017-09-11, 04:05 
Offline

Joined: Thu, 2017-09-07, 07:42
Posts: 2
Thank you for the replies.
1. xlc doesn't support C++11, so I disable it when do build configuration.
2. The error is xlc compiler issue, but AIX doesn't want to fix it. Besides, add “public:" doesn't make compile work.
Is there any easy way to fix that error? Or any suggestion to bypass such part of code?


Top
 Profile  
 
PostPosted: Mon, 2017-09-11, 12:10 
Offline
OFFIS DICOM Team
OFFIS DICOM Team

Joined: Mon, 2014-03-03, 09:51
Posts: 216
Location: Oldenburg, Germany
Sorry, if adding 'public:' doesnt help I have no idea how to get the compiler to allow access to types defined inside structs/classes outside of them. Perhaps changing struct -> class will trigger different compiler behavior (although that would be idiotic, but the current behavior already is idiotic, so, who knows).


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: Bing [Bot] and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group