Proof:
The hypothesis is that $p^{q-1}$ is the smallest power of $p$ that is congruent to $1$ modulo $q$.
Now, what are the orders of the (cyclic) groups $\Bbb F_{p^m}^\times$? They are, of course, $p^m-1$, and a field $\Bbb F_{p^m}$ contains a primitive $q$-th root of unity if and only if $q|(p^m-1)$, i.e. if and only if $p^m\equiv1\pmod q$. Thus our hypothesis says that $\Bbb F_{p^{q-1}}$ is the first extension of $\Bbb F_p$ that contains a $q$-th root of unity $\zeta_q$. In other words, $\zeta_q$ generates an extension of degree $q-1$, so $X^{q-1}+\cdots+X+1$ is irreducible over $\Bbb F_p$