blob: 1a4ba9f3d52de22a5f63df4a4f01ece7735de6b1 [file] [log] [blame]
San Mehatf1b736b2009-10-10 17:22:08 -07001LOCAL_PATH:= $(call my-dir)
2
Kenny Rootacc9e7d2010-06-18 19:06:50 -07003common_src_files := \
4 VolumeManager.cpp \
5 CommandListener.cpp \
6 VoldCommand.cpp \
7 NetlinkManager.cpp \
8 NetlinkHandler.cpp \
Kenny Rootacc9e7d2010-06-18 19:06:50 -07009 Process.cpp \
Kenny Root344ca102012-04-03 17:23:01 -070010 Ext4.cpp \
Kenny Rootacc9e7d2010-06-18 19:06:50 -070011 Fat.cpp \
12 Loop.cpp \
13 Devmapper.cpp \
14 ResponseCode.cpp \
Paul Lawrence87999172014-02-20 12:21:31 -080015 CheckBattery.cpp \
Ken Sumrall9caab762013-06-11 19:10:20 -070016 VoldUtil.c \
Ken Sumrallb87937c2013-03-19 21:46:39 -070017 fstrim.c \
Jeff Sharkeydeb24052015-03-02 21:01:40 -080018 cryptfs.c \
19 Disk.cpp \
20 VolumeBase.cpp \
21 PublicVolume.cpp \
Jeff Sharkey9c484982015-03-31 10:35:33 -070022 PrivateVolume.cpp \
Jeff Sharkeydeb24052015-03-02 21:01:40 -080023 EmulatedVolume.cpp \
24 Utils.cpp \
Kenny Rootacc9e7d2010-06-18 19:06:50 -070025
26common_c_includes := \
Ken Sumrall3ed82362011-01-28 23:31:16 -080027 system/extras/ext4_utils \
Daniel Rosenberge82df162014-08-15 22:19:23 +000028 system/extras/f2fs_utils \
Paul Lawrence87999172014-02-20 12:21:31 -080029 external/scrypt/lib/crypto \
Paul Lawrence69f4ebd2014-04-14 12:17:14 -070030 frameworks/native/include \
31 system/security/keystore \
32 hardware/libhardware/include/hardware \
33 system/security/softkeymaster/include/keymaster
Kenny Rootacc9e7d2010-06-18 19:06:50 -070034
35common_shared_libraries := \
36 libsysutils \
Paul Lawrence87999172014-02-20 12:21:31 -080037 libbinder \
Kenny Rootacc9e7d2010-06-18 19:06:50 -070038 libcutils \
Ying Wang741a1692013-04-09 22:05:28 -070039 liblog \
Kenny Rootacc9e7d2010-06-18 19:06:50 -070040 libdiskconfig \
Ken Sumrall5d4c68e2011-01-30 19:06:03 -080041 libhardware_legacy \
Rom Lemarchand2ba45aa2013-01-16 12:29:28 -080042 liblogwrap \
Ken Sumrall5cf759a2013-08-14 20:15:17 -070043 libext4_utils \
Daniel Rosenberge82df162014-08-15 22:19:23 +000044 libf2fs_sparseblock \
Robert Craigb9e3ba52014-02-04 10:53:00 -050045 libcrypto \
Paul Lawrence87999172014-02-20 12:21:31 -080046 libselinux \
Paul Lawrence69f4ebd2014-04-14 12:17:14 -070047 libutils \
48 libhardware \
Dan Albertae9e8902015-03-16 10:35:17 -070049 libsoftkeymaster \
50 libbase \
Kenny Rootacc9e7d2010-06-18 19:06:50 -070051
Kenny Rootc4c70f12013-06-14 12:11:38 -070052common_static_libraries := \
53 libfs_mgr \
Mohamad Ayyashc489d7f2015-04-06 18:15:53 -070054 libsquashfs_utils \
Geremy Condrac49f0f22013-08-07 13:12:41 -070055 libscrypt_static \
Paul Lawrence87999172014-02-20 12:21:31 -080056 libmincrypt \
57 libbatteryservice
Kenny Rootc4c70f12013-06-14 12:11:38 -070058
Dan Albertc07fa3f2014-12-18 10:00:55 -080059vold_conlyflags := -std=c11
Jeff Sharkeydeb24052015-03-02 21:01:40 -080060vold_cflags := -Werror -Wall -Wno-missing-field-initializers -Wno-unused-variable -Wno-unused-parameter
Dan Albertc07fa3f2014-12-18 10:00:55 -080061
San Mehatf1b736b2009-10-10 17:22:08 -070062include $(CLEAR_VARS)
63
Dan Albertb2aaf3a2014-09-12 10:48:12 -070064LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk
Kenny Rootacc9e7d2010-06-18 19:06:50 -070065LOCAL_MODULE := libvold
Dan Albertc07fa3f2014-12-18 10:00:55 -080066LOCAL_CLANG := true
Kenny Rootacc9e7d2010-06-18 19:06:50 -070067LOCAL_SRC_FILES := $(common_src_files)
Kenny Rootacc9e7d2010-06-18 19:06:50 -070068LOCAL_C_INCLUDES := $(common_c_includes)
Kenny Rootacc9e7d2010-06-18 19:06:50 -070069LOCAL_SHARED_LIBRARIES := $(common_shared_libraries)
Kenny Rootc4c70f12013-06-14 12:11:38 -070070LOCAL_STATIC_LIBRARIES := $(common_static_libraries)
Kenny Rootacc9e7d2010-06-18 19:06:50 -070071LOCAL_MODULE_TAGS := eng tests
Dan Albertc07fa3f2014-12-18 10:00:55 -080072LOCAL_CFLAGS := $(vold_cflags)
73LOCAL_CONLYFLAGS := $(vold_conlyflags)
Kenny Rootacc9e7d2010-06-18 19:06:50 -070074
75include $(BUILD_STATIC_LIBRARY)
76
77include $(CLEAR_VARS)
San Mehatf1b736b2009-10-10 17:22:08 -070078
Dan Albertb2aaf3a2014-09-12 10:48:12 -070079LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk
San Mehatf1b736b2009-10-10 17:22:08 -070080LOCAL_MODULE:= vold
Dan Albertc07fa3f2014-12-18 10:00:55 -080081LOCAL_CLANG := true
Kenny Rootacc9e7d2010-06-18 19:06:50 -070082LOCAL_SRC_FILES := \
83 main.cpp \
84 $(common_src_files)
85
86LOCAL_C_INCLUDES := $(common_c_includes)
Dan Albertc07fa3f2014-12-18 10:00:55 -080087LOCAL_CFLAGS := $(vold_cflags)
88LOCAL_CONLYFLAGS := $(vold_conlyflags)
San Mehatf1b736b2009-10-10 17:22:08 -070089
Ajay Dudani87701e22014-09-17 21:02:52 -070090ifeq ($(TARGET_HW_DISK_ENCRYPTION),true)
91LOCAL_C_INCLUDES += $(TARGET_CRYPTFS_HW_PATH)
92common_shared_libraries += libcryptfs_hw
93LOCAL_CFLAGS += -DCONFIG_HW_DISK_ENCRYPTION
94endif
95
Kenny Rootacc9e7d2010-06-18 19:06:50 -070096LOCAL_SHARED_LIBRARIES := $(common_shared_libraries)
Kenny Rootc4c70f12013-06-14 12:11:38 -070097LOCAL_STATIC_LIBRARIES := $(common_static_libraries)
Ken Sumrallf0679f02012-04-01 23:58:44 -070098
San Mehatf1b736b2009-10-10 17:22:08 -070099include $(BUILD_EXECUTABLE)
100
101include $(CLEAR_VARS)
Kenny Root7b18a7b2010-03-15 13:13:41 -0700102
Dan Albertb2aaf3a2014-09-12 10:48:12 -0700103LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk
Dan Albertc07fa3f2014-12-18 10:00:55 -0800104LOCAL_CLANG := true
Kenny Root7b18a7b2010-03-15 13:13:41 -0700105LOCAL_SRC_FILES:= vdc.c
San Mehatf1b736b2009-10-10 17:22:08 -0700106LOCAL_MODULE:= vdc
San Mehatf1b736b2009-10-10 17:22:08 -0700107LOCAL_SHARED_LIBRARIES := libcutils
Dan Albertc07fa3f2014-12-18 10:00:55 -0800108LOCAL_CFLAGS := $(vold_cflags)
109LOCAL_CONLYFLAGS := $(vold_conlyflags)
San Mehatf1b736b2009-10-10 17:22:08 -0700110
111include $(BUILD_EXECUTABLE)