Answer
It can be proved using integration by parts twice that
$$\int_0^a f(x)g''(x) dx=f(a) g'(a)-f'(a) g(a)+\int_0^a{f''(x)g(x) }dx$$
Work Step by Step
Since $f''$ and $g'' $ are continuous we can apply integration by parts on
$$\int_0^a f(x)g''(x) dx$$
using the formula
$$A= uv-\int{vdu}$$
putting $u=f(x)$ and $dv=g''(x)$
then
$$A=[f(x) g'(x)]_{0}^{a}-\int_0^a{f'(x)g'(x) }dx$$
but f(0)=0
then $$A=f(a) g'(a)-\int_0^a{f'(x)g'(x) }dx$$
the second term is also an integral that can be solved by parts
thus
$$\int_0^a{f'(x)g'(x) }dx=[f'(x) g(x)]_{0}^{a}-\int_0^a{f''(x)g(x) }dx$$
but g(0)=0
thus
$$\int_0^a{f'(x)g'(x) }dx=f'(a) g(a)-\int_0^a{f''(x)g(x) }dx$$
then
$$A=f(a) g'(a)-f'(a) g(a)+\int_0^a{f''(x)g(x) }dx$$
or
$$\int_0^a f(x)g''(x) dx=f(a) g'(a)-f'(a) g(a)+\int_0^a{f''(x)g(x) }dx$$