Note that this equality is as topological groups, where Hom is endowed with uniform convergence on compact subsets. 

Every such homomorphism is zero on $p^n$ for some $n$. Hence the given homomorphism group $G$ can be written as $\bigcup G_n$, where $G_n$ is the set of homomorphisms that vanish on $p^n$. Note that $G_n$ is open.

By definition,
$$G_0=\mathrm{Hom}(\mathbf{Q}/\mathbf{Z},\mathbf{Z}(p^\infty))=\mathrm{Hom}(\bigoplus_\ell\mathbf{Z}(\ell^\infty),\mathbf{Z}(p^\infty))=\mathrm{End}(\mathbf{Z}(p^\infty)),$$
because for prime $\ell\neq p$ we have $\mathrm{Hom}(\mathbf{Z}(\ell^\infty),\mathbf{Z}(p^\infty))=0$. It is classical that $\mathrm{End}(\mathbf{Z}(p^\infty))$ is isomorphic to $\mathbf{Z}_p$ as a topological ring (details upon request).

Hence each $G_n$ is isomorphic to $\mathbf{Z}_p$. Multiplication by $p$ maps $G_n$ into $G_{n-1}$. Also, mapping $f$ to $x\mapsto f(p^{-1}x)$ maps $G_{n-1}$ into $G_n$ and is an inverse to multiplication by $p$. So indeed $pG_n=G_{n-1}$, and we deduce the result.