The Labour Chancellor has announced the "largest real-terms funding settlement" for devolved governments in 25 years.