roughtime.googlesource.com/roughtime.git@v0.0.0-20201210012726-dd529367052d/BUILD.gn (about) 1 # Copyright 2017 The Roughtime Authors. 2 3 # Licensed under the Apache License, Version 2.0 (the "License"); 4 # you may not use this file except in compliance with the License. 5 # You may obtain a copy of the License at 6 7 # http://www.apache.org/licenses/LICENSE-2.0 8 9 # Unless required by applicable law or agreed to in writing, software 10 # distributed under the License is distributed on an "AS IS" BASIS, 11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 # See the License for the specific language governing permissions and 13 # limitations under the License. 14 15 config("client_config") { 16 visibility = [ ":*" ] 17 include_dirs = [ "." ] 18 } 19 20 executable("simple_server") { 21 sources = [ 22 "clock_linux.cc", 23 "simple_server_main.cc", 24 "sys_time.cc", 25 ] 26 defines = [ 27 "USE_GLOG", 28 "ROUGHTIME_OPEN_SOURCE", 29 ] 30 include_dirs = [ "." ] 31 deps = [ 32 ":simple_server_lib", 33 "//third_party/boringssl", 34 "//third_party/glog", 35 ] 36 } 37 38 static_library("simple_server_lib") { 39 sources = [ 40 "protocol.cc", 41 "server.cc", 42 "simple_server.cc", 43 "simple_server.h", 44 "udp_processor.cc", 45 "udp_processor.h", 46 ] 47 defines = [ 48 "USE_GLOG", 49 "ROUGHTIME_OPEN_SOURCE", 50 ] 51 include_dirs = [ "." ] 52 public_configs = [ ":client_config" ] 53 deps = [ 54 "//third_party/boringssl", 55 "//third_party/glog", 56 ] 57 } 58 59 static_library("client_lib") { 60 sources = [ 61 "client.cc", 62 "clock_linux.cc", 63 "protocol.cc", 64 ] 65 defines = [ "USE_GLOG" ] 66 public_configs = [ ":client_config" ] 67 deps = [ 68 "//third_party/boringssl", 69 "//third_party/glog", 70 ] 71 }