xref: /linux/kernel/Makefile (revision 8637c09901049f061b94f684915d4f18ecf91d79)
11da177e4SLinus Torvalds#
21da177e4SLinus Torvalds# Makefile for the linux kernel.
31da177e4SLinus Torvalds#
41da177e4SLinus Torvalds
51da177e4SLinus Torvaldsobj-y     = sched.o fork.o exec_domain.o panic.o printk.o profile.o \
61da177e4SLinus Torvalds	    exit.o itimer.o time.o softirq.o resource.o \
71da177e4SLinus Torvalds	    sysctl.o capability.o ptrace.o timer.o user.o \
81da177e4SLinus Torvalds	    signal.o sys.o kmod.o workqueue.o pid.o \
9fd279197SAdrian Bunk	    rcupdate.o extable.o params.o posix-timers.o \
10c0a31329SThomas Gleixner	    kthread.o wait.o kfifo.o sys_ni.o posix-cpu-timers.o mutex.o \
11c0a31329SThomas Gleixner	    hrtimer.o
121da177e4SLinus Torvalds
13*8637c099SIngo Molnarobj-$(CONFIG_STACKTRACE) += stacktrace.o
14ad596171Sjohn stultzobj-y += time/
15408894eeSIngo Molnarobj-$(CONFIG_DEBUG_MUTEXES) += mutex-debug.o
161da177e4SLinus Torvaldsobj-$(CONFIG_FUTEX) += futex.o
1734f192c6SIngo Molnarifeq ($(CONFIG_COMPAT),y)
1834f192c6SIngo Molnarobj-$(CONFIG_FUTEX) += futex_compat.o
1934f192c6SIngo Molnarendif
2023f78d4aSIngo Molnarobj-$(CONFIG_RT_MUTEXES) += rtmutex.o
21e7eebaf6SIngo Molnarobj-$(CONFIG_DEBUG_RT_MUTEXES) += rtmutex-debug.o
2261a87122SThomas Gleixnerobj-$(CONFIG_RT_MUTEX_TESTER) += rtmutex-tester.o
231da177e4SLinus Torvaldsobj-$(CONFIG_GENERIC_ISA_DMA) += dma.o
241da177e4SLinus Torvaldsobj-$(CONFIG_SMP) += cpu.o spinlock.o
25fb1c8f93SIngo Molnarobj-$(CONFIG_DEBUG_SPINLOCK) += spinlock.o
261da177e4SLinus Torvaldsobj-$(CONFIG_UID16) += uid16.o
271da177e4SLinus Torvaldsobj-$(CONFIG_MODULES) += module.o
281da177e4SLinus Torvaldsobj-$(CONFIG_KALLSYMS) += kallsyms.o
294552d5dcSJan Beulichobj-$(CONFIG_STACK_UNWIND) += unwind.o
301da177e4SLinus Torvaldsobj-$(CONFIG_PM) += power/
311da177e4SLinus Torvaldsobj-$(CONFIG_BSD_PROCESS_ACCT) += acct.o
32dc009d92SEric W. Biedermanobj-$(CONFIG_KEXEC) += kexec.o
331da177e4SLinus Torvaldsobj-$(CONFIG_COMPAT) += compat.o
341da177e4SLinus Torvaldsobj-$(CONFIG_CPUSETS) += cpuset.o
351da177e4SLinus Torvaldsobj-$(CONFIG_IKCONFIG) += configs.o
361da177e4SLinus Torvaldsobj-$(CONFIG_STOP_MACHINE) += stop_machine.o
37fe7752baSDavid Woodhouseobj-$(CONFIG_AUDIT) += audit.o auditfilter.o
381da177e4SLinus Torvaldsobj-$(CONFIG_AUDITSYSCALL) += auditsc.o
391da177e4SLinus Torvaldsobj-$(CONFIG_KPROBES) += kprobes.o
401da177e4SLinus Torvaldsobj-$(CONFIG_SYSFS) += ksysfs.o
418446f1d3SIngo Molnarobj-$(CONFIG_DETECT_SOFTLOCKUP) += softlockup.o
421da177e4SLinus Torvaldsobj-$(CONFIG_GENERIC_HARDIRQS) += irq/
431da177e4SLinus Torvaldsobj-$(CONFIG_SECCOMP) += seccomp.o
44a241ec65SPaul E. McKenneyobj-$(CONFIG_RCU_TORTURE_TEST) += rcutorture.o
45b86ff981SJens Axboeobj-$(CONFIG_RELAY) += relay.o
461da177e4SLinus Torvalds
477d12e522SAnton Blanchardifneq ($(CONFIG_SCHED_NO_NO_OMIT_FRAME_POINTER),y)
481da177e4SLinus Torvalds# According to Alan Modra <alan@linuxcare.com.au>, the -fno-omit-frame-pointer is
491da177e4SLinus Torvalds# needed for x86 only.  Why this used to be enabled for all architectures is beyond
501da177e4SLinus Torvalds# me.  I suspect most platforms don't need this, but until we know that for sure
511da177e4SLinus Torvalds# I turn this off for IA-64 only.  Andreas Schwab says it's also needed on m68k
521da177e4SLinus Torvalds# to get a correct value for the wait-channel (WCHAN in ps). --davidm
531da177e4SLinus TorvaldsCFLAGS_sched.o := $(PROFILING) -fno-omit-frame-pointer
541da177e4SLinus Torvaldsendif
551da177e4SLinus Torvalds
561da177e4SLinus Torvalds$(obj)/configs.o: $(obj)/config_data.h
571da177e4SLinus Torvalds
581da177e4SLinus Torvalds# config_data.h contains the same information as ikconfig.h but gzipped.
591da177e4SLinus Torvalds# Info from config_data can be extracted from /proc/config*
601da177e4SLinus Torvaldstargets += config_data.gz
611da177e4SLinus Torvalds$(obj)/config_data.gz: .config FORCE
621da177e4SLinus Torvalds	$(call if_changed,gzip)
631da177e4SLinus Torvalds
641da177e4SLinus Torvaldsquiet_cmd_ikconfiggz = IKCFG   $@
651da177e4SLinus Torvalds      cmd_ikconfiggz = (echo "static const char kernel_config_data[] = MAGIC_START"; cat $< | scripts/bin2c; echo "MAGIC_END;") > $@
661da177e4SLinus Torvaldstargets += config_data.h
671da177e4SLinus Torvalds$(obj)/config_data.h: $(obj)/config_data.gz FORCE
681da177e4SLinus Torvalds	$(call if_changed,ikconfiggz)
69