“At first, I could not do it,” she said. “My sister-in-law went for me. But then we went together, and now I do what I have to do.” In addition to two hot meals, she is given a loaf of bread, a liter of milk and four containers of yogurt.

Image Abdoulaye Diallo, of Senegal, worked steadily in Spain from 2002 to 2008. He now lives in a camp outside Huelva. Credit... Lourdes Segade for The New York Times

Soon, the Riveras will borrow a car from a relative and go to France, where they expect to camp while picking beets, asparagus and artichokes, then grapes in the fall. They got work there last year, though the cost of the campsite ate up half their wages. This time, a French farmer has agreed to let them stay on his property.

Mr. Rivera’s predicament is hardly unique. Mayors across Andalusia say local residents come to their offices all the time looking for work. Some do not want farmwork, saying it is too hard. But many, says Emilio Vergara, mayor of Paterna del Campo, a small farming village outside Huelva, would gladly take it.

Together with three other nearby mayors, Mr. Vergara began an effort to persuade farmers to hire local people. But, he says, of the 450 people who signed up from his village, none have been offered a job.

“I am concerned about a potential outburst of xenophobia, and hope that it can be avoided at all costs, because Spain is traditionally a hospitable country,” Mr. Vergara said.

Experts say some farmers do hire immigrants to take advantage of them. Mr. Cañamero, the union leader, says 15 to 20 cases of serious abuse are reported each year, in which workers have not been paid or do not have enough food or water.