A former Student Union building in Glasgow will be turned into a digital, entrepreneurial and social engagement hub after a £30 million contribution from a former student.