]>
Commit | Line | Data |
---|---|---|
12788f63 MT |
1 | From e057a1b5930ec538c2b8abbba700a436ef2c81d5 Mon Sep 17 00:00:00 2001 |
2 | From: Joseph Myers <joseph@codesourcery.com> | |
3 | Date: Wed, 21 Sep 2011 13:27:50 -0700 | |
4 | Subject: [PATCH] Link libresolv.so with ld.so for __stack_chk_guard. | |
5 | ||
6 | --- | |
7 | resolv/Makefile | 8 +++++++- | |
8 | 1 files changed, 7 insertions(+), 1 deletions(-) | |
9 | ||
10 | diff --git a/resolv/Makefile b/resolv/Makefile | |
11 | index ec3788f..b4287de 100644 | |
12 | --- a/resolv/Makefile | |
13 | +++ b/resolv/Makefile | |
14 | @@ -1,4 +1,5 @@ | |
15 | -# Copyright (C) 1994-2001,2003,2004,2007,2008 Free Software Foundation, Inc. | |
16 | +# Copyright (C) 1994-2001,2003,2004,2007,2008,2011 | |
17 | +# Free Software Foundation, Inc. | |
18 | # This file is part of the GNU C Library. | |
19 | ||
20 | # The GNU C Library is free software; you can redistribute it and/or | |
21 | @@ -88,6 +89,11 @@ CFLAGS-res_hconf.c = -fexceptions | |
22 | # This ensures they will load libc.so for needed symbols if loaded by | |
23 | # a statically-linked program that hasn't already loaded it. | |
24 | $(objpfx)libresolv.so: $(common-objpfx)libc.so $(common-objpfx)libc_nonshared.a | |
25 | +# Some hosts need '__stack_chk_guard', so pull in the definition from | |
26 | +# ld.so if required. | |
27 | +ifeq (yesyes,$(have-ssp)$(elf)) | |
28 | +LDLIBS-resolv.so += $(as-needed) $(elfobjdir)/ld.so $(no-as-needed) | |
29 | +endif | |
30 | ||
31 | # The DNS NSS modules needs the resolver. | |
32 | $(objpfx)libnss_dns.so: $(objpfx)libresolv.so $(common-objpfx)libc.so \ | |
33 | -- | |
34 | 1.7.3.4 | |
35 |