Bug 1300 - tc-arm.c:11073: warning: format '%08lX' expects type 'long unsigned int', but argument 4 has type 'offsetT'
Summary: tc-arm.c:11073: warning: format '%08lX' expects type 'long unsigned int', but...
Status: RESOLVED FIXED
Alias: None
Product: binutils
Classification: Unclassified
Component: gas (show other bugs)
Version: 2.17
: P2 normal
Target Milestone: ---
Assignee: unassigned
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-09-05 21:17 UTC by James Troup
Modified: 2005-12-27 11:55 UTC (History)
1 user (show)

See Also:
Host: arm-linux-gnu
Target: arm-linux-gnu
Build: arm-linux-gnu
Last reconfirmed:


Attachments
proposed patch (347 bytes, patch)
2005-12-07 04:49 UTC, James Troup
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description James Troup 2005-09-05 21:17:18 UTC
When compiling CVS HEAD 'all linux arches' enabled binutils on arm-linux-gnu, I
got the following error: 

gcc -DHAVE_CONFIG_H -I. -I../../gas -I. -D_GNU_SOURCE -I. -I../../gas -I../bfd
-I../../gas/config -I../../gas/../include -I../../gas/.. -I../../gas/../bfd
-I../../gas/../intl -I../intl -DLOCALEDIR="\"/usr/share/locale\""   -W -Wall
-Wstrict-prototypes -Wmissing-prototypes -Werror -g -O2 -c ../../gas/config/tc-arm.c
cc1: warnings being treated as errors
../../gas/config/tc-arm.c: In function 'md_apply_fix':
../../gas/config/tc-arm.c:11073: warning: format '%08lX' expects type 'long
unsigned int', but argument 4 has type 'offsetT'

This is gcc version: gcc (GCC) 4.0.2 20050821 (prerelease) (Debian 4.0.1-6)
running on Debian unstable.  NB: config/tc-arm.c compiled successfully when
compiling binutils targeted at arm-linux only.
Comment 1 James Troup 2005-12-07 04:49:44 UTC
Created attachment 780 [details]
proposed patch

This patch, by Lennert Buytenhek, is what we're using in Debian to work around
this problem.
Comment 2 Nick Clifton 2005-12-27 11:55:48 UTC
Patch approved and applied along with this ChangeLog entry.

gas/ChangeLog
2005-12-27  James Troup  <james@nocrew.org>

	PR 1300
	* config/tc-arm.c (md_apply_fix): Fix casts to match type in
	printf format.