Below is a well known Corollary from Analytic number theory and a proof (excerpt) by G. Fousserau (1892) which I have found here: Narkiewicz. (2000). The Development of Prime Number Theory on page 13.
Corollary 2. Let $\pi(x)$ be the prime counting function. Then $\pi(x)=o(x)$ applies for $x\rightarrow\infty$, i.e. $$ \lim _{x \rightarrow \infty} \frac{\pi(x)}{x}=0 . $$
Proof. For any $k>1$ we have $$ \pi(x) \leq k+\sum_{\substack{n \leq x \\\operatorname{gcd}(n, k)=1}} 1, $$ hence writing $x=q k+r$ with $0 \leq r<k$ we get $$ \pi(x) \leq k+q \varphi(k)+r \leq 2 k+\color{red}{\left\lfloor \frac{x}{k} \right\rfloor} \varphi(k) . $$
This implies $$ \limsup _{x \rightarrow \infty} \frac{\pi(x)}{x} \leq \frac{\varphi(k)}{k} . $$ [...]
I do not understand the estimate of $q$ by the $\color{red}{\text{floor function}}$. I get that $q\leq\frac{x}{k}$. This also does the job. Also, I think that it should be $<$ as $r\leq k-1$. Maybe someone can clarify some of the details here.
Note: The book says after the proof: See Mamangakis 1962.
I think this leads to this source here. In Fousseraus work I cannot really find the proof I am refering to. The proof in Mamangakis is a little bit different from the one in Narkiewicz.