add argument compiling, adjust to different platforms