kpatch-build: do not use -ffunction-sections for a patch module itself

-ffunction-sections and -fdata-sections are needed when building the
original and the patched kernels.

It is not necessary, however, to use these options when building a
patch module itself, its functions and data are OK in the sections they
are.

Let us remove these options from KCGLAGS after the kernels have been
built.
This commit is contained in:
Evgenii Shatokhin 2015-10-21 21:13:23 +03:00
parent 1cd59c6603
commit 7b9629fc0a

View File

@ -537,6 +537,8 @@ echo -n "Patched objects:"
for i in "${!objnames[@]}"; do echo -n " $(basename $i)"; done
echo
export KCFLAGS="-I$DATADIR/patch"
echo "Building patch module: kpatch-$PATCHNAME.ko"
cp "$OBJDIR/.config" "$SRCDIR"
cd "$SRCDIR"