Bunch of changes to server engine generator

Mainly to support zgossip stack in CZMQ.