For Shimano gear If you are going all 9-speed, you're fine using most STI shifters with 9-speed mountain derailleurs.
New 10 spd Dyna-Sys rear derailleurs won't work with 10 spd STI shifters if you're going Shimano. However, I've heard people have had success using a 9-speed Shimano Deore M592 Shadow Rear Derailleur with 10 speed STI shifters.
See thread on MTBR for a bit more info on someone's successful setup with a Shimano 10 speed road/mountain setup http://www.bikeforums.net/archive/index.php/t-673861.html
I don't think there are any issues if you're going for a SRAM road shifter / mountain derailleur combination if you're going 10 speed and using the XX mountain group which has the same pull ratio as the road groups. It appears that 9 speed mountain gear and some of the other 10 speed mountain group sets, have a slightly different pull ratio and don't play well with road shifters.