CODE_END = $(shell printf '0x%x' $$($(READELF) -s $(TARGET_OUT_U1) | /usr/local/bin/gawk -F " " '/_flash_code_end/ {print $$2}'))
The above doesn't seem to output a number...printf doesn't like the hex output and I can't figure out how to tell it that its HEX.
I get
/bin/sh: line 0: printf: 4023cc1e: invalid number
Ultimately I want to take that and subtract off the 40200000 to get just the offset for end of code.