Commit db1bec4f authored by Sam Ravnborg's avatar Sam Ravnborg
Browse files

kbuild: install all headers when arch is changed



We see some header files that are selected dependent on
the actual architecture so force a reinstallation
of all header files when the arch changes.
This slows down "make headers_check_all" but then
we better reflect reality.

Signed-off-by: default avatarSam Ravnborg <sam@ravnborg.org>
parent 6b36ab27
Loading
Loading
Loading
Loading
+4 −3
Original line number Original line Diff line number Diff line
@@ -43,8 +43,9 @@ printdir = $(patsubst $(INSTALL_HDR_PATH)/%/,%,$(dir $@))


quiet_cmd_install = INSTALL $(printdir) ($(words $(all-files))\
quiet_cmd_install = INSTALL $(printdir) ($(words $(all-files))\
                            file$(if $(word 2, $(all-files)),s))
                            file$(if $(word 2, $(all-files)),s))
      cmd_install = $(PERL) $< $(srctree)/$(obj) $(install) $(header-y); \
      cmd_install = \
                    $(PERL) $< $(objtree)/$(obj) $(install) $(objhdr-y); \
        $(PERL) $< $(srctree)/$(obj) $(install) $(SRCARCH) $(header-y); \
        $(PERL) $< $(objtree)/$(obj) $(install) $(SRCARCH) $(objhdr-y); \
        touch $@
        touch $@


quiet_cmd_remove = REMOVE  $(unwanted)
quiet_cmd_remove = REMOVE  $(unwanted)
+8 −5
Original line number Original line Diff line number Diff line
@@ -3,9 +3,12 @@
# headers_install prepare the listed header files for use in
# headers_install prepare the listed header files for use in
# user space and copy the files to their destination.
# user space and copy the files to their destination.
#
#
# Usage: headers_install.pl odir installdir [files...]
# Usage: headers_install.pl readdir installdir arch [files...]
# odir:    dir to open files
# readdir:    dir to open files
# install: dir to install the files
# installdir: dir to install the files
# arch:       current architecture
#             arch is used to force a reinstallation when the arch
#             changes because kbuild then detect a command line change.
# files:      list of files to check
# files:      list of files to check
#
#
# Step in preparation for users space:
# Step in preparation for users space:
@@ -16,7 +19,7 @@
use strict;
use strict;
use warnings;
use warnings;


my ($readdir, $installdir, @files) = @ARGV;
my ($readdir, $installdir, $arch, @files) = @ARGV;


my $unifdef = "scripts/unifdef -U__KERNEL__";
my $unifdef = "scripts/unifdef -U__KERNEL__";