File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -90,11 +90,31 @@ if [[ ! -s "${TMP_DIR}/mysql_imports.txt" ]]; then
9090 exit 1
9191fi
9292
93- MISSING_COUNT=" $(
94- LC_ALL=C comm -23 " ${TMP_DIR} /mysql_imports.txt" " ${TMP_DIR} /mysql_exports.txt" \
95- | tee " ${TMP_DIR} /mysql_missing.txt" \
96- | wc -l
97- ) "
93+ LC_ALL=C comm -12 " ${TMP_DIR} /mysql_imports.txt" " ${TMP_DIR} /mysql_exports.txt" > " ${TMP_DIR} /mysql_exported_needed.txt"
94+ LC_ALL=C comm -23 " ${TMP_DIR} /mysql_imports.txt" " ${TMP_DIR} /mysql_exports.txt" > " ${TMP_DIR} /mysql_missing.txt"
95+
96+ IMPORT_COUNT=" $( wc -l < " ${TMP_DIR} /mysql_imports.txt" ) "
97+ EXPORTED_COUNT=" $( wc -l < " ${TMP_DIR} /mysql_exported_needed.txt" ) "
98+ MISSING_COUNT=" $( wc -l < " ${TMP_DIR} /mysql_missing.txt" ) "
99+
100+ echo " Plugin expects mysql_* symbols (${IMPORT_COUNT} ):"
101+ sed ' s/^/ - /' " ${TMP_DIR} /mysql_imports.txt"
102+ echo
103+ echo " libmariadb exports for expected symbols (${EXPORTED_COUNT} ):"
104+ if [[ " ${EXPORTED_COUNT} " -gt 0 ]]; then
105+ sed ' s/^/ - /' " ${TMP_DIR} /mysql_exported_needed.txt"
106+ else
107+ echo " (none)"
108+ fi
109+ echo
110+ echo " Per-symbol resolution:"
111+ awk '
112+ NR == FNR { exported[$0] = 1; next }
113+ {
114+ if (exported[$0]) print " OK " $0;
115+ else print " MISSING " $0;
116+ }
117+ ' " ${TMP_DIR} /mysql_exports.txt" " ${TMP_DIR} /mysql_imports.txt"
98118
99119if [[ " ${MISSING_COUNT} " -ne 0 ]]; then
100120 echo " ERROR: linked libmariadb is missing exported mysql_* symbols required by plugin:" >&2
You can’t perform that action at this time.
0 commit comments