How to Rotate A Box Around A Pivot

How can be rotated a box around a pivot?

For example box dimension is 2cm X 5cm X 20cm.

And if we want to rotate box around centre of the box, how can it be? (Pivot is centre of the box)

( glRotatef )

  1. Translate( - PIVOT )
  2. Rotate
  3. Translate( PIVOT )

(Do appropriate OpenGL commands in reverse order).