thread_create and script to compile