单项选择题

It was two hours that we spent ______ all the trees.

A. to be planted
B. planting
C. to plant
D. planted