added a cmake file and linked some librarys to make it compileable under linux

also changed the structure a bit, to represent the partition between library and example