You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@axis.apache.org by "S.Uthaiyashankar (JIRA)" <ji...@apache.org> on 2010/03/04 04:59:27 UTC

[jira] Commented: (AXIS2C-1362) Compile with -D_FORTIFY_SOURCE=2 results in warnings which fail build

    [ https://issues.apache.org/jira/browse/AXIS2C-1362?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12841047#action_12841047 ] 

S.Uthaiyashankar commented on AXIS2C-1362:
------------------------------------------

I could not recreate above warnings. However, there was one warning in util/test/util/test_util.c, which I fixed in revision 918839

> Compile with -D_FORTIFY_SOURCE=2 results in warnings which fail build
> ---------------------------------------------------------------------
>
>                 Key: AXIS2C-1362
>                 URL: https://issues.apache.org/jira/browse/AXIS2C-1362
>             Project: Axis2-C
>          Issue Type: Bug
>          Components: build system (Unix/Linux)
>         Environment: Configure command:
> CLASSPATH="" CFLAGS="-O2 -g -D_FORTIFY_SOURCE=2 -fstack-protector" CXXFLAGS="-O2 -g -D_FORTIFY_SOURCE=2 -fstack-protector " CPPFLAGS="" LDFLAGS="-g -O1 " CC=gcc CXX=g++  ./configure --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib64 --libexecdir=/usr/libexec --localstatedir=/var --sharedstatedir=/usr/com --mandir=/usr/share/man --infodir=/usr/share/info 
>            Reporter: Adam Chasen
>            Assignee: S.Uthaiyashankar
>            Priority: Minor
>             Fix For: 1.7.0
>
>
> There are warnings (which are treated as errors due to -Werror) which fail the build in:
> /bin/sh ../libtool --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I. -I.. -I../include    -O2 -g -D_FORTIFY_SOURCE=2 -fstack-protector -D_LARGEFILE64_SOURCE -ansi -Wall -Werror -Wno-implicit-function-declaration -D_GNU_SOURCE  -MT dir_handler.lo -MD -MP -MF .deps/dir_handler.Tpo -c -o dir_handler.lo dir_handler.c
>  gcc -DHAVE_CONFIG_H -I. -I.. -I../include -O2 -g -D_FORTIFY_SOURCE=2 -fstack-protector -D_LARGEFILE64_SOURCE -ansi -Wall -Werror -Wno-implicit-function-declaration -D_GNU_SOURCE -MT dir_handler.lo -MD -MP -MF .deps/dir_handler.Tpo -c dir_handler.c  -fPIC -DPIC -o .libs/dir_handler.o
> cc1: warnings being treated as errors
> dir_handler.c: In function 'axutil_dir_handler_list_service_or_module_dirs':
> dir_handler.c:207: warning: ignoring return value of 'chdir', declared with attribute warn_unused_result
> dir_handler.c:213: warning: ignoring return value of 'chdir', declared with attribute warn_unused_result
> There may be other errors in util dir, I removed -Werror from configure in ./util to continue build
> make[3]: Entering directory `/tmp/rmake/builds/axis2c/axis2c-src-1.5.0/tools/tcpmon/src'
> gcc -DHAVE_CONFIG_H -I. -I../../.. -I../../../include -I ../../../util/include -I ../../../axiom/include -I ../../../include -I ../include  -D_LARGEFILE64_SOURCE -DAXIS2_GUTHTHILA_ENABLED -DAXIS2_SVR_MULTI_THREADED  -O2 -g -D_FORTIFY_SOURCE=2 -fstack-protector -D_LARGEFILE64_SOURCE -ansi -Wall -Werror -Wno-implicit-function-declaration -g -D_GNU_SOURCE -DAXIS2_GUTHTHILA_ENABLED -DAXIS2_SVR_MULTI_THREADED -MT tcpmon.o -MD -MP -MF .deps/tcpmon.Tpo -c -o tcpmon.o tcpmon.c
> cc1: warnings being treated as errors
> tcpmon.c: In function 'resend_request':
> tcpmon.c:658: warning: ignoring return value of 'fread', declared with attribute warn_unused_result
> There may be other errors , I removed -Werror from the configure in ./ to continue build

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: c-dev-unsubscribe@axis.apache.org
For additional commands, e-mail: c-dev-help@axis.apache.org