diff --git a/find-requires.ksyms b/find-requires.ksyms index eac4010..3a50a48 100644 --- a/find-requires.ksyms +++ b/find-requires.ksyms @@ -3,7 +3,7 @@ # This script is called during external module building to create dependencies # both upon the RHEL kernel, and on additional external modules. Symbols that # cannot be reconciled against those provided by the kernel are assumed to be -# provided by an external module and "ksym" replaces th regular "kernel" dep. +# provided by an external module and "ksym" replaces the regular "kernel" dep. IFS=$'\n' export LC_ALL=C @@ -174,21 +174,23 @@ if [ ${#modules[@]} -gt 0 ]; then { print $2 ":" $1 } ' \ | sed -r -e 's:$:\t'"$kernel"':' \ - | sort -k1,1 -u > $symvers + | sort -k1,1 -u > "$symvers" # Symbols matching with the kernel get a "kernel" dependency mod_req=$(mktemp -t mod_req.XXXXX) mod_requires "${modules[@]}" > "$mod_req" - join -t $'\t' -j 1 $symvers "$mod_req" | sort -u \ + join -t $'\t' -j 1 "$symvers" "$mod_req" | sort -u \ | awk 'BEGIN { FS = "[\t:]" ; OFS = "\t" } { print "kernel(" $1 ") = " $2 }' # Symbols from elsewhere get a "ksym" dependency - join -t $'\t' -j 1 -v 2 $symvers "$mod_req" | sort -u \ + join -t $'\t' -j 1 -v 2 "$symvers" "$mod_req" | sort -u \ | awk 'BEGIN { FS = "[\t:]" ; OFS = "\t" } { print "ksym(" $1 ") = " $2 }' # Check kABI if the kabi-stablelists package is installed # Do this last so we can try to output this error at the end - kabi_check_symbols=($(join -t $'\t' -j 1 $symvers "$mod_req" | sort -u \ + kabi_check_symbols=($(join -t $'\t' -j 1 "$symvers" "$mod_req" | sort -u \ | awk 'BEGIN { FS = "[\t:]" ; OFS = "\t" } { print $1 }')) check_kabi "${kabi_check_symbols[@]}" + + rm -f -- "$symvers" "$mod_req" fi