Skip to content

Commit

Permalink
Merge tag 'kbuild-fixes-v6.10-4' of git://git.kernel.org/pub/scm/linu…
Browse files Browse the repository at this point in the history
…x/kernel/git/masahiroy/linux-kbuild

Pull Kbuild fixes from Masahiro Yamada:

 - Make scripts/ld-version.sh robust against the latest LLD

 - Fix warnings in rpm-pkg with device tree support

 - Fix warnings in fortify tests with KASAN

* tag 'kbuild-fixes-v6.10-4' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild:
  fortify: fix warnings in fortify tests with KASAN
  kbuild: rpm-pkg: avoid the warnings with dtb's listed twice
  kbuild: Make ld-version.sh more robust against version string changes
  • Loading branch information
torvalds committed Jul 14, 2024
2 parents 3653469 + 84679f0 commit 882ddcd
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
4 changes: 4 additions & 0 deletions lib/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -426,3 +426,7 @@ $(obj)/$(TEST_FORTIFY_LOG): $(addprefix $(obj)/, $(TEST_FORTIFY_LOGS)) FORCE
ifeq ($(CONFIG_FORTIFY_SOURCE),y)
$(obj)/string.o: $(obj)/$(TEST_FORTIFY_LOG)
endif

# Some architectures define __NO_FORTIFY if __SANITIZE_ADDRESS__ is undefined.
# Pass CFLAGS_KASAN to avoid warnings.
$(foreach x, $(patsubst %.log,%.o,$(TEST_FORTIFY_LOGS)), $(eval KASAN_SANITIZE_$(x) := y))
8 changes: 5 additions & 3 deletions scripts/ld-version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,11 @@ else
fi
fi

# Some distributions append a package release number, as in 2.34-4.fc32
# Trim the hyphen and any characters that follow.
version=${version%-*}
# There may be something after the version, such as a distribution's package
# release number (like Fedora's "2.34-4.fc32") or punctuation (like LLD briefly
# added before the "compatible with GNU linkers" string), so remove everything
# after just numbers and periods.
version=${version%%[!0-9.]*}

cversion=$(get_canonical_version $version)
min_cversion=$(get_canonical_version $min_version)
Expand Down
1 change: 0 additions & 1 deletion scripts/package/kernel.spec
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,6 @@ ln -fns /usr/src/kernels/%{KERNELRELEASE} %{buildroot}/lib/modules/%{KERNELRELEA
done

if [ -d "%{buildroot}/lib/modules/%{KERNELRELEASE}/dtb" ];then
echo "/lib/modules/%{KERNELRELEASE}/dtb"
find "%{buildroot}/lib/modules/%{KERNELRELEASE}/dtb" -printf "%%%ghost /boot/dtb-%{KERNELRELEASE}/%%P\n"
fi

Expand Down

0 comments on commit 882ddcd

Please sign in to comment.