summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrian Carlstrom <bdc@google.com>2013-05-02 16:07:54 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2013-05-02 16:07:54 +0000
commite16c809d12fe57dc6521a5231368eaaabf66eb77 (patch)
tree524a8507bc28036dd944db9a4d5ec342e944e3a2
parent06ebe80bbc8a9108d6d7582561f855be78118f6c (diff)
parent3042efc693a56888cdd0194ba1fd2504ef1ab67d (diff)
downloadlibcore-e16c809d12fe57dc6521a5231368eaaabf66eb77.zip
libcore-e16c809d12fe57dc6521a5231368eaaabf66eb77.tar.gz
libcore-e16c809d12fe57dc6521a5231368eaaabf66eb77.tar.bz2
Merge "Tracking changes to *-host for host shared libraries"
-rw-r--r--NativeCode.mk42
-rw-r--r--luni/src/test/native/sub.mk22
2 files changed, 10 insertions, 54 deletions
diff --git a/NativeCode.mk b/NativeCode.mk
index 5369453..01eee13 100644
--- a/NativeCode.mk
+++ b/NativeCode.mk
@@ -52,29 +52,6 @@ endef
# sub.mk files don't see anything stray from the last rule that was
# set up.
-# Set up the test library first
-ifeq ($(LIBCORE_SKIP_TESTS),)
-include $(CLEAR_VARS)
-LOCAL_MODULE := $(core_magic_local_target)
-core_src_files :=
-
-# Include the sub.mk files.
-$(foreach dir, \
- luni/src/test/native, \
- $(eval $(call include-core-native-dir,$(dir))))
-
-# This is for the test library, so rename the variable.
-test_src_files := $(core_src_files)
-core_src_files :=
-
-# Extract out the allowed LOCAL_* variables. Note: $(sort) also
-# removes duplicates.
-test_c_includes := $(sort libcore/include $(LOCAL_C_INCLUDES) $(JNI_H_INCLUDE))
-test_shared_libraries := $(sort $(LOCAL_SHARED_LIBRARIES))
-test_static_libraries := $(sort $(LOCAL_STATIC_LIBRARIES))
-endif # LIBCORE_SKIP_TESTS
-
-
include $(CLEAR_VARS)
LOCAL_MODULE := $(core_magic_local_target)
LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/NativeCode.mk
@@ -92,6 +69,9 @@ core_shared_libraries := $(sort $(LOCAL_SHARED_LIBRARIES))
core_static_libraries := $(sort $(LOCAL_STATIC_LIBRARIES))
core_cflags := -DJNI_JARJAR_PREFIX="com/android/"
+core_test_files := \
+ luni/src/test/native/test_openssl_engine.cpp \
+
#
# Build for the target (device).
#
@@ -135,10 +115,9 @@ LOCAL_CFLAGS += -Wno-psabi
endif
# Define the rules.
-LOCAL_SRC_FILES := $(test_src_files)
-LOCAL_C_INCLUDES := $(test_c_includes)
-LOCAL_SHARED_LIBRARIES := $(test_shared_libraries)
-LOCAL_STATIC_LIBRARIES := $(test_static_libraries)
+LOCAL_SRC_FILES := $(core_test_files)
+LOCAL_C_INCLUDES := libcore/include external/openssl/include
+LOCAL_SHARED_LIBRARIES := libcrypto
LOCAL_MODULE_TAGS := optional
LOCAL_MODULE := libjavacoretests
LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/NativeCode.mk
@@ -162,23 +141,22 @@ ifeq ($(WITH_HOST_DALVIK),true)
LOCAL_MODULE_TAGS := optional
LOCAL_MODULE := libjavacore
LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/NativeCode.mk
- LOCAL_SHARED_LIBRARIES := $(core_shared_libraries) libexpat libicuuc libicui18n libssl libcrypto libz-host
+ LOCAL_SHARED_LIBRARIES := $(core_shared_libraries) libexpat-host libicuuc-host libicui18n-host libssl-host libcrypto-host libz-host
LOCAL_STATIC_LIBRARIES := $(core_static_libraries)
include $(BUILD_HOST_SHARED_LIBRARY)
ifeq ($(LIBCORE_SKIP_TESTS),)
include $(CLEAR_VARS)
# Define the rules.
- LOCAL_SRC_FILES := $(test_src_files)
+ LOCAL_SRC_FILES := $(core_test_files)
LOCAL_CFLAGS += $(core_cflags)
- LOCAL_C_INCLUDES := $(test_c_includes)
+ LOCAL_C_INCLUDES := libcore/include external/openssl/include
LOCAL_CPPFLAGS += $(core_cppflags)
LOCAL_LDLIBS += -ldl -lpthread
LOCAL_MODULE_TAGS := optional
LOCAL_MODULE := libjavacoretests
LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/NativeCode.mk
- LOCAL_SHARED_LIBRARIES := $(test_shared_libraries)
- LOCAL_STATIC_LIBRARIES := $(test_static_libraries)
+ LOCAL_SHARED_LIBRARIES := libcrypto-host
include $(BUILD_HOST_SHARED_LIBRARY)
endif # LIBCORE_SKIP_TESTS
endif
diff --git a/luni/src/test/native/sub.mk b/luni/src/test/native/sub.mk
deleted file mode 100644
index 24dc52c..0000000
--- a/luni/src/test/native/sub.mk
+++ /dev/null
@@ -1,22 +0,0 @@
-# Copyright (C) 2013 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.
-
-LOCAL_SRC_FILES := \
- test_openssl_engine.cpp
-
-LOCAL_C_INCLUDES += \
- external/openssl/include
-
-LOCAL_SHARED_LIBRARIES += \
- libcrypto