home *** CD-ROM | disk | FTP | other *** search
/ PC Welt 2006 November (DVD) / PCWELT_11_2006.ISO / casper / filesystem.squashfs / usr / src / linux-headers-2.6.17-6 / arch / um / scripts / Makefile.rules
Encoding:
Makefile  |  2006-08-11  |  1.2 KB  |  33 lines

  1. # ===========================================================================
  2. # arch/um: Generic definitions
  3. # ===========================================================================
  4.  
  5. USER_SINGLE_OBJS := \
  6.     $(foreach f,$(patsubst %.o,%,$(obj-y) $(obj-m)),$($(f)-objs))
  7. USER_OBJS += $(filter %_user.o,$(obj-y) $(obj-m)  $(USER_SINGLE_OBJS))
  8. USER_OBJS := $(foreach file,$(USER_OBJS),$(obj)/$(file))
  9.  
  10. $(USER_OBJS:.o=.%): \
  11.     c_flags = -Wp,-MD,$(depfile) $(USER_CFLAGS) $(CFLAGS_$(*F).o)
  12. $(USER_OBJS) : CHECKFLAGS := -D__linux__ -Dlinux -D__STDC__ \
  13.     -Dunix -D__unix__ -D__$(SUBARCH)__
  14.  
  15. # These are like USER_OBJS but filter USER_CFLAGS through unprofile instead of
  16. # using it directly.
  17. UNPROFILE_OBJS := $(foreach file,$(UNPROFILE_OBJS),$(obj)/$(file))
  18.  
  19. $(UNPROFILE_OBJS:.o=.%): \
  20.     c_flags = -Wp,-MD,$(depfile) $(call unprofile,$(USER_CFLAGS)) $(CFLAGS_$(*F).o)
  21. $(UNPROFILE_OBJS) : CHECKFLAGS := -D__linux__ -Dlinux -D__STDC__ \
  22.     -Dunix -D__unix__ -D__$(SUBARCH)__
  23.  
  24. # The stubs and unmap.o can't try to call mcount or update basic block data
  25. define unprofile
  26.     $(patsubst -pg,,$(patsubst -fprofile-arcs -ftest-coverage,,$(1)))
  27. endef
  28.  
  29. ifdef subarch-obj-y
  30. obj-y += subarch.o
  31. subarch-y = $(addprefix ../../$(SUBARCH)/,$(subarch-obj-y))
  32. endif
  33.