This is generated when compiling glibc using the Make utility.
In the glibc Makefile, there is a rule (started make install) that only echoes the necessary lines to some temporary file $@.new:
(echo '/* GNU ld script';\
echo ' Use the shared library, but some functions are only in';\
echo ' the static library, so try that secondarily. */';\
cat $<; \
echo 'GROUP ( $(slibdir)/libc.so$(libc.so-version)' \
'$(libdir)/$(patsubst %,$(libtype.oS),$(libprefix)$(libc-name))'\
' AS_NEEDED (' $(slibdir)/$(rtld-installed-name) ') )' \
) > $@.new
And then this file will be renamed to libc.so
mv -f $@.new $@
Here is a comment from the Makefile that explains a bit:
: libc.so.6 -, . , glibc - glibc - libc_nonshared.a. libc.so.6 libc_nonstared.a, script, ld- -lc (libc)
? :
$ objdump -t /usr/lib/libc_nonshared.a |grep " F "|grep -v __
00000000 g F .text 00000058 .hidden atexit
00000000 w F .text 00000050 .hidden stat
00000000 w F .text 00000050 .hidden fstat
00000000 w F .text 00000050 .hidden lstat
00000000 g F .text 00000050 .hidden stat64
00000000 g F .text 00000050 .hidden fstat64
00000000 g F .text 00000050 .hidden lstat64
00000000 g F .text 00000050 .hidden fstatat
00000000 g F .text 00000050 .hidden fstatat64
00000000 w F .text 00000058 .hidden mknod
00000000 g F .text 00000050 .hidden mknodat
00000000 l F .text 00000001 nop
atexit(), *stat*(), mknod. ? , glibc.
http://giraffe-data.com/~bryanh/giraffehome/d/note/proglib, :
The stat() family of functions and mknod() are special. Their
interfaces are tied so tightly to the underlying operating system that
they change occasionally.