German rail privatisation agreed