Skip to content

Commit aa17617

Browse files
committed
Support new libgit2 IO poll features
This change came with Windows schannel support. * GIT_IO_WSAPOLL * GIT_IO_POLL * GIT_IO_SELECT
1 parent 500cc9d commit aa17617

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

libgit2-sys/build.rs

+8
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,14 @@ fn main() {
122122
features.push_str("#define GIT_USE_NSEC 1\n");
123123
}
124124

125+
if windows {
126+
features.push_str("#define GIT_IO_WSAPOLL 1\n");
127+
} else {
128+
// Should we fallback to `select` as more systems have that?
129+
features.push_str("#define GIT_IO_POLL 1\n");
130+
features.push_str("#define GIT_IO_SELECT 1\n");
131+
}
132+
125133
if target.contains("apple") {
126134
features.push_str("#define GIT_USE_STAT_MTIMESPEC 1\n");
127135
} else {

0 commit comments

Comments
 (0)