author | fparain |
Wed, 04 Jan 2012 03:49:35 -0800 | |
changeset 11365 | 05d995976571 |
parent 10561 | bf51fe78a9ad |
child 12729 | 684b5857e506 |
permissions | -rw-r--r-- |
10561
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
1 |
# |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
2 |
# Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
3 |
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
4 |
# |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
5 |
# This code is free software; you can redistribute it and/or modify it |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
6 |
# under the terms of the GNU General Public License version 2 only, as |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
7 |
# published by the Free Software Foundation. |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
8 |
# |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
9 |
# This code is distributed in the hope that it will be useful, but WITHOUT |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
10 |
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
11 |
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
12 |
# version 2 for more details (a copy is included in the LICENSE file that |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
13 |
# accompanied this code). |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
14 |
# |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
15 |
# You should have received a copy of the GNU General Public License version |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
16 |
# 2 along with this work; if not, write to the Free Software Foundation, |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
17 |
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
18 |
# |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
19 |
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
20 |
# or visit www.oracle.com if you need additional information or have any |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
21 |
# questions. |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
22 |
# |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
23 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
24 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
25 |
# @test Xchecksig.sh |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
26 |
# @bug 7051189 |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
27 |
# @summary Need to suppress info message if -xcheck:jni used with libjsig.so |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
28 |
# @run shell Xchecksig.sh |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
29 |
# |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
30 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
31 |
if [ "${TESTSRC}" = "" ] |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
32 |
then TESTSRC=. |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
33 |
fi |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
34 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
35 |
if [ "${TESTJAVA}" = "" ] |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
36 |
then |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
37 |
PARENT=`dirname \`which java\`` |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
38 |
TESTJAVA=`dirname ${PARENT}` |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
39 |
printf "TESTJAVA not set, selecting " ${TESTJAVA} |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
40 |
printf " If this is incorrect, try setting the variable manually.\n" |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
41 |
fi |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
42 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
43 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
44 |
BIT_FLAG="" |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
45 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
46 |
OS=`uname -s` |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
47 |
case "$OS" in |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
48 |
SunOS | Linux ) |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
49 |
FS="/" |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
50 |
## for solaris, linux it's HOME |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
51 |
FILE_LOCATION=$HOME |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
52 |
if [ -f ${FILE_LOCATION}${FS}JDK64BIT -a ${OS} = "SunOS" ] |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
53 |
then |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
54 |
BIT_FLAG=`cat ${FILE_LOCATION}${FS}JDK64BIT` |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
55 |
fi |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
56 |
;; |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
57 |
Windows_* ) |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
58 |
printf "Not testing libjsig.so on Windows. PASSED.\n " |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
59 |
exit 0 |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
60 |
;; |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
61 |
* ) |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
62 |
printf "Not testing libjsig.so on unrecognised system. PASSED.\n " |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
63 |
exit 0 |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
64 |
;; |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
65 |
esac |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
66 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
67 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
68 |
JAVA=${TESTJAVA}${FS}bin${FS}java |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
69 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
70 |
# LD_PRELOAD arch needs to match the binary we run, so run the java |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
71 |
# 64-bit binary directly if we are testing 64-bit (bin/ARCH/java). |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
72 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
73 |
# However JPRT runs: .../solaris_x64_5.10-debug/bin/java |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
74 |
# ..which is 32-bit, when it has built the 64-bit version to test. |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
75 |
# |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
76 |
# How does this script know we are meant to run the 64-bit version? |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
77 |
# Can check for the path of the binary containing "x64" on Solaris. |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
78 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
79 |
if [ ${OS} -eq "SunOS" ] |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
80 |
then |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
81 |
printf "SunOS test JAVA=${JAVA}" |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
82 |
printf ${JAVA} | grep x64 > /dev/null |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
83 |
if [ $? -eq 0 ] |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
84 |
then |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
85 |
printf "SunOS x64 test, forcing -d64\n" |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
86 |
BIT_FLAG=-d64 |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
87 |
fi |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
88 |
fi |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
89 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
90 |
ARCH=`uname -p` |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
91 |
case $ARCH in |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
92 |
i386) |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
93 |
if [ X${BIT_FLAG} != "X" ] |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
94 |
then |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
95 |
ARCH=amd64 |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
96 |
JAVA=${TESTJAVA}${FS}bin${FS}${ARCH}${FS}java |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
97 |
fi |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
98 |
;; |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
99 |
sparc) |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
100 |
if [ X${BIT_FLAG} != "X" ] |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
101 |
then |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
102 |
ARCH=sparcv9 |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
103 |
JAVA=${TESTJAVA}${FS}bin${FS}${ARCH}${FS}java |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
104 |
fi |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
105 |
;; |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
106 |
* ) |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
107 |
printf "Not testing architecture $ARCH, skipping test.\n" |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
108 |
exit 0 |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
109 |
;; |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
110 |
esac |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
111 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
112 |
LIBJSIG=${TESTJAVA}${FS}jre${FS}lib${FS}${ARCH}${FS}libjsig.so |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
113 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
114 |
# If libjsig and binary do not match, skip test. |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
115 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
116 |
A=`file ${LIBJSIG} | awk '{ print $3 }'` |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
117 |
B=`file ${JAVA} | awk '{ print $3 }'` |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
118 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
119 |
if [ $A -ne $B ] |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
120 |
then |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
121 |
printf "Mismatching binary and library to preload, skipping test.\n" |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
122 |
exit 0 |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
123 |
fi |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
124 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
125 |
if [ ! -f ${LIBJSIG} ] |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
126 |
then |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
127 |
printf "Skipping test: libjsig missing for given architecture: ${LIBJSIG}\n" |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
128 |
exit 0 |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
129 |
fi |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
130 |
# Use java -version to test, java version info appeas on stderr, |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
131 |
# the libjsig message we are removing appears on stdout. |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
132 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
133 |
# grep returns zero meaning found, non-zero means not found: |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
134 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
135 |
LD_PRELOAD=${LIBJSIG} ${JAVA} ${BIT_FLAG} -Xcheck:jni -version 2>&1 | grep "libjsig is activated" |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
136 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
137 |
if [ $? -eq 0 ]; then |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
138 |
printf "Failed: -Xcheck:jni prints message when libjsig.so is loaded.\n" |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
139 |
exit 1 |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
140 |
fi |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
141 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
142 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
143 |
LD_PRELOAD=${LIBJSIG} ${JAVA} ${BIT_FLAG} -Xcheck:jni -verbose:jni -version 2>&1 | grep "libjsig is activated" |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
144 |
if [ $? != 0 ]; then |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
145 |
printf "Failed: -Xcheck:jni does not print message when libjsig.so is loaded and -verbose:jni is set.\n" |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
146 |
exit 1 |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
147 |
fi |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
148 |
|
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
149 |
printf "PASSED\n" |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
150 |
exit 0 |
bf51fe78a9ad
7051189: Need to suppress info message if -xcheck:jni used with libjsig.so
kevinw
parents:
diff
changeset
|
151 |