mirror of
https://github.com/nestriness/cdc-file-transfer.git
synced 2026-05-01 18:43:08 +03:00
[common] Add support for ClientSocket on Linux (#97)
Uses the abstractions written for ServerSocket in ClientSocket, so that it builds on Linux. Also adds a method to poll for connections and uses that in cdc_rsync. Similar code will be used in cdc_fuse_fs to wait for a connection in a future CL.
This commit is contained in:
11
common/BUILD
11
common/BUILD
@@ -62,7 +62,10 @@ cc_library(
|
||||
|
||||
cc_library(
|
||||
name = "client_socket",
|
||||
srcs = ["client_socket.cc"],
|
||||
srcs = [
|
||||
"client_socket.cc",
|
||||
"socket_internal.h",
|
||||
],
|
||||
hdrs = ["client_socket.h"],
|
||||
linkopts = select({
|
||||
"//tools:windows": [
|
||||
@@ -70,7 +73,6 @@ cc_library(
|
||||
],
|
||||
"//conditions:default": [],
|
||||
}),
|
||||
target_compatible_with = ["@platforms//os:windows"],
|
||||
deps = [
|
||||
":log",
|
||||
":socket",
|
||||
@@ -473,7 +475,10 @@ cc_test(
|
||||
|
||||
cc_library(
|
||||
name = "server_socket",
|
||||
srcs = ["server_socket.cc"],
|
||||
srcs = [
|
||||
"server_socket.cc",
|
||||
"socket_internal.h",
|
||||
],
|
||||
hdrs = ["server_socket.h"],
|
||||
linkopts = select({
|
||||
"//tools:windows": [
|
||||
|
||||
Reference in New Issue
Block a user