Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1 | # |
| 2 | # Makefile for the ia32 kernel emulation subsystem. |
| 3 | # |
| 4 | |
Christoph Hellwig | e6a6d2e | 2006-01-09 20:52:14 -0800 | [diff] [blame] | 5 | obj-$(CONFIG_IA32_EMULATION) := ia32entry.o sys_ia32.o ia32_signal.o tls32.o \ |
Andi Kleen | 8817210 | 2006-01-17 07:03:38 +0100 | [diff] [blame] | 6 | ia32_binfmt.o fpu32.o ptrace32.o syscall32.o syscall32_syscall.o \ |
| 7 | mmap32.o |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 8 | |
| 9 | sysv-$(CONFIG_SYSVIPC) := ipc32.o |
| 10 | obj-$(CONFIG_IA32_EMULATION) += $(sysv-y) |
| 11 | |
| 12 | obj-$(CONFIG_IA32_AOUT) += ia32_aout.o |
| 13 | |
Al Viro | b915543 | 2006-07-01 03:56:16 -0400 | [diff] [blame] | 14 | audit-class-$(CONFIG_AUDIT) := audit.o |
| 15 | obj-$(CONFIG_IA32_EMULATION) += $(audit-class-y) |
| 16 | |
Andreas Gruenbacher | 2275cfa | 2005-07-28 21:15:44 -0700 | [diff] [blame] | 17 | $(obj)/syscall32_syscall.o: \ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 18 | $(foreach F,sysenter syscall,$(obj)/vsyscall-$F.so) |
| 19 | |
| 20 | # Teach kbuild about targets |
| 21 | targets := $(foreach F,sysenter syscall,vsyscall-$F.o vsyscall-$F.so) |
| 22 | |
| 23 | # The DSO images are built using a special linker script |
| 24 | quiet_cmd_syscall = SYSCALL $@ |
| 25 | cmd_syscall = $(CC) -m32 -nostdlib -shared -s \ |
Roland McGrath | 0b0bf7a | 2006-07-30 03:04:06 -0700 | [diff] [blame] | 26 | $(call ld-option, -Wl$(comma)--hash-style=sysv) \ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 27 | -Wl,-soname=linux-gate.so.1 -o $@ \ |
| 28 | -Wl,-T,$(filter-out FORCE,$^) |
| 29 | |
| 30 | $(obj)/vsyscall-sysenter.so $(obj)/vsyscall-syscall.so: \ |
| 31 | $(obj)/vsyscall-%.so: $(src)/vsyscall.lds $(obj)/vsyscall-%.o FORCE |
| 32 | $(call if_changed,syscall) |
| 33 | |
Andi Kleen | ddbe3ee | 2006-04-22 02:35:57 -0700 | [diff] [blame] | 34 | AFLAGS_vsyscall-sysenter.o = -m32 -Wa,-32 |
| 35 | AFLAGS_vsyscall-syscall.o = -m32 -Wa,-32 |