texturecache: cosmetics; mklocal.py: add support for foreign encodings