rotation problem

hai ,
i am new to opengl.
i want to rotate a line around a circle
can anyone help me

i wnt to rotate the line around the outer edge of the cirlce

translate the line rotation point to the origin, rotate by x degrees, calculate the new point on the circle to match this rotation, translate the line to the new point