Author Topic: VS2010  (Read 5802 times)

Offline David Raphael

  • PixInsight Addict
  • ***
  • Posts: 226
    • Astrofactors CCD Cameras
VS2010
« on: 2011 July 23 10:18:18 »
Hi Juan -

I remember you mentioning that VS2010 is now supported - how do we migrate existing projects?

Thanks!
Dave
David Raphael

Offline David Raphael

  • PixInsight Addict
  • ***
  • Posts: 226
    • Astrofactors CCD Cameras
Re: VS2010
« Reply #1 on: 2011 July 23 11:00:00 »
I went ahead and took a stab at migrating...

I'm getting this error:
Code: [Select]
1>PCL-pxi.lib(Dialog.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in CameraData.obj

I'm actually getting that error for all of the *.obj

I'm guessing that the PCL-pxi.lib is built in release mode but my project is in debug mode.  Is there something obvious I need to do to?


David Raphael

Offline David Raphael

  • PixInsight Addict
  • ***
  • Posts: 226
    • Astrofactors CCD Cameras
Re: VS2010
« Reply #2 on: 2011 July 23 11:14:12 »
My wife says I always like talking to myself...I guess she is right :-)

So here is the solution to my problem - the compiler needs this:
-D_ITERATOR_DEBUG_LEVEL=0

I haven't tried debugging...so I am not sure if this affects that...I think it is not related.

David Raphael

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: VS2010
« Reply #3 on: 2011 July 24 03:43:14 »
Hi Dave,

Migrating existing VC2008 projects should be automatically managed by VC2010. In theory you just have to open the old project with VS2010 and follow the proposed steps.

However I strongly recommend you recreate the entire project using the standard Makefile Generator script in PixInsight. This will rebuild your projects and makefiles for all supported platforms from scratch.

I have no idea what the _ITERATOR_DEBUG_LEVEL thing is; I haven't seen it before. I don't use any MS products at all except to build PixInsight and test it on Windows, which I only use for the same reason. Again, if you rebuild your projects with the Makefile Generator script this won't happen.
Juan Conejero
PixInsight Development Team
http://pixinsight.com/

Offline zvrastil

  • PixInsight Addict
  • ***
  • Posts: 179
    • Astrophotography
Re: VS2010
« Reply #4 on: 2011 July 24 06:55:00 »
Hi Juan,

if you remember, this is the problem I wrote you about in a mail. It only happens with VS2010 and only compiling in Debug. It happens even with standard sample projects, including SandBox. As far as I was able to google it, it's problem of linking debug binaries agains PCL libraries, which are release. I was not able to find any solution for it, so I still do my PCL development in VS2008.

regards, Zbynek

Offline David Raphael

  • PixInsight Addict
  • ***
  • Posts: 226
    • Astrofactors CCD Cameras
Re: VS2010
« Reply #5 on: 2011 July 24 10:02:24 »
Zbynek,

My screenshot shows the fix, but here is a link to another - http://stackoverflow.com/questions/5727815/how-to-set-iterator-debug-level-in-vs2010

I have now been compiling all my different modules in VS2010 without any issues. 

Best,
Dave
David Raphael

Offline zvrastil

  • PixInsight Addict
  • ***
  • Posts: 179
    • Astrophotography
Re: VS2010
« Reply #6 on: 2011 July 24 23:49:04 »
Hi Dave,

thanks for the link. Seems I should've spend little more time googling :).

regards, Zbynek