Wolverine, Beast & Storm are members of both Avengers and X-Men. As they are common to both teams, how can they fight?
They fight because they are holding to higher idealogical tenants than simple loyalty to team members.
Cyclops' side believes that mutants are the next line and that Hope is the key to mutant survival, that the ends justify the means. If this means putting children on the line then so be it.
Wolverine's side believes that regardless the children deserve to grow up before facing the world as it is.
The Avengers' side believes in not being killed by the Phoenix force.
Ultimately what Beast, Storm, Wolverine etc fight for will determine the sides and allies they pick.
This fight seems to be similar to the big Civil War arc in which hero is being pitted against hero based on their ideology. So to answer your question how can they fight, they will fight for the side that represents their ideals best. But I foresee a more fully fleshed answer will be available in a week when issue #2 comes out.