<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-11 10:47 PM, Keith Packard
wrote:<br>
</div>
<blockquote cite="mid:86ha852dr0.fsf@miki.keithp.com" type="cite">
<pre wrap="">Oh, right, I remember this from fontconfig -- ubuntu sets
_FORTIFY_SOURCE by default. I'd love to use this in the X server by
default, but I'm concerned that we'll end up breaking builds on ubuntu
if we unilaterally define it. Can you see what your build does with
$ make CC="gcc -D_FORTIFY_SOURCE=2"
</pre>
</blockquote>
First, I need to correct a mistake: the O/S is the unreleased 14-04
version. The 13-10 version contains gcc 4.8.1 and I wanted 4.8.2 for
the test. <br>
<br>
I need a clean build of the xserver module.<br>
<br>
On gcc 4.8.2, (Ubuntu 14-04) I get a complete clean build.<br>
On gcc 4.6.3 (Ubuntu 12-04), I get the following error in hw/vfb
when linking<br>
<blockquote>.<tt>./../Xext/.libs/libXext.a(xvmc.o): In function
`xf86XvMCRegisterDRInfo':</tt><tt><br>
</tt><tt>/home/nadon/xorg/src/xserver/Xext/xvmc.c:808: undefined
reference to `strlcpy'</tt><tt><br>
</tt><tt>/home/nadon/xorg/src/xserver/Xext/xvmc.c:809: undefined
reference to `strlcpy'</tt><tt><br>
</tt><tt>../../os/os.O: In function `siHostnameAddrMatch':</tt><tt><br>
</tt><tt>/home/nadon/xorg/src/xserver/os/access.c:1683: undefined
reference to `strlcpy'</tt><tt><br>
</tt><tt>../../os/os.O: In function `AuthAudit':</tt><tt><br>
</tt><tt>/home/nadon/xorg/src/xserver/os/connection.c:540:
undefined reference to `strlcpy'</tt><tt><br>
</tt><tt>/home/nadon/xorg/src/xserver/os/connection.c:559:
undefined reference to `strlcpy'</tt><tt><br>
</tt><tt>../../os/os.O:/home/nadon/xorg/src/xserver/os/log.c:870:
more undefined references to `strlcpy' follow</tt><tt><br>
</tt></blockquote>
<blockquote cite="mid:86ha852dr0.fsf@miki.keithp.com" type="cite">
<pre wrap="">
if it works, then we'd be find setting it for all gcc builds, otherwise
we'll need magic.</pre>
</blockquote>
It could be optional if we add this feature to the <tt>--enable-strict-compilation</tt>
we have on every module.<br>
<blockquote cite="mid:86ha852dr0.fsf@miki.keithp.com" type="cite">
<pre wrap="">Here's a patch which cleans up all of the -Wunused-result warnings I'm
getting with -D_FORTIFY_SOURCE=2. I haven't tried running this server...
</pre>
</blockquote>
The patch works as advertized. Too many code changes for me to give
a rb.<br>
I did manage to start X however.<br>
<br>
Tested-by: Gaetan Nadon <a class="moz-txt-link-rfc2396E" href="mailto:memsize@videotron.ca"><memsize@videotron.ca></a><br>
<br>
<br>
<br>
</body>
</html>