Omit OUTPUT_FORMAT in the linker script if none was provided

Bernhard Fischer at
Wed Feb 6 11:18:11 UTC 2008

On Tue, Feb 05, 2008 at 03:06:34PM -0800, Chris Zankel wrote:
>I want to commit the following change, which is required for Xtensa. It
>doesn't affect architectures that do provide the OUTPUT_FORMAT(...) line
>in their linker script (as printed by 'gcc -Wl,--verbose')


>-OUTPUT_FORMAT = $(CC) $(CFLAGS) -Wl,--verbose 2>&1 | sed -n 's/^OUTPUT_FORMAT("\([^"]*\)",.*/\1/p'
+OUTPUT_FORMAT = $(CC) $(CFLAGS) -Wl,--verbose 2>&1 | sed -n 's/^OUTPUT_FORMAT("\([^"]*\)",.*/OUTPUT_FORMAT ( \1 )/p'

should do what you seem to want to achieve and is less bloated.

More information about the uClibc mailing list