This stack check implementation leverages the compiler's profiling (gcc -p)
[linux-2.6.git] / arch / um / kernel / skas / Makefile
1
2 # Copyright (C) 2002 Jeff Dike (jdike@karaya.com)
3 # Licensed under the GPL
4 #
5
6 obj-y = exec_kern.o exec_user.o mem.o mem_user.o mmu.o process.o \
7         process_kern.o syscall_kern.o syscall_user.o time.o tlb.o trap_user.o \
8         uaccess.o sys-$(SUBARCH)/
9
10 host-progs      := util/mk_ptregs
11 clean-files     := include/skas_ptregs.h
12
13 USER_OBJS = $(filter %_user.o,$(obj-y)) process.o time.o
14 USER_OBJS := $(foreach file,$(USER_OBJS),$(obj)/$(file))
15
16 $(TOPDIR)/arch/um/include/skas_ptregs.h : $(src)/util/mk_ptregs
17         @echo -n '  Generating $@'
18         @$< > $@.tmp
19         @if [ -r $@ ] && cmp -s $@ $@.tmp; then \
20                 echo ' (unchanged)'; \
21                 rm -f $@.tmp; \
22         else \
23                 echo ' (updated)'; \
24                 mv -f $@.tmp $@; \
25         fi
26
27 $(USER_OBJS) : %.o: %.c
28         $(CC) $(CFLAGS_$(notdir $@)) $(USER_CFLAGS) -c -o $@ $<