Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automatically detecting compiler & linker used by kernel #298

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions dkms.in
Original file line number Diff line number Diff line change
Expand Up @@ -824,11 +824,11 @@ detect_toolchain_version() {
# $4 = patch version, optional
local -a filenames
if [[ "$4" ]]; then
filenames+=( "$1-$(printf "%d.%d.%d" "$2" "$3" "$4")" )
filenames+=( "$1-$((10#$2)).$((10#$3)).$((10#$4))" )
fi
filenames+=(
"$1-$(printf "%d.%d" "$2" "$3")"
"$1-$(printf "%d" "$2")"
"$1-$((10#$2)).$((10#$3))"
"$1-$((10#$2))"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please squash this with the respective commit and add an inline comment or two.
Something like "Zero extend (or zero prefix perhaps?) the respective versions to avoid issues like XXX being detected as YYY"

"$1"
)
for f in "${filenames[@]}"; do
Expand Down