in reply to Re^2: Any help on Perl h2xs would appreciate
in thread Any help on Perl h2xs would appreciate

The thing to do in dealing with long lists of errors (such as the list that confronts you) is to deal with the very first error. Often, when that first error is fixed, the rest just disappear.

The first error is:
C:\Perl\bin\Remote-Connection\afxv_w32.h(178) : error C2371: 'HKEY' : +redefinition; different basic types C:\Program Files\Microsoft Visual + Studio 8\VC\PlatformSDK\include\windef.h(246) : see declaration of ' +HKEY'
It looks to me that, at line 178 of C:\Perl\bin\Remote-Connection\afxv_w32.h, HKEY is being redefined, and your compiler is upset about that. So ... try to fix that first.

One thing I've just noticed from your first post in this thread is that you've assigned LD => '$(CC)'. I think that's rather unusual for a Microsoft compiler. Normally I'm used to seeing link assigned to LD. I don't know much about C++, and I don't think this has anything to do with the immediate problem, but it's something to bear in mind if you experience linking errors later on.

Cheers,
Rob

Replies are listed 'Best First'.
Re^4: Any help on Perl h2xs would appreciate
by anupama (Novice) on Feb 18, 2009 at 04:21 UTC
    I had put all the VC++ header files in my project folder.
    when i run the command nmake i get the foolowing error msg:
    C:\Perl\bin\Remote-Connection\afxv_w32.h(178) : error C2371: 'HKEY' :
    +redefinition; different basic types C:\Program Files\Microsoft Visual
    + Studio 8\VC\PlatformSDK\include\windef.h(246) : see declaration of '+HKEY'
    . But if i dont have any Vcc++ dependent header file in my
    project folder and try to execute the same follwing error msg pops up
    C:\Perl\bin\Remote-Connection>nmake cp lib/Remote/Connection.pm blib\lib\Remote\Connection.pm C:\Perl\bin\perl.exe C:\Perl\lib\ExtUtils\xsubpp -typemap C:\Perl\lib\ExtUtils\typemap -typemap typemap Connection.xs > Connection.xsc && C:\Perl\bin\perl.exe -MExtUtils::Command -e mv Connection.xsc Connection.c cl -TP -c -I. -nologo -GF -W3 -MD -Zi -DNDEBUG -O1 -DWIN32 -D_CONSOLE-DNO_STRICT -DHAVE_DES_FCRYPT -DUSE_SITECUSTOMIZE -DPRIVLIB_LAST_IN_INC -DPERL_I MPLICIT_CONTEXT -DPERL_IMPLICIT_SYS -DUSE_PERLIO -DPERL_MSVCRT_READFIX -MD -Zi -DNDEBUG -O1 -DVERSION=\"0.01\" -DXS_VERSION=\"0.01\" "-IC:\Perl\lib\CORE"
    Connection.c
    Connection.c
    c:\perl\bin\remote-connection\const-c.inc(52) : warning
    C4060: switch statement contains no 'case' or 'default' labels C:\Program Files\Microsoft Visual Studio 8\VC\ATLMFC\INCLUDE\afx.h(24) : fatal error C1189: #error : Building MFC application with /MDd (CRT dll version) requires MFC shared dll version. Please #define _AFXDLL or do not use /MDd
    NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 8\VC\BIN\cl.EXE"' : return code '0x2'
    Stop.