heh that's actually an interesting problem, it would depend on how many times the gun needs to fire, also how stable can the copter be as it fires? if it only needs to get one shot off then you're good(but then it'd be more practical to load the thing with explosives, ugh that idea gives me nightmares)
maybe some sort of dual gyroscopic stabilizer like a camera coupled with opposing barrels as some one mentioned, but using blanks instead of live ammo?