Basic setup for profiling This fixes the examples so they will build and adds a PROFILE option to the CMakeFile that enabled gprof info on non-Windows