The usual proof (as in Kanamori's book, section 11) is as follows: Work in $\mathsf{ZF}$. Note first, with Bernstein, that if $\omega_1\le\mathfrak c$, then there is a set of reals without the perfect set property: Either $\omega_1=\mathfrak c$, so $\mathbb R$ can be well-ordered, and we can build Bernstein sets using the usual transfinite recursion, or else $\omega_1<\mathfrak c$, and any set of reals of size $\omega_1$ lacks the perfect set property (that there are exactly continuum many perfect sets, and that each perfect set contains a copy of the Cantor set and therefore has size $\mathfrak c$ are provable in $\mathsf{ZF}$).
Now, under the assumption that all sets of reals have the perfect set property, we argue that $\omega_1$ is a limit cardinal in $L[r]$ for all reals $r$: Suppose otherwise, so for some real $r$ and some $\kappa$, $\omega_1=\kappa^+$ in $L[r]$. Let $s$ be a real coding $r$ and a well-ordering of $\omega$ in type $\kappa$. In $L[s]$, we have that $\omega_1$ is computed correctly. But now we see that $\omega_1\le\mathfrak c$, as witnessed by $\mathbb R^{L[s]}$.
As Asaf points out in the comments, if $\omega_1$ is regular in $V$, this gives us that it is inaccessible in $L[r]$ for all reals $r$, but it is equiconsistent with $\mathsf{ZF}$ that $\omega_1$ is singular and yet the perfect set property holds, see
John Truss. Models of set theory containing many perfect sets. Ann. Math. Logic, 7, (1974), 197–219. MR0369068 (51 #5304).