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