1 // 2 // Copyright (C) 2014 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 // host + device static lib 18 cc_library_static { 19 host_supported: true, 20 name: "libc++_static", 21 clang: true, 22 srcs: [ 23 "src/algorithm.cpp", 24 "src/any.cpp", 25 "src/bind.cpp", 26 "src/chrono.cpp", 27 "src/condition_variable.cpp", 28 "src/debug.cpp", 29 "src/exception.cpp", 30 "src/future.cpp", 31 "src/hash.cpp", 32 "src/ios.cpp", 33 "src/iostream.cpp", 34 "src/locale.cpp", 35 "src/memory.cpp", 36 "src/mutex.cpp", 37 "src/new.cpp", 38 "src/optional.cpp", 39 "src/random.cpp", 40 "src/regex.cpp", 41 "src/shared_mutex.cpp", 42 "src/stdexcept.cpp", 43 "src/string.cpp", 44 "src/strstream.cpp", 45 "src/system_error.cpp", 46 "src/thread.cpp", 47 "src/typeinfo.cpp", 48 "src/utility.cpp", 49 "src/valarray.cpp", 50 ], 51 local_include_dirs: ["include"], 52 export_include_dirs: ["include"], 53 cppflags: [ 54 "-std=c++14", 55 "-nostdinc++", 56 "-fexceptions", 57 "-DLIBCXX_BUILDING_LIBCXXABI", 58 ], 59 rtti: true, 60 whole_static_libs: [ 61 "libc++abi", 62 ], 63 stl: "none", 64 } 65 66 // host + device dynamic lib 67 cc_library_shared { 68 host_supported: true, 69 name: "libc++", 70 clang: true, 71 whole_static_libs: ["libc++_static"], 72 stl: "none", 73 74 target: { 75 android: { 76 shared_libs: ["libdl"], 77 }, 78 android_arm: { 79 static_libs: ["libunwind_llvm"], 80 ldflags: ["-Wl,--exclude-libs,libunwind_llvm.a"], 81 }, 82 host: { 83 ldflags: ["-nodefaultlibs"], 84 }, 85 darwin: { 86 unexported_symbols_list: "lib/libc++unexp.exp", 87 force_symbols_not_weak_list: "lib/notweak.exp", 88 force_symbols_weak_list: "lib/weak.exp", 89 }, 90 91 linux: { 92 host_ldlibs: [ 93 "-lrt", 94 "-lpthread", 95 "-ldl", 96 ], 97 }, 98 }, 99 } 100 101 102 // ANDROIDMK TRANSLATION ERROR: unsupported conditional 103 // ifdef LIBCXX_TESTING 104 // ANDROIDMK TRANSLATION ERROR: unsupported include 105 // include $(LOCAL_PATH)/buildcmds/Android.mk 106 107 // ANDROIDMK TRANSLATION ERROR: endif from unsupported contitional 108 // endif 109 // TARGET_BUILD_APPS 110 111