author | duke |
Wed, 05 Jul 2017 20:54:03 +0200 | |
changeset 32971 | 1a52a30674cd |
parent 32812 | 7a2d9c874229 |
child 33031 | e208908e7d48 |
permissions | -rw-r--r-- |
14111 | 1 |
#!/bin/bash |
2 |
# |
|
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
3 |
# Copyright (c) 2012, 2015, Oracle and/or its affiliates. All rights reserved. |
14111 | 4 |
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
5 |
# |
|
6 |
# This code is free software; you can redistribute it and/or modify it |
|
7 |
# under the terms of the GNU General Public License version 2 only, as |
|
8 |
# published by the Free Software Foundation. |
|
9 |
# |
|
10 |
# This code is distributed in the hope that it will be useful, but WITHOUT |
|
11 |
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
|
12 |
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
|
13 |
# version 2 for more details (a copy is included in the LICENSE file that |
|
14 |
# accompanied this code). |
|
15 |
# |
|
16 |
# You should have received a copy of the GNU General Public License version |
|
17 |
# 2 along with this work; if not, write to the Free Software Foundation, |
|
18 |
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
|
19 |
# |
|
20 |
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
|
21 |
# or visit www.oracle.com if you need additional information or have any |
|
22 |
# questions. |
|
23 |
# |
|
24 |
||
28356 | 25 |
# This script is processed by configure before it's usable. It is run from |
14111 | 26 |
# the root of the build directory. |
27 |
||
28 |
||
29157 | 29 |
################################################################################ |
14111 | 30 |
|
31 |
# Check that we are run via the wrapper generated by configure |
|
32 |
if [ -z "$SRC_ROOT" ]; then |
|
33 |
echo "Error: You must run this script using build/[conf]/compare.sh" |
|
34 |
exit 1 |
|
35 |
fi |
|
36 |
||
37 |
if [ "$OPENJDK_TARGET_OS" = "macosx" ]; then |
|
29157 | 38 |
FULLDUMP_CMD="$OTOOL -v -V -h -X -d" |
14111 | 39 |
LDD_CMD="$OTOOL -L" |
40 |
DIS_CMD="$OTOOL -v -t" |
|
41 |
STAT_PRINT_SIZE="-f %z" |
|
42 |
elif [ "$OPENJDK_TARGET_OS" = "windows" ]; then |
|
43 |
FULLDUMP_CMD="$DUMPBIN -all" |
|
44 |
LDD_CMD="$DUMPBIN -dependants | $GREP .dll" |
|
45 |
DIS_CMD="$DUMPBIN -disasm:nobytes" |
|
46 |
STAT_PRINT_SIZE="-c %s" |
|
47 |
else |
|
48 |
FULLDUMP_CMD="$READELF -a" |
|
49 |
LDD_CMD="$LDD" |
|
50 |
DIS_CMD="$OBJDUMP -d" |
|
51 |
STAT_PRINT_SIZE="-c %s" |
|
52 |
fi |
|
53 |
||
54 |
UNARCHIVE="$UNZIP -q" |
|
55 |
||
56 |
COMPARE_EXCEPTIONS_INCLUDE="$SRC_ROOT/common/bin/compare_exceptions.sh.incl" |
|
57 |
if [ ! -e "$COMPARE_EXCEPTIONS_INCLUDE" ]; then |
|
58 |
echo "Error: Cannot locate the exceptions file, it should have been here: $COMPARE_EXCEPTIONS_INCLUDE" |
|
59 |
exit 1 |
|
60 |
fi |
|
61 |
# Include exception definitions |
|
62 |
. "$COMPARE_EXCEPTIONS_INCLUDE" |
|
63 |
||
29157 | 64 |
################################################################################ |
14111 | 65 |
# Compare text files and ignore specific differences: |
66 |
# |
|
67 |
# * Timestamps in Java sources generated by idl2java |
|
68 |
# * Sorting order and cleanup style in .properties files |
|
69 |
||
70 |
diff_text() { |
|
71 |
OTHER_FILE=$1 |
|
72 |
THIS_FILE=$2 |
|
73 |
||
74 |
SUFFIX="${THIS_FILE##*.}" |
|
75 |
||
76 |
TMP=1 |
|
77 |
||
78 |
if [[ "$THIS_FILE" = *"META-INF/MANIFEST.MF" ]]; then |
|
28356 | 79 |
# Filter out date string, ant version and java version differences. |
20049 | 80 |
TMP=$(LC_ALL=C $DIFF $OTHER_FILE $THIS_FILE | \ |
14111 | 81 |
$GREP '^[<>]' | \ |
82 |
$SED -e '/[<>] Ant-Version: Apache Ant .*/d' \ |
|
28356 | 83 |
-e '/[<>] Created-By: .* (Oracle [Corpatin)]*/d' \ |
84 |
-e '/[<>] [Corpatin]*)/d' \ |
|
85 |
-e '/[<>].*[0-9]\{4\}_[0-9]\{2\}_[0-9]\{2\}_[0-9]\{2\}_[0-9]\{2\}-b[0-9]\{2\}.*/d') |
|
14111 | 86 |
fi |
87 |
if test "x$SUFFIX" = "xjava"; then |
|
20049 | 88 |
TMP=$(LC_ALL=C $DIFF $OTHER_FILE $THIS_FILE | \ |
14111 | 89 |
$GREP '^[<>]' | \ |
90 |
$SED -e '/[<>] \* from.*\.idl/d' \ |
|
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
91 |
-e '/[<>] .*[0-9]\{4\}_[0-9]\{2\}_[0-9]\{2\}_[0-9]\{2\}_[0-9]\{2\}-b[0-9]\{2\}.*/d' \ |
14111 | 92 |
-e '/[<>] \*.*[0-9]\{4\} [0-9][0-9]*:[0-9]\{2\}:[0-9]\{2\}.*/d' \ |
93 |
-e '/\/\/ Generated from input file.*/d' \ |
|
94 |
-e '/\/\/ This file was generated AUTOMATICALLY from a template file.*/d' \ |
|
95 |
-e '/\/\/ java GenerateCharacter.*/d') |
|
96 |
fi |
|
97 |
# Ignore date strings in class files. |
|
25854 | 98 |
# Anonymous lambda classes get randomly assigned counters in their names. |
14111 | 99 |
if test "x$SUFFIX" = "xclass"; then |
100 |
# To improve performance when large diffs are found, do a rough filtering of classes |
|
101 |
# elibeble for these exceptions |
|
15058
61c4ac49cbda
8005635: build-infra: Support building install in jprt
erikj
parents:
14466
diff
changeset
|
102 |
if $GREP -R -e '[0-9]\{4\}_[0-9]\{2\}_[0-9]\{2\}_[0-9]\{2\}_[0-9]\{2\}-b[0-9]\{2\}' \ |
28356 | 103 |
-e '[0-9]\{2\}/[0-9]\{2\}/[0-9]\{4\}' \ |
25854 | 104 |
-e 'lambda\$[a-zA-Z0-9]*\$[0-9]' ${THIS_FILE} > /dev/null; then |
27560 | 105 |
$JAVAP -c -constants -l -p "${OTHER_FILE}" > ${OTHER_FILE}.javap |
106 |
$JAVAP -c -constants -l -p "${THIS_FILE}" > ${THIS_FILE}.javap |
|
14111 | 107 |
TMP=$($DIFF ${OTHER_FILE}.javap ${THIS_FILE}.javap | \ |
108 |
$GREP '^[<>]' | \ |
|
109 |
$SED -e '/[<>].*[0-9]\{4\}_[0-9]\{2\}_[0-9]\{2\}_[0-9]\{2\}_[0-9]\{2\}-b[0-9]\{2\}.*/d' \ |
|
28356 | 110 |
-e '/[0-9]\{2\}\/[0-9]\{2\}\/[0-9]\{4\}/d' \ |
25854 | 111 |
-e '/[<>].*lambda\$[a-zA-Z0-9]*\$[0-9]*/d') |
14111 | 112 |
fi |
113 |
fi |
|
114 |
if test "x$SUFFIX" = "xproperties"; then |
|
15059
4131faaca93d
8005575: build-infra: Three JCK tests fails on Solaris with new RE Autoconf-Based build
erikj
parents:
15058
diff
changeset
|
115 |
# Run through nawk to add possibly missing newline at end of file. |
23428
3c8a05bf4656
8038340: Cleanup and fix sysroot and devkit handling on Linux and Solaris
erikj
parents:
21759
diff
changeset
|
116 |
$CAT $OTHER_FILE | $NAWK '{ print }' | LC_ALL=C $SORT > $OTHER_FILE.cleaned |
15059
4131faaca93d
8005575: build-infra: Three JCK tests fails on Solaris with new RE Autoconf-Based build
erikj
parents:
15058
diff
changeset
|
117 |
# Disable this exception since we aren't changing the properties cleaning method yet. |
4131faaca93d
8005575: build-infra: Three JCK tests fails on Solaris with new RE Autoconf-Based build
erikj
parents:
15058
diff
changeset
|
118 |
# $CAT $OTHER_FILE | $SED -e 's/\([^\\]\):/\1\\:/g' -e 's/\([^\\]\)=/\1\\=/g' -e 's/#.*/#/g' \ |
4131faaca93d
8005575: build-infra: Three JCK tests fails on Solaris with new RE Autoconf-Based build
erikj
parents:
15058
diff
changeset
|
119 |
# | $SED -f "$SRC_ROOT/common/makefiles/support/unicode2x.sed" \ |
28356 | 120 |
# | $SED -e '/^#/d' -e '/^$/d' \ |
15059
4131faaca93d
8005575: build-infra: Three JCK tests fails on Solaris with new RE Autoconf-Based build
erikj
parents:
15058
diff
changeset
|
121 |
# -e :a -e '/\\$/N; s/\\\n//; ta' \ |
28356 | 122 |
# -e 's/^[ \t]*//;s/[ \t]*$//' \ |
123 |
# -e 's/\\=/=/' | LC_ALL=C $SORT > $OTHER_FILE.cleaned |
|
25854 | 124 |
# Filter out date string differences. |
125 |
TMP=$(LC_ALL=C $DIFF $OTHER_FILE.cleaned $THIS_FILE | \ |
|
126 |
$GREP '^[<>]' | \ |
|
127 |
$SED -e '/[<>].*[0-9]\{4\}_[0-9]\{2\}_[0-9]\{2\}_[0-9]\{2\}_[0-9]\{2\}-b[0-9]\{2\}.*/d') |
|
128 |
fi |
|
28356 | 129 |
if test "x$SUFFIX" = "xhtml"; then |
29157 | 130 |
# Some javadoc versions do not put quotes around font size |
131 |
HTML_FILTER="$SED \ |
|
132 |
-e 's/<font size=-1>/<font size=\"-1\">/g'" |
|
133 |
$CAT $THIS_FILE | eval "$HTML_FILTER" > $THIS_FILE.filtered |
|
134 |
$CAT $OTHER_FILE | eval "$HTML_FILTER" > $OTHER_FILE.filtered |
|
135 |
TMP=$(LC_ALL=C $DIFF $OTHER_FILE.filtered $THIS_FILE.filtered | \ |
|
25854 | 136 |
$GREP '^[<>]' | \ |
29157 | 137 |
$SED -e '/[<>] <!-- Generated by javadoc .* on .* -->/d' \ |
138 |
-e '/[<>] <meta name="date" content=".*">/d' ) |
|
14111 | 139 |
fi |
140 |
if test -n "$TMP"; then |
|
141 |
echo Files $OTHER_FILE and $THIS_FILE differ |
|
142 |
return 1 |
|
143 |
fi |
|
144 |
||
145 |
return 0 |
|
146 |
} |
|
147 |
||
29157 | 148 |
################################################################################ |
14111 | 149 |
# Compare directory structure |
150 |
||
151 |
compare_dirs() { |
|
152 |
THIS_DIR=$1 |
|
153 |
OTHER_DIR=$2 |
|
154 |
WORK_DIR=$3 |
|
155 |
||
156 |
mkdir -p $WORK_DIR |
|
157 |
||
158 |
(cd $OTHER_DIR && $FIND . -type d | $SORT > $WORK_DIR/dirs_other) |
|
159 |
(cd $THIS_DIR && $FIND . -type d | $SORT > $WORK_DIR/dirs_this) |
|
160 |
||
25854 | 161 |
$DIFF $WORK_DIR/dirs_other $WORK_DIR/dirs_this > $WORK_DIR/dirs_diff |
28356 | 162 |
|
14111 | 163 |
echo -n Directory structure... |
164 |
if [ -s $WORK_DIR/dirs_diff ]; then |
|
165 |
echo Differences found. |
|
166 |
REGRESSIONS=true |
|
167 |
# Differences in directories found. |
|
168 |
ONLY_OTHER=$($GREP '<' $WORK_DIR/dirs_diff) |
|
169 |
if [ "$ONLY_OTHER" ]; then |
|
170 |
echo Only in $OTHER |
|
171 |
$GREP '<' $WORK_DIR/dirs_diff | $SED 's|< ./| |g' |
|
172 |
fi |
|
173 |
ONLY_THIS=$($GREP '>' $WORK_DIR/dirs_diff) |
|
174 |
if [ "$ONLY_THIS" ]; then |
|
175 |
echo Only in $THIS |
|
176 |
$GREP '>' $WORK_DIR/dirs_diff | $SED 's|> ./| |g' |
|
177 |
fi |
|
178 |
else |
|
179 |
echo Identical! |
|
180 |
fi |
|
181 |
} |
|
182 |
||
183 |
||
29157 | 184 |
################################################################################ |
14111 | 185 |
# Compare file structure |
186 |
||
187 |
compare_files() { |
|
188 |
THIS_DIR=$1 |
|
189 |
OTHER_DIR=$2 |
|
190 |
WORK_DIR=$3 |
|
191 |
||
192 |
$MKDIR -p $WORK_DIR |
|
193 |
||
194 |
(cd $OTHER_DIR && $FIND . ! -type d | $SORT > $WORK_DIR/files_other) |
|
195 |
(cd $THIS_DIR && $FIND . ! -type d | $SORT > $WORK_DIR/files_this) |
|
28356 | 196 |
|
14111 | 197 |
$DIFF $WORK_DIR/files_other $WORK_DIR/files_this > $WORK_DIR/files_diff |
198 |
||
199 |
echo -n File names... |
|
200 |
if [ -s $WORK_DIR/files_diff ]; then |
|
201 |
echo Differences found. |
|
202 |
REGRESSIONS=true |
|
203 |
# Differences in files found. |
|
204 |
ONLY_OTHER=$($GREP '<' $WORK_DIR/files_diff) |
|
205 |
if [ "$ONLY_OTHER" ]; then |
|
206 |
echo Only in $OTHER |
|
207 |
$GREP '<' $WORK_DIR/files_diff | $SED 's|< ./| |g' |
|
208 |
fi |
|
209 |
ONLY_THIS=$($GREP '>' $WORK_DIR/files_diff) |
|
210 |
if [ "$ONLY_THIS" ]; then |
|
211 |
echo Only in $THIS |
|
212 |
$GREP '>' $WORK_DIR/files_diff | $SED 's|> ./| |g' |
|
213 |
fi |
|
214 |
else |
|
215 |
echo Identical! |
|
216 |
fi |
|
217 |
} |
|
218 |
||
219 |
||
29157 | 220 |
################################################################################ |
14111 | 221 |
# Compare permissions |
222 |
||
223 |
compare_permissions() { |
|
224 |
THIS_DIR=$1 |
|
225 |
OTHER_DIR=$2 |
|
226 |
WORK_DIR=$3 |
|
227 |
||
228 |
mkdir -p $WORK_DIR |
|
229 |
||
230 |
echo -n Permissions... |
|
231 |
found="" |
|
232 |
for f in `cd $OTHER_DIR && $FIND . -type f` |
|
233 |
do |
|
234 |
if [ ! -f ${OTHER_DIR}/$f ]; then continue; fi |
|
235 |
if [ ! -f ${THIS_DIR}/$f ]; then continue; fi |
|
236 |
OP=`ls -l ${OTHER_DIR}/$f | awk '{printf("%.10s\n", $1);}'` |
|
237 |
TP=`ls -l ${THIS_DIR}/$f | awk '{printf("%.10s\n", $1);}'` |
|
238 |
if [ "$OP" != "$TP" ] |
|
239 |
then |
|
28356 | 240 |
if [ -z "$found" ]; then echo ; found="yes"; fi |
241 |
$PRINTF "\tother: ${OP} this: ${TP}\t$f\n" |
|
14111 | 242 |
fi |
243 |
done |
|
28356 | 244 |
if [ -z "$found" ]; then |
14111 | 245 |
echo "Identical!" |
246 |
else |
|
247 |
REGRESSIONS=true |
|
248 |
fi |
|
249 |
} |
|
250 |
||
29157 | 251 |
################################################################################ |
14111 | 252 |
# Compare file command output |
253 |
||
254 |
compare_file_types() { |
|
255 |
THIS_DIR=$1 |
|
256 |
OTHER_DIR=$2 |
|
257 |
WORK_DIR=$3 |
|
258 |
||
259 |
$MKDIR -p $WORK_DIR |
|
260 |
||
261 |
echo -n File types... |
|
262 |
found="" |
|
263 |
for f in `cd $OTHER_DIR && $FIND . ! -type d` |
|
264 |
do |
|
265 |
if [ ! -f ${OTHER_DIR}/$f ]; then continue; fi |
|
266 |
if [ ! -f ${THIS_DIR}/$f ]; then continue; fi |
|
25854 | 267 |
OF=`cd ${OTHER_DIR} && $FILE -h $f | $SED 's/BuildID[^,]*//g'` |
268 |
TF=`cd ${THIS_DIR} && $FILE -h $f | $SED 's/BuildID[^,]*//g'` |
|
14111 | 269 |
if [ "$OF" != "$TF" ] |
270 |
then |
|
28356 | 271 |
if [ "`echo $OF | $GREP -c 'Zip archive data'`" -gt 0 ] \ |
272 |
&& [ "`echo $TF | $GREP -c 'Zip archive data'`" -gt 0 ] |
|
273 |
then |
|
274 |
# the way we produce zip-files make it so that directories are stored in |
|
275 |
# old file but not in new (only files with full-path) this makes file |
|
276 |
# report them as different |
|
277 |
continue |
|
278 |
else |
|
279 |
if [ -z "$found" ]; then echo ; found="yes"; fi |
|
280 |
$PRINTF "\tother: ${OF}\n\tthis : ${TF}\n" |
|
281 |
fi |
|
14111 | 282 |
fi |
283 |
done |
|
28356 | 284 |
if [ -z "$found" ]; then |
14111 | 285 |
echo "Identical!" |
286 |
else |
|
287 |
REGRESSIONS=true |
|
288 |
fi |
|
289 |
} |
|
290 |
||
29157 | 291 |
################################################################################ |
14111 | 292 |
# Compare the rest of the files |
293 |
||
294 |
compare_general_files() { |
|
295 |
THIS_DIR=$1 |
|
296 |
OTHER_DIR=$2 |
|
297 |
WORK_DIR=$3 |
|
28356 | 298 |
|
29157 | 299 |
GENERAL_FILES=$(cd $THIS_DIR && $FIND . -type f ! -name "*.so" ! -name "*.jar" \ |
300 |
! -name "*.zip" ! -name "*.debuginfo" ! -name "*.dylib" ! -name "jexec" \ |
|
301 |
! -name "*.jimage" ! -name "ct.sym" ! -name "*.diz" ! -name "*.dll" \ |
|
302 |
! -name "*.cpl" ! -name "*.pdb" ! -name "*.exp" ! -name "*.ilk" \ |
|
14458 | 303 |
! -name "*.lib" ! -name "*.war" ! -name "JavaControlPanel" \ |
29157 | 304 |
! -name "*.obj" ! -name "*.o" ! -name "JavaControlPanelHelper" \ |
305 |
! -name "JavaUpdater" ! -name "JavaWSApplicationStub" \ |
|
306 |
! -name "jspawnhelper" \ |
|
14111 | 307 |
| $GREP -v "./bin/" | $SORT | $FILTER) |
308 |
||
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
309 |
echo Other files with binary differences... |
14111 | 310 |
for f in $GENERAL_FILES |
311 |
do |
|
312 |
if [ -e $OTHER_DIR/$f ]; then |
|
14466
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
313 |
SUFFIX="${f##*.}" |
14111 | 314 |
if [ "$(basename $f)" = "release" ]; then |
315 |
# Ignore differences in change numbers in release file. |
|
316 |
OTHER_FILE=$WORK_DIR/$f.other |
|
317 |
THIS_FILE=$WORK_DIR/$f.this |
|
318 |
$MKDIR -p $(dirname $OTHER_FILE) |
|
319 |
$MKDIR -p $(dirname $THIS_FILE) |
|
320 |
$CAT $OTHER_DIR/$f | $SED 's/\:[0-9a-f]\{12,12\}/:CHANGE/g' > $OTHER_FILE |
|
321 |
$CAT $THIS_DIR/$f | $SED 's/\:[0-9a-f]\{12,12\}/:CHANGE/g' > $THIS_FILE |
|
14466
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
322 |
elif [ "x$SUFFIX" = "xhtml" ]; then |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
323 |
# Ignore time stamps in docs files |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
324 |
OTHER_FILE=$WORK_DIR/$f.other |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
325 |
THIS_FILE=$WORK_DIR/$f.this |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
326 |
$MKDIR -p $(dirname $OTHER_FILE) |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
327 |
$MKDIR -p $(dirname $THIS_FILE) |
15058
61c4ac49cbda
8005635: build-infra: Support building install in jprt
erikj
parents:
14466
diff
changeset
|
328 |
#Note that | doesn't work on mac sed. |
14466
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
329 |
$CAT $OTHER_DIR/$f | $SED -e 's/\(-- Generated by javadoc \).*\( --\)/\1(removed)\2/' \ |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
330 |
-e 's/\(<meta name="date" content="\).*\(">\)/\1(removed)\2/' \ |
15058
61c4ac49cbda
8005635: build-infra: Support building install in jprt
erikj
parents:
14466
diff
changeset
|
331 |
-e 's/[A-Z][a-z]*, [A-Z][a-z]* [0-9][0-9]*, [12][0-9]* [0-9][0-9:]* [AMP]\{2,2\} [A-Z][A-Z]*/(removed)/' \ |
61c4ac49cbda
8005635: build-infra: Support building install in jprt
erikj
parents:
14466
diff
changeset
|
332 |
-e 's/[A-Z][a-z]* [A-Z][a-z]* [0-9][0-9] [0-9][0-9:]* [A-Z][A-Z]* [12][0-9]*/(removed)/' \ |
14466
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
333 |
-e 's/^\( from \).*\(\.idl\)$/\1(removed)\2/' \ |
25854 | 334 |
-e 's/^\(.*\)\( o'"'"'clock \)\([A-Z][A-Z][A-Z]\)/(removed)\2(removed)/' \ |
14466
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
335 |
> $OTHER_FILE |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
336 |
$CAT $THIS_DIR/$f | $SED -e 's/\(-- Generated by javadoc \).*\( --\)/\1(removed)\2/' \ |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
337 |
-e 's/\(<meta name="date" content="\).*\(">\)/\1(removed)\2/' \ |
15058
61c4ac49cbda
8005635: build-infra: Support building install in jprt
erikj
parents:
14466
diff
changeset
|
338 |
-e 's/[A-Z][a-z]*, [A-Z][a-z]* [0-9][0-9]*, [12][0-9]* [0-9][0-9:]* [AMP]\{2,2\} [A-Z][A-Z]*/(removed)/' \ |
61c4ac49cbda
8005635: build-infra: Support building install in jprt
erikj
parents:
14466
diff
changeset
|
339 |
-e 's/[A-Z][a-z]* [A-Z][a-z]* [0-9][0-9] [0-9][0-9:]* [A-Z][A-Z]* [12][0-9]*/(removed)/' \ |
14466
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
340 |
-e 's/^\( from \).*\(\.idl\)$/\1(removed)\2/' \ |
25854 | 341 |
-e 's/^\(.*\)\( o'"'"'clock \)\([A-Z][A-Z][A-Z]\)/(removed)\2(removed)/' \ |
14466
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
342 |
> $THIS_FILE |
14111 | 343 |
else |
344 |
OTHER_FILE=$OTHER_DIR/$f |
|
345 |
THIS_FILE=$THIS_DIR/$f |
|
346 |
fi |
|
347 |
DIFF_OUT=$($DIFF $OTHER_FILE $THIS_FILE 2>&1) |
|
348 |
if [ -n "$DIFF_OUT" ]; then |
|
349 |
echo $f |
|
350 |
REGRESSIONS=true |
|
351 |
if [ "$SHOW_DIFFS" = "true" ]; then |
|
352 |
echo "$DIFF_OUT" |
|
353 |
fi |
|
354 |
fi |
|
355 |
fi |
|
356 |
done |
|
357 |
||
358 |
||
359 |
} |
|
360 |
||
29157 | 361 |
################################################################################ |
14111 | 362 |
# Compare zip file |
363 |
||
364 |
compare_zip_file() { |
|
365 |
THIS_DIR=$1 |
|
366 |
OTHER_DIR=$2 |
|
367 |
WORK_DIR=$3 |
|
368 |
ZIP_FILE=$4 |
|
15179
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
369 |
# Optionally provide different name for other zipfile |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
370 |
OTHER_ZIP_FILE=$5 |
14111 | 371 |
|
372 |
THIS_ZIP=$THIS_DIR/$ZIP_FILE |
|
15179
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
373 |
if [ -n "$OTHER_ZIP_FILE" ]; then |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
374 |
OTHER_ZIP=$OTHER_DIR/$OTHER_ZIP_FILE |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
375 |
else |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
376 |
OTHER_ZIP=$OTHER_DIR/$ZIP_FILE |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
377 |
fi |
14111 | 378 |
|
379 |
THIS_SUFFIX="${THIS_ZIP##*.}" |
|
380 |
OTHER_SUFFIX="${OTHER_ZIP##*.}" |
|
381 |
if [ "$THIS_SUFFIX" != "$OTHER_SUFFIX" ]; then |
|
28356 | 382 |
echo "The files do not have the same suffix type! ($THIS_SUFFIX != $OTHER_SUFFIX)" |
14111 | 383 |
return 2 |
384 |
fi |
|
385 |
||
386 |
TYPE="$THIS_SUFFIX" |
|
387 |
||
388 |
if $CMP $OTHER_ZIP $THIS_ZIP > /dev/null |
|
389 |
then |
|
390 |
return 0 |
|
391 |
fi |
|
392 |
# Not quite identical, the might still contain the same data. |
|
393 |
# Unpack the jar/zip files in temp dirs |
|
28356 | 394 |
|
14111 | 395 |
THIS_UNZIPDIR=$WORK_DIR/$ZIP_FILE.this |
396 |
OTHER_UNZIPDIR=$WORK_DIR/$ZIP_FILE.other |
|
397 |
$RM -rf $THIS_UNZIPDIR $OTHER_UNZIPDIR |
|
398 |
$MKDIR -p $THIS_UNZIPDIR |
|
399 |
$MKDIR -p $OTHER_UNZIPDIR |
|
27560 | 400 |
if [ "$TYPE" = "jimage" ] |
401 |
then |
|
402 |
(cd $THIS_UNZIPDIR && $JIMAGE extract $THIS_ZIP) |
|
403 |
(cd $OTHER_UNZIPDIR && $JIMAGE extract $OTHER_ZIP) |
|
404 |
else |
|
405 |
(cd $THIS_UNZIPDIR && $UNARCHIVE $THIS_ZIP) |
|
406 |
(cd $OTHER_UNZIPDIR && $UNARCHIVE $OTHER_ZIP) |
|
407 |
fi |
|
14111 | 408 |
|
14280
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
409 |
# Find all archives inside and unzip them as well to compare the contents rather than |
15058
61c4ac49cbda
8005635: build-infra: Support building install in jprt
erikj
parents:
14466
diff
changeset
|
410 |
# the archives. pie.jar.pack.gz i app3.war is corrupt, skip it. |
61c4ac49cbda
8005635: build-infra: Support building install in jprt
erikj
parents:
14466
diff
changeset
|
411 |
EXCEPTIONS="pie.jar.pack.gz" |
61c4ac49cbda
8005635: build-infra: Support building install in jprt
erikj
parents:
14466
diff
changeset
|
412 |
for pack in $($FIND $THIS_UNZIPDIR \( -name "*.pack" -o -name "*.pack.gz" \) -a ! -name pie.jar.pack.gz); do |
14280
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
413 |
($UNPACK200 $pack $pack.jar) |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
414 |
# Filter out the unzipped archives from the diff below. |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
415 |
EXCEPTIONS="$EXCEPTIONS $pack $pack.jar" |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
416 |
done |
15058
61c4ac49cbda
8005635: build-infra: Support building install in jprt
erikj
parents:
14466
diff
changeset
|
417 |
for pack in $($FIND $OTHER_UNZIPDIR \( -name "*.pack" -o -name "*.pack.gz" \) -a ! -name pie.jar.pack.gz); do |
14280
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
418 |
($UNPACK200 $pack $pack.jar) |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
419 |
EXCEPTIONS="$EXCEPTIONS $pack $pack.jar" |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
420 |
done |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
421 |
for zip in $($FIND $THIS_UNZIPDIR -name "*.jar" -o -name "*.zip"); do |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
422 |
$MKDIR $zip.unzip |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
423 |
(cd $zip.unzip && $UNARCHIVE $zip) |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
424 |
EXCEPTIONS="$EXCEPTIONS $zip" |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
425 |
done |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
426 |
for zip in $($FIND $OTHER_UNZIPDIR -name "*.jar" -o -name "*.zip"); do |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
427 |
$MKDIR $zip.unzip |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
428 |
(cd $zip.unzip && $UNARCHIVE $zip) |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
429 |
EXCEPTIONS="$EXCEPTIONS $zip" |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
430 |
done |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
431 |
|
14111 | 432 |
CONTENTS_DIFF_FILE=$WORK_DIR/$ZIP_FILE.diff |
433 |
# On solaris, there is no -q option. |
|
434 |
if [ "$OPENJDK_TARGET_OS" = "solaris" ]; then |
|
20049 | 435 |
LC_ALL=C $DIFF -r $OTHER_UNZIPDIR $THIS_UNZIPDIR \ |
14111 | 436 |
| $GREP -v -e "^<" -e "^>" -e "^Common subdirectories:" \ |
437 |
> $CONTENTS_DIFF_FILE |
|
438 |
else |
|
20049 | 439 |
LC_ALL=C $DIFF -rq $OTHER_UNZIPDIR $THIS_UNZIPDIR > $CONTENTS_DIFF_FILE |
14111 | 440 |
fi |
441 |
||
442 |
ONLY_OTHER=$($GREP "^Only in $OTHER_UNZIPDIR" $CONTENTS_DIFF_FILE) |
|
443 |
ONLY_THIS=$($GREP "^Only in $THIS_UNZIPDIR" $CONTENTS_DIFF_FILE) |
|
444 |
||
445 |
return_value=0 |
|
446 |
||
447 |
if [ -n "$ONLY_OTHER" ]; then |
|
448 |
echo " Only OTHER $ZIP_FILE contains:" |
|
449 |
echo "$ONLY_OTHER" | sed "s|Only in $OTHER_UNZIPDIR| |"g | sed 's|: |/|g' |
|
450 |
return_value=1 |
|
451 |
fi |
|
452 |
||
453 |
if [ -n "$ONLY_THIS" ]; then |
|
454 |
echo " Only THIS $ZIP_FILE contains:" |
|
455 |
echo "$ONLY_THIS" | sed "s|Only in $THIS_UNZIPDIR| |"g | sed 's|: |/|g' |
|
456 |
return_value=1 |
|
457 |
fi |
|
458 |
||
459 |
if [ "$OPENJDK_TARGET_OS" = "solaris" ]; then |
|
29157 | 460 |
DIFFING_FILES=$($GREP -e 'differ$' -e '^diff ' $CONTENTS_DIFF_FILE \ |
461 |
| $SED -e 's/^Files //g' -e 's/diff -r //g' | $CUT -f 1 -d ' ' \ |
|
462 |
| $SED "s|$OTHER_UNZIPDIR/||g") |
|
14111 | 463 |
else |
464 |
DIFFING_FILES=$($GREP -e "differ$" $CONTENTS_DIFF_FILE \ |
|
465 |
| $CUT -f 2 -d ' ' | $SED "s|$OTHER_UNZIPDIR/||g") |
|
466 |
fi |
|
467 |
||
468 |
$RM -f $WORK_DIR/$ZIP_FILE.diffs |
|
469 |
for file in $DIFFING_FILES; do |
|
28356 | 470 |
if [[ "$ACCEPTED_JARZIP_CONTENTS $EXCEPTIONS" != *"$file"* ]]; then |
14111 | 471 |
diff_text $OTHER_UNZIPDIR/$file $THIS_UNZIPDIR/$file >> $WORK_DIR/$ZIP_FILE.diffs |
28356 | 472 |
fi |
14111 | 473 |
done |
474 |
||
475 |
if [ -s "$WORK_DIR/$ZIP_FILE.diffs" ]; then |
|
476 |
return_value=1 |
|
477 |
echo " Differing files in $ZIP_FILE" |
|
29157 | 478 |
$CAT $WORK_DIR/$ZIP_FILE.diffs | $GREP 'differ$' | cut -f 2 -d ' ' | \ |
14111 | 479 |
$SED "s|$OTHER_UNZIPDIR| |g" > $WORK_DIR/$ZIP_FILE.difflist |
480 |
$CAT $WORK_DIR/$ZIP_FILE.difflist |
|
481 |
||
482 |
if [ -n "$SHOW_DIFFS" ]; then |
|
483 |
for i in $(cat $WORK_DIR/$ZIP_FILE.difflist) ; do |
|
484 |
if [ -f "${OTHER_UNZIPDIR}/$i.javap" ]; then |
|
20049 | 485 |
LC_ALL=C $DIFF ${OTHER_UNZIPDIR}/$i.javap ${THIS_UNZIPDIR}/$i.javap |
14111 | 486 |
elif [ -f "${OTHER_UNZIPDIR}/$i.cleaned" ]; then |
20049 | 487 |
LC_ALL=C $DIFF ${OTHER_UNZIPDIR}/$i.cleaned ${THIS_UNZIPDIR}/$i |
14111 | 488 |
else |
20049 | 489 |
LC_ALL=C $DIFF ${OTHER_UNZIPDIR}/$i ${THIS_UNZIPDIR}/$i |
14111 | 490 |
fi |
491 |
done |
|
492 |
fi |
|
493 |
fi |
|
494 |
||
495 |
return $return_value |
|
496 |
} |
|
497 |
||
498 |
||
29157 | 499 |
################################################################################ |
14111 | 500 |
# Compare all zip files |
501 |
||
502 |
compare_all_zip_files() { |
|
503 |
THIS_DIR=$1 |
|
504 |
OTHER_DIR=$2 |
|
505 |
WORK_DIR=$3 |
|
506 |
||
507 |
ZIPS=$(cd $THIS_DIR && $FIND . -type f -name "*.zip" | $SORT | $FILTER ) |
|
508 |
||
509 |
if [ -n "$ZIPS" ]; then |
|
510 |
echo Zip files... |
|
511 |
||
512 |
return_value=0 |
|
513 |
for f in $ZIPS; do |
|
514 |
if [ -f "$OTHER_DIR/$f" ]; then |
|
515 |
compare_zip_file $THIS_DIR $OTHER_DIR $WORK_DIR $f |
|
516 |
if [ "$?" != "0" ]; then |
|
517 |
return_value=1 |
|
518 |
REGRESSIONS=true |
|
519 |
fi |
|
520 |
fi |
|
521 |
done |
|
522 |
fi |
|
523 |
||
524 |
return $return_value |
|
525 |
} |
|
526 |
||
29157 | 527 |
################################################################################ |
14111 | 528 |
# Compare all jar files |
529 |
||
530 |
compare_all_jar_files() { |
|
531 |
THIS_DIR=$1 |
|
532 |
OTHER_DIR=$2 |
|
533 |
WORK_DIR=$3 |
|
534 |
||
535 |
# TODO filter? |
|
25854 | 536 |
ZIPS=$(cd $THIS_DIR && $FIND . -type f -name "*.jar" -o -name "*.war" \ |
27560 | 537 |
-o -name "*.jimage" | $SORT | $FILTER) |
14111 | 538 |
|
539 |
if [ -n "$ZIPS" ]; then |
|
540 |
echo Jar files... |
|
541 |
||
542 |
return_value=0 |
|
543 |
for f in $ZIPS; do |
|
544 |
if [ -f "$OTHER_DIR/$f" ]; then |
|
545 |
compare_zip_file $THIS_DIR $OTHER_DIR $WORK_DIR $f |
|
546 |
if [ "$?" != "0" ]; then |
|
547 |
return_value=1 |
|
548 |
REGRESSIONS=true |
|
549 |
fi |
|
550 |
fi |
|
551 |
done |
|
552 |
fi |
|
553 |
||
554 |
return $return_value |
|
555 |
} |
|
556 |
||
29157 | 557 |
################################################################################ |
14111 | 558 |
# Compare binary (executable/library) file |
559 |
||
560 |
compare_bin_file() { |
|
561 |
THIS_DIR=$1 |
|
562 |
OTHER_DIR=$2 |
|
563 |
WORK_DIR=$3 |
|
564 |
BIN_FILE=$4 |
|
25854 | 565 |
OTHER_BIN_FILE=$5 |
14111 | 566 |
|
567 |
THIS_FILE=$THIS_DIR/$BIN_FILE |
|
25854 | 568 |
if [ -n "$OTHER_BIN_FILE" ]; then |
569 |
OTHER_FILE=$OTHER_DIR/$OTHER_BIN_FILE |
|
570 |
else |
|
571 |
OTHER_FILE=$OTHER_DIR/$BIN_FILE |
|
572 |
fi |
|
14111 | 573 |
NAME=$(basename $BIN_FILE) |
574 |
WORK_FILE_BASE=$WORK_DIR/$BIN_FILE |
|
575 |
FILE_WORK_DIR=$(dirname $WORK_FILE_BASE) |
|
576 |
||
577 |
$MKDIR -p $FILE_WORK_DIR |
|
578 |
||
28356 | 579 |
# Make soft links to original files from work dir to facilitate debugging |
580 |
$LN -f -s $THIS_FILE $WORK_FILE_BASE.this |
|
581 |
$LN -f -s $OTHER_FILE $WORK_FILE_BASE.other |
|
582 |
||
14111 | 583 |
ORIG_THIS_FILE="$THIS_FILE" |
584 |
ORIG_OTHER_FILE="$OTHER_FILE" |
|
585 |
||
32811
df82db312e58
8135060: Stop building Xcode projects in install build
erikj
parents:
31310
diff
changeset
|
586 |
if [ "$STRIP_ALL" = "true" ] || [[ "$STRIP_BEFORE_COMPARE" = *"$BIN_FILE"* ]]; then |
14111 | 587 |
THIS_STRIPPED_FILE=$FILE_WORK_DIR/this/$NAME |
588 |
OTHER_STRIPPED_FILE=$FILE_WORK_DIR/other/$NAME |
|
589 |
$MKDIR -p $FILE_WORK_DIR/this $FILE_WORK_DIR/other |
|
590 |
$CP $THIS_FILE $THIS_STRIPPED_FILE |
|
591 |
$CP $OTHER_FILE $OTHER_STRIPPED_FILE |
|
592 |
$STRIP $THIS_STRIPPED_FILE |
|
593 |
$STRIP $OTHER_STRIPPED_FILE |
|
594 |
THIS_FILE="$THIS_STRIPPED_FILE" |
|
595 |
OTHER_FILE="$OTHER_STRIPPED_FILE" |
|
596 |
fi |
|
597 |
||
598 |
if [ "$OPENJDK_TARGET_OS" = "windows" ]; then |
|
28356 | 599 |
unset _NT_SYMBOL_PATH |
600 |
# On windows we need to unzip the debug symbols, if present |
|
601 |
OTHER_FILE_BASE=${OTHER_FILE/.dll/} |
|
602 |
OTHER_FILE_BASE=${OTHER_FILE_BASE/.exe/} |
|
603 |
OTHER_FILE_BASE=${OTHER_FILE_BASE/.cpl/} |
|
604 |
DIZ_NAME=$(basename $OTHER_FILE_BASE).diz |
|
14111 | 605 |
# java.exe and java.dll diz files will have the same name. Have to |
28356 | 606 |
# make sure java.exe gets the right one. This is only needed for |
607 |
# OTHER since in the new build, all pdb files are left around. |
|
608 |
if [ "$NAME" = "java.exe" ] && [ -f "$OTHER/tmp/java/java/obj64/java.diz" ]; then |
|
609 |
OTHER_DIZ_FILE="$OTHER/tmp/java/java/obj64/java.diz" |
|
610 |
elif [ -f "${OTHER_FILE_BASE}.diz" ]; then |
|
611 |
OTHER_DIZ_FILE=${OTHER_FILE_BASE}.diz |
|
612 |
else |
|
14111 | 613 |
# Some files, jli.dll, appears twice in the image but only one of |
28356 | 614 |
# thme has a diz file next to it. |
615 |
OTHER_DIZ_FILE="$($FIND $OTHER_DIR -name $DIZ_NAME | $SED 1q)" |
|
616 |
if [ ! -f "$OTHER_DIZ_FILE" ]; then |
|
617 |
# As a last resort, look for diz file in the whole build output |
|
618 |
# dir. |
|
619 |
OTHER_DIZ_FILE="$($FIND $OTHER -name $DIZ_NAME | $SED 1q)" |
|
620 |
fi |
|
621 |
fi |
|
622 |
if [ -n "$OTHER_DIZ_FILE" ]; then |
|
623 |
$MKDIR -p $FILE_WORK_DIR/other |
|
624 |
(cd $FILE_WORK_DIR/other ; $UNARCHIVE -o $OTHER_DIZ_FILE) |
|
625 |
export _NT_SYMBOL_PATH="$FILE_WORK_DIR/other" |
|
626 |
fi |
|
627 |
THIS_FILE_BASE=${THIS_FILE/.dll/} |
|
628 |
THIS_FILE_BASE=${THIS_FILE_BASE/.exe/} |
|
629 |
if [ -f "${THIS_FILE/.dll/}.diz" ]; then |
|
630 |
THIS_DIZ_FILE=${THIS_FILE/.dll/}.diz |
|
631 |
else |
|
632 |
THIS_DIZ_FILE="$($FIND $THIS_DIR -name $DIZ_NAME | $SED 1q)" |
|
633 |
if [ ! -f "$THIS_DIZ_FILE" ]; then |
|
634 |
# As a last resort, look for diz file in the whole build output |
|
635 |
# dir. |
|
636 |
THIS_DIZ_FILE="$($FIND $THIS -name $DIZ_NAME | $SED 1q)" |
|
637 |
fi |
|
638 |
fi |
|
639 |
if [ -n "$THIS_DIZ_FILE" ]; then |
|
640 |
$MKDIR -p $FILE_WORK_DIR/this |
|
641 |
(cd $FILE_WORK_DIR/this ; $UNARCHIVE -o $THIS_DIZ_FILE) |
|
642 |
export _NT_SYMBOL_PATH="$_NT_SYMBOL_PATH;$FILE_WORK_DIR/this" |
|
643 |
fi |
|
14111 | 644 |
fi |
645 |
||
646 |
if [ -z "$SKIP_BIN_DIFF" ]; then |
|
647 |
if cmp $OTHER_FILE $THIS_FILE > /dev/null; then |
|
648 |
# The files were bytewise identical. |
|
649 |
if [ -n "$VERBOSE" ]; then |
|
27595
cff167b3bfa2
8065914: Various improvements and cleanup of build system
ihse
parents:
25854
diff
changeset
|
650 |
echo " : : : : : : $BIN_FILE" |
14111 | 651 |
fi |
652 |
return 0 |
|
653 |
fi |
|
654 |
BIN_MSG=" diff " |
|
655 |
if [[ "$ACCEPTED_BIN_DIFF" != *"$BIN_FILE"* ]]; then |
|
656 |
DIFF_BIN=true |
|
657 |
if [[ "$KNOWN_BIN_DIFF" != *"$BIN_FILE"* ]]; then |
|
658 |
BIN_MSG="*$BIN_MSG*" |
|
659 |
REGRESSIONS=true |
|
660 |
else |
|
661 |
BIN_MSG=" $BIN_MSG " |
|
662 |
fi |
|
663 |
else |
|
664 |
BIN_MSG="($BIN_MSG)" |
|
665 |
DIFF_BIN= |
|
666 |
fi |
|
667 |
fi |
|
668 |
||
669 |
if [ -n "$STAT" ]; then |
|
670 |
THIS_SIZE=$($STAT $STAT_PRINT_SIZE "$THIS_FILE") |
|
671 |
OTHER_SIZE=$($STAT $STAT_PRINT_SIZE "$OTHER_FILE") |
|
672 |
else |
|
673 |
THIS_SIZE=$(ls -l "$THIS_FILE" | awk '{ print $5 }') |
|
674 |
OTHER_SIZE=$(ls -l "$OTHER_FILE" | awk '{ print $5 }') |
|
675 |
fi |
|
676 |
if [ $THIS_SIZE -ne $OTHER_SIZE ]; then |
|
677 |
DIFF_SIZE_NUM=$($EXPR $THIS_SIZE - $OTHER_SIZE) |
|
678 |
DIFF_SIZE_REL=$($EXPR $THIS_SIZE \* 100 / $OTHER_SIZE) |
|
679 |
SIZE_MSG=$($PRINTF "%3d%% %4d" $DIFF_SIZE_REL $DIFF_SIZE_NUM) |
|
14458 | 680 |
if [[ "$ACCEPTED_SMALL_SIZE_DIFF" = *"$BIN_FILE"* ]] && [ "$DIFF_SIZE_REL" -gt 98 ] \ |
28356 | 681 |
&& [ "$DIFF_SIZE_REL" -lt 102 ]; then |
14111 | 682 |
SIZE_MSG="($SIZE_MSG)" |
683 |
DIFF_SIZE= |
|
14458 | 684 |
elif [ "$OPENJDK_TARGET_OS" = "windows" ] \ |
28356 | 685 |
&& [[ "$ACCEPTED_SMALL_SIZE_DIFF" = *"$BIN_FILE"* ]] \ |
686 |
&& [ "$DIFF_SIZE_NUM" = 512 ]; then |
|
687 |
# On windows, size of binaries increase in 512 increments. |
|
14458 | 688 |
SIZE_MSG="($SIZE_MSG)" |
689 |
DIFF_SIZE= |
|
690 |
elif [ "$OPENJDK_TARGET_OS" = "windows" ] \ |
|
28356 | 691 |
&& [[ "$ACCEPTED_SMALL_SIZE_DIFF" = *"$BIN_FILE"* ]] \ |
692 |
&& [ "$DIFF_SIZE_NUM" = -512 ]; then |
|
693 |
# On windows, size of binaries increase in 512 increments. |
|
14111 | 694 |
SIZE_MSG="($SIZE_MSG)" |
695 |
DIFF_SIZE= |
|
696 |
else |
|
697 |
if [[ "$ACCEPTED_SIZE_DIFF" != *"$BIN_FILE"* ]]; then |
|
698 |
DIFF_SIZE=true |
|
699 |
if [[ "$KNOWN_SIZE_DIFF" != *"$BIN_FILE"* ]]; then |
|
700 |
SIZE_MSG="*$SIZE_MSG*" |
|
701 |
REGRESSIONS=true |
|
702 |
else |
|
703 |
SIZE_MSG=" $SIZE_MSG " |
|
704 |
fi |
|
705 |
else |
|
706 |
SIZE_MSG="($SIZE_MSG)" |
|
707 |
DIFF_SIZE= |
|
708 |
fi |
|
709 |
fi |
|
710 |
else |
|
711 |
SIZE_MSG=" " |
|
712 |
DIFF_SIZE= |
|
713 |
if [[ "$KNOWN_SIZE_DIFF $ACCEPTED_SIZE_DIFF" = *"$BIN_FILE"* ]]; then |
|
714 |
SIZE_MSG=" ! " |
|
715 |
fi |
|
716 |
fi |
|
717 |
||
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
718 |
if [ "$SORT_ALL_SYMBOLS" = "true" ] || [[ "$SORT_SYMBOLS" = *"$BIN_FILE"* ]]; then |
14111 | 719 |
SYM_SORT_CMD="sort" |
720 |
else |
|
721 |
SYM_SORT_CMD="cat" |
|
722 |
fi |
|
723 |
||
724 |
# Check symbols |
|
725 |
if [ "$OPENJDK_TARGET_OS" = "windows" ]; then |
|
726 |
# The output from dumpbin on windows differs depending on if the debug symbol |
|
727 |
# files are still around at the location the binary is pointing too. Need |
|
28356 | 728 |
# to filter out that extra information. |
729 |
$DUMPBIN -exports $OTHER_FILE | $GREP -E '^ +[0-9A-F]+ +[0-9A-F]+ [0-9A-F]+' | sed 's/ = .*//g' | cut -c27- | $SYM_SORT_CMD > $WORK_FILE_BASE.symbols.other |
|
730 |
$DUMPBIN -exports $THIS_FILE | $GREP -E '^ +[0-9A-F]+ +[0-9A-F]+ [0-9A-F]+' | sed 's/ = .*//g' | cut -c27- | $SYM_SORT_CMD > $WORK_FILE_BASE.symbols.this |
|
14111 | 731 |
elif [ "$OPENJDK_TARGET_OS" = "solaris" ]; then |
732 |
# Some symbols get seemingly random 15 character prefixes. Filter them out. |
|
733 |
$NM -a $ORIG_OTHER_FILE 2> /dev/null | $GREP -v $NAME | $AWK '{print $2, $3, $4, $5}' | $SED 's/^\([a-zA-Z] [\.\$]\)[a-zA-Z0-9_\$]\{15,15\}\./\1./g' | $SYM_SORT_CMD > $WORK_FILE_BASE.symbols.other |
|
28356 | 734 |
$NM -a $ORIG_THIS_FILE 2> /dev/null | $GREP -v $NAME | $AWK '{print $2, $3, $4, $5}' | $SED 's/^\([a-zA-Z] [\.\$]\)[a-zA-Z0-9_\$]\{15,15\}\./\1./g' | $SYM_SORT_CMD > $WORK_FILE_BASE.symbols.this |
14111 | 735 |
else |
28356 | 736 |
$NM -a $ORIG_OTHER_FILE 2> /dev/null | $GREP -v $NAME | $AWK '{print $2, $3, $4, $5}' | $SYM_SORT_CMD > $WORK_FILE_BASE.symbols.other |
737 |
$NM -a $ORIG_THIS_FILE 2> /dev/null | $GREP -v $NAME | $AWK '{print $2, $3, $4, $5}' | $SYM_SORT_CMD > $WORK_FILE_BASE.symbols.this |
|
14111 | 738 |
fi |
28356 | 739 |
|
20049 | 740 |
LC_ALL=C $DIFF $WORK_FILE_BASE.symbols.other $WORK_FILE_BASE.symbols.this > $WORK_FILE_BASE.symbols.diff |
14111 | 741 |
if [ -s $WORK_FILE_BASE.symbols.diff ]; then |
742 |
SYM_MSG=" diff " |
|
743 |
if [[ "$ACCEPTED_SYM_DIFF" != *"$BIN_FILE"* ]]; then |
|
744 |
DIFF_SYM=true |
|
745 |
if [[ "$KNOWN_SYM_DIFF" != *"$BIN_FILE"* ]]; then |
|
746 |
SYM_MSG="*$SYM_MSG*" |
|
747 |
REGRESSIONS=true |
|
748 |
else |
|
749 |
SYM_MSG=" $SYM_MSG " |
|
750 |
fi |
|
751 |
else |
|
28356 | 752 |
SYM_MSG="($SYM_MSG)" |
14111 | 753 |
DIFF_SYM= |
754 |
fi |
|
755 |
else |
|
756 |
SYM_MSG=" " |
|
757 |
DIFF_SYM= |
|
758 |
if [[ "$KNOWN_SYM_DIFF $ACCEPTED_SYM_DIFF" = *"$BIN_FILE"* ]]; then |
|
759 |
SYM_MSG=" ! " |
|
760 |
fi |
|
761 |
fi |
|
762 |
||
763 |
# Check dependencies |
|
764 |
if [ -n "$LDD_CMD" ]; then |
|
28356 | 765 |
(cd $FILE_WORK_DIR && $CP $OTHER_FILE . && $LDD_CMD $NAME 2>/dev/null | $AWK '{ print $1;}' | $SORT | $TEE $WORK_FILE_BASE.deps.other | $UNIQ > $WORK_FILE_BASE.deps.other.uniq) |
766 |
(cd $FILE_WORK_DIR && $CP $THIS_FILE . && $LDD_CMD $NAME 2</dev/null | $AWK '{ print $1;}' | $SORT | $TEE $WORK_FILE_BASE.deps.this | $UNIQ > $WORK_FILE_BASE.deps.this.uniq) |
|
767 |
(cd $FILE_WORK_DIR && $RM -f $NAME) |
|
768 |
||
769 |
LC_ALL=C $DIFF $WORK_FILE_BASE.deps.other $WORK_FILE_BASE.deps.this > $WORK_FILE_BASE.deps.diff |
|
770 |
LC_ALL=C $DIFF $WORK_FILE_BASE.deps.other.uniq $WORK_FILE_BASE.deps.this.uniq > $WORK_FILE_BASE.deps.diff.uniq |
|
771 |
||
772 |
if [ -s $WORK_FILE_BASE.deps.diff ]; then |
|
14111 | 773 |
if [ -s $WORK_FILE_BASE.deps.diff.uniq ]; then |
28356 | 774 |
DEP_MSG=" diff " |
14111 | 775 |
else |
28356 | 776 |
DEP_MSG=" redun " |
14111 | 777 |
fi |
778 |
if [[ "$ACCEPTED_DEP_DIFF" != *"$BIN_FILE"* ]]; then |
|
28356 | 779 |
DIFF_DEP=true |
780 |
if [[ "$KNOWN_DEP_DIFF" != *"$BIN_FILE"* ]]; then |
|
14111 | 781 |
DEP_MSG="*$DEP_MSG*" |
782 |
REGRESSIONS=true |
|
28356 | 783 |
else |
14111 | 784 |
DEP_MSG=" $DEP_MSG " |
28356 | 785 |
fi |
14111 | 786 |
else |
28356 | 787 |
DEP_MSG="($DEP_MSG)" |
788 |
DIFF_DEP= |
|
14111 | 789 |
fi |
28356 | 790 |
else |
791 |
DEP_MSG=" " |
|
792 |
DIFF_DEP= |
|
14111 | 793 |
if [[ "$KNOWN_DEP_DIFF $ACCEPTED_DEP_DIFF" = *"$BIN_FILE"* ]]; then |
794 |
DEP_MSG=" ! " |
|
795 |
fi |
|
28356 | 796 |
fi |
14111 | 797 |
else |
28356 | 798 |
DEP_MSG=" - " |
14111 | 799 |
fi |
28356 | 800 |
|
14111 | 801 |
# Compare fulldump output |
802 |
if [ -n "$FULLDUMP_CMD" ] && [ -z "$SKIP_FULLDUMP_DIFF" ]; then |
|
29157 | 803 |
if [ -z "$FULLDUMP_DIFF_FILTER" ]; then |
804 |
FULLDUMP_DIFF_FILTER="$CAT" |
|
805 |
fi |
|
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
806 |
$FULLDUMP_CMD $OTHER_FILE | eval "$FULLDUMP_DIFF_FILTER" \ |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
807 |
> $WORK_FILE_BASE.fulldump.other 2>&1 |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
808 |
$FULLDUMP_CMD $THIS_FILE | eval "$FULLDUMP_DIFF_FILTER" \ |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
809 |
> $WORK_FILE_BASE.fulldump.this 2>&1 |
29157 | 810 |
|
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
811 |
LC_ALL=C $DIFF $WORK_FILE_BASE.fulldump.other $WORK_FILE_BASE.fulldump.this \ |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
812 |
> $WORK_FILE_BASE.fulldump.diff |
28356 | 813 |
|
14111 | 814 |
if [ -s $WORK_FILE_BASE.fulldump.diff ]; then |
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
815 |
FULLDUMP_DIFF_SIZE=$(ls -n $WORK_FILE_BASE.fulldump.diff | awk '{print $5}') |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
816 |
FULLDUMP_MSG=$($PRINTF "%8d" $FULLDUMP_DIFF_SIZE) |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
817 |
if [[ "$ACCEPTED_FULLDUMP_DIFF" != *"$BIN_FILE"* ]]; then |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
818 |
DIFF_FULLDUMP=true |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
819 |
if [[ "$KNOWN_FULLDUMP_DIFF" != *"$BIN_FILE"* ]]; then |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
820 |
FULLDUMP_MSG="*$FULLDUMP_MSG*" |
14111 | 821 |
REGRESSIONS=true |
822 |
else |
|
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
823 |
FULLDUMP_MSG=" $FULLDUMP_MSG " |
14111 | 824 |
fi |
825 |
else |
|
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
826 |
FULLDUMP_MSG="($FULLDUMP_MSG)" |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
827 |
DIFF_FULLDUMP= |
14111 | 828 |
fi |
829 |
else |
|
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
830 |
FULLDUMP_MSG=" " |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
831 |
DIFF_FULLDUMP= |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
832 |
if [[ "$KNOWN_FULLDUMP_DIFF $ACCEPTED_FULLDUMP_DIFF" = *"$BIN_FILE"* ]]; then |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
833 |
FULLDUMP_MSG=" ! " |
14111 | 834 |
fi |
835 |
fi |
|
836 |
fi |
|
837 |
||
838 |
# Compare disassemble output |
|
839 |
if [ -n "$DIS_CMD" ] && [ -z "$SKIP_DIS_DIFF" ]; then |
|
28356 | 840 |
# By default we filter out differences that include references to symbols. |
841 |
# To get a raw diff with the complete disassembly, set |
|
842 |
# DIS_DIFF_FILTER="$CAT" |
|
843 |
if [ -z "$DIS_DIFF_FILTER" ]; then |
|
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
844 |
DIS_DIFF_FILTER="$GREP -v ' # .* <.*>$' | $SED -r -e 's/(\b|x)([0-9a-fA-F]+)(\b|:|>)/X/g'" |
28356 | 845 |
fi |
846 |
$DIS_CMD $OTHER_FILE | $GREP -v $NAME | eval "$DIS_DIFF_FILTER" > $WORK_FILE_BASE.dis.other 2>&1 |
|
847 |
$DIS_CMD $THIS_FILE | $GREP -v $NAME | eval "$DIS_DIFF_FILTER" > $WORK_FILE_BASE.dis.this 2>&1 |
|
848 |
||
20049 | 849 |
LC_ALL=C $DIFF $WORK_FILE_BASE.dis.other $WORK_FILE_BASE.dis.this > $WORK_FILE_BASE.dis.diff |
28356 | 850 |
|
14111 | 851 |
if [ -s $WORK_FILE_BASE.dis.diff ]; then |
852 |
DIS_DIFF_SIZE=$(ls -n $WORK_FILE_BASE.dis.diff | awk '{print $5}') |
|
853 |
DIS_MSG=$($PRINTF "%8d" $DIS_DIFF_SIZE) |
|
854 |
if [[ "$ACCEPTED_DIS_DIFF" != *"$BIN_FILE"* ]]; then |
|
855 |
DIFF_DIS=true |
|
856 |
if [[ "$KNOWN_DIS_DIFF" != *"$BIN_FILE"* ]]; then |
|
857 |
DIS_MSG="*$DIS_MSG*" |
|
858 |
REGRESSIONS=true |
|
859 |
else |
|
860 |
DIS_MSG=" $DIS_MSG " |
|
861 |
fi |
|
862 |
else |
|
863 |
DIS_MSG="($DIS_MSG)" |
|
864 |
DIFF_DIS= |
|
865 |
fi |
|
866 |
else |
|
867 |
DIS_MSG=" " |
|
868 |
DIFF_DIS= |
|
869 |
if [[ "$KNOWN_DEP_DIFF $ACCEPTED_DEP_DIFF" = *"$BIN_FILE"* ]]; then |
|
870 |
DIS_MSG=" ! " |
|
871 |
fi |
|
872 |
fi |
|
873 |
fi |
|
874 |
||
875 |
||
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
876 |
if [ -n "$DIFF_BIN$DIFF_SIZE$DIFF_SYM$DIFF_DEP$DIFF_FULLDUMP$DIFF_DIS" ] || [ -n "$VERBOSE" ]; then |
14111 | 877 |
if [ -n "$BIN_MSG" ]; then echo -n "$BIN_MSG:"; fi |
878 |
if [ -n "$SIZE_MSG" ]; then echo -n "$SIZE_MSG:"; fi |
|
879 |
if [ -n "$SYM_MSG" ]; then echo -n "$SYM_MSG:"; fi |
|
880 |
if [ -n "$DEP_MSG" ]; then echo -n "$DEP_MSG:"; fi |
|
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
881 |
if [ -n "$FULLDUMP_MSG" ]; then echo -n "$FULLDUMP_MSG:"; fi |
14111 | 882 |
if [ -n "$DIS_MSG" ]; then echo -n "$DIS_MSG:"; fi |
883 |
echo " $BIN_FILE" |
|
884 |
if [ "$SHOW_DIFFS" = "true" ]; then |
|
885 |
if [ -s "$WORK_FILE_BASE.symbols.diff" ]; then |
|
886 |
echo "Symbols diff:" |
|
887 |
$CAT $WORK_FILE_BASE.symbols.diff |
|
888 |
fi |
|
889 |
if [ -s "$WORK_FILE_BASE.deps.diff" ]; then |
|
890 |
echo "Deps diff:" |
|
891 |
$CAT $WORK_FILE_BASE.deps.diff |
|
892 |
fi |
|
893 |
if [ -s "$WORK_FILE_BASE.fulldump.diff" ]; then |
|
894 |
echo "Fulldump diff:" |
|
895 |
$CAT $WORK_FILE_BASE.fulldump.diff |
|
896 |
fi |
|
897 |
if [ -s "$WORK_FILE_BASE.dis.diff" ]; then |
|
898 |
echo "Disassembly diff:" |
|
899 |
$CAT $WORK_FILE_BASE.dis.diff |
|
900 |
fi |
|
901 |
fi |
|
902 |
return 1 |
|
903 |
fi |
|
904 |
return 0 |
|
905 |
} |
|
906 |
||
29157 | 907 |
################################################################################ |
14111 | 908 |
# Print binary diff header |
909 |
||
910 |
print_binary_diff_header() { |
|
911 |
if [ -z "$SKIP_BIN_DIFF" ]; then echo -n " Binary :"; fi |
|
912 |
if [ -z "$SKIP_SIZE_DIFF" ]; then echo -n " Size :"; fi |
|
913 |
if [ -z "$SKIP_SYM_DIFF" ]; then echo -n " Symbols :"; fi |
|
914 |
if [ -z "$SKIP_DEP_DIFF" ]; then echo -n " Deps :"; fi |
|
915 |
if [ -z "$SKIP_FULLDUMP_DIFF" ]; then echo -n " Fulldump :"; fi |
|
916 |
if [ -z "$SKIP_DIS_DIFF" ]; then echo -n " Disass :"; fi |
|
917 |
echo |
|
918 |
} |
|
919 |
||
29157 | 920 |
################################################################################ |
14111 | 921 |
# Compare all libraries |
922 |
||
923 |
compare_all_libs() { |
|
924 |
THIS_DIR=$1 |
|
925 |
OTHER_DIR=$2 |
|
926 |
WORK_DIR=$3 |
|
927 |
||
28356 | 928 |
LIBS=$(cd $THIS_DIR && $FIND . -type f \( -name 'lib*.so' -o -name '*.dylib' \ |
929 |
-o -name '*.dll' -o -name '*.obj' -o -name '*.o' \ |
|
930 |
-o -name '*.cpl' \) | $SORT | $FILTER) |
|
14111 | 931 |
|
932 |
if [ -n "$LIBS" ]; then |
|
933 |
echo Libraries... |
|
934 |
print_binary_diff_header |
|
935 |
for l in $LIBS; do |
|
936 |
if [ -f "$OTHER_DIR/$l" ]; then |
|
937 |
compare_bin_file $THIS_DIR $OTHER_DIR $WORK_DIR $l |
|
938 |
if [ "$?" != "0" ]; then |
|
939 |
return_value=1 |
|
940 |
fi |
|
941 |
fi |
|
942 |
done |
|
943 |
fi |
|
944 |
||
945 |
return $return_value |
|
946 |
} |
|
947 |
||
29157 | 948 |
################################################################################ |
14111 | 949 |
# Compare all executables |
950 |
||
951 |
compare_all_execs() { |
|
952 |
THIS_DIR=$1 |
|
953 |
OTHER_DIR=$2 |
|
954 |
WORK_DIR=$3 |
|
955 |
||
956 |
if [ "$OPENJDK_TARGET_OS" = "windows" ]; then |
|
957 |
EXECS=$(cd $THIS_DIR && $FIND . -type f -name '*.exe' | $SORT | $FILTER) |
|
958 |
else |
|
14280
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
959 |
EXECS=$(cd $THIS_DIR && $FIND . -name db -prune -o -type f -perm -100 \! \ |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
960 |
\( -name '*.so' -o -name '*.dylib' -o -name '*.dll' -o -name '*.cgi' \ |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
961 |
-o -name '*.jar' -o -name '*.diz' -o -name 'jcontrol' -o -name '*.properties' \ |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
962 |
-o -name '*.data' -o -name '*.bfc' -o -name '*.src' -o -name '*.txt' \ |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
963 |
-o -name '*.cfg' -o -name 'meta-index' -o -name '*.properties.ja' \ |
7d8ad47b2dbf
8002220: build-infra: update for mac, solaris 11 issues
erikj
parents:
14111
diff
changeset
|
964 |
-o -name 'classlist' \) | $SORT | $FILTER) |
14111 | 965 |
fi |
966 |
||
967 |
if [ -n "$EXECS" ]; then |
|
968 |
echo Executables... |
|
969 |
print_binary_diff_header |
|
970 |
for e in $EXECS; do |
|
971 |
if [ -f "$OTHER_DIR/$e" ]; then |
|
972 |
compare_bin_file $THIS_DIR $OTHER_DIR $WORK_DIR $e |
|
973 |
if [ "$?" != "0" ]; then |
|
974 |
return_value=1 |
|
975 |
fi |
|
976 |
fi |
|
977 |
done |
|
978 |
fi |
|
979 |
||
980 |
return $return_value |
|
981 |
} |
|
982 |
||
29157 | 983 |
################################################################################ |
14111 | 984 |
# Initiate configuration |
985 |
||
986 |
COMPARE_ROOT=/tmp/cimages.$USER |
|
987 |
$MKDIR -p $COMPARE_ROOT |
|
988 |
if [ "$OPENJDK_TARGET_OS" = "windows" ]; then |
|
989 |
if [ "$(uname -o)" = "Cygwin" ]; then |
|
28356 | 990 |
COMPARE_ROOT=$(cygpath -msa $COMPARE_ROOT) |
14111 | 991 |
fi |
992 |
fi |
|
993 |
||
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
994 |
THIS="$( cd "$( dirname "$0" )" > /dev/null && pwd )" |
14111 | 995 |
echo "$THIS" |
996 |
THIS_SCRIPT="$0" |
|
997 |
||
998 |
if [ -z "$1" ] || [ "$1" = "-h" ] || [ "$1" = "-?" ] || [ "$1" = "/h" ] || [ "$1" = "/?" ] || [ "$1" = "-help" ] || [ "$1" = "--help" ]; then |
|
999 |
echo "bash ./compare.sh [OPTIONS] [FILTER]" |
|
1000 |
echo "" |
|
1001 |
echo "-all Compare all files in all known ways" |
|
1002 |
echo "-names Compare the file names and directory structure" |
|
1003 |
echo "-perms Compare the permission bits on all files and directories" |
|
1004 |
echo "-types Compare the output of the file command on all files" |
|
1005 |
echo "-general Compare the files not convered by the specialized comparisons" |
|
1006 |
echo "-zips Compare the contents of all zip files" |
|
1007 |
echo "-jars Compare the contents of all jar files" |
|
1008 |
echo "-libs Compare all native libraries" |
|
1009 |
echo "-execs Compare all executables" |
|
1010 |
echo "-v Verbose output, does not hide known differences" |
|
1011 |
echo "-vv More verbose output, shows diff output of all comparisons" |
|
1012 |
echo "-o [OTHER] Compare with build in other directory. Will default to the old build directory" |
|
1013 |
echo "" |
|
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
1014 |
echo "--sort-symbols Sort all symbols before comparing" |
32811
df82db312e58
8135060: Stop building Xcode projects in install build
erikj
parents:
31310
diff
changeset
|
1015 |
echo "--strip Strip all binaries before comparing" |
df82db312e58
8135060: Stop building Xcode projects in install build
erikj
parents:
31310
diff
changeset
|
1016 |
echo "" |
14111 | 1017 |
echo "[FILTER] List filenames in the image to compare, works for jars, zips, libs and execs" |
1018 |
echo "Example:" |
|
1019 |
echo "bash ./common/bin/compareimages.sh CodePointIM.jar" |
|
15179
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1020 |
echo "" |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1021 |
echo "-2zips <file1> <file2> Compare two zip files only" |
25854 | 1022 |
echo "-2bins <file1> <file2> Compare two binary files only" |
1023 |
echo "-2dirs <dir1> <dir2> Compare two directories as if they were images" |
|
15179
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1024 |
echo "" |
14111 | 1025 |
exit 10 |
1026 |
fi |
|
1027 |
||
1028 |
CMP_NAMES=false |
|
1029 |
CMP_PERMS=false |
|
1030 |
CMP_TYPES=false |
|
1031 |
CMP_GENERAL=false |
|
1032 |
CMP_ZIPS=false |
|
1033 |
CMP_JARS=false |
|
1034 |
CMP_LIBS=false |
|
1035 |
CMP_EXECS=false |
|
1036 |
||
1037 |
while [ -n "$1" ]; do |
|
1038 |
case "$1" in |
|
1039 |
-v) |
|
1040 |
VERBOSE=true |
|
1041 |
;; |
|
1042 |
-vv) |
|
1043 |
VERBOSE=true |
|
1044 |
SHOW_DIFFS=true |
|
1045 |
;; |
|
1046 |
-o) |
|
1047 |
OTHER="$2" |
|
1048 |
shift |
|
1049 |
;; |
|
1050 |
-all) |
|
1051 |
CMP_NAMES=true |
|
1052 |
if [ "$OPENJDK_TARGET_OS" != "windows" ]; then |
|
1053 |
CMP_PERMS=true |
|
1054 |
fi |
|
1055 |
CMP_TYPES=true |
|
1056 |
CMP_GENERAL=true |
|
1057 |
CMP_ZIPS=true |
|
1058 |
CMP_JARS=true |
|
1059 |
CMP_LIBS=true |
|
1060 |
CMP_EXECS=true |
|
1061 |
;; |
|
1062 |
-names) |
|
1063 |
CMP_NAMES=true |
|
1064 |
;; |
|
1065 |
-perms) |
|
1066 |
CMP_PERMS=true |
|
1067 |
;; |
|
1068 |
-types) |
|
1069 |
CMP_TYPES=true |
|
1070 |
;; |
|
1071 |
-general) |
|
1072 |
CMP_GENERAL=true |
|
1073 |
;; |
|
1074 |
-zips) |
|
1075 |
CMP_ZIPS=true |
|
1076 |
;; |
|
1077 |
-jars) |
|
1078 |
CMP_JARS=true |
|
1079 |
;; |
|
1080 |
-libs) |
|
1081 |
CMP_LIBS=true |
|
1082 |
;; |
|
1083 |
-execs) |
|
1084 |
CMP_EXECS=true |
|
1085 |
;; |
|
25854 | 1086 |
-2dirs) |
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1087 |
THIS="$(cd "$2" > /dev/null && pwd )" |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1088 |
OTHER="$(cd "$3" > /dev/null && pwd )" |
25854 | 1089 |
THIS_BASE_DIR="$THIS" |
1090 |
OTHER_BASE_DIR="$OTHER" |
|
1091 |
SKIP_DEFAULT=true |
|
1092 |
shift |
|
1093 |
shift |
|
1094 |
;; |
|
15179
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1095 |
-2zips) |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1096 |
CMP_2_ZIPS=true |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1097 |
THIS_FILE=$2 |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1098 |
OTHER_FILE=$3 |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1099 |
shift |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1100 |
shift |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1101 |
;; |
25854 | 1102 |
-2bins) |
1103 |
CMP_2_BINS=true |
|
1104 |
THIS_FILE=$2 |
|
1105 |
OTHER_FILE=$3 |
|
1106 |
shift |
|
1107 |
shift |
|
1108 |
;; |
|
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
1109 |
--sort-symbols) |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
1110 |
SORT_ALL_SYMBOLS=true |
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
1111 |
;; |
32811
df82db312e58
8135060: Stop building Xcode projects in install build
erikj
parents:
31310
diff
changeset
|
1112 |
--strip) |
df82db312e58
8135060: Stop building Xcode projects in install build
erikj
parents:
31310
diff
changeset
|
1113 |
STRIP_ALL=true |
df82db312e58
8135060: Stop building Xcode projects in install build
erikj
parents:
31310
diff
changeset
|
1114 |
;; |
14111 | 1115 |
*) |
1116 |
CMP_NAMES=false |
|
1117 |
CMP_PERMS=false |
|
1118 |
CMP_TYPES=false |
|
1119 |
CMP_ZIPS=true |
|
1120 |
CMP_JARS=true |
|
1121 |
CMP_LIBS=true |
|
1122 |
CMP_EXECS=true |
|
28356 | 1123 |
|
14111 | 1124 |
if [ -z "$FILTER" ]; then |
1125 |
FILTER="$GREP" |
|
1126 |
fi |
|
1127 |
FILTER="$FILTER -e $1" |
|
1128 |
;; |
|
1129 |
esac |
|
1130 |
shift |
|
1131 |
done |
|
1132 |
||
15179
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1133 |
if [ "$CMP_2_ZIPS" = "true" ]; then |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1134 |
THIS_DIR="$(dirname $THIS_FILE)" |
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1135 |
THIS_DIR="$(cd "$THIS_DIR" > /dev/null && pwd )" |
15179
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1136 |
OTHER_DIR="$(dirname $OTHER_FILE)" |
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1137 |
OTHER_DIR="$(cd "$OTHER_DIR" > /dev/null && pwd )" |
15179
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1138 |
THIS_FILE_NAME="$(basename $THIS_FILE)" |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1139 |
OTHER_FILE_NAME="$(basename $OTHER_FILE)" |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1140 |
echo Comparing $THIS_DIR/$THIS_FILE_NAME and $OTHER_DIR/$OTHER_FILE_NAME |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1141 |
compare_zip_file $THIS_DIR $OTHER_DIR $COMPARE_ROOT/2zips $THIS_FILE_NAME $OTHER_FILE_NAME |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1142 |
exit |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1143 |
fi |
d5be3992e87e
8006663: build-infra: Compare two arbitrary zip/jar files with compare.sh
erikj
parents:
15068
diff
changeset
|
1144 |
|
25854 | 1145 |
if [ "$CMP_2_BINS" = "true" ]; then |
1146 |
THIS_DIR="$(dirname $THIS_FILE)" |
|
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1147 |
THIS_DIR="$(cd "$THIS_DIR" > /dev/null && pwd )" |
25854 | 1148 |
OTHER_DIR="$(dirname $OTHER_FILE)" |
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1149 |
OTHER_DIR="$(cd "$OTHER_DIR" > /dev/null && pwd )" |
25854 | 1150 |
THIS_FILE_NAME="$(basename $THIS_FILE)" |
1151 |
OTHER_FILE_NAME="$(basename $OTHER_FILE)" |
|
1152 |
echo Comparing $THIS_DIR/$THIS_FILE_NAME and $OTHER_DIR/$OTHER_FILE_NAME |
|
1153 |
compare_bin_file $THIS_DIR $OTHER_DIR $COMPARE_ROOT/2bins $THIS_FILE_NAME $OTHER_FILE_NAME |
|
1154 |
exit |
|
1155 |
fi |
|
1156 |
||
14111 | 1157 |
if [ "$CMP_NAMES" = "false" ] && [ "$CMP_TYPES" = "false" ] && [ "$CMP_PERMS" = "false" ] && [ "$CMP_GENERAL" = "false" ] && [ "$CMP_ZIPS" = "false" ] && [ "$CMP_JARS" = "false" ] && [ "$CMP_LIBS" = "false" ] && [ "$CMP_EXECS" = "false" ]; then |
1158 |
CMP_NAMES=true |
|
1159 |
CMP_PERMS=true |
|
1160 |
CMP_TYPES=true |
|
1161 |
CMP_GENERAL=true |
|
1162 |
CMP_ZIPS=true |
|
1163 |
CMP_JARS=true |
|
1164 |
CMP_LIBS=true |
|
1165 |
CMP_EXECS=true |
|
1166 |
fi |
|
1167 |
||
1168 |
if [ -z "$FILTER" ]; then |
|
1169 |
FILTER="$CAT" |
|
1170 |
fi |
|
1171 |
||
25854 | 1172 |
if [ "$SKIP_DEFAULT" != "true" ]; then |
1173 |
if [ -z "$OTHER" ]; then |
|
27595
cff167b3bfa2
8065914: Various improvements and cleanup of build system
ihse
parents:
25854
diff
changeset
|
1174 |
echo "Nothing to compare to, set with -o" |
cff167b3bfa2
8065914: Various improvements and cleanup of build system
ihse
parents:
25854
diff
changeset
|
1175 |
exit 1 |
25854 | 1176 |
else |
1177 |
if [ ! -d "$OTHER" ]; then |
|
1178 |
echo "Other build directory does not exist:" |
|
1179 |
echo "$OTHER" |
|
1180 |
exit 1 |
|
1181 |
fi |
|
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1182 |
OTHER="$( cd "$OTHER" > /dev/null && pwd )" |
25854 | 1183 |
echo "Comparing to:" |
14111 | 1184 |
echo "$OTHER" |
25854 | 1185 |
echo |
14111 | 1186 |
fi |
1187 |
||
1188 |
||
27595
cff167b3bfa2
8065914: Various improvements and cleanup of build system
ihse
parents:
25854
diff
changeset
|
1189 |
# Find the common images to compare, prioritizing later build stages |
27560 | 1190 |
if [ -d "$THIS/install/jdk" ] && [ -d "$OTHER/install/jdk" ]; then |
29157 | 1191 |
THIS_JDK="$THIS/install/jdk" |
1192 |
THIS_JRE="$THIS/install/jre" |
|
1193 |
OTHER_JDK="$OTHER/install/jdk" |
|
1194 |
OTHER_JRE="$OTHER/install/jre" |
|
27595
cff167b3bfa2
8065914: Various improvements and cleanup of build system
ihse
parents:
25854
diff
changeset
|
1195 |
echo "Selecting install images for compare" |
31310 | 1196 |
elif [ -d "$THIS/images/jdk" ] && [ -d "$OTHER/deploy/images/jdk" ]; then |
1197 |
THIS_JDK="$THIS/images/jdk" |
|
1198 |
THIS_JRE="$THIS/images/jre" |
|
1199 |
OTHER_JDK="$OTHER/deploy/images/jdk" |
|
1200 |
OTHER_JRE="$OTHER/deploy/images/jre" |
|
27595
cff167b3bfa2
8065914: Various improvements and cleanup of build system
ihse
parents:
25854
diff
changeset
|
1201 |
echo "Selecting deploy images for compare" |
27560 | 1202 |
elif [ -d "$THIS/images/jdk" ] && [ -d "$OTHER/images/jdk" ]; then |
29157 | 1203 |
THIS_JDK="$THIS/images/jdk" |
1204 |
THIS_JRE="$THIS/images/jre" |
|
1205 |
OTHER_JDK="$OTHER/images/jdk" |
|
1206 |
OTHER_JRE="$OTHER/images/jre" |
|
27595
cff167b3bfa2
8065914: Various improvements and cleanup of build system
ihse
parents:
25854
diff
changeset
|
1207 |
echo "Selecting jdk images for compare" |
cff167b3bfa2
8065914: Various improvements and cleanup of build system
ihse
parents:
25854
diff
changeset
|
1208 |
else |
28356 | 1209 |
echo "No common images found." |
1210 |
exit 1 |
|
14111 | 1211 |
fi |
31310 | 1212 |
echo " $THIS_JDK" |
1213 |
echo " $OTHER_JDK" |
|
14111 | 1214 |
|
31310 | 1215 |
if [ -d "$THIS/images/jdk-bundle" -o -d "$THIS/deploy/images/jdk-bundle" ] \ |
1216 |
&& [ -d "$OTHER/images/jdk-bundle" -o -d "$OTHER/deploy/images/jdk-bundle" ]; then |
|
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1217 |
if [ -d "$THIS/deploy/images/jdk-bundle" ]; then |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1218 |
THIS_JDK_BUNDLE="$THIS/deploy/images/jdk-bundle" |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1219 |
THIS_JRE_BUNDLE="$THIS/deploy/images/jre-bundle" |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1220 |
else |
31310 | 1221 |
THIS_JDK_BUNDLE="$THIS/images/jdk-bundle" |
1222 |
THIS_JRE_BUNDLE="$THIS/images/jre-bundle" |
|
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1223 |
fi |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1224 |
if [ -d "$OTHER/deploy/images/jdk-bundle" ]; then |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1225 |
OTHER_JDK_BUNDLE="$OTHER/deploy/images/jdk-bundle" |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1226 |
OTHER_JRE_BUNDLE="$OTHER/deploy/images/jre-bundle" |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1227 |
else |
31310 | 1228 |
OTHER_JDK_BUNDLE="$OTHER/images/jdk-bundle" |
1229 |
OTHER_JRE_BUNDLE="$OTHER/images/jre-bundle" |
|
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1230 |
fi |
32720
7e0e586a6817
8137014: Various improvements in build infrastructure
ihse
parents:
31310
diff
changeset
|
1231 |
echo "Also comparing jdk macosx bundles" |
31310 | 1232 |
echo " $THIS_JDK_BUNDLE" |
1233 |
echo " $OTHER_JDK_BUNDLE" |
|
27595
cff167b3bfa2
8065914: Various improvements and cleanup of build system
ihse
parents:
25854
diff
changeset
|
1234 |
fi |
cff167b3bfa2
8065914: Various improvements and cleanup of build system
ihse
parents:
25854
diff
changeset
|
1235 |
|
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1236 |
if [ -d "$THIS/deploy/bundles" -o -d "$THIS/deploy/images/bundles" ] \ |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1237 |
&& [ -d "$OTHER/deploy/bundles" -o -d "$OTHER/deploy/images/bundles" ]; then |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1238 |
if [ -d "$THIS/deploy/images/bundles" ]; then |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1239 |
THIS_DEPLOY_BUNDLE_DIR="$THIS/deploy/images/bundles" |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1240 |
else |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1241 |
THIS_DEPLOY_BUNDLE_DIR="$THIS/deploy/bundles" |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1242 |
fi |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1243 |
if [ -d "$OTHER/deploy/images/bundles" ]; then |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1244 |
OTHER_DEPLOY_BUNDLE_DIR="$OTHER/deploy/images/bundles" |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1245 |
else |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1246 |
OTHER_DEPLOY_BUNDLE_DIR="$OTHER/deploy/bundles" |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1247 |
fi |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1248 |
echo "Also comparing deploy javadoc bundles" |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1249 |
fi |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1250 |
|
31310 | 1251 |
if [ -d "$THIS/images/JavaAppletPlugin.plugin" ] \ |
1252 |
&& [ -d "$OTHER/images/JavaAppletPlugin.plugin" -o -d "$OTHER/deploy/images/JavaAppletPlugin.plugin" ]; then |
|
1253 |
if [ -d "$THIS/images/JavaAppletPlugin.plugin" ]; then |
|
1254 |
THIS_DEPLOY_APPLET_PLUGIN_DIR="$THIS/images/JavaAppletPlugin.plugin" |
|
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1255 |
else |
31310 | 1256 |
THIS_DEPLOY_APPLET_PLUGIN_DIR="$THIS/deploy/images/JavaAppletPlugin.plugin" |
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1257 |
fi |
31310 | 1258 |
if [ -d "$OTHER/images/JavaAppletPlugin.plugin" ]; then |
1259 |
OTHER_DEPLOY_APPLET_PLUGIN_DIR="$OTHER/images/JavaAppletPlugin.plugin" |
|
1260 |
else |
|
29158
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1261 |
OTHER_DEPLOY_APPLET_PLUGIN_DIR="$OTHER/deploy/images/JavaAppletPlugin.plugin" |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1262 |
fi |
5d46751992d9
8074055: Improvements in compare.sh from build-infra
ihse
parents:
29157
diff
changeset
|
1263 |
echo "Also comparing deploy applet image" |
31310 | 1264 |
echo " $THIS_DEPLOY_APPLET_PLUGIN_DIR" |
1265 |
echo " $OTHER_DEPLOY_APPLET_PLUGIN_DIR" |
|
28356 | 1266 |
fi |
1267 |
||
25854 | 1268 |
if [ -d "$OTHER/images" ]; then |
1269 |
OTHER_SEC_DIR="$OTHER/images" |
|
1270 |
else |
|
1271 |
OTHER_SEC_DIR="$OTHER/tmp" |
|
1272 |
fi |
|
1273 |
OTHER_SEC_BIN="$OTHER_SEC_DIR/sec-bin.zip" |
|
1274 |
THIS_SEC_DIR="$THIS/images" |
|
1275 |
THIS_SEC_BIN="$THIS_SEC_DIR/sec-bin.zip" |
|
1276 |
if [ "$OPENJDK_TARGET_OS" = "windows" ]; then |
|
1277 |
if [ "$OPENJDK_TARGET_CPU" = "x86_64" ]; then |
|
1278 |
JGSS_WINDOWS_BIN="jgss-windows-x64-bin.zip" |
|
1279 |
else |
|
1280 |
JGSS_WINDOWS_BIN="jgss-windows-i586-bin.zip" |
|
1281 |
fi |
|
1282 |
OTHER_SEC_WINDOWS_BIN="$OTHER_SEC_DIR/sec-windows-bin.zip" |
|
1283 |
OTHER_JGSS_WINDOWS_BIN="$OTHER_SEC_DIR/$JGSS_WINDOWS_BIN" |
|
1284 |
THIS_SEC_WINDOWS_BIN="$THIS_SEC_DIR/sec-windows-bin.zip" |
|
1285 |
THIS_JGSS_WINDOWS_BIN="$THIS_SEC_DIR/$JGSS_WINDOWS_BIN" |
|
1286 |
fi |
|
14466
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
1287 |
|
27595
cff167b3bfa2
8065914: Various improvements and cleanup of build system
ihse
parents:
25854
diff
changeset
|
1288 |
if [ -d "$THIS/docs" ] && [ -d "$OTHER/docs" ]; then |
25854 | 1289 |
THIS_DOCS="$THIS/docs" |
1290 |
OTHER_DOCS="$OTHER/docs" |
|
28356 | 1291 |
echo "Also comparing docs" |
27595
cff167b3bfa2
8065914: Various improvements and cleanup of build system
ihse
parents:
25854
diff
changeset
|
1292 |
else |
25854 | 1293 |
echo "WARNING! Docs haven't been built and won't be compared." |
1294 |
fi |
|
15063
16aa1979a584
8005723: build-infra: in new infra build, sec-windows-bin-zip and jgss-windows-*-bin.zip are missing
erikj
parents:
15062
diff
changeset
|
1295 |
fi |
15062 | 1296 |
|
29157 | 1297 |
################################################################################ |
14111 | 1298 |
# Do the work |
1299 |
||
1300 |
if [ "$CMP_NAMES" = "true" ]; then |
|
29157 | 1301 |
if [ -n "$THIS_JDK" ] && [ -n "$OTHER_JDK" ]; then |
1302 |
echo -n "JDK " |
|
1303 |
compare_dirs $THIS_JDK $OTHER_JDK $COMPARE_ROOT/jdk |
|
1304 |
echo -n "JRE " |
|
1305 |
compare_dirs $THIS_JRE $OTHER_JRE $COMPARE_ROOT/jre |
|
28356 | 1306 |
|
29157 | 1307 |
echo -n "JDK " |
1308 |
compare_files $THIS_JDK $OTHER_JDK $COMPARE_ROOT/jdk |
|
1309 |
echo -n "JRE " |
|
1310 |
compare_files $THIS_JRE $OTHER_JRE $COMPARE_ROOT/jre |
|
14111 | 1311 |
fi |
29157 | 1312 |
if [ -n "$THIS_JDK_BUNDLE" ] && [ -n "$OTHER_JDK_BUNDLE" ]; then |
1313 |
echo -n "JDK Bundle " |
|
1314 |
compare_dirs $THIS_JDK_BUNDLE $OTHER_JDK_BUNDLE $COMPARE_ROOT/jdk-bundle |
|
1315 |
echo -n "JRE Bundle " |
|
1316 |
compare_dirs $THIS_JRE_BUNDLE $OTHER_JRE_BUNDLE $COMPARE_ROOT/jre-bundle |
|
28356 | 1317 |
|
29157 | 1318 |
echo -n "JDK Bundle " |
1319 |
compare_files $THIS_JDK_BUNDLE $OTHER_JDK_BUNDLE $COMPARE_ROOT/jdk-bundle |
|
1320 |
echo -n "JRE Bundle " |
|
1321 |
compare_files $THIS_JRE_BUNDLE $OTHER_JRE_BUNDLE $COMPARE_ROOT/jre-bundle |
|
14111 | 1322 |
fi |
14466
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
1323 |
if [ -n "$THIS_DOCS" ] && [ -n "$OTHER_DOCS" ]; then |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
1324 |
echo -n "Docs " |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
1325 |
compare_dirs $THIS_DOCS $OTHER_DOCS $COMPARE_ROOT/docs |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
1326 |
echo -n "Docs " |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
1327 |
compare_files $THIS_DOCS $OTHER_DOCS $COMPARE_ROOT/docs |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
1328 |
fi |
25854 | 1329 |
if [ -n "$THIS_BASE_DIR" ] && [ -n "$OTHER_BASE_DIR" ]; then |
1330 |
compare_dirs $THIS_BASE_DIR $OTHER_BASE_DIR $COMPARE_ROOT/base_dir |
|
1331 |
compare_files $THIS_BASE_DIR $OTHER_BASE_DIR $COMPARE_ROOT/base_dir |
|
1332 |
fi |
|
28356 | 1333 |
if [ -n "$THIS_DEPLOY_APPLET_PLUGIN_DIR" ] && [ -n "$OTHER_DEPLOY_APPLET_PLUGIN_DIR" ]; then |
1334 |
echo -n "JavaAppletPlugin " |
|
1335 |
compare_dirs $THIS_DEPLOY_APPLET_PLUGIN_DIR $OTHER_DEPLOY_APPLET_PLUGIN_DIR $COMPARE_ROOT/plugin |
|
1336 |
echo -n "JavaAppletPlugin " |
|
1337 |
compare_files $THIS_DEPLOY_APPLET_PLUGIN_DIR $OTHER_DEPLOY_APPLET_PLUGIN_DIR $COMPARE_ROOT/plugin |
|
1338 |
fi |
|
14111 | 1339 |
fi |
1340 |
||
1341 |
if [ "$CMP_PERMS" = "true" ]; then |
|
29157 | 1342 |
if [ -n "$THIS_JDK" ] && [ -n "$OTHER_JDK" ]; then |
1343 |
echo -n "JDK " |
|
1344 |
compare_permissions $THIS_JDK $OTHER_JDK $COMPARE_ROOT/jdk |
|
1345 |
echo -n "JRE " |
|
1346 |
compare_permissions $THIS_JRE $OTHER_JRE $COMPARE_ROOT/jre |
|
14111 | 1347 |
fi |
25854 | 1348 |
if [ -n "$THIS_BASE_DIR" ] && [ -n "$OTHER_BASE_DIR" ]; then |
1349 |
compare_permissions $THIS_BASE_DIR $OTHER_BASE_DIR $COMPARE_ROOT/base_dir |
|
1350 |
fi |
|
28356 | 1351 |
if [ -n "$THIS_DEPLOY_APPLET_PLUGIN_DIR" ] && [ -n "$OTHER_DEPLOY_APPLET_PLUGIN_DIR" ]; then |
1352 |
echo -n "JavaAppletPlugin " |
|
1353 |
compare_permissions $THIS_DEPLOY_APPLET_PLUGIN_DIR $OTHER_DEPLOY_APPLET_PLUGIN_DIR $COMPARE_ROOT/plugin |
|
1354 |
fi |
|
14111 | 1355 |
fi |
1356 |
||
1357 |
if [ "$CMP_TYPES" = "true" ]; then |
|
29157 | 1358 |
if [ -n "$THIS_JDK" ] && [ -n "$OTHER_JDK" ]; then |
1359 |
echo -n "JDK " |
|
1360 |
compare_file_types $THIS_JDK $OTHER_JDK $COMPARE_ROOT/jdk |
|
1361 |
echo -n "JRE " |
|
1362 |
compare_file_types $THIS_JRE $OTHER_JRE $COMPARE_ROOT/jre |
|
14111 | 1363 |
fi |
29157 | 1364 |
if [ -n "$THIS_JDK_BUNDLE" ] && [ -n "$OTHER_JDK_BUNDLE" ]; then |
1365 |
echo -n "JDK Bundle " |
|
1366 |
compare_file_types $THIS_JDK_BUNDLE $OTHER_JDK_BUNDLE $COMPARE_ROOT/jdk-bundle |
|
1367 |
echo -n "JRE Bundle " |
|
1368 |
compare_file_types $THIS_JRE_BUNDLE $OTHER_JRE_BUNDLE $COMPARE_ROOT/jre-bundle |
|
14111 | 1369 |
fi |
25854 | 1370 |
if [ -n "$THIS_BASE_DIR" ] && [ -n "$OTHER_BASE_DIR" ]; then |
1371 |
compare_file_types $THIS_BASE_DIR $OTHER_BASE_DIR $COMPARE_ROOT/base_dir |
|
1372 |
fi |
|
28356 | 1373 |
if [ -n "$THIS_DEPLOY_APPLET_PLUGIN_DIR" ] && [ -n "$OTHER_DEPLOY_APPLET_PLUGIN_DIR" ]; then |
1374 |
echo -n "JavaAppletPlugin " |
|
1375 |
compare_file_types $THIS_DEPLOY_APPLET_PLUGIN_DIR $OTHER_DEPLOY_APPLET_PLUGIN_DIR $COMPARE_ROOT/plugin |
|
1376 |
fi |
|
14111 | 1377 |
fi |
1378 |
||
1379 |
if [ "$CMP_GENERAL" = "true" ]; then |
|
29157 | 1380 |
if [ -n "$THIS_JDK" ] && [ -n "$OTHER_JDK" ]; then |
1381 |
echo -n "JDK " |
|
1382 |
compare_general_files $THIS_JDK $OTHER_JDK $COMPARE_ROOT/jdk |
|
1383 |
echo -n "JRE " |
|
1384 |
compare_general_files $THIS_JRE $OTHER_JRE $COMPARE_ROOT/jre |
|
14111 | 1385 |
fi |
29157 | 1386 |
if [ -n "$THIS_JDK_BUNDLE" ] && [ -n "$OTHER_JDK_BUNDLE" ]; then |
1387 |
echo -n "JDK Bundle " |
|
1388 |
compare_general_files $THIS_JDK_BUNDLE $OTHER_JDK_BUNDLE $COMPARE_ROOT/jdk-bundle |
|
1389 |
echo -n "JRE Bundle " |
|
1390 |
compare_general_files $THIS_JRE_BUNDLE $OTHER_JRE_BUNDLE $COMPARE_ROOT/jre-bundle |
|
14111 | 1391 |
fi |
14466
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
1392 |
if [ -n "$THIS_DOCS" ] && [ -n "$OTHER_DOCS" ]; then |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
1393 |
echo -n "Docs " |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
1394 |
compare_general_files $THIS_DOCS $OTHER_DOCS $COMPARE_ROOT/docs |
2f85b948660b
8003844: build-infra: docs target isn't working properly
erikj
parents:
14458
diff
changeset
|
1395 |
fi |
25854 | 1396 |
if [ -n "$THIS_BASE_DIR" ] && [ -n "$OTHER_BASE_DIR" ]; then |
1397 |
compare_general_files $THIS_BASE_DIR $OTHER_BASE_DIR $COMPARE_ROOT/base_dir |
|
1398 |
fi |
|
28356 | 1399 |
if [ -n "$THIS_DEPLOY_APPLET_PLUGIN_DIR" ] && [ -n "$OTHER_DEPLOY_APPLET_PLUGIN_DIR" ]; then |
1400 |
echo -n "JavaAppletPlugin " |
|
1401 |
compare_general_files $THIS_DEPLOY_APPLET_PLUGIN_DIR $OTHER_DEPLOY_APPLET_PLUGIN_DIR $COMPARE_ROOT/plugin |
|
1402 |
fi |
|
14111 | 1403 |
fi |
1404 |
||
1405 |
if [ "$CMP_ZIPS" = "true" ]; then |
|
29157 | 1406 |
if [ -n "$THIS_JDK" ] && [ -n "$OTHER_JDK" ]; then |
1407 |
compare_all_zip_files $THIS_JDK $OTHER_JDK $COMPARE_ROOT/jdk |
|
14111 | 1408 |
fi |
15062 | 1409 |
if [ -n "$THIS_SEC_BIN" ] && [ -n "$OTHER_SEC_BIN" ]; then |
1410 |
if [ -n "$(echo $THIS_SEC_BIN | $FILTER)" ]; then |
|
1411 |
echo "sec-bin.zip..." |
|
15068
4f8e8dd6e6d5
8005858: build-infra: Add missed comparison of sec-windows-bin.zip and friends to compare.sh
erikj
parents:
15063
diff
changeset
|
1412 |
compare_zip_file $THIS_SEC_DIR $OTHER_SEC_DIR $COMPARE_ROOT/sec-bin sec-bin.zip |
4f8e8dd6e6d5
8005858: build-infra: Add missed comparison of sec-windows-bin.zip and friends to compare.sh
erikj
parents:
15063
diff
changeset
|
1413 |
fi |
4f8e8dd6e6d5
8005858: build-infra: Add missed comparison of sec-windows-bin.zip and friends to compare.sh
erikj
parents:
15063
diff
changeset
|
1414 |
fi |
4f8e8dd6e6d5
8005858: build-infra: Add missed comparison of sec-windows-bin.zip and friends to compare.sh
erikj
parents:
15063
diff
changeset
|
1415 |
if [ -n "$THIS_SEC_WINDOWS_BIN" ] && [ -n "$OTHER_SEC_WINDOWS_BIN" ]; then |
4f8e8dd6e6d5
8005858: build-infra: Add missed comparison of sec-windows-bin.zip and friends to compare.sh
erikj
parents:
15063
diff
changeset
|
1416 |
if [ -n "$(echo $THIS_SEC_WINDOWS_BIN | $FILTER)" ]; then |
4f8e8dd6e6d5
8005858: build-infra: Add missed comparison of sec-windows-bin.zip and friends to compare.sh
erikj
parents:
15063
diff
changeset
|
1417 |
echo "sec-windows-bin.zip..." |
4f8e8dd6e6d5
8005858: build-infra: Add missed comparison of sec-windows-bin.zip and friends to compare.sh
erikj
parents:
15063
diff
changeset
|
1418 |
compare_zip_file $THIS_SEC_DIR $OTHER_SEC_DIR $COMPARE_ROOT/sec-bin sec-windows-bin.zip |
4f8e8dd6e6d5
8005858: build-infra: Add missed comparison of sec-windows-bin.zip and friends to compare.sh
erikj
parents:
15063
diff
changeset
|
1419 |
fi |
4f8e8dd6e6d5
8005858: build-infra: Add missed comparison of sec-windows-bin.zip and friends to compare.sh
erikj
parents:
15063
diff
changeset
|
1420 |
fi |
4f8e8dd6e6d5
8005858: build-infra: Add missed comparison of sec-windows-bin.zip and friends to compare.sh
erikj
parents:
15063
diff
changeset
|
1421 |
if [ -n "$THIS_JGSS_WINDOWS_BIN" ] && [ -n "$OTHER_JGSS_WINDOWS_BIN" ]; then |
4f8e8dd6e6d5
8005858: build-infra: Add missed comparison of sec-windows-bin.zip and friends to compare.sh
erikj
parents:
15063
diff
changeset
|
1422 |
if [ -n "$(echo $THIS_JGSS_WINDOWS_BIN | $FILTER)" ]; then |
4f8e8dd6e6d5
8005858: build-infra: Add missed comparison of sec-windows-bin.zip and friends to compare.sh
erikj
parents:
15063
diff
changeset
|
1423 |
echo "$JGSS_WINDOWS_BIN..." |
4f8e8dd6e6d5
8005858: build-infra: Add missed comparison of sec-windows-bin.zip and friends to compare.sh
erikj
parents:
15063
diff
changeset
|
1424 |
compare_zip_file $THIS_SEC_DIR $OTHER_SEC_DIR $COMPARE_ROOT/sec-bin $JGSS_WINDOWS_BIN |
15062 | 1425 |
fi |
1426 |
fi |
|
25854 | 1427 |
if [ -n "$THIS_BASE_DIR" ] && [ -n "$OTHER_BASE_DIR" ]; then |
1428 |
compare_all_zip_files $THIS_BASE_DIR $OTHER_BASE_DIR $COMPARE_ROOT/base_dir |
|
1429 |
fi |
|
28356 | 1430 |
if [ -n "$THIS_DEPLOY_BUNDLE_DIR" ] && [ -n "$OTHER_DEPLOY_BUNDLE_DIR" ]; then |
1431 |
compare_all_zip_files $THIS_DEPLOY_BUNDLE_DIR $OTHER_DEPLOY_BUNDLE_DIR $COMPARE_ROOT/deploy-bundle |
|
1432 |
fi |
|
1433 |
if [ -n "$THIS_DEPLOY_APPLET_PLUGIN_DIR" ] && [ -n "$OTHER_DEPLOY_APPLET_PLUGIN_DIR" ]; then |
|
1434 |
compare_all_zip_files $THIS_DEPLOY_APPLET_PLUGIN_DIR $OTHER_DEPLOY_APPLET_PLUGIN_DIR $COMPARE_ROOT/plugin |
|
1435 |
fi |
|
14111 | 1436 |
fi |
1437 |
||
1438 |
if [ "$CMP_JARS" = "true" ]; then |
|
29157 | 1439 |
if [ -n "$THIS_JDK" ] && [ -n "$OTHER_JDK" ]; then |
1440 |
compare_all_jar_files $THIS_JDK $OTHER_JDK $COMPARE_ROOT/jdk |
|
14111 | 1441 |
fi |
25854 | 1442 |
if [ -n "$THIS_BASE_DIR" ] && [ -n "$OTHER_BASE_DIR" ]; then |
1443 |
compare_all_jar_files $THIS_BASE_DIR $OTHER_BASE_DIR $COMPARE_ROOT/base_dir |
|
1444 |
fi |
|
28356 | 1445 |
if [ -n "$THIS_DEPLOY_APPLET_PLUGIN_DIR" ] && [ -n "$OTHER_DEPLOY_APPLET_PLUGIN_DIR" ]; then |
1446 |
compare_all_jar_files $THIS_DEPLOY_APPLET_PLUGIN_DIR $OTHER_DEPLOY_APPLET_PLUGIN_DIR $COMPARE_ROOT/plugin |
|
1447 |
fi |
|
14111 | 1448 |
fi |
1449 |
||
1450 |
if [ "$CMP_LIBS" = "true" ]; then |
|
29157 | 1451 |
if [ -n "$THIS_JDK" ] && [ -n "$OTHER_JDK" ]; then |
1452 |
echo -n "JDK " |
|
1453 |
compare_all_libs $THIS_JDK $OTHER_JDK $COMPARE_ROOT/jdk |
|
14458 | 1454 |
if [ "$OPENJDK_TARGET_OS" = "macosx" ]; then |
29157 | 1455 |
echo -n "JRE " |
1456 |
compare_all_libs $THIS_JRE $OTHER_JRE $COMPARE_ROOT/jre |
|
14458 | 1457 |
fi |
14111 | 1458 |
fi |
25854 | 1459 |
if [ -n "$THIS_BASE_DIR" ] && [ -n "$OTHER_BASE_DIR" ]; then |
1460 |
compare_all_libs $THIS_BASE_DIR $OTHER_BASE_DIR $COMPARE_ROOT/base_dir |
|
1461 |
fi |
|
28356 | 1462 |
if [ -n "$THIS_DEPLOY_APPLET_PLUGIN_DIR" ] && [ -n "$OTHER_DEPLOY_APPLET_PLUGIN_DIR" ]; then |
1463 |
echo -n "JavaAppletPlugin " |
|
1464 |
compare_all_libs $THIS_DEPLOY_APPLET_PLUGIN_DIR $OTHER_DEPLOY_APPLET_PLUGIN_DIR $COMPARE_ROOT/plugin |
|
1465 |
fi |
|
14111 | 1466 |
fi |
1467 |
||
1468 |
if [ "$CMP_EXECS" = "true" ]; then |
|
29157 | 1469 |
if [ -n "$THIS_JDK" ] && [ -n "$OTHER_JDK" ]; then |
1470 |
compare_all_execs $THIS_JDK $OTHER_JDK $COMPARE_ROOT/jdk |
|
28356 | 1471 |
if [ "$OPENJDK_TARGET_OS" = "macosx" ]; then |
29157 | 1472 |
echo -n "JRE " |
1473 |
compare_all_execs $THIS_JRE $OTHER_JRE $COMPARE_ROOT/jre |
|
28356 | 1474 |
fi |
14111 | 1475 |
fi |
25854 | 1476 |
if [ -n "$THIS_BASE_DIR" ] && [ -n "$OTHER_BASE_DIR" ]; then |
1477 |
compare_all_execs $THIS_BASE_DIR $OTHER_BASE_DIR $COMPARE_ROOT/base_dir |
|
1478 |
fi |
|
28356 | 1479 |
if [ -n "$THIS_DEPLOY_APPLET_PLUGIN_DIR" ] && [ -n "$OTHER_DEPLOY_APPLET_PLUGIN_DIR" ]; then |
1480 |
echo -n "JavaAppletPlugin " |
|
1481 |
compare_all_execs $THIS_DEPLOY_APPLET_PLUGIN_DIR $OTHER_DEPLOY_APPLET_PLUGIN_DIR $COMPARE_ROOT/plugin |
|
1482 |
fi |
|
14111 | 1483 |
fi |
1484 |
||
1485 |
echo |
|
1486 |
||
1487 |
if [ -n "$REGRESSIONS" ]; then |
|
1488 |
echo "REGRESSIONS FOUND!" |
|
1489 |
echo |
|
1490 |
exit 1 |
|
1491 |
else |
|
1492 |
echo "No regressions found" |
|
1493 |
echo |
|
1494 |
exit 0 |
|
1495 |
fi |