Embedded Linux Training
Penguin and books
Free training materials and presentations!
Free Electrons button

The LXR Cross Referencer

source navigation ]
diff markup ]
identifier search ]
general search ]

Other LXR websites...
Architecture: i386 ] [ x86_64 ] [ arm ] [ avr32 ] [ blackfin ] [ m68k ] [ m68knommu ] [ mips ] [ ppc ] [ powerpc ] [ sh ] [ sparc ] [ um ]
Version: 2.4.35 ] [ 2.6.16.53 ] [ 2.6.17 ] [ 2.6.18 ] [ 2.6.19 ] [ 2.6.20 ] [ 2.6.21 ] [ 2.6.22 ] [ 2.6.23 ] [ 2.6.24 ] [ 2.6.25 ]

001 #
002 # Kbuild for top-level directory of the kernel
003 # This file takes care of the following:
004 # 1) Generate asm-offsets.h
005 # 2) Check for missing system calls
006 
007 #####
008 # 1) Generate asm-offsets.h
009 #
010 
011 offsets-file := include/asm-$(SRCARCH)/asm-offsets.h
012 
013 always  := $(offsets-file)
014 targets := $(offsets-file)
015 targets += arch/$(SRCARCH)/kernel/asm-offsets.s
016 clean-files := $(addprefix $(objtree)/,$(targets))
017 
018 # Default sed regexp - multiline due to syntax constraints
019 define sed-y
020         "/^->/{s:^->\([^ ]*\) [\$$#]*\([^ ]*\) \(.*\):#define \1 \2 /* \3 */:; s:->::; p;}"
021 endef
022 # Override default regexp for specific architectures
023 sed-$(CONFIG_MIPS) := "/^@@@/{s/^@@@//; s/ \#.*\$$//; p;}"
024 
025 quiet_cmd_offsets = GEN     $@
026 define cmd_offsets
027         (set -e; \
028          echo "#ifndef __ASM_OFFSETS_H__"; \
029          echo "#define __ASM_OFFSETS_H__"; \
030          echo "/*"; \
031          echo " * DO NOT MODIFY."; \
032          echo " *"; \
033          echo " * This file was generated by Kbuild"; \
034          echo " *"; \
035          echo " */"; \
036          echo ""; \
037          sed -ne $(sed-y) $<; \
038          echo ""; \
039          echo "#endif" ) > $@
040 endef
041 
042 # We use internal kbuild rules to avoid the "is up to date" message from make
043 arch/$(SRCARCH)/kernel/asm-offsets.s: arch/$(SRCARCH)/kernel/asm-offsets.c FORCE
044         $(Q)mkdir -p $(dir $@)
045         $(call if_changed_dep,cc_s_c)
046 
047 $(obj)/$(offsets-file): arch/$(SRCARCH)/kernel/asm-offsets.s Kbuild
048         $(Q)mkdir -p $(dir $@)
049         $(call cmd,offsets)
050 
051 #####
052 # 2) Check for missing system calls
053 #
054 
055 quiet_cmd_syscalls = CALL    $<
056       cmd_syscalls = $(CONFIG_SHELL) $< $(CC) $(c_flags)
057 
058 PHONY += missing-syscalls
059 missing-syscalls: scripts/checksyscalls.sh FORCE
060         $(call cmd,syscalls)

source navigation ] diff markup ] identifier search ] general search ]

This page was automatically generated by the LXR engine (cvs-20070828).
The LXR team
Valid HTML 4.01!