Blame SOURCES/binutils-2.19.50.0.1-output-format.sed

38fe89
# Generate OUTPUT_FORMAT line for .so files from the system linker output.
38fe89
# Imported from glibc/Makerules.
38fe89
38fe89
/ld.*[ 	]-E[BL]/b f
38fe89
/collect.*[ 	]-E[BL]/b f
38fe89
/OUTPUT_FORMAT[^)]*$/{N
38fe89
s/\n[	 ]*/ /
38fe89
}
38fe89
t o
38fe89
: o
38fe89
s/^.*OUTPUT_FORMAT(\([^,]*\), \1, \1).*$/OUTPUT_FORMAT(\1)/
38fe89
t q
38fe89
s/^.*OUTPUT_FORMAT(\([^,]*\), \([^,]*\), \([^,]*\)).*$/\1,\2,\3/
38fe89
t s
38fe89
s/^.*OUTPUT_FORMAT(\([^,)]*\).*$)/OUTPUT_FORMAT(\1)/
38fe89
t q
38fe89
d
38fe89
: s
38fe89
s/"//g
38fe89
G
38fe89
s/\n//
38fe89
s/^\([^,]*\),\([^,]*\),\([^,]*\),B/OUTPUT_FORMAT(\2)/p
38fe89
s/^\([^,]*\),\([^,]*\),\([^,]*\),L/OUTPUT_FORMAT(\3)/p
38fe89
s/^\([^,]*\),\([^,]*\),\([^,]*\)/OUTPUT_FORMAT(\1)/p
38fe89
/,/s|^|*** BUG in libc/scripts/output-format.sed *** |p
38fe89
q
38fe89
: q
38fe89
s/"//g
38fe89
p
38fe89
q
38fe89
: f
38fe89
s/^.*[ 	]-E\([BL]\)[ 	].*$/,\1/
38fe89
t h
38fe89
s/^.*[ 	]-E\([BL]\)$/,\1/
38fe89
t h
38fe89
d
38fe89
: h
38fe89
h