<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">On 14-02-12 06:24 PM, Keith Packard
wrote:<br>
</div>
<blockquote cite="mid:867g8zzzhk.fsf@miki.keithp.com" type="cite">
<pre wrap="">So, we could simply add
#ifndef _FORTIFY_SOURCE
#define _FORTIFY_SOURCE 2
#endif
to some X server header file, or you could do something fancier with the
configure macros. I'm easy, but I definitely want it somehow <span class="moz-smiley-s1" title=":-)"><span>:-)</span></span> </pre>
</blockquote>
How about this for a start. If it works fine we can apply it to all
modules through util-macros where we can be a little fancier if need
be, like taking care of non GNU compilers.<br>
<blockquote><tt>diff --git a/configure.ac b/configure.ac</tt><tt><br>
</tt><tt>index 21a6591..66dd24f 100644</tt><tt><br>
</tt><tt>--- a/configure.ac</tt><tt><br>
</tt><tt>+++ b/configure.ac</tt><tt><br>
</tt><tt>@@ -85,7 +85,7 @@ XORG_PROG_RAWCPP</tt><tt><br>
</tt><tt> </tt><tt><br>
</tt><tt> # Quoted so that make will expand $(CWARNFLAGS) in
makefiles to allow</tt><tt><br>
</tt><tt> # easier overrides at build time.</tt><tt><br>
</tt><tt>-XSERVER_CFLAGS='$(CWARNFLAGS)'</tt><tt><br>
</tt><tt>+XSERVER_CFLAGS='$(CWARNFLAGS) -D_FORTIFY_SOURCE=2'</tt><tt><br>
</tt><tt> </tt><tt><br>
</tt><tt> dnl Explicitly add -fno-strict-aliasing since this
option should disappear</tt><tt><br>
</tt><tt> dnl from util-macros CWARNFLAGS</tt><tt><br>
</tt></blockquote>
</body>
</html>