Moving tdehwlib to a standalone library