Squashed 'lib/TH/' changes from 036463c..b21641c

b21641c made TH standalone installation more flexible

git-subtree-dir: lib/TH
git-subtree-split: b21641cfbc37d201256d15200152b5444b237c6a
Merge commit 'c8ae7e597429a1f1f1610f99b59490ed0ef89b82'