I would like to prove that for all $u\in C_c^1(0,1)$ $$\|u\|_{L^2(0,1)}\leq\frac 1 \pi \|u'\|_{L^2(0,1)}$$ by means of elementary integral inequalities (Hölder, Young, or Fourier series...)
My attempt: I thought of using Wirtinger's inequality (proved using Fourier series): $$\|u-\bar{u}\|_{L^2(0,1)}\leq\frac 1 {2\pi} \|u'\|_{L^2(0,1)}.$$ So I tried to show that $|\bar{u}|\leq 1/(2\pi) \|u'\|_{L^2(0,1)}$. The best I could achieve is the following: $|\bar{u}|=\int_0^1 u(x)\,dx=-\int_0^1 x\,u'(x)\,dx=-\int_0^1(x-1/2)u'(x)\,dx$, so $|\bar{u}|\leq \|x-1/2\|_{L^2(0,1)} \|u'\|_{L^2(0,1)} = 1/(2\sqrt{3})\|u'\|_{L^2(0,1)}$.
$C_c(0,1)$ implies that $u$ is zero in a neighbourhood of $0$ and $1$, so we can write $u$ as $\sum_{n=1}^{\infty} a_n \sin{\pi nx}$ for some coefficients $a_n$. Of course, then $ \int_0^1 \lvert u \rvert^2 = \frac{1}{2}\sum_{n=1}^{\infty} \lvert a_n \rvert^2 $, and $\int_0^1 \lvert u' \rvert^2 = \frac{\pi}{2} \sum_{n=1}^{\infty} n^2 \lvert a_n \rvert^2$, and then the result follows since $n^2>1$ for $n>1$.