Bug fixes to get compilation to C working.