[IGSTK-Users] help on itk 3.20.1 vs2008 compilation needed
Aiden
agongheli at 163.com
Tue May 8 23:01:36 EDT 2012
Hi, Özgür:
Thanks a lot for help.
I could reproduce what you did with manually setting value of VXL_SIZEOF_SIZE_T.
I tried to include the file CheckTypeSize.cmake. But it gave me the same error. I print out the path of ${CMAKE_ROOT}/Modules/CheckTypeSize.cmake, it is correct. Print out the value of VXL_SIZEOF_SIZE_T, error, message() could print out anything.
I did another experiment: Originally I am compiling ITK 32bit on a x64 machine. I tried to configure it on a x86 OS. This time, cmake passed. Printing out the value of VXL_SIZEOF_SIZE_T gave me a number 4. Then I moved the generated generated build directory and compiled on the original x64 machine without any problem.
I guess it is the cmake does not handle check_type_size() well on a x64 environment.
Although I got a workaround (will it pose serious problem in the road ahead?), still hope it will be resolved on x64 environment. More and more computer are installed x64 OS now.
Thanks.
Aiden
At 2012-05-09 09:58:16,"Özgür Güler" <ozgur_guler at gmx.at> wrote:
>Hi Aiden,
>
>when I run following simple CMakeLists.txt
>
>----CMakeLists.txt
>cmake_minimum_required(VERSION 2.6)
>
>set(VXL_SIZEOF_SIZE_T 7)
>MATH(EXPR VXL_ADDRESS_BITS 8*${VXL_SIZEOF_SIZE_T} )
>message(${VXL_ADDRESS_BITS})
>----
>
>with CMake 2.8 and 2.6 it works fine and I get the result 56 as output.
>
>The error you get is reproducible if you comment the line where I set
>VXL_SIZEOF_SIZE_T to 7.
>
>In ITKs CMakeLists.txt this means that this variable is not set, which
>causes the strange error message.
>ITK tries to set this variable one line above MATH(.... with
>
>check_type_size(size_t VXL_SIZEOF_SIZE_T)
>
>this CMake command should set the variable VXL_SIZEOF_SIZE_T with 4
>(byte) or 8 (byte)
>it seems that this command does not set this variable.
>
>the following code snippet gives on my Laptop 32 (CMake 2.8, CMake 2.6)
>
>INCLUDE (${CMAKE_ROOT}/Modules/CheckTypeSize.cmake)
>#set(VXL_SIZEOF_SIZE_T 7)
>CHECK_TYPE_SIZE(size_t VXL_SIZEOF_SIZE_T)
>MATH(EXPR VXL_ADDRESS_BITS 8*${VXL_SIZEOF_SIZE_T} )
>message(${VXL_ADDRESS_BITS})
>
>could you try that and post the result?
>
>Best,
>Özgür
>
>
>
>
>2012/5/8 Aiden <agongheli at 163.com>:
>> Hi,
>>
>> May I ask for help on the compilation of itk 3.20.1 using vs2008?
>>
>> If I use cmake 2.8.7, I got the same error when configuring:
>>
>> http://www.itk.org/pipermail/insight-users/2011-December/043132.html
>>
>> Then I switched to cmake 2.6.4, turned off BUILD_TESTING and BUILD_EXAMPLE,
>> I got a similar warning, as attached.
>>
>> In the end, I got a message of error, but without any red line. The "OK"
>> button is grayed. I guess it is the same error with cmake 2.8.7. I attached
>> the CMakeCache.txt, ITKBuildSettings.cmake, ITKConfig.cmake here.
>>
>> Thanks a lot for helping out.
>>
>> Regards,
>> Aiden
>>
>>
>>
>>
>> _______________________________________________
>> Powered by www.kitware.com
>>
>> Visit other Kitware open-source projects at
>> http://www.kitware.com/opensource/opensource.html
>>
>> Follow this link to subscribe/unsubscribe:
>> http://public.kitware.com/cgi-bin/mailman/listinfo/igstk-users
>
>
>
>--
>*********************************************************************
>Dr. Dipl.-Ing. Özgür Güler, Bakk. techn. PhD
>Research Assistant
>4D-Visualization Laboratory
>Univ. ENT Clinic
>Innsbruck Medical University
>Anichstr. 35, A-6020 Innsbruck, Austria
>
>tel.: +43 512 504 23428, fax.: +43 512 504 25231
>
>voxelmaster.eu
>www.gueler.at
>*********************************************************************
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/igstk-users/attachments/20120509/b27131eb/attachment.html>
More information about the IGSTK-Users
mailing list