Cake Box said it has agreed to buy Ambala Foods for 22 million pounds ($28.5 million) and that it would raise funds to partly finance the transaction.