minor changes to adapt eoc on Linux