Skip to content

Commit

Permalink
kbuild: do not try to build content of initramfs
Browse files Browse the repository at this point in the history
When a file supplied via CONFIG_INITRAMFS pointed to a file
for which kbuild had a rule to compile it (foo.c => foo.o)
then kbuild would compile the file before adding the
file to the initramfs.

Teach make that files included in initramfs shall not be updated by adding
an 'empty command'. (See "Using Empty Commands" in info make).

Signed-off-by: Sam Ravnborg <[email protected]>
  • Loading branch information
Sam Ravnborg committed Aug 7, 2006
1 parent 8ccf283 commit 58a2f7d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions usr/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@ quiet_cmd_initfs = GEN $@
cmd_initfs = $(initramfs) -o $@ $(ramfs-args) $(ramfs-input)

targets := initramfs_data.cpio.gz
# do not try to update files included in initramfs
$(deps_initramfs): ;

$(deps_initramfs): klibcdirs
# We rebuild initramfs_data.cpio.gz if:
# 1) Any included file is newer then initramfs_data.cpio.gz
Expand Down

0 comments on commit 58a2f7d

Please sign in to comment.