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