The DLL was not working with VS 2015. Also libxml2 covers the most commonly used encoding internally: http://www.xmlsoft.org/encoding.html In any case most (all?) parsing via lxml in calibre pre-decodes input in python.