2015-12-16 01:04:53 +01:00
|
|
|
# Copyright 2015 The Android Open Source Project
|
2015-12-16 01:04:53 +01:00
|
|
|
#
|
|
|
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
# you may not use this file except in compliance with the License.
|
|
|
|
# You may obtain a copy of the License at
|
|
|
|
#
|
2015-12-16 01:04:53 +01:00
|
|
|
# http://www.apache.org/licenses/LICENSE-2.0
|
2015-12-16 01:04:53 +01:00
|
|
|
#
|
|
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
|
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
# See the License for the specific languae governing permissions and
|
|
|
|
# limitations under the License.
|
|
|
|
|
|
|
|
LOCAL_PATH := $(call my-dir)
|
|
|
|
|
2016-03-17 23:29:23 +01:00
|
|
|
include $(CLEAR_VARS)
|
2015-12-16 01:04:53 +01:00
|
|
|
|
2015-12-16 01:04:53 +01:00
|
|
|
otafault_static_libs := \
|
2016-09-09 05:10:11 +02:00
|
|
|
libziparchive \
|
2015-12-16 01:04:53 +01:00
|
|
|
libz \
|
2016-08-06 03:00:04 +02:00
|
|
|
libselinux \
|
|
|
|
libbase \
|
|
|
|
liblog
|
2015-12-16 01:04:53 +01:00
|
|
|
|
2017-04-07 08:54:03 +02:00
|
|
|
LOCAL_CFLAGS := \
|
2017-08-28 23:15:07 +02:00
|
|
|
-Wall \
|
2017-04-07 08:54:03 +02:00
|
|
|
-Werror \
|
|
|
|
-Wthread-safety \
|
|
|
|
-Wthread-safety-negative \
|
|
|
|
-D_LIBCPP_ENABLE_THREAD_SAFETY_ANNOTATIONS
|
|
|
|
|
2015-12-16 01:04:53 +01:00
|
|
|
LOCAL_SRC_FILES := config.cpp ota_io.cpp
|
2015-12-16 01:04:53 +01:00
|
|
|
LOCAL_MODULE_TAGS := eng
|
2015-12-16 01:04:53 +01:00
|
|
|
LOCAL_MODULE := libotafault
|
2015-12-16 01:04:53 +01:00
|
|
|
LOCAL_C_INCLUDES := bootable/recovery
|
|
|
|
LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)
|
|
|
|
LOCAL_WHOLE_STATIC_LIBRARIES := $(otafault_static_libs)
|
2015-12-16 01:04:53 +01:00
|
|
|
|
|
|
|
include $(BUILD_STATIC_LIBRARY)
|
|
|
|
|
2016-03-03 20:43:47 +01:00
|
|
|
# otafault_test (static executable)
|
|
|
|
# ===============================
|
2015-12-16 01:04:53 +01:00
|
|
|
include $(CLEAR_VARS)
|
|
|
|
|
2015-12-16 01:04:53 +01:00
|
|
|
LOCAL_SRC_FILES := config.cpp ota_io.cpp test.cpp
|
2015-12-16 01:04:53 +01:00
|
|
|
LOCAL_MODULE_TAGS := tests
|
|
|
|
LOCAL_MODULE := otafault_test
|
2015-12-16 01:04:53 +01:00
|
|
|
LOCAL_STATIC_LIBRARIES := $(otafault_static_libs)
|
2017-08-28 23:15:07 +02:00
|
|
|
LOCAL_CFLAGS := -Wall -Werror
|
2015-12-16 01:04:53 +01:00
|
|
|
LOCAL_C_INCLUDES := bootable/recovery
|
2015-12-16 01:04:53 +01:00
|
|
|
LOCAL_FORCE_STATIC_EXECUTABLE := true
|
|
|
|
|
|
|
|
include $(BUILD_EXECUTABLE)
|