first complete integration with enric. it does not compile on mac