fixed a few linker errors