This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH 10/15] Link a non-libc-using test with -fno-stack-protector.


From: Nick Alcock <nick.alcock@oracle.com>

This test cannot see __stack_chk_fail() because it is not linked with
libc at all.

v3: Use $(no-stack-protector).
v10: Drop a bunch of tests that don't need this option.

	* elf/Makefile (CFLAGS-filtmod1.c): Use $(no-stack-protector) for
	non-libc-linking testcase.
---
 elf/Makefile | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/elf/Makefile b/elf/Makefile
index daf0ebd..2c87a94 100644
--- a/elf/Makefile
+++ b/elf/Makefile
@@ -775,6 +775,9 @@ $(objpfx)filtmod1.so: $(objpfx)filtmod1.os $(objpfx)filtmod2.so
 		  $< -Wl,-F,$(objpfx)filtmod2.so
 $(objpfx)filter: $(objpfx)filtmod1.so
 
+# This does not link against libc.
+CFLAGS-filtmod1.c = $(no-stack-protector)
+
 $(objpfx)unload: $(libdl)
 $(objpfx)unload.out: $(objpfx)unloadmod.so
 
-- 
2.10.1.208.gbec66bc


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]