summaryrefslogtreecommitdiffstats
path: root/binutils-2.25/gold/testsuite/hidden_test.sh
diff options
context:
space:
mode:
authorRahul Chaudhry <rahulchaudhry@google.com>2016-06-29 17:01:25 +0000
committerandroid-build-merger <android-build-merger@google.com>2016-06-29 17:01:25 +0000
commit1e1ca302a342a4966c5520704a1d003e1c4c7767 (patch)
tree641fb37846e0eb33ad84c003979bc5049d2b061f /binutils-2.25/gold/testsuite/hidden_test.sh
parent850063a5c4a41433b50cc3eeac69e4285ef5129a (diff)
parent129dec3ed0e1fc07f75a4322014d770cfd642f4d (diff)
downloadtoolchain_binutils-1e1ca302a342a4966c5520704a1d003e1c4c7767.tar.gz
toolchain_binutils-1e1ca302a342a4966c5520704a1d003e1c4c7767.tar.bz2
toolchain_binutils-1e1ca302a342a4966c5520704a1d003e1c4c7767.zip
Remove warning about references from shared objects to hidden symbols. am: 6422a80df9
am: 129dec3ed0 Change-Id: Ia2d30b822ea4c0d85f5d63a347c4b1cc06d436d6
Diffstat (limited to 'binutils-2.25/gold/testsuite/hidden_test.sh')
-rwxr-xr-xbinutils-2.25/gold/testsuite/hidden_test.sh24
1 files changed, 14 insertions, 10 deletions
diff --git a/binutils-2.25/gold/testsuite/hidden_test.sh b/binutils-2.25/gold/testsuite/hidden_test.sh
index 39ebbf68..05633d04 100755
--- a/binutils-2.25/gold/testsuite/hidden_test.sh
+++ b/binutils-2.25/gold/testsuite/hidden_test.sh
@@ -29,11 +29,11 @@
# error messages are issued for the references to internal and
# hidden symbols. The errors will be found in hidden_test.err.
-check()
+check_missing()
{
- if ! grep -q "$2" "$1"
+ if grep -q "$2" "$1"
then
- echo "Did not find expected error in $1:"
+ echo "Found unexpected error in $1:"
echo " $2"
echo ""
echo "Actual error output below:"
@@ -42,25 +42,29 @@ check()
fi
}
-check_missing()
+check_missing_sym()
{
if grep -q "$2" "$1"
then
- echo "Found unexpected error in $1:"
+ echo "Found unexpected symbol in $1:"
echo " $2"
echo ""
- echo "Actual error output below:"
+ echo "Actual nm output below:"
cat "$1"
exit 1
fi
}
-# We should see errors for hidden and internal symbols.
-check hidden_test.err "hidden symbol 'main_hidden' in hidden_test_main.o is referenced by DSO libhidden.so"
-check hidden_test.err "internal symbol 'main_internal' in hidden_test_main.o is referenced by DSO libhidden.so"
-
# We shouldn't see errors for the default and protected symbols.
check_missing hidden_test.err "main_default"
check_missing hidden_test.err "main_protected"
+# We shouldn't see errors for the hidden and internal symbols either (PR 15574).
+check_missing hidden_test.err "main_hidden"
+check_missing hidden_test.err "main_internal"
+
+# We shouldn't see the hidden or internal symbols in the dynamic symbol table.
+check_missing_sym hidden_test.syms "main_hidden"
+check_missing_sym hidden_test.syms "main_internal"
+
exit 0