diff options
author | Dan Albert <danalbert@google.com> | 2014-05-09 09:57:08 -0700 |
---|---|---|
committer | Dan Albert <danalbert@google.com> | 2014-05-09 12:17:52 -0700 |
commit | edacbbc69a13b76442263964833b5fc445c87177 (patch) | |
tree | dd088658e94802c23c28737cad2943dc6b0a8c50 | |
parent | 37b27dcbc2a5aee3209485fae792b0fcd19fec0d (diff) | |
download | libcxxrt-edacbbc69a13b76442263964833b5fc445c87177.tar.gz |
Adds an Android makefile
Change-Id: Ice952a419a68f121c7121c3c4eef83cfa10f60fc
-rw-r--r-- | Android.mk | 70 |
1 files changed, 70 insertions, 0 deletions
diff --git a/Android.mk b/Android.mk new file mode 100644 index 0000000..df0b100 --- /dev/null +++ b/Android.mk @@ -0,0 +1,70 @@ +# +# Copyright (C) 2014 The Android Open Source Project +# +# 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 +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# 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 language governing permissions and +# limitations under the License. +# + +# Don't build for unbundled branches +ifeq (,$(TARGET_BUILD_APPS)) + +LOCAL_PATH := $(call my-dir) + +LIBCXXRT_SRC_FILES := \ + src/auxhelper.cc \ + src/cxa_atexit.c \ + src/cxa_finalize.c \ + src/dynamic_cast.cc \ + src/exception.cc \ + src/guard.cc \ + src/libelftc_dem_gnu3.c \ + src/memory.cc \ + src/stdexcept.cc \ + src/terminate.cc \ + src/typeinfo.cc \ + +LIBCXXRT_CFLAGS := \ + -I$(LOCAL_PATH)/include/ \ + +LIBCXXRT_RTTI_FLAG := -frtti +LIBCXXRT_CPPFLAGS := \ + -std=c++11 \ + -fexceptions \ + +include $(CLEAR_VARS) +LOCAL_MODULE := libcxxrt +LOCAL_CLANG := true +LOCAL_CPP_EXTENSION := .cc +LOCAL_SRC_FILES := $(LIBCXXRT_SRC_FILES) +LOCAL_CFLAGS := $(LIBCXXRT_CFLAGS) +LOCAL_CPPFLAGS := $(LIBCXXRT_CPPFLAGS) +LOCAL_RTTI_FLAG := $(LIBCXXRT_RTTI_FLAG) +LOCAL_LDFLAGS := -nodefaultlibs +LOCAL_SYSTEM_SHARED_LIBRARIES := libc +include $(BUILD_STATIC_LIBRARY) + +ifneq ($(HOST_OS),darwin) +include $(CLEAR_VARS) +LOCAL_MODULE := libcxxrt +LOCAL_CLANG := true +LOCAL_CPP_EXTENSION := .cc +LOCAL_SRC_FILES := $(LIBCXXRT_SRC_FILES) +LOCAL_CFLAGS := $(LIBCXXRT_CFLAGS) +LOCAL_CPPFLAGS := $(LIBCXXRT_CPPFLAGS) +LOCAL_RTTI_FLAG := $(LIBCXXRT_RTTI_FLAG) +LOCAL_LDFLAGS := -nodefaultlibs +LOCAL_SHARED_LIBRARIES := libunwind +LOCAL_LDLIBS := -lc +include $(BUILD_HOST_STATIC_LIBRARY) +endif + +endif # TARGET_BUILD_APPS |