Tpt2.8: same commits as before but ontop of the newest master.

see PR#257