May need to update avr-as [Was: [Solved] GAS: Register equates ?]
Erik Christiansen
dvalin@internode.on.net
Sat May 18 10:50:00 GMT 2013
Hi Jens,
Well, I tried:
On 18.05.13 11:16, Jens Bauer wrote:
> Unfortunately I have to do without info. I also have to do without
> apt-get; I have only PowerMacs (eg. no intel). ...But regarding
> register equates...
>
> On AVR, try... rColor=17 ...and you will see it does not work.
and maybe your avr-as is past its use-by date, since I have no errors
with:
rColor = 17
.global rColor
and it works:
$ nm obj/foo.elf | grep rC
00000011 A rColor
using:
$ avr-as --version
GNU assembler (GNU Binutils) 2.20
...
> In other words: *ANY* equate that starts with lowercase 'r' would not
> work for me, when I wrote some assembly-code for AVR.
I'll admit to having encountered that in the past, and assume that I
updated avr-as to cure it, since I don't recall having done anything
else.
> I ended up using the preprocessor #define instead (but I prefer to
> avoid the preprocessor now).
Yes, I did the same for many years, since there are then no mysterious
gcc interventions to fear. Now that my AVR coding is just a hobby, I'm
risking cpp, for the convenience of automatic tuning of the reams of SFR
addresses and bit numbers to the -mmcu=atmega...
I'll send a copy of "info gas" which you can read and search with your
favourite text editor. (And maybe we should move any more AVR stuff off
to the avr-chat or avr-gcc ML, where there's doubtless more interest in
the topic?)
møjn,
Erik
--
"Walking on water and developing software from a specification are easy
if both are frozen." - Edward V. Berard
More information about the Binutils
mailing list