Hi there, After reporting this bug, I am told that there's no Debian program which uses XIM variable. However, my system seemed not to work well without exporting XIM=SCIM.
So let's hold on merging this patch for a moment. I'll investigate more about it. Takes your time, Zheng YAN