I have encountered a problem running CMake 2.8.12.2 on dcmtk-3.6.1_20150217
OS: Windows 8.1 x64
Compiler: VS 2010 x64 [CMake: Visual Studio 10 Win64]
Reading the DCMTK FAQ did not provide any insight, so I like to post my
question to the forum:
1/ Configure CMake error messages:
CMake Error at CMake/GenerateDCMTKConfigure.cmake:773 (MESSAGE):
Inspecting fundamental arithmetic types...
-- Error: missing destination file to store collected information.
Call Stack (most recent call first):
CMakeLists.txt:45 (INSPECT_FUNDAMENTAL_ARITHMETIC_TYPES)
Checking
../Program Files/DCMTK/build/CMakeFiles/CMakeOutput.log
all the builds were reported as successful
Checking
../Program Files/DCMTK/build/CMakeFiles/CMakeError.log
The first build failure error message is
Determining if the __PRETTY_FUNCTION__ exist failed with the following output:
Change Dir: F:/Program Files/DCMTK/build/CMakeFiles/CMakeTmp
Run Build Command:F:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\devenv.com CMAKE_TRY_COMPILE.sln /build Debug /project cmTryCompileExec2941954956
Microsoft (R) Visual Studio Version 10.0.40219.1.
Copyright (C) Microsoft Corp. All rights reserved.
1>------ Build started: Project: cmTryCompileExec2941954956, Configuration: Debug x64 ------
1>Build started 2015-03-09 5:30:20 AM.
1>PrepareForBuild:
1> Creating directory "F:\Program Files\DCMTK\build\CMakeFiles\CMakeTmp\Debug\".
1>InitializeBuildStatus:
1> Creating "cmTryCompileExec2941954956.dir\Debug\cmTryCompileExec2941954956.unsuccessfulbuild" because "AlwaysCreate" was specified.
1>ClCompile:
1> CheckSymbolExists.c
1>CheckSymbolExists.c(7): error C2065: '__PRETTY_FUNCTION__' : undeclared identifier
1>
1>Build FAILED.
1>
1>Time Elapsed 00:00:00.09
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
I thought that " __PRETTY_FUNCTION__" is not part of the Windows VS 2010 enviroment.
2/ Generate CMake error messages:
Info: DCMTK's builtin private dictionary support will be enabled
Info: Thread support will be enabled
Info: Wide char file I/O functions will be disabled
Info: Wide char main function for command line tools will be disabled
CMake Error at CMake/GenerateDCMTKConfigure.cmake:773 (MESSAGE):
Inspecting fundamental arithmetic types...
-- Error: missing destination file to store collected information.
Call Stack (most recent call first):
CMakeLists.txt:45 (INSPECT_FUNDAMENTAL_ARITHMETIC_TYPES)
Any insight would be appreciated. Thank you.
Audrius
Windows 8.1 x64 | CMake 2.8.12.2 with dcmtk-3.6.1_20150217
Moderator: Moderator Team
Windows 8.1 x64 | CMake 2.8.12.2 with dcmtk-3.6.1_20150217
Last edited by Audrius on Mon, 2015-03-09, 17:23, edited 1 time in total.
-
- OFFIS DICOM Team
- Posts: 318
- Joined: Mon, 2014-03-03, 09:51
- Location: Oldenburg, Germany
Re: Windows 8.1 x64 | CMake 2.8.12.2 with dcmtk-3.6.1_201502
It's pretty hard to answer this question, since this definitely should not happen. Normally CMake compiles an executable called arith.exe during configuration and then calls 'arith.exe ${ARITH_H_FILE}', where ${ARITH_H_FILE} is set the following way (in CMake/GenerateDCMTKConfigure.cmake):
Looking at arith.cc
The only thing I can come up with is that your build directory contains a space, which is why CMake interprets it as two arguments and arith reports it got called with the wrong number of arguments. Please try if changing the set statement the following way fixes this problem:
It may be I forgot these quotes when writing that code, so I'll commit this, if it fixes things for you (never run into this kind of problem during testing though).
Code: Select all
SET(ARITH_H_FILE ${DCMTK_BINARY_DIR}/config/include/dcmtk/config/arith.h)
Code: Select all
COUT << "Inspecting fundamental arithmetic types... " << OFendl;
if( argc != 2 )
{
STD_NAMESPACE cerr << "-- " << "Error: missing destination file "
<< "to store collected information." << OFendl;
return 1;
}
Code: Select all
SET(ARITH_H_FILE "${DCMTK_BINARY_DIR}/config/include/dcmtk/config/arith.h")
Re: Windows 8.1 x64 | CMake 2.8.12.2 with dcmtk-3.6.1_201502
Thank you for your prompt response and advice.
I did make the change that you suggested:
cleared the CMake cache, and reran CMake. Unfortunately, the same error message was again generated.
However, your observation that "your build directory contains a space, . . ." is correct.
The directory I used is
F:\Program Files\DCMTK\dcmtk-3.6.1_20150217
Once I changed the DCMTK directory to
F:\DCMTK\dcmtk-3.6.1_20150217
CMake successfully completed the configuration step, specifically
Inspecting fundamental arithmetic types...
--
-- TRAPS MODULO
-- char yes yes
-- signed char yes yes
-- unsigned char yes yes
-- signed short yes yes
-- unsigned short yes yes
-- signed int yes yes
-- unsigned int yes yes
-- signed long yes yes
-- unsigned long yes yes
--
-- float double
-- TRAPS no no
-- HAS INFINITY yes yes
-- QUIET NAN yes yes
-- SIGNALING NAN yes yes
-- IEC-559 yes yes
-- HAS DENORM yes yes
-- TINYNESS BEFORE yes yes
-- DENORM LOSS yes yes
I think that this result suggests that there is one (or more) additional line(s) in the CMake processed code that requires " ".
As
..\Program Files\..
is a standard directory in Windows to place code such as DCMTK it may be worthwhile to find and fix this bug to avoid similar questions in the future.
Thanks again for your prompt assistance
I did make the change that you suggested:
Code: Select all
SET(ARITH_H_FILE "${DCMTK_BINARY_DIR}/config/include/dcmtk/config/arith.h")
However, your observation that "your build directory contains a space, . . ." is correct.
The directory I used is
F:\Program Files\DCMTK\dcmtk-3.6.1_20150217
Once I changed the DCMTK directory to
F:\DCMTK\dcmtk-3.6.1_20150217
CMake successfully completed the configuration step, specifically
Inspecting fundamental arithmetic types...
--
-- TRAPS MODULO
-- char yes yes
-- signed char yes yes
-- unsigned char yes yes
-- signed short yes yes
-- unsigned short yes yes
-- signed int yes yes
-- unsigned int yes yes
-- signed long yes yes
-- unsigned long yes yes
--
-- float double
-- TRAPS no no
-- HAS INFINITY yes yes
-- QUIET NAN yes yes
-- SIGNALING NAN yes yes
-- IEC-559 yes yes
-- HAS DENORM yes yes
-- TINYNESS BEFORE yes yes
-- DENORM LOSS yes yes
I think that this result suggests that there is one (or more) additional line(s) in the CMake processed code that requires " ".
As
..\Program Files\..
is a standard directory in Windows to place code such as DCMTK it may be worthwhile to find and fix this bug to avoid similar questions in the future.
Thanks again for your prompt assistance
-
- OFFIS DICOM Team
- Posts: 318
- Joined: Mon, 2014-03-03, 09:51
- Location: Oldenburg, Germany
Re: Windows 8.1 x64 | CMake 2.8.12.2 with dcmtk-3.6.1_201502
Thanks for your help in tracking it down, i'll setup my configuration like that and look into it.
-
- OFFIS DICOM Team
- Posts: 318
- Joined: Mon, 2014-03-03, 09:51
- Location: Oldenburg, Germany
Re: Windows 8.1 x64 | CMake 2.8.12.2 with dcmtk-3.6.1_201502
We tracked it down, it seems this fixes the problem, not sure why though:
The patch will become part of DCMTK tomorrow, if we don't run into problems with todays nightly builds.
Code: Select all
diff --git a/CMake/GenerateDCMTKConfigure.cmake b/CMake/GenerateDCMTKConfigure.cmake
index ab9aa6b..b05825c 100644
--- a/CMake/GenerateDCMTKConfigure.cmake
+++ b/CMake/GenerateDCMTKConfigure.cmake
@@ -759,7 +759,7 @@ FUNCTION(INSPECT_FUNDAMENTAL_ARITHMETIC_TYPES)
COMPILE_DEFINITIONS -I"${DCMTK_BINARY_DIR}/config/include" -I"${DCMTK_SOURCE_DIR}/ofs
RUN_OUTPUT_VARIABLE OUTPUT
COMPILE_OUTPUT_VARIABLE CERR
- ARGS ${ARITH_H_FILE}
+ ARGS \"${ARITH_H_FILE}\"
)
IF(COMPILED)
IF(NOT RESULT)
Who is online
Users browsing this forum: No registered users and 1 guest