use relative path, clean up unused functions.