Can you show the complete linkingcommand? There should be some objectfiles , that are linked to the binary onscripter...
This now seems to take onscripter as an inputfile, not as the outputfile.
Also I'd recommend you to google how a linker works and what the necessary commands and parameters are, so you know what you're missing here.