Students walk by the iconic tower at the University of Texas at Austin. (Eric Gay/AP)

Guns will be allowed in classrooms at the University of Texas at Austin next school year, but not in the dorms save for some narrow exceptions, under guidelines issued Wednesday.

University President Greg Fenves submitted the rules reluctantly to comply with the state’s new campus carry law, which has generated intense controversy.

The law allows the concealed carrying of weapons by license holders in public university buildings across the state.

Universities were given the power to create limited rules that designate some “gun-free zones” in areas where it would be too dangerous to have weapons.

Those zones have to be limited in scope, however, and can’t have the effect of making it practically impossible to carry a gun anywhere on campus.

In separate letters to UT System Chancellor Bill McRaven and the university community, Fenves said he opposes the idea of guns on campus. But the law gives him no choice, he said. That has made the process of writing the rules the most difficult thing he has done since becoming president last year, he said. 

“As a professor, I understand the deep concerns raised by so many,” he wrote in his letter to faculty, students and staff. “However, as president, I have an obligation to uphold the law.”

Fenves’s rules will ban guns in dorms except for three exceptions: Concealed guns would be allowed in common areas. Family members visiting dorms would be allowed to carry a gun. And staff members who work in the dorms could carry a gun.

While no classroom ban will be imposed, faculty members who don’t share an office with anyone else can ban guns in their specific areas, Fenves said.

He also issued strict rules for how those guns can be carried. In most cases, students and other people carrying guns must keep the weapons “on or about their person” at all times. If people aren’t carrying their guns, they’ll have to keep them in their locked cars. Gun safes will only be allowed in one place — university apartments, which are mostly reserved for families and graduate students. 

All guns that are being carried will have to be kept in a holster that protects the trigger. The gun can’t have a bullet in its chamber. And it can’t be visible; the state’s new open carry law doesn’t apply to college campuses.

Several other areas of campus will also have gun bans, including daycare centers, labs where dangerous materials are stored and health-care and counseling facilities. 

The law put university presidents in charge of making the rules, but the schools’ boards of regents have the power to change them with a two-thirds vote.

A UT System spokeswoman said that its board will review — but not necessarily take action on — all of its schools’ plans later this spring. Fenves and other university presidents have consulted with system officials throughout the rule-making process.

Campus carry has been one of the most controversial issues in years at colleges across the state.

Private universities were given the choice about whether they wanted to comply. So far, 24 private schools have opted out of the new law; none have opted in.

Opposition has been especially strong at UT-Austin. The university’s faculty council passed numerous resolutions against allowing guns in classrooms.

The college’s only Nobel Prize-winning faculty member has promised to flout the law and ban guns in his class no matter what Fenves’s rule said.

But the task force convened by Fenves decided that a classroom ban went too far. Many students come on campus solely for the purpose of attending class, so a classroom ban would prevent them from carrying their guns at all.

The task force considered setting up storage areas for guns, but decided that would pose too much of a security risk or chance for accidental firings.

The dorm ban is different. State leaders, including Attorney General Ken Paxton, have argued that guns should be allowed in student housing, too. But the task force reached a different conclusion, saying few of the people old enough to have a concealed handgun license — you have to be 21 to obtain one in Texas — actually live in dorms.

Fenves’s rules are likely to be challenged by both sides. McRaven predicted earlier this year that his schools will be sued by people who think the guidelines are too strict or too lenient.

The law goes into effect Aug. 1.

“Since this is a new law with an unknown effect on UT-Austin, we will monitor implementation and its impact on students, faculty members and staffers,” Fenves wrote to McRaven.

“I have significant concerns about how the law will affect our ability to recruit and retain faculty members and students. If problems develop, we will work to understand the causes and make adjustments to the policies, rules and practices, consistent with the law.”

Disclosure: The University of Texas at Austin is a corporate sponsor of The Texas Tribune. A complete list of Tribune donors and sponsors can be viewed here.

This story has been cross-posted from the Texas Tribune.