(The following is all 100% amateur hearsay taken from video games – yes, video games – and the Internet, so take it with a HUGE mountain of salt. I thought about not posting what amounts to little more than conjecture in a GQ thread, but upon re-reading it, I think this might be at least a little interesting if not outright informative)
First, in direct answer to the OP, I think the 2007 film Shooter with Mark Wahlberg used a device exactly like you mentioned, something Wikipedia claims is the “Telepresent Rapid-Aiming Platform” from Precision Remotes. It’s a remote weapon system. According to random internet sources, the company’s first model could automatically adjust for range and wind conditions, but the current-generation product pages make no mention of this.
As for more common systems, the Phalanx CIWS is more like a “aim in general direction, fire a gazillion rounds and hope that at least one hits” thing than a super-accurate sniper rifle. And even the land-based version does seem to be rather big for a single person to carry. The Korean sentry gun seems similar.
For a true auto-aiming “one shot, one kill” sniper rifle to come to life, there would have to be many advances in technology – it’s a multi-part problem. But looking at existing, publicly-known military tech and research, it’s possible to see how we might get there.
One (perhaps optional) part is computer vision, as HorseleverFat pointed out. Pattern recognition software, used for a variety of situations and specifically researched (I believe) in a very similar context for use in the cancelled Objective Individual Combat Weapon program, sought a way to identify and track human targets (moving or not) in the field of view. The ability to see in different spectrums and lighting conditions (thermal imaging, night vision) would give automated systems an advantage that soldiers don’t always have access to, but it’s still non-trivial to identify human targets from background noise and other animals. It’s harder still to identify a particular human or even a group of humans (i.e., the enemy). Facial recognition can only do so much for the former issue, and for the latter, I think the most common present-day solution is for vehicles and individual soldiers to wear special plates that look different through imaging devices – that, and proper planning and communication, which doesn’t always seem to happen.
Another part is actually hitting the target with a projectile. I think our tanks (M1 Abrams) can currently laser-rangefind a target, track it while it’s moving to get an estimate of its vector (with the help of a human), automatically adjust for wind conditions, the shooter’s own movements, etc. and land a round. But one huge, steady tank firing at another huge, steady tank is not quite the same as one small, jittery human firing at another.
What if you used explosive projectiles so that even near-hits would be lethal? Missiles already use a variety of laser, wire, and visual tracking systems and they can change direction mid-flight, but they are big and expensive and impractical for individual combat.
On the other hand, one of the OICW’s main features was supposed to be its air-bursting grenades; a soldier would aim at an enemy’s cover, lase it with the built-in rangefinder, move the sight just a little and fire; the ballistics computer would program the grenade to detonate at the right range so that it’d explode over the target’s head, killing him that way. There’s also research into outright laser-guided bullets, supposedly, but I can’t find the cite anymore – though there’s a similar-looking patent.
Combine all of the above and point-click-kill seems like a pretty likely eventuality, but again, I have to emphasize that this is just conjecture.