Revert "Revert "Use dlopen to load oat files.""
This reverts commit 7a46b7e235a7c35191cd9ddbab6ca4db0e535da5.
Change-Id: I33439d0e3d7a7e63591a8c7b356e716dcb62bca1
diff --git a/test/137-cfi/run b/test/137-cfi/run
new file mode 100755
index 0000000..78cf2aa
--- /dev/null
+++ b/test/137-cfi/run
@@ -0,0 +1,21 @@
+#!/bin/bash
+#
+# Copyright (C) 2008 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.
+
+# Temporarily disable address space layout randomization (ASLR).
+# This is need on host so that the linker loads core.oat at fixed address.
+export LD_USE_LOAD_BIAS=1
+
+exec ${RUN} "$@"
diff --git a/test/137-cfi/src/Main.java b/test/137-cfi/src/Main.java
index 658ba53..a88adc1 100644
--- a/test/137-cfi/src/Main.java
+++ b/test/137-cfi/src/Main.java
@@ -26,7 +26,7 @@
public class Main implements Comparator<Main> {
// Whether to test local unwinding. Libunwind uses linker info to find executables. As we do
// not dlopen at the moment, this doesn't work, so keep it off for now.
- public final static boolean TEST_LOCAL_UNWINDING = false;
+ public final static boolean TEST_LOCAL_UNWINDING = true;
// Unwinding another process, modelling debuggerd. This doesn't use the linker, so should work
// no matter whether we're using dlopen or not.