Got it to run. Not sure if this is what you wanted though. Also I added compatibility for gcc on Linux.