Pin Chrome's shortcut to the Win10 Start menu on install and OS upgrade.
[chromium-blink-merge.git] / third_party / android_platform / bionic / tools / relocation_packer / Android.mk
blob94c946cda4f656316601c149f574780d14456284
2 # Copyright (C) 2015 The Android Open Source Project
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
8 # http://www.apache.org/licenses/LICENSE-2.0
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.
17 common_cppflags := -Wall -Wextra -Wunused -Werror -Wold-style-cast
19 LOCAL_PATH := $(call my-dir)
21 include $(CLEAR_VARS)
23 LOCAL_CPP_EXTENSION := .cc
25 LOCAL_SRC_FILES := \
26 src/debug.cc \
27 src/delta_encoder.cc \
28 src/elf_file.cc \
29 src/packer.cc \
30 src/sleb128.cc \
32 LOCAL_STATIC_LIBRARIES := libelf
33 LOCAL_C_INCLUDES := external/elfutils/src/libelf
34 LOCAL_MODULE := lib_relocation_packer
36 LOCAL_CPPFLAGS := $(common_cppflags)
38 LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk
40 include $(BUILD_HOST_STATIC_LIBRARY)
42 include $(CLEAR_VARS)
44 LOCAL_CPP_EXTENSION := .cc
46 LOCAL_SRC_FILES := src/main.cc
47 LOCAL_STATIC_LIBRARIES := lib_relocation_packer libelf
49 # Statically linking libc++ to make it work from prebuilts
50 LOCAL_CXX_STL := libc++_static
51 LOCAL_C_INCLUDES := external/elfutils/src/libelf libnativehelper/include
53 LOCAL_MODULE := relocation_packer
55 LOCAL_CPPFLAGS := $(common_cppflags)
57 LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk
59 include $(BUILD_HOST_EXECUTABLE)
61 include $(CLEAR_VARS)
63 LOCAL_CPP_EXTENSION := .cc
65 LOCAL_SRC_FILES := \
66 src/debug_unittest.cc \
67 src/delta_encoder_unittest.cc \
68 src/elf_file_unittest.cc \
69 src/sleb128_unittest.cc \
70 src/packer_unittest.cc \
72 LOCAL_STATIC_LIBRARIES := lib_relocation_packer libelf
73 LOCAL_C_INCLUDES := external/elfutils/src/libelf
75 LOCAL_CPPFLAGS := $(common_cppflags)
77 LOCAL_MODULE := relocation_packer_unit_tests
78 LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk
80 include $(BUILD_HOST_NATIVE_TEST)
82 # $(1) library name
83 define copy-test-library
84 include $(CLEAR_VARS)
85 LOCAL_IS_HOST_MODULE := true
86 LOCAL_MODULE := $(1)
87 LOCAL_MODULE_CLASS := SHARED_LIBRARIES
88 LOCAL_MODULE_PATH := $(HOST_OUT_EXECUTABLES)
89 LOCAL_STRIP_MODULE := false
90 LOCAL_SRC_FILES := test_data/$(1)
91 include $(BUILD_PREBUILT)
92 endef
94 $(eval $(call copy-test-library,elf_file_unittest_relocs_arm32.so))
95 $(eval $(call copy-test-library,elf_file_unittest_relocs_arm32_packed.so))
96 $(eval $(call copy-test-library,elf_file_unittest_relocs_arm64.so))
97 $(eval $(call copy-test-library,elf_file_unittest_relocs_arm64_packed.so))
98 $(eval $(call copy-test-library,elf_file_unittest_relocs_ia32.so))
99 $(eval $(call copy-test-library,elf_file_unittest_relocs_ia32_packed.so))
100 $(eval $(call copy-test-library,elf_file_unittest_relocs_x64.so))
101 $(eval $(call copy-test-library,elf_file_unittest_relocs_x64_packed.so))
102 $(eval $(call copy-test-library,elf_file_unittest_relocs_mips32.so))
103 $(eval $(call copy-test-library,elf_file_unittest_relocs_mips32_packed.so))