This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
getting gnu as to check the current location
- From: Harvey Chapman <hchapman-binutils at 3gfp dot com>
- To: binutils at sourceware dot org
- Date: Tue, 13 Apr 2010 13:36:16 -0400
- Subject: getting gnu as to check the current location
Is it possible with gnu as to do something like this?
.if (. - _start1) < 0x100 || (. - _start1) > 0x1ff
.error "some_label must be between 0x100 and 0x1FF!"
.endif
some_label:
I'm trying to just let the label exist where it may, but if anyone adds/removes code that causes that condition to change, I'd like them to know about it at compile time.
Thanks,
Harvey