-
-
Notifications
You must be signed in to change notification settings - Fork 5
/
Android.mk
64 lines (55 loc) · 2.58 KB
/
Android.mk
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
# Copyright 2017 Joey Hewitt <[email protected]>
#
# This file is part of ril_ofono.
#
# ril_ofono is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# ril_ofono is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with ril_ofono. If not, see <http://www.gnu.org/licenses/>.
LOCAL_PATH := $(call my-dir)
# Build third-party libraries (separately so we can ignore warnings)
include $(CLEAR_VARS)
LOCAL_MODULE := RilOfono.3rdparty
LOCAL_SRC_FILES := $(call find-subdir-files,lib/java/dbus -path lib/java/dbus/org/freedesktop/dbus/test -prune -o \( -name "*.java" -print \)) \
$(call all-java-files-under,lib/java/debug) \
$(call all-java-files-under,lib/java/ofono)
include $(BUILD_STATIC_JAVA_LIBRARY)
# Build our Java RIL (as a lib, because we need the RilWrapper to complete building, but building the RilWrapper needs the rest)
include $(CLEAR_VARS)
LOCAL_MODULE := RilOfono.lib
LOCAL_SRC_FILES := $(call all-java-files-under,src/java) $(call all-java-files-under,build/java)
LOCAL_STATIC_JAVA_LIBRARIES := RilOfono.3rdparty
LOCAL_JAVA_LIBRARIES := telephony-common
LOCAL_JAVACFLAGS := -Xlint
include $(BUILD_STATIC_JAVA_LIBRARY)
# Define RilWrapper build process
RILOFONO_WRAPPER_JAVA := $(call generated-sources-dir-for,APPS,RilOfono)/RilWrapper.java
$(RILOFONO_WRAPPER_JAVA): PRIVATE_CUSTOM_TOOL = java -cp $(call normalize-path-list,$^) net.scintill.ril_ofono.BuildRilWrapper > "$@"
$(RILOFONO_WRAPPER_JAVA): $(foreach lib,RilOfono.lib framework telephony-common,$(call intermediates-dir-for,JAVA_LIBRARIES,$(lib),,COMMON)/classes.jar)
$(transform-generated-source)
# Build RIL package
include $(CLEAR_VARS)
LOCAL_PACKAGE_NAME := RilOfono
LOCAL_GENERATED_SOURCES := $(RILOFONO_WRAPPER_JAVA)
LOCAL_STATIC_JAVA_LIBRARIES := RilOfono.lib
LOCAL_JAVA_LIBRARIES := telephony-common
LOCAL_CERTIFICATE := platform
LOCAL_JAVACFLAGS := -Xlint
LOCAL_PROGUARD_FLAG_FILES = proguard.flags
include $(BUILD_PACKAGE)
# Build rild lib (for native code that needs rild privs)
include $(CLEAR_VARS)
LOCAL_MODULE := librilofono_rild
LOCAL_SRC_FILES := \
src/c/librilofono_rild.c
LOCAL_SHARED_LIBRARIES := \
libnetutils
include $(BUILD_SHARED_LIBRARY)