Add log dir, fix package variable handling.