I think what helps with small talk/getting to know someone for the first time is having specifics. Y'know, a particular thing that you want to hear this person tell you about. How they did their hair, where they got their clothes/shoes/phone case, whether they understood what the professor just said, etc. A specific question that likely has a direct, simple answer, and can easily invite a longer answer/follow-up questions if it works out.
If you're not one of those people who likes to talk just for the sake of talking, I find this approach is much easier to grapple with than "how's the weather"-type ice breakers, where you ask for someone's general opinion on some vague concept like their day or their emotional state. IMO, that stuff is for brief encounters with strangers, not for trying to strike up an actual conversation.
Anyway, as true as it is that you're not guaranteed to make a friend out of just this, I think the best way to make friends in general is to present yourself as a friendly person, who takes a genuine interest in other people. The rest will naturally come to you in time.