* cvs tracepoint.c build error @ 2010-01-16 14:40 Hui Zhu 2010-01-16 18:53 ` Stan Shebs 0 siblings, 1 reply; 4+ messages in thread From: Hui Zhu @ 2010-01-16 14:40 UTC (permalink / raw) To: gdb; +Cc: Stan Shebs What I got: gcc -g -I. -I../../src/gdb -I../../src/gdb/common -I../../src/gdb/config -DLOCALEDIR="\"/usr/local/share/locale\"" -DHAVE_CONFIG_H -I../../src/gdb/../include/opcode -I../../src/gdb/../readline/.. -I../bfd -I../../src/gdb/../bfd -I../../src/gdb/../include -I../libdecnumber -I../../src/gdb/../libdecnumber -I../../src/gdb/gnulib -Ignulib -DMI_OUT=1 -DTUI=1 -DGDBTK -Wall -Wdeclaration-after-statement -Wpointer-arith -Wformat-nonliteral -Wno-pointer-sign -Wno-unused -Wunused-value -Wno-switch -Wno-char-subscripts -Werror -c -o tracepoint.o -MT tracepoint.o -MMD -MP -MF .deps/tracepoint.Tpo ../../src/gdb/tracepoint.c cc1: warnings being treated as errors ../../src/gdb/tracepoint.c: In function 'trace_status_command': ../../src/gdb/tracepoint.c:1651: error: format '%d' expects type 'int', but argument 2 has type 'size_t' make[2]: *** [tracepoint.o] Error 1 make[2]: Leaving directory `/home/teawater/gdb/bgdbno/gdb' Thanks, Hui ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: cvs tracepoint.c build error 2010-01-16 14:40 cvs tracepoint.c build error Hui Zhu @ 2010-01-16 18:53 ` Stan Shebs 2010-01-16 22:07 ` Jan Kratochvil 0 siblings, 1 reply; 4+ messages in thread From: Stan Shebs @ 2010-01-16 18:53 UTC (permalink / raw) To: Hui Zhu; +Cc: gdb, Stan Shebs Hui Zhu wrote: > What I got: > gcc -g -I. -I../../src/gdb -I../../src/gdb/common > -I../../src/gdb/config -DLOCALEDIR="\"/usr/local/share/locale\"" > -DHAVE_CONFIG_H -I../../src/gdb/../include/opcode > -I../../src/gdb/../readline/.. -I../bfd -I../../src/gdb/../bfd > -I../../src/gdb/../include -I../libdecnumber > -I../../src/gdb/../libdecnumber -I../../src/gdb/gnulib -Ignulib > -DMI_OUT=1 -DTUI=1 -DGDBTK -Wall -Wdeclaration-after-statement > -Wpointer-arith -Wformat-nonliteral -Wno-pointer-sign -Wno-unused > -Wunused-value -Wno-switch -Wno-char-subscripts -Werror -c -o > tracepoint.o -MT tracepoint.o -MMD -MP -MF .deps/tracepoint.Tpo > ../../src/gdb/tracepoint.c > cc1: warnings being treated as errors > ../../src/gdb/tracepoint.c: In function 'trace_status_command': > ../../src/gdb/tracepoint.c:1651: error: format '%d' expects type > 'int', but argument 2 has type 'size_t' > make[2]: *** [tracepoint.o] Error 1 > make[2]: Leaving directory `/home/teawater/gdb/bgdbno/gdb' > Oops, sorry! In retrospect, size_t was a bad idea, this is our own code and we should use unsigned long long (large buffers with 32x64). Fix forthcoming. Stan ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: cvs tracepoint.c build error 2010-01-16 18:53 ` Stan Shebs @ 2010-01-16 22:07 ` Jan Kratochvil 2010-01-19 3:19 ` Hui Zhu 0 siblings, 1 reply; 4+ messages in thread From: Jan Kratochvil @ 2010-01-16 22:07 UTC (permalink / raw) To: Stan Shebs; +Cc: Hui Zhu, gdb On Sat, 16 Jan 2010 19:53:38 +0100, Stan Shebs wrote: > Oops, sorry! In retrospect, size_t was a bad idea, this is our own > code and we should use unsigned long long (large buffers with > 32x64). Fix forthcoming. With -Wp,-D_FORTIFY_SOURCE=1 -O1 (Fedora 12) I get also: tracepoint.c: In function ‘trace_save_command’: tracepoint.c:2392: error: ignoring return value of ‘fwrite’, declared with attribute warn_unused_result tracepoint.c:2476: error: ignoring return value of ‘fwrite’, declared with attribute warn_unused_result tracepoint.c:2481: error: ignoring return value of ‘fwrite’, declared with attribute warn_unused_result tracepoint.c: In function ‘tfile_open’: tracepoint.c:2826: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c:2847: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c: In function ‘tfile_get_traceframe_address’: tracepoint.c:3152: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c: In function ‘tfile_trace_find’: tracepoint.c:3184: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c:3188: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c: In function ‘tfile_fetch_registers’: tracepoint.c:3264: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c:3269: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c:3296: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c: In function ‘tfile_xfer_partial’: tracepoint.c:3333: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c:3342: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c:3343: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c:3346: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c: In function ‘tfile_get_trace_state_variable_value’: tracepoint.c:3380: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c:3390: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c:3395: error: ignoring return value of ‘read’, declared with attribute warn_unused_result tracepoint.c:3398: error: ignoring return value of ‘read’, declared with attribute warn_unused_result which IMO should be properly checked. Thanks, Jan ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: cvs tracepoint.c build error 2010-01-16 22:07 ` Jan Kratochvil @ 2010-01-19 3:19 ` Hui Zhu 0 siblings, 0 replies; 4+ messages in thread From: Hui Zhu @ 2010-01-19 3:19 UTC (permalink / raw) To: Stan Shebs; +Cc: gdb, Jan Kratochvil Cvs-head build is OK in my pc now. Thanks. Best regards, Hui 2010/1/17 Jan Kratochvil <jan.kratochvil@redhat.com>: > On Sat, 16 Jan 2010 19:53:38 +0100, Stan Shebs wrote: >> Oops, sorry! In retrospect, size_t was a bad idea, this is our own >> code and we should use unsigned long long (large buffers with >> 32x64). Fix forthcoming. > > With -Wp,-D_FORTIFY_SOURCE=1 -O1 (Fedora 12) I get also: > > tracepoint.c: In function ‘trace_save_command’: > tracepoint.c:2392: error: ignoring return value of ‘fwrite’, declared with attribute warn_unused_result > tracepoint.c:2476: error: ignoring return value of ‘fwrite’, declared with attribute warn_unused_result > tracepoint.c:2481: error: ignoring return value of ‘fwrite’, declared with attribute warn_unused_result > tracepoint.c: In function ‘tfile_open’: > tracepoint.c:2826: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c:2847: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c: In function ‘tfile_get_traceframe_address’: > tracepoint.c:3152: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c: In function ‘tfile_trace_find’: > tracepoint.c:3184: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c:3188: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c: In function ‘tfile_fetch_registers’: > tracepoint.c:3264: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c:3269: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c:3296: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c: In function ‘tfile_xfer_partial’: > tracepoint.c:3333: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c:3342: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c:3343: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c:3346: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c: In function ‘tfile_get_trace_state_variable_value’: > tracepoint.c:3380: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c:3390: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c:3395: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > tracepoint.c:3398: error: ignoring return value of ‘read’, declared with attribute warn_unused_result > > which IMO should be properly checked. > > > Thanks, > Jan > ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2010-01-19 3:19 UTC | newest] Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2010-01-16 14:40 cvs tracepoint.c build error Hui Zhu 2010-01-16 18:53 ` Stan Shebs 2010-01-16 22:07 ` Jan Kratochvil 2010-01-19 3:19 ` Hui Zhu
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox