minor fixes
more minor fixes
more fixes
even more fixes
now compiles