diff options
author | Roland McGrath <roland@redhat.com> | 2008-01-30 07:30:40 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-01-30 07:30:40 -0500 |
commit | 5b93049337301d6fbd3cf55db99b34e6b0dbd3a3 (patch) | |
tree | 69e42bddac98aff8035f03a36fc88030a7f2a902 /arch/x86/vdso/Makefile | |
parent | c1d171a002942ea2d93b4fbd0c9583c56fce0772 (diff) |
x86 vDSO: generate vdso-syms.lds
This patch adds a new way of extracting symbols from the built vDSO image.
This is much simpler and less fragile than using ld -R; it removes the
need to control the DSO layout quite so exactly. I was clearly unduly
distracted by clever ld uses when I did the original vDSO implementation.
Signed-off-by: Roland McGrath <roland@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86/vdso/Makefile')
-rw-r--r-- | arch/x86/vdso/Makefile | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/arch/x86/vdso/Makefile b/arch/x86/vdso/Makefile index e7bff0fbac23..d8200adae9fa 100644 --- a/arch/x86/vdso/Makefile +++ b/arch/x86/vdso/Makefile | |||
@@ -55,6 +55,20 @@ SYSCFLAGS_vdso-syms.o = -r -d | |||
55 | $(obj)/vdso-syms.o: $(src)/vdso.lds $(vobjs) FORCE | 55 | $(obj)/vdso-syms.o: $(src)/vdso.lds $(vobjs) FORCE |
56 | $(call if_changed,syscall) | 56 | $(call if_changed,syscall) |
57 | 57 | ||
58 | targets += vdso-syms.lds | ||
59 | obj-y += vdso-syms.lds | ||
60 | |||
61 | # | ||
62 | # Match symbols in the DSO that look like VDSO*; produce a file of constants. | ||
63 | # | ||
64 | sed-vdsosym := -e 's/^00*/0/' \ | ||
65 | -e 's/^\([0-9a-fA-F]*\) . \(VDSO[a-zA-Z0-9_]*\)$$/\2 = 0x\1;/p' | ||
66 | quiet_cmd_vdsosym = VDSOSYM $@ | ||
67 | cmd_vdsosym = $(NM) $< | sed -n $(sed-vdsosym) | LC_ALL=C sort > $@ | ||
68 | |||
69 | $(obj)/%-syms.lds: $(obj)/%.so.dbg FORCE | ||
70 | $(call if_changed,vdsosym) | ||
71 | |||
58 | quiet_cmd_vdso_install = INSTALL $@ | 72 | quiet_cmd_vdso_install = INSTALL $@ |
59 | cmd_vdso_install = cp $(obj)/$@.dbg $(MODLIB)/vdso/$@ | 73 | cmd_vdso_install = cp $(obj)/$@.dbg $(MODLIB)/vdso/$@ |
60 | vdso.so: | 74 | vdso.so: |