This is solving the problem in the wrong place. The proper way for OS is to treat filenames as binary sequences like Linux does and have no problems.
The problems that arise elsewhere should be solved elsewhere.
The problems that arise elsewhere should be solved elsewhere.