Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 07268ce3 authored by Dmitriy Ivanov's avatar Dmitriy Ivanov
Browse files

Link sigchain to main executable

 Also export necessary symbols to preempt calls from
 libart.so

Bug: 15345057
Bug: 15426766

(cherry picked from commit 96e0cfa7)

Change-Id: I0930d96edde7dc0636e8d50d7c778f099237f748
parent c218d8f1
Loading
Loading
Loading
Loading
+15 −2
Original line number Diff line number Diff line
@@ -2,10 +2,18 @@ LOCAL_PATH:= $(call my-dir)

include $(CLEAR_VARS)

# TODO: Trying to link libsigchain as a static library prevents
# static linker from exporting necessary symbols. So as a workaround
# we use sigchain.o
LOCAL_SRC_FILES:= \
	app_main.cpp
	app_main.cpp \
	sigchain_proxy.cpp

LOCAL_LDFLAGS := -Wl,--version-script,art/sigchainlib/version-script.txt -Wl,--export-dynamic
LOCAL_CPPFLAGS := -std=c++11 -Iart

LOCAL_SHARED_LIBRARIES := \
	libdl \
	libcutils \
	libutils \
	liblog \
@@ -28,8 +36,10 @@ ifeq ($(TARGET_ARCH),arm)

include $(CLEAR_VARS)

# see comment above (~l5)
LOCAL_SRC_FILES:= \
	app_main.cpp
	app_main.cpp \
	sigchain_proxy.cpp

LOCAL_SHARED_LIBRARIES := \
	libcutils \
@@ -38,6 +48,9 @@ LOCAL_SHARED_LIBRARIES := \
	libbinder \
	libandroid_runtime

LOCAL_LDFLAGS := -ldl -Wl,--version-script,art/sigchainlib/version-script.txt -Wl,--export-dynamic
LOCAL_CPPFLAGS := -std=c++11 -Iart

LOCAL_MODULE := app_process__asan
LOCAL_MODULE_TAGS := eng
LOCAL_MODULE_PATH := $(TARGET_OUT_EXECUTABLES)/asan
+17 −0
Original line number Diff line number Diff line
/*
 * 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.
 */

#include "sigchainlib/sigchain.cc"