I am trying to compile dcmtk-3.5.3 in order to use it in my application. First of all I had to change the file extensions in the project from *.cxx to *.cc, since the source files had the *.cc extension in the toolkit. This has been done.
I’m using Visual Studio 7.0 and I get the following error in many (but not all) applications:
Compiling...
findscu.cc
Linking...
LINK : fatal error LNK1117: syntax error in option ''
It’s command line (which I don’t know how to change) is:
/Od /I "../../config\include" /I "../../dcmnet\include" /I "../../ofstd\include" /I "../../dcmdata\include" /I "../../../zlib-1.2.1\include" /I "../../dcmtls\include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_REENTRANT" /D "WITH_LIBPNG" /D "WITH_LIBTIFF" /D "WITH_ZLIB" /D "findscu_EXPORTS" /D "CMAKE_INTDIR=\"Debug\"" /D "_MBCS" /FD /EHsc /RTC1 /MTd /GS /YX"stdafx.h" /Fp".\Debug/findscu.pch" /Fo".\Debug/findscu1.obj" /Fd".\Debug/" /W3 /c /Z7
".\findscu.cc"
I just did a project Clean, just make sure I didn’t have junk in the way. I decided to concentrate on findscu.cc as the most important application, i.e. the one to query the Dicom server.
As can be seen from the above findscu.cc also suffers from this mysterious error LNK1117. I don’t see what option it is complaining about.
Can someone please point me in the right direction?
Link errors with Visual Studio 7.0
Moderator: Moderator Team
Link errors with Visual Studio 7.0
Thanks,
Ilan
Ilan
-
- OFFIS DICOM Team
- Posts: 1493
- Joined: Tue, 2004-11-02, 17:22
- Location: Oldenburg, Germany
- Contact:
The DCMTK source code distribution for the Windows platform uses the .cxx extension - there should be nothing to change. When compiling with VC7, make sure that you re-generate the project files from scratch using CMake as explained in the installation instructions, since an import of the VC6 project files will not work.
-
- Posts: 53
- Joined: Thu, 2005-04-14, 15:07
- Location: St. Petersburg, Russia
Re: Link errors with Visual Studio 7.0
> First of all I had to change the file extensions
> in the project from *.cxx to *.cc,
But you had not. Everything is compiled with *.cxx extention.
************
Compiling...
findscu.cc
Linking...
LINK : fatal error LNK1117: syntax error in option ''
It’s command line (which I don’t know how to change) is:
/Od /I "../../config\include" /I "../../dcmnet\include" /I "../../ofstd\include" /I "../../dcmdata\include" /I "../../../zlib-1.2.1\include" /I "../../dcmtls\include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_REENTRANT" /D "WITH_LIBPNG" /D "WITH_LIBTIFF" /D "WITH_ZLIB" /D "findscu_EXPORTS" /D "CMAKE_INTDIR=\"Debug\"" /D "_MBCS" /FD /EHsc /RTC1 /MTd /GS /YX"stdafx.h" /Fp".\Debug/findscu.pch" /Fo".\Debug/findscu1.obj" /Fd".\Debug/" /W3 /c /Z7
".\findscu.cc"
****************
You have got a link error, but command line is from "C/C++" properties.
Look through "Linker" properties.
Then have a detailed look at "General/Output File, /Additonal Library Directories" etc.
You can change propeties and the command line will be changed automatically.
Try to understand the every option in a command line, make a "manual" parse of it.
Alexander.
> in the project from *.cxx to *.cc,
But you had not. Everything is compiled with *.cxx extention.
************
Compiling...
findscu.cc
Linking...
LINK : fatal error LNK1117: syntax error in option ''
It’s command line (which I don’t know how to change) is:
/Od /I "../../config\include" /I "../../dcmnet\include" /I "../../ofstd\include" /I "../../dcmdata\include" /I "../../../zlib-1.2.1\include" /I "../../dcmtls\include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_REENTRANT" /D "WITH_LIBPNG" /D "WITH_LIBTIFF" /D "WITH_ZLIB" /D "findscu_EXPORTS" /D "CMAKE_INTDIR=\"Debug\"" /D "_MBCS" /FD /EHsc /RTC1 /MTd /GS /YX"stdafx.h" /Fp".\Debug/findscu.pch" /Fo".\Debug/findscu1.obj" /Fd".\Debug/" /W3 /c /Z7
".\findscu.cc"
****************
You have got a link error, but command line is from "C/C++" properties.
Look through "Linker" properties.
Then have a detailed look at "General/Output File, /Additonal Library Directories" etc.
You can change propeties and the command line will be changed automatically.
Try to understand the every option in a command line, make a "manual" parse of it.
Alexander.
Thanks
Dear Marco,
I would just like to thank you for your most welcomed help in putting me on the right track. I failed to see the first time around the renaming of *.cc to *.cxx and I failed to see the fact that an automatic upgrade of Visual Studio 6.0 to 7.0 doesn’t work.
It was a real struggle with this mistake, but the experience I gained made it trivial the second time around.
I downloaded and used Cmake, so that the compilation went through with only 2 errors. Both errors involved include files where the file names were *.cc instead of the renamed *.cxx. These were trivial to fix.
I also downloaded and used doxygen to generate help, and then compiled help files. The only suggestion I can make here is you write specifically in your document to use htmldocs.cfg instead of the “make html” which is currently written. (I still don’t know what make html is supposed to do, but “doxygen htmldocs.cgf” works just great.)
So I’m finally at the point where I can try to incorporate some calls to your software and see what happens. The most interesting one from my point of view is dcmnet, so I’ll start with it.
Thanks again for your most crucial comment which got me out of the mud.
I would just like to thank you for your most welcomed help in putting me on the right track. I failed to see the first time around the renaming of *.cc to *.cxx and I failed to see the fact that an automatic upgrade of Visual Studio 6.0 to 7.0 doesn’t work.
It was a real struggle with this mistake, but the experience I gained made it trivial the second time around.
I downloaded and used Cmake, so that the compilation went through with only 2 errors. Both errors involved include files where the file names were *.cc instead of the renamed *.cxx. These were trivial to fix.
I also downloaded and used doxygen to generate help, and then compiled help files. The only suggestion I can make here is you write specifically in your document to use htmldocs.cfg instead of the “make html” which is currently written. (I still don’t know what make html is supposed to do, but “doxygen htmldocs.cgf” works just great.)
So I’m finally at the point where I can try to incorporate some calls to your software and see what happens. The most interesting one from my point of view is dcmnet, so I’ll start with it.
Thanks again for your most crucial comment which got me out of the mud.
Thanks,
Ilan
Ilan
Who is online
Users browsing this forum: Ahrefs [Bot] and 1 guest