File tree Expand file tree Collapse file tree 1 file changed +11
-3
lines changed
Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -6,11 +6,19 @@ QLTEST_LOG="$CODEQL_EXTRACTOR_SWIFT_LOG_DIR"/qltest.log
66
77export LD_LIBRARY_PATH=" $CODEQL_EXTRACTOR_SWIFT_ROOT /tools/$CODEQL_PLATFORM "
88
9+ EXTRACTOR=" $CODEQL_EXTRACTOR_SWIFT_ROOT /tools/$CODEQL_PLATFORM /extractor"
10+ SDK=" $CODEQL_EXTRACTOR_SWIFT_ROOT /qltest/$CODEQL_PLATFORM /sdk"
11+
912for src in * .swift; do
10- opts=(-sdk " $CODEQL_EXTRACTOR_SWIFT_ROOT /qltest/ $CODEQL_PLATFORM /sdk " -c -primary-file $src )
13+ opts=(-sdk " $SDK " -c -primary-file " $src " )
1114 opts+=($( sed -n ' 1 s=//codeql-extractor-options:==p' $src ) )
1215 echo -e " calling extractor with flags: ${opts[@]} \n" >> $QLTEST_LOG
13- " $CODEQL_EXTRACTOR_SWIFT_ROOT /tools/$CODEQL_PLATFORM /extractor" " ${opts[@]} " >> $QLTEST_LOG 2>&1 || FAILED=1
16+ if ! " $EXTRACTOR " " ${opts[@]} " >> $QLTEST_LOG 2>&1 ; then
17+ FAILED=1
18+ fi
1419done
1520
16- [ -z " $FAILED " ] || cat " $QLTEST_LOG " # Show compiler errors on extraction failure
21+ if [ -n " $FAILED " ]; then
22+ cat " $QLTEST_LOG " # Show compiler errors on extraction failure
23+ exit 1
24+ fi
You can’t perform that action at this time.
0 commit comments