FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.

» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > ArchLinux > ArchLinux Pacman Development

LinkBack Thread Tools
Old 07-16-2012, 04:38 AM
Allan McRae
Default build failu _FORTIFY_SOURCE requires compiling with optimization

On 16/07/12 08:31, Clemens Buchacher wrote:
> I am trying to build like this:
> ./autogen.sh
> ./configure --enable-debug --enable-git-version --prefix=$HOME/.local/pacman CFLAGS=-g
> And I get during make:
> In file included from /usr/include/stdlib.h:24:0,
> from add.c:21:
> /usr/include/features.h:330:4: error: #warning _FORTIFY_SOURCE requires compiling with optimization (-O) [-Werror=cpp]
> cc1: all warnings being treated as errors
> Autoconf checks if FORTIFY_SOURCE works, but it does so without -Werror
> which is later used for compiling:
> # configure.ac
> if test "x$debug" = "xyes" ; then
> WARNING_CFLAGS="-g -Wall -Werror"
> I attempted to fix this by considering WARNING_CFLAGS in
> GCC_FORTIFY_SOURCE_CC, but Autoconf is a mystery to me.
> In any case, it seems strange that _FORTIFY_SOURCE would be used only
> with debugging while the standard library warns about its use without
> optimization.

Ah... new warning introduced by glibc-2.16. I guess we all build with
-O2 by default until we run into an error that needs serious debugging.

Patch to follow.


Thread Tools

All times are GMT. The time now is 01:27 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org