avr-libc-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-libc-dev] Possible hole in the assembler interrupt documentatio


From: Joerg Wunsch
Subject: Re: [avr-libc-dev] Possible hole in the assembler interrupt documentation
Date: Thu, 1 Nov 2012 17:25:33 +0100
User-agent: Mutt/1.5.20 (2009-06-14)

As Dale wrote:

> The issue then is the case of a library that contains an ISR.

That's correct.  In this case, you have to cause an explicit undefined
reference to it, in order to make the linker even consider pulling the
library module.  In addition to placing another (referenced) symbol
into the same module, this might be done using the -u linker option:
suppose, my __vector_8 function where placed in a library, the
respective (compiler) commandline switch would be "-Wl,-u,__vector_8".
This makes the symbol "__vector_8" a "global undefined" straight from
the beginning, so pulling the library module in satisfies that
reference to the linker.

However, I think putting ISRs in libraries is a rarely used feature,
so I'm not sure the avr-libc documentation would really be a good
place for it.  Well, if someone crafted a FAQ entry, this might be an
idea.
-- 
cheers, J"org               .-.-.   --... ...--   -.. .  DL8DTL

http://www.sax.de/~joerg/                        NIC: JW11-RIPE
Never trust an operating system you don't have sources for. ;-)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]