Add of CMake macros for easier build of functions and observers plugins

* Added automatically installed CMake macros
* Added tests and test datasets

(references #36)