I don't know if there would be a penalty, but it certainly wouldn't look like organic link building. At the very least, I wouldn't expect those links to do much good. Yahoo seems more likely to penalize for that sort of thing. Google would most likely just devalue the links. There are better ways to spend your link building time and/or money.