public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* [BUILDROBOT][PATCH] moxie: right-hand operand of comma expression has no effect
@ 2014-08-24 20:33 Jan-Benedict Glaw
  2014-08-26  7:47 ` Nicholas Clifton
  0 siblings, 1 reply; 2+ messages in thread
From: Jan-Benedict Glaw @ 2014-08-24 20:33 UTC (permalink / raw)
  To: binutils, Anthony Green

[-- Attachment #1: Type: text/plain, Size: 2896 bytes --]

Hi!

Building Binutils for moxie-elf with a somewhat recent GCC gives me
(cf.
http://toolchain.lug-owl.de/buildbot/show_build_details.php?id=346240):

 gcc -DHAVE_CONFIG_H -I. -I/home/vaxbuild/repos/binutils_gdb/gas  -I. -I/home/vaxbuild/repos/binutils_gdb/gas -I../bfd -I/home/vaxbuild/repos/binutils_gdb/gas/config -I/home/vaxbuild/repos/binutils_gdb/gas/../include -I/home/vaxbuild/repos/binutils_gdb/gas/.. -I/home/vaxbuild/repos/binutils_gdb/gas/../bfd -DLOCALEDIR="\"/home/vaxbuild/build/moxie-elf/_install_/share/locale\""  -W -Wall -Wstrict-prototypes -Wmissing-prototypes -Wshadow -Werror -g -O2 -MT write.o -MD -MP -MF .deps/write.Tpo -c -o write.o /home/vaxbuild/repos/binutils_gdb/gas/write.c
In file included from ./targ-cpu.h:1:0,
                 from /home/vaxbuild/repos/binutils_gdb/gas/config/obj-elf.h:39,
                 from ./obj-format.h:1,
                 from /home/vaxbuild/repos/binutils_gdb/gas/config/te-generic.h:36,
                 from ./targ-env.h:1,
                 from /home/vaxbuild/repos/binutils_gdb/gas/as.h:540,
                 from /home/vaxbuild/repos/binutils_gdb/gas/write.c:23:
/home/vaxbuild/repos/binutils_gdb/gas/write.c: In function ‘cvt_frag_to_fill’:
/home/vaxbuild/repos/binutils_gdb/gas/config/tc-moxie.h:37:76: error: right-hand operand of comma expression has no effect [-Werror=unused-value]
 #define md_convert_frag(B, S, F)            (as_fatal (_("convert_frag\n")), 0)
                                                                            ^
/home/vaxbuild/repos/binutils_gdb/gas/write.c:487:7: note: in expansion of macro ‘md_convert_frag’
       md_convert_frag (stdoutput, sec, fragP);
       ^
cc1: all warnings being treated as errors
Makefile:896: recipe for target 'write.o' failed
make[3]: *** [write.o] Error 1


This should cure it:


2014-08-24  Jan-Benedict Glaw  <jbglaw@lug-owl.de>

gas/
	* config/tc-moxie.h (md_convert_frag): Silence warning.

 
diff --git a/gas/config/tc-moxie.h b/gas/config/tc-moxie.h
index ed4f273..0a88813 100644
--- a/gas/config/tc-moxie.h
+++ b/gas/config/tc-moxie.h
@@ -34,7 +34,7 @@
 /* These macros must be defined, but is will be a fatal assembler
    error if we ever hit them.  */
 #define md_estimate_size_before_relax(A, B) (as_fatal (_("estimate size\n")), 0)
-#define md_convert_frag(B, S, F)            (as_fatal (_("convert_frag\n")), 0)
+#define md_convert_frag(B, S, F)            as_fatal (_("convert_frag\n"))
 
 /* If you define this macro, it should return the offset between the
    address of a PC relative fixup and the position from which the PC



Ok?

MfG, JBG

-- 
      Jan-Benedict Glaw      jbglaw@lug-owl.de              +49-172-7608481
Signature of:                     Eine Freie Meinung in einem Freien Kopf
the second  :                   für einen Freien Staat voll Freier Bürger.

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [BUILDROBOT][PATCH] moxie: right-hand operand of comma expression has no effect
  2014-08-24 20:33 [BUILDROBOT][PATCH] moxie: right-hand operand of comma expression has no effect Jan-Benedict Glaw
@ 2014-08-26  7:47 ` Nicholas Clifton
  0 siblings, 0 replies; 2+ messages in thread
From: Nicholas Clifton @ 2014-08-26  7:47 UTC (permalink / raw)
  To: Jan-Benedict Glaw, binutils, Anthony Green

Hi Jan-Benedict,

> 2014-08-24  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
>
> gas/
> 	* config/tc-moxie.h (md_convert_frag): Silence warning.

Approved - please apply.

Cheers
   Nick

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-08-26  7:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-24 20:33 [BUILDROBOT][PATCH] moxie: right-hand operand of comma expression has no effect Jan-Benedict Glaw
2014-08-26  7:47 ` Nicholas Clifton

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).