I just merged in the latest snapshot to try and correct some of the
channel/session issues fixed since 1.1. I have to issues:

 

I am using Visual Studio 2008 so my _MSC_VER is 1500 but ssize_t is not
defined. I have solved this with the following patch to include/libssh2.h:

 

--- C:\Users\giermang\Desktop\libssh2-1.1.1-20090613\include\libssh2.h
2009-06-12 21:02:23.000000000 -0500   
+++ C:\Users\giermang\new\libssh2-1.1\include\libssh2.h 2009-06-13
18:59:35.000000000 -0500   
@@ -76,12 +76,19 @@   
typedef __int64 libssh2_int64_t;   
typedef unsigned int uint32_t;   
#ifndef _SSIZE_T_DEFINED   
typedef int ssize_t;   
#define _SSIZE_T_DEFINED   
#endif   
+#elif defined(LIBSSH2_WIN32) && defined(_MSC_VER) && (_MSC_VER >= 1500)   
+#ifndef _SSIZE_T_DEFINED   
+typedef int ssize_t;   
+#define _SSIZE_T_DEFINED   
+#endif   
+typedef unsigned long long libssh2_uint64_t;   
+typedef long long libssh2_int64_t;   
#else   
typedef unsigned long long libssh2_uint64_t;   
typedef long long libssh2_int64_t;   
#endif   
  
/* We use underscore instead of dash when appending CVS in dev versions just


 

Now I have an issue with the new hostkey stuff. When I try to compile I get:

 

1>hostkey.c

1>c:\users\giermang\new\libssh2-1.1\src\hostkey.c(445) : error C2491:
'libssh2_hostkey_hash' : definition of dllimport function not allowed

1>c:\users\giermang\new\libssh2-1.1\src\hostkey.c(468) : error C2491:
'libssh2_session_hostkey' : definition of dllimport function not allowed

 

My Preprocessor Defines are
"WIN32;_DEBUG;LIBSSH2_WIN32;_LIB;_CRT_SECURE_NO_WARNINGS;_CRT_SECURE_NO_DEPR
ECATE"

 

I'm not quite sure what the issue is there so I'm wondering if there is
anyone else that can look at the C2491 errors

 

------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensing option that enables unlimited
royalty-free distribution of the report engine for externally facing 
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
libssh2-devel mailing list
libssh2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libssh2-devel

Reply via email to