std::rt: Add start_on_main_thread function

Applications that need to use the GUI can override start and set up the runtime using
this function.
auto merge of #7864 : brson/rust/start-on-main-thread, r=brson

Applications that need to use the GUI can override start and set up the runtime using
this function.