Updated smlib and some 1.7 fixes