[FIX] Fixing various compilation bugs.