Modification toward sharing dynmat.c between _phonopy.c and _phono3py.c