mkx: Add check targets
mkx: Fix memory leaks