Updated CMakeLists.txt

Added support to MACOSX_RPATH.
Removed warnings on CMake 3.0