Consider a mechanical system, the Lagrangian of which is: $$-L(u,\dot u)=\int\left(\dfrac{\partial^2 u}{\partial x^2}\right)^2\mathrm{d}x$$
This would correspond to a system in torsion, for example. I intentionally dropped the terms which are not of interest (such as kinetic energy).
Then, calculate the first term in the Euler-Lagrange equation: $$\dfrac{\partial L}{\partial u}(u,\dot u)=\dfrac{\partial}{\partial u}\int u''^2 \mathrm{d}x$$
First possibility: $$\dfrac{\partial}{\partial u}\int u''^2 \mathrm{d}x=0$$ because $\dfrac{\partial u''}{\partial u}=0$, similarly to $\dfrac{\dot u}{\partial u}=0$. I think this is not true, because $\dot u$ is a variable, but not $u''$.
Second possibility: $$\dfrac{\partial}{\partial u}\int u''^2 \mathrm{d}x=\dfrac{\partial}{\partial u}\int u\,u^{(4)}\mathrm{d}x=\int u^{(4)}\mathrm{d}x$$
by double integration by part and because $\dfrac{\partial u^{(4)}}{\partial u}=0$. I am really not sure about this latter argument either.
Third possibility Define a new variable in the Lagrangian such that $L(u,\dot u,v,\dot v)=\int v^2\mathrm{d}x$ and somehow link $v$ to $x$ later.
Can someone please enlighten me?