View Single Post
Re: Half life SDk with Visual Studio 2010?
Old
  (#2)
SamPlay
Member
 
Status: Offline
Posts: 46
Join Date: Jan 2006
Default Re: Half life SDk with Visual Studio 2010? - 26-07-2011

HI,
you should not expect a lot of activity during summer holidays!
I am using vc9 , not vc 10 but I compiled several old programms developped with vc6. It works but you unfortunately have to correct the code in some places:
- first because vc6 allowed things that are now forbidden , and set as such in in ms compilers> vc6; mainly due to "int i" and the like set in "for" loops the declaration of wich is now restricted to the loop (easiest solution: place the "int i" or whatever outside the loop: beware that the behavior is still the same.)
replace
for(int i= 0...)
by
int i;
for( i=...
this is the simplest but most time consuming change to do.
- in some case vc6 would allow a function as a righ-hand-side value where a function pointer is now demanded ( add a &..).
- some macros in the sdk bear the same name than macros introduce by ms later: no general solution here ( eg use "#undef ...", change sdk macro name, change order of #includes",..)
-warnings are generated for "old style" ( mainly input/output) standard functions ( fopen,..) but they still work and the compiler tells what preprocessor directive to use to get rid of those warnings.
-"libc.lib" may cause problems, which I always successfully get rid of by adding this lib in the "ignore specific library" in the "input" section of the linker. This goes along with getting rid of reference to the vc6 project in the "Inherited Project property sheets" in the"General" section once it has been translated into a vc9 solution.
I probably forgets some issues but
1. google is your friend, even for what seem extremely specific issues
2. I may help- just post here-, as I have gone trough that ( painful ) process before.
Again I assume vc10 is not too different from vc9.
good luck!
  
Reply With Quote