CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Page 2 of 2 FirstFirst 12
Results 16 to 17 of 17
  1. #16
    Join Date
    Feb 2009
    Posts
    48

    Re: Linking problem - unresolved external symbol

    Hmm I'm not sure about it.
    Found a link to MSDN page about defines
    http://msdn.microsoft.com/en-us/libr...=vs.80%29.aspx
    saying _WIN32 Defined for applications for Win32 and Win64. Always defined.

  2. #17
    Join Date
    Apr 1999
    Posts
    27,449

    Re: Linking problem - unresolved external symbol

    Quote Originally Posted by Anakunda View Post
    Hmm I'm not sure about it.
    Found a link to MSDN page about defines
    http://msdn.microsoft.com/en-us/libr...=vs.80%29.aspx
    saying _WIN32 Defined for applications for Win32 and Win64. Always defined.
    What about the WIN32 preprocessor symbol, without the leading underscore? Same thing with WIN64. Many third-party headers use the non-underscore version (or some variation of them) to distinguish between a 32-bit build and 64-bit builds.

    This is where you need to specify the correct preprocessor that the library code uses to distinguish between the two versions. My inclination is to just define WIN64 (or whatever preprocessor the library uses to define a 64-bit build) and let it be, since that has worked for me whenever I build a 64-bit app.

    Regards,

    Paul McKenzie
    Last edited by Paul McKenzie; December 14th, 2010 at 07:49 PM.

Page 2 of 2 FirstFirst 12

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured