summaryrefslogtreecommitdiff
path: root/libssh2-sys/lib.rs
diff options
context:
space:
mode:
authorAlex Crichton <alex@alexcrichton.com>2016-02-13 22:57:57 -0800
committerAlex Crichton <alex@alexcrichton.com>2016-02-13 22:57:57 -0800
commit003ed04fbeb05b862caa9ffb2855cf72930afd9d (patch)
tree37c43a18954525151a6b69deacb9e025c0f4bd83 /libssh2-sys/lib.rs
parentddb55867d00dc0254d0b5970fec5ed08c6030782 (diff)
downloadssh2-rs-003ed04fbeb05b862caa9ffb2855cf72930afd9d.zip
Drop the winapi/ws2_32 dep
Not worth the build times
Diffstat (limited to 'libssh2-sys/lib.rs')
-rw-r--r--libssh2-sys/lib.rs10
1 files changed, 6 insertions, 4 deletions
diff --git a/libssh2-sys/lib.rs b/libssh2-sys/lib.rs
index bb6c46f..02fd203 100644
--- a/libssh2-sys/lib.rs
+++ b/libssh2-sys/lib.rs
@@ -2,8 +2,6 @@
#![allow(bad_style)]
extern crate libc;
-extern crate ws2_32;
-extern crate winapi;
extern crate libz_sys;
#[cfg(unix)]
@@ -211,8 +209,12 @@ pub type LIBSSH2_PASSWD_CHANGEREQ_FUNC = extern fn(sess: *mut LIBSSH2_SESSION,
newpw_len: *mut c_int,
abstrakt: *mut *mut c_void);
-#[cfg(unix)] pub type libssh2_socket_t = c_int;
-#[cfg(windows)] pub type libssh2_socket_t = winapi::SOCKET;
+#[cfg(unix)]
+pub type libssh2_socket_t = c_int;
+#[cfg(all(windows, target_arch = "x86"))]
+pub type libssh2_socket_t = u32;
+#[cfg(all(windows, target_arch = "x86_64"))]
+pub type libssh2_socket_t = u64;
extern {
// misc