A sweeping machine with a hopper forming a compactor flap or plate is provided. The hopper has an opening which receives dirt and debris swept from a surface being cleaned by a rotatable brush of the sweeping machine. The compactor flap is pivotally mounted in the hopper and has an outer edge positioned close to an edge of the hopper opening when in a first position. The outer edge of the flap is spaced farther from the hopper opening and toward an end wall of the hopper when in a second position. The compactor flap is pivoted from the first position to the second position periodically to move dirt and debris away from the hopper opening and to compact it against the hopper end wall. The hopper also has a movable lip adjacent the lower edge of the opening. A flexible strip extends across the hopper and has an upper edge connected to the edge of the bottom wall of the hopper defining the lower edge of the opening. The flexible strip has an intermediate portion connected to an edge of the movable lip and the strip has a lower edge which contacts the surface to be cleaned. The movable lip can be counterweighted so as to pivot upwardly when the hopper is passing over larger debris and otherwise is closer to the surface to be cleaned to prevent dirt being swept by the rotatable brush from escaping under the hopper.