uses the first one it finds, so the order matters. its not unusual for programs to override certain library function by providing ther own version and putting them first in the object file list. this works only when the function you want to replace sits alone in his own object file (the smallest unit of linkage).
the kernel does link in some standard libc functions, but obviously not the ones attempting syscalls :) -- cinap