fixing klib vector stuff and adding ksort.h to get sorting