Support 3-character locales
reuse constants
add APLv2 license