blob: 8f790ba3a0ad343e6c9b6849514dc7dd0fc5dd54 [file] [log] [blame]
Dan Willemsen710b7222016-07-13 23:33:44 -07001// Copyright (C) 2015 The Android Open Source Project
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
Yabin Cui848a1b62016-07-26 15:01:09 -070015cc_library {
Dan Willemsen710b7222016-07-13 23:33:44 -070016 name: "libevent",
17 host_supported: true,
Dan Willemsen509ebc12018-10-23 13:46:34 -070018 recovery_available: true,
Dan Willemsen596447c2017-04-07 14:12:51 -070019 vendor_available: true,
Justin Yunf109eb42017-07-24 15:19:44 +090020 vndk: {
21 enabled: true,
22 },
Dan Willemsen0a4fdc92016-07-22 13:43:21 -070023 unique_host_soname: true,
Dan Willemsen710b7222016-07-13 23:33:44 -070024
25 arch: {
26 arm: {
27 instruction_set: "arm",
28 },
29 },
30 cflags: [
31 "-D_BSD_SOURCE",
32 "-O3",
33 "-Wno-implicit-function-declaration",
34 "-Wno-strict-aliasing",
35 "-Wno-unused-parameter",
36 "-Werror",
37 ],
Dan Willemsen710b7222016-07-13 23:33:44 -070038 export_include_dirs: ["include"],
39
Narayan Kamathfc74cb42017-09-13 12:53:52 +010040 local_include_dirs: ["compat"],
41
Dan Willemsen710b7222016-07-13 23:33:44 -070042 srcs: [
43 // core
44 "buffer.c",
45 "bufferevent.c",
46 "bufferevent_filter.c",
47 "bufferevent_pair.c",
48 "bufferevent_ratelim.c",
49 "bufferevent_sock.c",
50 "event.c",
51 "evmap.c",
52 "evthread.c",
53 "evutil.c",
54 "evutil_rand.c",
Narayan Kamathfc74cb42017-09-13 12:53:52 +010055 "evutil_time.c",
Dan Willemsen710b7222016-07-13 23:33:44 -070056 "listener.c",
57 "log.c",
58 "signal.c",
59 "strlcpy.c",
60
61 // extra
62 "evdns.c",
63 "event_tagging.c",
64 "evrpc.c",
65 "http.c",
66
67 "poll.c",
68 "select.c",
69 ],
70
71 target: {
Dan Willemsen98a4ebe2017-10-03 14:16:05 -070072 linux: {
Dan Willemsen710b7222016-07-13 23:33:44 -070073 srcs: ["epoll.c"],
Dan Willemsen710b7222016-07-13 23:33:44 -070074 },
Dan Willemsen520e0222017-03-15 14:37:17 -070075 linux_bionic: {
76 enabled: true,
Dan Willemsen520e0222017-03-15 14:37:17 -070077 },
Dan Willemsen710b7222016-07-13 23:33:44 -070078 darwin: {
79 srcs: ["kqueue.c"],
80 },
81 },
82}