xref: /openbmc/linux/init/Makefile (revision 1da177e4)
1#
2# Makefile for the linux kernel.
3#
4
5obj-y				:= main.o version.o mounts.o initramfs.o
6obj-$(CONFIG_GENERIC_CALIBRATE_DELAY) += calibrate.o
7
8mounts-y			:= do_mounts.o
9mounts-$(CONFIG_DEVFS_FS)	+= do_mounts_devfs.o
10mounts-$(CONFIG_BLK_DEV_RAM)	+= do_mounts_rd.o
11mounts-$(CONFIG_BLK_DEV_INITRD)	+= do_mounts_initrd.o
12mounts-$(CONFIG_BLK_DEV_MD)	+= do_mounts_md.o
13
14# files to be removed upon make clean
15clean-files := ../include/linux/compile.h
16
17# dependencies on generated files need to be listed explicitly
18
19$(obj)/version.o: include/linux/compile.h
20
21# compile.h changes depending on hostname, generation number, etc,
22# so we regenerate it always.
23# mkcompile_h will make sure to only update the
24# actual file if its content has changed.
25
26include/linux/compile.h: FORCE
27	@echo '  CHK     $@'
28	@$(CONFIG_SHELL) $(srctree)/scripts/mkcompile_h $@ "$(UTS_MACHINE)" "$(CONFIG_SMP)" "$(CC) $(CFLAGS)"
29