Use the method of variation of arbitrary constants. The solution to the homogeneous equation is:
<br />
y_{0}(t) = C_{1} \, \cos{t} + C_{2} \, \sin{t}<br />
Then, assume C_{i} \rightarrow C_{i}(t), i = 1, 2 where these functions satisfy the following conditions:
<br />
\left[\begin{array}{cc}<br />
\cos{t} & \sin{t} \\<br />
<br />
-\sin{t} & \cos{t}<br />
\end{array}\right] \cdot \left[\begin{array}{c}<br />
C'_{1}(t) \\<br />
<br />
C'_{2}(t)<br />
\end{array}\right] = \left[\begin{array}{c}<br />
0 \\<br />
g(t)<br />
\end{array}\right]<br />
The solution for C'_{i}(t) is:
<br />
\left[\begin{array}{c}<br />
C'_{1}(t) \\<br />
<br />
C'_{2}(t)<br />
\end{array}\right] = \left[\begin{array}{cc}<br />
\cos{t} & -\sin{t} \\<br />
<br />
\sin{t} & \cos{t}<br />
\end{array}\right] \cdot \left[\begin{array}{c}<br />
0 \\<br />
g(t)<br />
\end{array}\right] = \left[\begin{array}{c}<br />
-\sin{t} \, g(t) \\<br />
<br />
\cos{t} \, g(t)<br />
\end{array}\right]<br />
One integration gives the following:
<br />
C_{1}(t) = C_{1} - \int_{t_{0}}^{t}{g(t') \, \sin{t'} \, dt'}<br />
<br />
C_{2}(t) = C_{2} + \int_{t_{0}}^{t}{g(t') \, \cos{t'} \, dt'}<br />
Substituting this into the expression for the general solution, one gets:
<br />
y(t) = C_{1} \, \cos{t} + C_{2} \, \sin{t} + \int_{t_{0}}^{t}{g(t') \, \left(\sin{t} \, \cos{t'} - \cos{t} \, \sin{t'}\right) \, dt' \right)}<br />
where, the integrating constants C_{1/2}, are determined from the initial conditions:
<br />
y(t_{0}) = C_{1}<br />
<br />
y'(t_{0}) = C_{2}<br />
Using the addition theorem for the sine function:
<br />
\sin{(t - t')} = \sin{t} \, \cos{t'} - \cos{t} \, \sin{t'}<br />
we see that the above integral can be written as:
<br />
\int_{t_{0}}^{t}{g(t') \, \sin{(t - t')} \, dt'}<br />
Take t_{0} = 0 and compare with the definition for convolution, you will get your desired result.