Erratic wind sent a brush fire roaring across 3,000 acres of rugged canyons near a Los Angeles suburb Friday, burning buildings at a movie set and prompting hundreds of people to leave their homes.

Dust, ash and smoke blew through the area. Flames destroyed four sheds and came within 50 feet of homes as about 1,000 firefighters used helicopters to drop water and positioned engines in the path of the blaze.

"What we're doing is we're making sure people don't lose their houses," county fire Inspector Mike Beran.

The blaze was 40 percent contained at dusk and its main thrust was into Angeles National Forest land adjacent to the city, easing the threat to homes.

But firefighters expected their task to get more difficult. The National Weather Service declared a wind advisory, with gusts to 35 mph, in the Santa Clarita Valley north of Los Angeles until Saturday afternoon.

"The wind is working against us. We're going to have more work cut out for us," Beran said.

The flames blew through the Veluzat Motion Picture Ranch, a 750-acre movie location where crews can film at sets depicting a Spanish town, a 1950s town, an Army camp and other locales. Dozens of prop sheds and set structures were destroyed.

The fire was spotted Friday morning near Santa Clarita, a city of 151,000, and moved rapidly through heavy brush, officials said. The fire's cause was not immediately known.

About 150 of the residents who voluntarily left their homes took refuge at a high school.

"This one's pretty big, as big as I've seen since I've been here," said Frank Zapata, 46, a 21-year resident.