Mexican President Felipe Calderón formally inaugurated a military barracks in the violence-racked northeastern town of Ciudad Mier, where he reiterated that the deployment of army soldiers to battle drug-trafficking gangs is a necessary but temporary measure.

He said the new army base will allow time for authorities to recruit and form their own police forces in that town and other areas of Tamaulipas state, saying that the weakness, vulnerability and, in some cases, complicity, of law enforcement had put people "at the mercy of criminals."

Calderón said Ciudad Mier, a colonial community in Tamaulipas state near the U.S.-Mexico border that was once known as the "Magic Town," should be a tourist destination but instead was abandoned by its citizens last year because of the presence of criminal gangs.

In late 2010, nearly all of the town's 6,300 inhabitants fled to neighboring municipalities and across the border into the United States due to fear of drug-related violence.

Many of them had relocated to a shelter in the nearby city of Ciudad Miguel Alemán.

Ciudad Mier, which is located in the "Frontera Chica" region of Tamaulipas, and many other towns in northeastern Mexico found themselves caught up in the war sparked by the March 2010 rupture of the alliance between the Gulf drug cartel and Los Zetas, the cartel's former armed wing.

The shootouts between gunmen working for the rival cartels occurred for about six months and sometimes lasted as long as eight hours, leaving the streets covered with bullet casings.

In a bid to boost security, the Defense Secretariat ordered the construction of a "mobile" military barracks to house soldiers deployed to Ciudad Mier, a move Calderón said prompted the return of two thirds of the people who had fled the town.

"Ciudad Mier had started to become a community of empty squares, abandoned houses, of shuttered schools and businesses, of bullet-ridden walls. Faced with that situation, the government couldn't remain with its arms crossed," Calderón said.

The presence of the army soldiers, who arrived in the second half of 2011, "is gradually helping the people of Ciudad Mier and all of Tamaulipas regain the tranquility that had been snatched away from them by the criminals," Calderón said.

He said homicides fell by more than 40 percent between the first and second halves of 2011, although he also acknowledged that "the road is long" and much work still remains.

The mobile military barracks, which the president formally inaugurated on Thursday, are capable of housing 600 troops.

The installations are the first of their type in the country, the Defense Secretariat said, noting that the materials used allow them to be taken down easily and moved to other areas as necessary.

The barracks, which occupy an area of 40 hectares (100 acres), respond to the need for mobile units capable of reacting to the contingencies that may arise in Tamaulipas state.

Shortly after taking office in December 2006, Calderón militarized the struggle against heavily armed drug cartels by deploying tens of thousands of army soldiers and federal police to drug-war flashpoints.

He said the deployment was necessary due to rampant corruption among Mexico's notoriously corrupt and underpaid local police forces.

The strategy has led to headline-grabbing captures of cartel kingpins, but drug-related violence has skyrocketed and claimed nearly 50,000 lives nationwide over the five-year period and rights groups both in Mexico and abroad have denounced widespread abuses by army and police.

New York-based Human Rights Watch, for example, said in a recent report that the war on drugs has led to a "dramatic increase in killings, torture, and other appalling abuses by security forces, which only make the climate of lawlessness and fear worse in many parts of the country."

Follow us on twitter.com/foxnewslatino
Like us at facebook.com/foxnewslatino