[Insight-users] SimpleITK Build Issues VS 2008 (x64)

Scott Johnson Scott.Johnson at neuwave.com
Sat Mar 31 11:05:33 EDT 2012


Thanks Dan.

Where is cmake looking to find stdint.h?

		-- Scott

-----Original Message-----
From: Dan Mueller [mailto:dan.muel at gmail.com] 
Sent: Friday, March 30, 2012 6:43 PM
To: Scott Johnson
Cc: itk (Insight-users at itk.org)
Subject: Re: [Insight-users] SimpleITK Build Issues VS 2008 (x64)

Hi Scott,

Yes, I also had discovered this. Sorry for not making this clear in my email.

Just to be clear, the options are:
1. Change SimpleITK so that VS10 builds do no use .NET 4.0 (meaning pre-built SimpleITKCSharpManaged.dll will be usable with VS9). I'm not going to be able to address this any time soon.
2. Get your VS9 environment to support TR1/C99, then build SimpleITK yourself.
(3. Switch to VS10.)

> If I can past the CMake issues I'll feel more confident that I can get it to build.
BTW: The issue you report is not an issue with the CMake build per se, but an issue with your compiler -- the CMake build is simply doing some checks and has determined that your build environment does not meet the requirements for SimpleITK.

Good luck.

Cheers, Dan

On 31 March 2012 09:40, Scott Johnson <Scott.Johnson at neuwave.com> wrote:
> Hi Again,
>
> With a little research I have found that Visual Studio 2008 is not compatible with .Net Framework 4.0.  Therefore the pre-built dlls cannot be used under VS 2008.
>
> Back to trying to build it.
>
> Thanks
>
>                -- Scott
>
> -----Original Message-----
> From: insight-users-bounces at itk.org 
> [mailto:insight-users-bounces at itk.org] On Behalf Of Scott Johnson
> Sent: Friday, March 30, 2012 6:00 PM
> To: Dan Mueller
> Cc: itk (Insight-users at itk.org)
> Subject: Re: [Insight-users] SimpleITK Build Issues VS 2008 (x64)
>
> Thanks for the response Dan.
>
> I'll try to target .NET 4.0 to see if I can use the prebuilt dlls.
>
> If I can past the CMake issues I'll feel more confident that I can get it to build.
>
>                -- Scott
>
> -----Original Message-----
> From: Dan Mueller [mailto:dan.muel at gmail.com]
> Sent: Friday, March 30, 2012 4:44 PM
> To: Scott Johnson
> Cc: itk (Insight-users at itk.org); Bradley Lowekamp
> Subject: Re: [Insight-users] SimpleITK Build Issues VS 2008 (x64)
>
> Hi Scott,
>
> Sorry to hear you are experiencing issues with building the SimpleITK C# wrappers.
>
> I tried to use SimpleITKCSharpManaged.dll from SimpleITK-0.4.0-CSharp-Win64-anycpu.zip in a Visual Studio 2008 project and experienced the same issue you described:
> Could not load file or assembly 'SimpleITKCSharpManaged.dll' or one of its dependencies. This assembly is built by a runtime newer than the currently loaded runtime and cannot be loaded.
>
> The issue is not that the assembly was built by Visual Study 2010 (which it was) but rather it was built to target the .NET 4.0 runtime.
> AFAIK it should be possible to build with Visual Studio 2010 but to target the .NET 2.0 runtime for example. That said, I am totally flat out at the moment and don't know when I will get a chance to do this... So you will probably get faster results if you build yourself.
>
> The SimpleITK FAQ does say that Visual Studio 9 is currently 
> problematic
>    
> http://www.itk.org/Wiki/ITK_Release_4/SimpleITK/FAQ#Currently_Problema
> tic but looking at the SimpleITK dashboard
>    http://open.cdash.org/index.php?project=simpleITK
> I notice there is one Visual Studio 2008 (aka Visual Studio 9) build (an x86 build), so it does seem possible to build SimpleITK with VS9.
>
> Brad owns this build machine, so I've cc'd him. Hopefully he can provide some advice on how to setup VS9 to support TR1/C99.
>
> Cheers, Dan
>
> On 31 March 2012 05:34, Scott Johnson <Scott.Johnson at neuwave.com> wrote:
>> Hello,
>>
>>
>>
>> I've been attempting to use SimpleITK under Windows 7 (x64) and 
>> Visual Studio 2008 and CMake 2.8.5.  The goal is to use the C# wrappers.
>>
>>
>>
>> First, I downloaded SimpleITK-0.4.0-CSharp-Win64-anycpu.zip and 
>> attempted to add a reference to SimpleITKCSharpManaged.dll to my 
>> solution.  VS didn't recognize the dll as being valid.  (Now I'm 
>> assuming that the dll was built against VS 2010 and isn't backward
>> compatible.)
>>
>>
>>
>> I then downloaded the source tree with the intent to build it myself.
>> (I've tried with both the source package from sourceforge and 
>> checking out the most recent code from GIT.)  I have been attempting 
>> to follow the directions at http://www.itk.org/Wiki/ITK_Release_4/SimpleITK/FAQ.
>>
>>
>>
>> When I first ran CMake I was given an error reading:
>>
>>
>>
>> CMake Error at CMakeLists.txt:117 (message):
>>
>> SimpleITK requires usage of C99 stdint.
>>
>> It may be available as an optional download for your compiler.
>>
>> Please see the FAQ for details and to see if your compiler is supported.
>>
>> http://www.itk.org/Wiki/ITK_Release_4/SimpleITK/FAQ#Do_I_need_to_down
>> l
>> oad_an_optional_package_for_C99.3F
>>
>>
>>
>> I downloaded the Visual C++ 2008 Feature Pack Release via the link on 
>> the web site and attempted to install it.  It failed because the 
>> installer said that I didn't have the proper features installed for 
>> the update.  I also grabbed the stdint.h file and copied it to the 
>> location called out in the directions.  I've searched for a 64 bit 
>> version of this feature pack with no luck.  I did find Microsoft 
>> Visual C++ 2008 Feature Pack Redistributable Package (x64) but that didn't help.
>>
>>
>>
>> CMake continues to give me errors and I've tracked the initial error 
>> to a line in the CMakeLists.txt file which reads:
>>
>> check_include_file_cxx( stdint.h SITK_HAS_STDINT_H )
>>
>> I've been looking around to find out what paths are searched by 
>> check_include_file_cxx to no avail.  But evidently C:\Program 
>> Files\Microsoft Visual Studio 9/0\VC\include isn't one of them.
>>
>>
>>
>> If possible I'd like to get this to work under VS 2008 and I'd 
>> appreciate any help I can get.  Right now I'm out of ideas as to what is going wrong.
>>
>>
>>
>> Thanks
>>
>>
>>
>>                                 -- Scott
> _____________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at 
> http://www.kitware.com/opensource/opensource.html
>
> Kitware offers ITK Training Courses, for more information visit:
> http://www.kitware.com/products/protraining.php
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-users


More information about the Insight-users mailing list