1# 2# Copyright (C) 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 17# ----------------------------------------------------------------------------- 18# Libraries used to test versioned symbols 19# ----------------------------------------------------------------------------- 20libtest_versioned_uselibv1_src_files := versioned_uselib.cpp 21 22libtest_versioned_uselibv1_shared_libraries := \ 23 libtest_versioned_libv1 24 25module := libtest_versioned_uselibv1 26include $(LOCAL_PATH)/Android.build.testlib.mk 27 28# ----------------------------------------------------------------------------- 29libtest_versioned_uselibv2_src_files := \ 30 versioned_uselib.cpp 31 32libtest_versioned_uselibv2_shared_libraries := \ 33 libtest_versioned_libv2 34 35libtest_versioned_uselibv2_ldflags := \ 36 -Wl,--version-script,$(LOCAL_PATH)/versioned_uselib.map 37 38module := libtest_versioned_uselibv2 39include $(LOCAL_PATH)/Android.build.testlib.mk 40 41# ----------------------------------------------------------------------------- 42libtest_versioned_uselibv2_other_src_files := \ 43 versioned_uselib.cpp 44 45libtest_versioned_uselibv2_other_shared_libraries := \ 46 libtest_versioned_otherlib_empty libtest_versioned_libv2 47 48module := libtest_versioned_uselibv2_other 49include $(LOCAL_PATH)/Android.build.testlib.mk 50 51# ----------------------------------------------------------------------------- 52libtest_versioned_uselibv3_other_src_files := \ 53 versioned_uselib.cpp 54 55libtest_versioned_uselibv3_other_shared_libraries := \ 56 libtest_versioned_otherlib_empty libtest_versioned_lib 57 58module := libtest_versioned_uselibv3_other 59include $(LOCAL_PATH)/Android.build.testlib.mk 60 61# ----------------------------------------------------------------------------- 62# lib v1 - this one used during static linking but never used at runtime 63# which forces libtest_versioned_uselibv1 to use function v1 from 64# libtest_versioned_lib.so 65# ----------------------------------------------------------------------------- 66libtest_versioned_libv1_src_files := \ 67 versioned_lib_v1.cpp 68 69libtest_versioned_libv1_ldflags := \ 70 -Wl,--version-script,$(LOCAL_PATH)/versioned_lib_v1.map \ 71 -Wl,-soname,libtest_versioned_lib.so 72 73module := libtest_versioned_libv1 74include $(LOCAL_PATH)/Android.build.testlib.mk 75 76# ----------------------------------------------------------------------------- 77# lib v2 - to make libtest_versioned_uselibv2.so use version 2 of versioned_function() 78# ----------------------------------------------------------------------------- 79libtest_versioned_libv2_src_files := \ 80 versioned_lib_v2.cpp 81 82libtest_versioned_libv2_ldflags := \ 83 -Wl,--version-script,$(LOCAL_PATH)/versioned_lib_v2.map \ 84 -Wl,-soname,libtest_versioned_lib.so 85 86module := libtest_versioned_libv2 87include $(LOCAL_PATH)/Android.build.testlib.mk 88 89 90# ----------------------------------------------------------------------------- 91# last version - this one is used at the runtime and exports 3 versions 92# of versioned_symbol(). 93# ----------------------------------------------------------------------------- 94libtest_versioned_lib_src_files := \ 95 versioned_lib_v3.cpp 96 97libtest_versioned_lib_ldflags := \ 98 -Wl,--version-script,$(LOCAL_PATH)/versioned_lib_v3.map 99 100module := libtest_versioned_lib 101include $(LOCAL_PATH)/Android.build.testlib.mk 102 103# ----------------------------------------------------------------------------- 104# This library is empty, the actual implementation will provide an unversioned 105# symbol for versioned_function(). 106# ----------------------------------------------------------------------------- 107libtest_versioned_otherlib_empty_src_files := empty.cpp 108 109libtest_versioned_otherlib_empty_ldflags := -Wl,-soname,libtest_versioned_otherlib.so 110module := libtest_versioned_otherlib_empty 111include $(LOCAL_PATH)/Android.build.testlib.mk 112 113# ----------------------------------------------------------------------------- 114libtest_versioned_otherlib_src_files := versioned_lib_other.cpp 115 116libtest_versioned_otherlib_ldflags := \ 117 -Wl,--version-script,$(LOCAL_PATH)/versioned_lib_other.map 118 119module := libtest_versioned_otherlib 120include $(LOCAL_PATH)/Android.build.testlib.mk 121