OLD | NEW |
1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 static_library("libevent") { | 5 static_library("libevent") { |
6 sources = [ | 6 sources = [ |
7 "buffer.c", | 7 "buffer.c", |
8 "epoll.c", | |
9 "epoll_sub.c", | |
10 "evbuffer.c", | 8 "evbuffer.c", |
11 "evdns.c", | 9 "evdns.c", |
12 "event.c", | 10 "event.c", |
13 "event_tagging.c", | 11 "event_tagging.c", |
14 "evrpc.c", | 12 "evrpc.c", |
15 "evutil.c", | 13 "evutil.c", |
16 "http.c", | 14 "http.c", |
17 "kqueue.c", | |
18 "log.c", | 15 "log.c", |
19 "poll.c", | 16 "poll.c", |
20 "select.c", | 17 "select.c", |
21 "signal.c", | 18 "signal.c", |
22 "strlcpy.c", | 19 "strlcpy.c", |
23 ] | 20 ] |
24 | 21 |
25 defines = [ "HAVE_CONFIG_H" ] | 22 defines = [ "HAVE_CONFIG_H" ] |
26 | 23 |
27 if (is_linux) { | 24 if (is_mac || is_ios) { |
28 libs = [ "rt" ] | 25 sources += [ "kqueue.c" ] |
29 } else { | |
30 sources -= [ "epoll.c", "epoll_sub.c" ] | |
31 } | |
32 | |
33 if (is_mac) { | |
34 include_dirs = [ "mac" ] | 26 include_dirs = [ "mac" ] |
35 } else if (is_linux) { | 27 } else if (is_linux) { |
| 28 sources += [ "epoll.c" ] |
36 include_dirs = [ "linux" ] | 29 include_dirs = [ "linux" ] |
37 sources -= [ "kqueue.c" ] | 30 libs = [ "rt" ] |
38 } else if (is_android) { | 31 } else if (is_android) { |
| 32 sources += [ "epoll.c" ] |
39 include_dirs = [ "android" ] | 33 include_dirs = [ "android" ] |
40 sources -= [ "kqueue.c" ] | |
41 } | 34 } |
42 | 35 |
43 configs -= [ "//build/config/compiler:chromium_code" ] | 36 configs -= [ "//build/config/compiler:chromium_code" ] |
44 configs += [ "//build/config/compiler:no_chromium_code" ] | 37 configs += [ "//build/config/compiler:no_chromium_code" ] |
45 } | 38 } |
OLD | NEW |