You can use a pancake box. To support the pancake box, use a 11/2 wide by 8" 1/2 thick strip of plywood. Use construction glue on 2" from each end. Insert the strip in the hole, centering it, so the glue sticks to the back side of the drywall. Use another strip of equal size with a screw in the center to hold the strip in place till the glue is dry. When dry, unscrew the second strip and screw your box in place. You can also use drywall screws on each side of the box opening to hold the strip in place if the fixture will cover them or painting is not complete.