Jump to content

Compiling Older version of T3D in Windows 10 with Visual Studio 2015


JackStone

Recommended Posts

Hello,


I recently built a new machine to take advantage of the Oculus Rift when it is released.


I am using Windows 10 and Visual Studio 2015 on the new machine, and can compile the most recent release of T3D with no problems.


I have copied over a project from my old machine to the same directory on the new machine. I used Windows 7 and Visual studio 2010 to compile the old project.


Everything seemed to go fine, except for a large number of errors around CSTDLIB.


It seems that some of the VC include files have changed, and are causing issues with older T3D code.


What would be the best way of dealing with this? Could I copy some of the old VC files from my old machine? Or should I modify my project, or build settings?


Thanks!

Link to comment
Share on other sites

I think I figured this out.


There are two main changes that I needed to make.


The main issue is that "strtok" in T3D is conflicting with the standard library.


To fix this, I simple renamed "strtok" in "stringfunctions.h".


Secondly, In daeElement.cpp, the code references a function "max" in xutility that is no longer present. Adding this function to daeElement.cpp fixes this:

 

//	ALGORITHM STUFF (from <algorithm>)
// TEMPLATE FUNCTION max
template<class _Ty> inline
const _Ty& (max)(const _Ty& _Left, const _Ty& _Right)
{	// return larger of _Left and _Right
return (_DEBUG_LT(_Left, _Right) ? _Right : _Left);
}
}

 

This should be all.


EDIT: posted the wrong function.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...