• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#
2# Copyright 2015 The Android Open Source Project
3#
4# Licensed under the Apache License, Version 2.0 (the "License");
5# you may not use this file except in compliance with the License.
6# You may obtain a copy of the License at
7#
8#      http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
15#
16
17LOCAL_PATH := $(my-dir)
18
19# TODO: Refactor to build and run unit tests.
20
21# webservd executable
22# ========================================================
23
24include $(CLEAR_VARS)
25LOCAL_MODULE := webservd
26LOCAL_SHARED_LIBRARIES := \
27    libcrypto \
28    libfirewalld-client \
29    libwebserv \
30    libwebserv-proxies-internal \
31
32ifdef BRILLO
33
34LOCAL_SHARED_LIBRARIES += \
35    libkeymaster_messages \
36    libkeystore_binder \
37
38endif
39
40LOCAL_SRC_FILES := \
41    config.cc \
42    dbus_bindings/dbus-service-config.json \
43    dbus_bindings/org.chromium.WebServer.ProtocolHandler.dbus-xml \
44    dbus_bindings/org.chromium.WebServer.Server.dbus-xml \
45    dbus_protocol_handler.cc \
46    dbus_request_handler.cc \
47    error_codes.cc \
48    firewalld_firewall.cc \
49    log_manager.cc \
50    main.cc \
51    protocol_handler.cc \
52    request.cc \
53    server.cc \
54    temp_file_manager.cc \
55    utils.cc \
56
57ifdef BRILLO
58LOCAL_SRC_FILES += keystore_encryptor.cc
59else
60LOCAL_SRC_FILES += fake_encryptor.cc
61endif
62
63LOCAL_INIT_RC := webservd.rc
64
65$(eval $(webservd_common))
66$(eval $(webservd_common_libraries))
67include $(BUILD_EXECUTABLE)
68
69# libwebservd-client-internal shared library
70# ========================================================
71# You do not want to depend on this.  Depend on libwebserv instead.
72# libwebserv abstracts and helps you consume this interface.
73
74ifeq ($(system_webservd_use_dbus),true)
75include $(CLEAR_VARS)
76LOCAL_MODULE := libwebservd-client-internal
77LOCAL_SRC_FILES := \
78    dbus_bindings/dbus-service-config.json \
79    dbus_bindings/org.chromium.WebServer.ProtocolHandler.dbus-xml \
80    dbus_bindings/org.chromium.WebServer.Server.dbus-xml \
81
82LOCAL_DBUS_PROXY_PREFIX := webservd
83include $(BUILD_SHARED_LIBRARY)
84endif
85