Fixed some issues found while building the examples