Compiling DCMTK for BCC32 6.20

All other questions regarding DCMTK

Moderator: Moderator Team

Post Reply
Message
Author
ivan.filgueiras
Posts: 3
Joined: Wed, 2010-01-27, 20:52
Contact:

Compiling DCMTK for BCC32 6.20

#1 Post by ivan.filgueiras »

Hello there!

I've had some trouble to compile DCMTK with bcc32 (borland). I had to do some modifications to the source code, but I don't trust them at all, since I just "silenced" the compiler in most cases.

Would someone more experienced with this library assist me in creating a patch that will improve the compatibility of DCMTK with Borland's environment?


Changes I had to made to compile DCMTK-3.5.5 snapshot in a Borland
environment:

- cfwin32.h had to be changed everytime I runned cmake:
- comment the #define HAVE_NO_TYPEDEF_SSIZE_T section; it
complains about multiple declarations of ssize_t... cmake
doesn't seem to be understanding my system's layout quite well
(Windows XP 32bits);
- #ifndef clauses to __MT__ and _MT to avoid tons of warning
about "Redefinition not identical".

- dcmtk-3.5.5_20100114/dcmjpeg/libijg8/jmorecfg8.h,
dcmtk-3.5.5_20100114/dcmjpeg/libijg12/jmorecfg12.h and
dcmtk-3.5.5_20100114/dcmjpeg/libijg16/jmorecfg16.h had to be
modified to the following:
- added #undef C_PROGRESSIVE_SUPPORTED to all of those files.

- all of the following files were in need of a "using namespace
std;" statement:
dcmtk-3.5.5_20100114/dcmnet/libsrc/cond.cc
dcmtk-3.5.5_20100114-orig/dcmnet/libsrc/cond.cc
dcmtk-3.5.5_20100114/oflog/include/dcmtk/oflog/helpers/timehelp.h
dcmtk-3.5.5_20100114-orig/oflog/include/dcmtk/oflog/helpers/timehelp.h
dcmtk-3.5.5_20100114/oflog/libsrc/fileap.cc
dcmtk-3.5.5_20100114-orig/oflog/libsrc/fileap.cc
dcmtk-3.5.5_20100114/ofstd/include/dcmtk/ofstd/ofconfig.h
dcmtk-3.5.5_20100114-orig/ofstd/include/dcmtk/ofstd/ofconfig.h
dcmtk-3.5.5_20100114/ofstd/include/dcmtk/ofstd/offile.h
dcmtk-3.5.5_20100114-orig/ofstd/include/dcmtk/ofstd/offile.h
dcmtk-3.5.5_20100114/ofstd/libsrc/ofcmdln.cc
dcmtk-3.5.5_20100114-orig/ofstd/libsrc/ofcmdln.cc
dcmtk-3.5.5_20100114/ofstd/libsrc/ofconapp.cc
dcmtk-3.5.5_20100114-orig/ofstd/libsrc/ofconapp.cc
dcmtk-3.5.5_20100114/ofstd/libsrc/ofdate.cc
dcmtk-3.5.5_20100114-orig/ofstd/libsrc/ofdate.cc
dcmtk-3.5.5_20100114/ofstd/libsrc/ofdatime.cc
dcmtk-3.5.5_20100114-orig/ofstd/libsrc/ofdatime.cc
dcmtk-3.5.5_20100114/ofstd/libsrc/offname.cc
dcmtk-3.5.5_20100114-orig/ofstd/libsrc/offname.cc
dcmtk-3.5.5_20100114/ofstd/libsrc/ofstd.cc
dcmtk-3.5.5_20100114-orig/ofstd/libsrc/ofstd.cc
dcmtk-3.5.5_20100114/ofstd/libsrc/ofstring.cc
dcmtk-3.5.5_20100114-orig/ofstd/libsrc/ofstring.cc
dcmtk-3.5.5_20100114/ofstd/libsrc/oftime.cc
dcmtk-3.5.5_20100114-orig/ofstd/libsrc/oftime.cc
dcmtk-3.5.5_20100114/dcmimage/libsrc/diqtfs.cc
dcmtk-3.5.5_20100114-orig/dcmimage/libsrc/diqtfs.cc
dcmtk-3.5.5_20100114/dcmimage/include/dcmtk/dcmimage/diqtpbox.h
dcmtk-3.5.5_20100114/dcmdata/libsrc/dcvm.cc
dcmtk-3.5.5_20100114/dcmdata/libsrc/vrscan.cc

- in the file
dcmtk-3.5.5_20100114/ofstd/include/dcmtk/ofstd/offile.h:
- changed _stati64 for stati64, since _stati64 doesn't seem to
exist on the headers of my Borland environment.

- missing includes (not certain about those):
- added #define INCLUDE_CSTDDEF to
dcmtk-3.5.5_20100114/ofstd/include/dcmtk/ofstd/oflist.h,
dcmtk-3.5.5_20100114-orig/dcmimage/include/dcmtk/dcmimage/diqtpbox.h;
- added #define INCLUDE_CSTDIO to
dcmtk-3.5.5_20100114/ofstd/libsrc/ofcmdln.cc;
- added #define INCLUDE_CSTDLIB to
dcmtk-3.5.5_20100114/ofstd/libsrc/ofconapp.cc and
dcmtk-3.5.5_20100114/ofstd/include/dcmtk/ofstd/ofconfig.h.

- commented the HAVE_MKTEMP section in
dcmtk-3.5.5_20100114/dcmdata/libsrc/dcdicdir.cc.

ivan.filgueiras
Posts: 3
Joined: Wed, 2010-01-27, 20:52
Contact:

#2 Post by ivan.filgueiras »

I think I posted in the wrong section of the forum.

Could a moderator move this topic for me? Thank you in advance.

Michael Onken
DCMTK Developer
Posts: 2054
Joined: Fri, 2004-11-05, 13:47
Location: Oldenburg, Germany
Contact:

#3 Post by Michael Onken »

Hi Ivan,

unfortunately non of the DICOM team members at OFFIS has experiences with BCC32, but we are happy that you got this going for you. For me, all your changes do not look critical, so chance are good everything is running fine ;)
If you experience any problems and/or find solutions, feel welcome to share it in the forum because your approach may be valuable for many other people working with Borland C++.

Best regards,
Michael

Post Reply

Who is online

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