TALODI, Sudan With a roar, an excavator shudders to life and plows into the dry ground outside this war-scarred Sudanese town, drawing cries of "Allahu akbar" from the Kalashnikov-armed soldiers nearby.
The one km-long (0.6-mile) earth dam being built here will have an unusually broad set of uses, officials say.
Not only will it protect the town from floods and irrigate land, it will deter rebels who have persistently assaulted the strategic spot.
"It will be a natural barrier so that there will be no attacks from this area," said Ibrahim Abdullah Abdelkarim, the South Kordofan border state's minister of urban planning and public utilities, during a government-organized tour of Talodi.
Wearing camouflage military fatigues, Abdelkarim gestured to rocky hills from which seasonal rains pour into the savanna.
"This is the idea, to make a project that has so many functions," he said, speaking fluent English.
It's unclear how effective the dam would actually be in holding back the insurgents, who claim they are fighting for their survival and reportedly are backed by artillery and tanks, but there is no question the town could use the development.
Fighting between Sudan and South Sudan this week has brought the two closer to a resumption of full-blown conflict after the south seceded last year under a peace deal that ended decades of civil war between north and south.
Talodi, about 50 km from Sudan's ill-defined border with South Sudan, is mostly stick huts and one-storey brick buildings. Its economy depends largely on agricultural products like honey, local officials say.
A small patch of grass and a few trees qualify as a public park for its roughly 30,000 residents.
Now, with violence convulsing Sudan's southern border regions, life in places like Talodi is only getting harder.
Construction of a road to the state capital Kadugli was halted after rebels attacked it and took the machinery, Sudanese officials said.
A brick marketplace to replace Talodi's ramshackle souk of stick and corrugated-iron sheeting stands unfinished. Even the small power station is shut down, its fuel tanks charred by what officials said was rebel shelling in a major assault last month.
Khartoum seizes on such instances to allege that the rebels, desperate for attention and cheap victories, are trying to force residents from their homes and disrupt normal life.
"For a week they tried to capture the town, but they failed," said South Kordofan state governor Ahmed Haroun, who is wanted by the International Criminal Court on charges of war crimes in Darfur, allegations which he dismisses as political.
"When they felt they had failed they began shelling into the town, targeting civilians and other places."
Rebels say their aim is just the opposite: to win their ethnic minority communities greater political and economic sway in Sudan's political and economic power structure, which they complain has long been dominated by an Arab elite.
Voicing those grievances, many people in South Kordofan - particularly in the Nuba Mountains region - joined southern rebels against Khartoum during Sudan's decades-long civil war.
But the 2005 peace deal that ended the war and paved the way for the country's partition last year left the Nuba Mountains and other former rebel territories north of the border. Fighting reignited in South Kordofan a month before South Sudan seceded.
The conflict has since become a cause célèbre for Sudan activists including Hollywood actor George Clooney, who snuck into South Kordofan illegally and released a YouTube video about the visit last month.
The United States and others have warned of impending famine in the region - which Sudan denies - and the United Nations estimates that more than 410,000 people have fled their homes in South Kordofan and Blue Nile, another border state.
Regardless of who is to blame, the fighting has obviously hit Talodi hard. About two thirds of the town's residents fled the fighting, the local commissioner said. Much of it still looks empty, with soldiers outnumbering civilians in places.
Troops in green uniforms filled the market, chatting and drinking tea at corner shops as women from the local Nuba tribe dressed in brightly coloured shawls shopped at the few stores that were still open.
Several people in the market, interviewed amid a heavy security presence, described intense fighting. "We were working in this office and then, 'Boom, boom, boom!'" Teya Hamed, a government worker, said, pointing to a nearby building.
Mohammed Suleiman stood near his shop, which he said was damaged during the fighting. "A rocket hit the shop only five minutes after I left it," he said.
Khartoum heavily restricts access for foreign journalists and aid agencies to conflict areas, making the full impact of war hard to independently assess.
That excavators and bulldozers are going to work in Talodi at all is meant to signify the Sudanese government's confidence in its grip on the volatile area after repulsing rebels.
But conflict between Sudan and South Sudan has revived in recent weeks and South Sudan's seizure of the Heglig oilfield, about 100 km southwest of Talodi, has touched a nerve.
The field accounted for about half of Sudan's 115,000 barrel-a-day oil output and its loss is another blow to an economy already struggling with rising food prices and a currency depreciating sharply on the black market.
Still, Sudanese officials dismiss the notion that outside intervention will be needed to avert mass starvation in the region. "Our government has enough resources for any humanitarian interventions. We can make it alone," Haroun said.
As illustration of this control, officials point to projects like a new 1,800-m (yard) bitumen airstrip which the government started building in Talodi last November.
Like the earth dam, it, too, has a dual civilian and military function which Abdelkarim, the state minister, said was necessary to ensure the development was "sustainable".
"You have to make a project that could defend itself or the city besides the other uses," he said. "Without defence, it will not be useful, because it could be attacked at any time."
(Reporting by Alexander Dziadosz; Editing by Michael Roddy)