I have a 32-bit ATL C++ in-proc COM server soultion. How do I port it to 64-bit Windows? I mean how do I make VC++7 emit 64-bit code? Is it possible with Visual Studio 2003?
You need a 64bit compiler that will compile long to a 64bit long. The version which was shipped in VS2005 would do. Later versions of Visual C++ and Windows SDK have higher versions of the compiler. 64bit support is disabled in standard or lower versions of Visual C++ but not in the freely available Windows SDK. Other compiler providers like Intel have their own products that supports Visual Studio and 64 bit.
Have a look at VSItanium . From the description:
The VSItanium plugin for Visual Studio .NET 2003 allows to compile Win32 Visual C++ projects with several external compilers, actually the Microsoft SDK 64bit Itanium and AMD Opteron compiler as well as the Intel C++ Itanium compiler.
Concerning compiler choice -- if migrating to a newer VS version is not an option because of reliance on cl 13 (VS 2005 uses cl 14), you should be able to find a cl 13 supporting IA-64 and amd64 in WDK 3790.1830, IIRC. There should be an old SDK with a 64 bit-supporting cl 13, but I do not know which one.
If your project builds fine with newer compilers, you basically have free choice of WDK and SDK versions.