Mercurial > mxe-octave
annotate src/msvc-libssh2-1.patch @ 4662:b77b935415aa
of-windows: update to v1.3.0
* build_packages.m: update windows verseion
* dist-files.mk: removed ref to of-windows-1-fixes.patch
* src/of-windows.mk: update version, checksum, remove bootstrap call
* src/of-windows-1-fixes.patch: removed file
author | John Donoghue |
---|---|
date | Tue, 17 Apr 2018 12:22:53 -0400 |
parents | c81056b5528e |
children |
rev | line source |
---|---|
3085
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
1 diff -ur libssh2-1.4.2-orig/example/direct_tcpip.c libssh2-1.4.2/example/direct_tcpip.c |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
2 --- libssh2-1.4.2-orig/example/direct_tcpip.c 2011-09-11 09:27:40 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
3 +++ libssh2-1.4.2/example/direct_tcpip.c 2013-06-23 23:09:22 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
4 @@ -27,6 +27,10 @@ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
5 #define INADDR_NONE (in_addr_t)-1 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
6 #endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
7 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
8 +#ifdef _MSC_VER |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
9 +#define strcasecmp stricmp |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
10 +#endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
11 + |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
12 const char *keyfile1 = "/home/username/.ssh/id_rsa.pub"; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
13 const char *keyfile2 = "/home/username/.ssh/id_rsa"; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
14 const char *username = "username"; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
15 diff -ur libssh2-1.4.2-orig/example/scp_nonblock.c libssh2-1.4.2/example/scp_nonblock.c |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
16 --- libssh2-1.4.2-orig/example/scp_nonblock.c 2011-09-11 09:27:40 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
17 +++ libssh2-1.4.2/example/scp_nonblock.c 2013-06-23 23:13:30 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
18 @@ -144,7 +144,9 @@ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
19 /* Since we have set non-blocking, tell libssh2 we are non-blocking */ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
20 libssh2_session_set_blocking(session, 0); |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
21 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
22 +#ifndef _MSC_VER |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
23 gettimeofday(&start, NULL); |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
24 +#endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
25 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
26 /* ... start it up. This will trade welcome banners, exchange keys, |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
27 * and setup crypto, compression, and MAC layers |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
28 @@ -247,11 +249,13 @@ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
29 break; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
30 } |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
31 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
32 +#ifndef _MSC_VER |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
33 gettimeofday(&end, NULL); |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
34 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
35 time_ms = tvdiff(end, start); |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
36 printf("Got %d bytes in %ld ms = %.1f bytes/sec spin: %d\n", total, |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
37 time_ms, total/(time_ms/1000.0), spin ); |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
38 +#endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
39 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
40 libssh2_channel_free(channel); |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
41 channel = NULL; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
42 diff -ur libssh2-1.4.2-orig/example/sftp.c libssh2-1.4.2/example/sftp.c |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
43 --- libssh2-1.4.2-orig/example/sftp.c 2011-09-11 09:27:40 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
44 +++ libssh2-1.4.2/example/sftp.c 2013-06-23 23:14:33 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
45 @@ -36,6 +36,10 @@ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
46 #include <stdio.h> |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
47 #include <ctype.h> |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
48 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
49 +#ifdef _MSC_VER |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
50 +#define strcasecmp stricmp |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
51 +#endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
52 + |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
53 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
54 const char *keyfile1="~/.ssh/id_rsa.pub"; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
55 const char *keyfile2="~/.ssh/id_rsa"; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
56 diff -ur libssh2-1.4.2-orig/example/sftp_nonblock.c libssh2-1.4.2/example/sftp_nonblock.c |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
57 --- libssh2-1.4.2-orig/example/sftp_nonblock.c 2012-03-13 17:01:10 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
58 +++ libssh2-1.4.2/example/sftp_nonblock.c 2013-06-23 23:15:25 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
59 @@ -146,7 +146,9 @@ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
60 /* Since we have set non-blocking, tell libssh2 we are non-blocking */ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
61 libssh2_session_set_blocking(session, 0); |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
62 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
63 +#ifndef _MSC_VER |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
64 gettimeofday(&start, NULL); |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
65 +#endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
66 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
67 /* ... start it up. This will trade welcome banners, exchange keys, |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
68 * and setup crypto, compression, and MAC layers |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
69 @@ -249,10 +251,12 @@ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
70 } |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
71 } while (1); |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
72 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
73 +#ifndef _MSC_VER |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
74 gettimeofday(&end, NULL); |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
75 time_ms = tvdiff(end, start); |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
76 printf("Got %d bytes in %ld ms = %.1f bytes/sec spin: %d\n", total, |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
77 time_ms, total/(time_ms/1000.0), spin ); |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
78 +#endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
79 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
80 libssh2_sftp_close(sftp_handle); |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
81 libssh2_sftp_shutdown(sftp_session); |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
82 diff -ur libssh2-1.4.2-orig/example/ssh2.c libssh2-1.4.2/example/ssh2.c |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
83 --- libssh2-1.4.2-orig/example/ssh2.c 2011-09-11 09:27:40 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
84 +++ libssh2-1.4.2/example/ssh2.c 2013-06-23 23:10:10 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
85 @@ -36,6 +36,9 @@ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
86 #include <stdio.h> |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
87 #include <ctype.h> |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
88 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
89 +#ifdef _MSC_VER |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
90 +#define strcasecmp stricmp |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
91 +#endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
92 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
93 const char *keyfile1="~/.ssh/id_rsa.pub"; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
94 const char *keyfile2="~/.ssh/id_rsa"; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
95 diff -ur libssh2-1.4.2-orig/example/ssh2_echo.c libssh2-1.4.2/example/ssh2_echo.c |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
96 --- libssh2-1.4.2-orig/example/ssh2_echo.c 2011-09-11 09:27:40 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
97 +++ libssh2-1.4.2/example/ssh2_echo.c 2013-06-23 23:17:50 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
98 @@ -30,7 +30,9 @@ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
99 # include <arpa/inet.h> |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
100 #endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
101 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
102 +#ifndef _MSC_VER |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
103 #include <sys/time.h> |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
104 +#endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
105 #include <sys/types.h> |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
106 #include <stdlib.h> |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
107 #include <fcntl.h> |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
108 diff -ur libssh2-1.4.2-orig/example/ssh2_exec.c libssh2-1.4.2/example/ssh2_exec.c |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
109 --- libssh2-1.4.2-orig/example/ssh2_exec.c 2011-12-08 04:54:46 -0500 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
110 +++ libssh2-1.4.2/example/ssh2_exec.c 2013-06-23 23:17:12 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
111 @@ -32,7 +32,9 @@ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
112 # include <arpa/inet.h> |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
113 #endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
114 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
115 +#ifndef _MSC_VER |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
116 #include <sys/time.h> |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
117 +#endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
118 #include <sys/types.h> |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
119 #include <stdlib.h> |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
120 #include <fcntl.h> |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
121 diff -ur libssh2-1.4.2-orig/example/subsystem_netconf.c libssh2-1.4.2/example/subsystem_netconf.c |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
122 --- libssh2-1.4.2-orig/example/subsystem_netconf.c 2012-02-10 10:31:38 -0500 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
123 +++ libssh2-1.4.2/example/subsystem_netconf.c 2013-06-23 23:20:07 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
124 @@ -28,6 +28,12 @@ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
125 #define INADDR_NONE (in_addr_t)~0 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
126 #endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
127 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
128 +#ifdef _MSC_VER |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
129 +#define __func__ __FUNCTION__ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
130 +#define snprintf _snprintf |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
131 +#define strcasecmp stricmp |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
132 +#endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
133 + |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
134 const char *keyfile1 = "/home/username/.ssh/id_rsa.pub"; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
135 const char *keyfile2 = "/home/username/.ssh/id_rsa"; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
136 const char *username = "username"; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
137 diff -ur libssh2-1.4.2-orig/example/tcpip-forward.c libssh2-1.4.2/example/tcpip-forward.c |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
138 --- libssh2-1.4.2-orig/example/tcpip-forward.c 2012-02-10 10:31:38 -0500 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
139 +++ libssh2-1.4.2/example/tcpip-forward.c 2013-06-23 23:21:08 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
140 @@ -27,6 +27,10 @@ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
141 #define INADDR_NONE (in_addr_t)-1 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
142 #endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
143 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
144 +#ifdef _MSC_VER |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
145 +#define strcasecmp stricmp |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
146 +#endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
147 + |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
148 const char *keyfile1 = "/home/username/.ssh/id_rsa.pub"; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
149 const char *keyfile2 = "/home/username/.ssh/id_rsa"; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
150 const char *username = "username"; |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
151 diff -ur libssh2-1.4.2-orig/src/libssh2_priv.h libssh2-1.4.2/src/libssh2_priv.h |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
152 --- libssh2-1.4.2-orig/src/libssh2_priv.h 2012-01-27 08:34:03 -0500 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
153 +++ libssh2-1.4.2/src/libssh2_priv.h 2013-06-23 23:07:02 -0400 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
154 @@ -108,6 +108,10 @@ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
155 #define TRUE 1 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
156 #endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
157 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
158 +#ifdef _MSC_VER |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
159 +#define snprintf _snprintf |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
160 +#endif |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
161 + |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
162 /* Provide iovec / writev on WIN32 platform. */ |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
163 #ifdef WIN32 |
c81056b5528e
[MSVC] enable libssh2 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
164 |