mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-09-27 23:50:18 +02:00
Merge pull request #12778 from dezgeg/pr-kernel-module-strip
kernel: Let the kernel build system strip modules
This commit is contained in:
commit
cf5c8085b6
|
@ -129,6 +129,9 @@ let
|
||||||
mkdir -p $out/dtbs
|
mkdir -p $out/dtbs
|
||||||
cp $buildRoot/arch/$karch/boot/dts/*.dtb $out/dtbs
|
cp $buildRoot/arch/$karch/boot/dts/*.dtb $out/dtbs
|
||||||
'' else "") + (if isModular then ''
|
'' else "") + (if isModular then ''
|
||||||
|
if [ -z "$dontStrip" ]; then
|
||||||
|
installFlagsArray+=("INSTALL_MOD_STRIP=1")
|
||||||
|
fi
|
||||||
make modules_install $makeFlags "''${makeFlagsArray[@]}" \
|
make modules_install $makeFlags "''${makeFlagsArray[@]}" \
|
||||||
$installFlags "''${installFlagsArray[@]}"
|
$installFlags "''${installFlagsArray[@]}"
|
||||||
unlink $out/lib/modules/${modDirVersion}/build
|
unlink $out/lib/modules/${modDirVersion}/build
|
||||||
|
@ -190,9 +193,6 @@ let
|
||||||
# !!! This leaves references to gcc in $dev
|
# !!! This leaves references to gcc in $dev
|
||||||
# that we might be able to avoid
|
# that we might be able to avoid
|
||||||
postFixup = if isModular then ''
|
postFixup = if isModular then ''
|
||||||
if [ -z "$dontStrip" ]; then
|
|
||||||
find $out -name "*.ko" -print0 | xargs -0 -r ''${crossConfig+$crossConfig-}strip -S
|
|
||||||
fi
|
|
||||||
# !!! Should this be part of stdenv? Also patchELF should take an argument...
|
# !!! Should this be part of stdenv? Also patchELF should take an argument...
|
||||||
prefix=$dev
|
prefix=$dev
|
||||||
patchELF
|
patchELF
|
||||||
|
|
Loading…
Reference in a new issue