Prior to this commit, -module was not respected when the specified
output name happened to end with the platform's shared library
suffix. In addition, the logic for generating shared libraries
with -module in effect has been incomplete and partially also
incorrect.
The above internal interface is now doing the right thing, namely to
split the argument vector between object arguments and all other arguments,
then rejoin the arguments by placing object arguments first, and all other
arguments last.