fix macro CMD_DECL, not test yet