]> git.ipfire.org Git - ipfire-2.x.git/commitdiff
kernel: remove old modules folder before kernel build
authorArne Fitzenreiter <arne_f@ipfire.org>
Tue, 30 Jul 2019 18:28:57 +0000 (18:28 +0000)
committerArne Fitzenreiter <arne_f@ipfire.org>
Tue, 30 Jul 2019 18:28:57 +0000 (18:28 +0000)
the build fails at creating source symlinks for external
modules build if it already exists.

Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
lfs/linux

index 4115a726774c830da1fb65ed5117a650f54ce226..47636ac84bd8e56bb3c14e9c563694e29195eea4 100644 (file)
--- a/lfs/linux
+++ b/lfs/linux
@@ -179,6 +179,9 @@ else
        cd $(DIR_APP) && make clean
        cd $(DIR_APP) && sed -i -e 's/EXTRAVERSION\ =.*/EXTRAVERSION\ =\ -$(VERSUFIX)/' Makefile
 
+       # Remove modules folder if exists
+       rm -rf /lib/modules/$(VER)-$(VERSUFIX)
+
        # Build the kernel
        cd $(DIR_APP) && make $(MAKETUNING) $(KERNEL_TARGET) modules