Use MKDIR_P instead of mkdir_p for compability with modern autotools wrt #47732