Has anything been "built" in space before?
Absolutely. Perhaps not "built" in the sense you're talking about, but certainly assembled. A sterling example is the International Space Station. There are about a dozen distinct modules in the ISS that are pressurized and fit for occupation. The first was Zarya, and the latest is Leonardo. They've been constructed by many different countries, and have been added on individually. There are also many unpressurized components. Here's a handy-dandy map - a guide to the ISS (from Wikipedia)
Some details regarding the assembly process can be found here, but I feel that this section better explains things. Many components were brought up on launches of the Russian Proton rockets, as well as numerous Space Shuttle launches. Each new module connected smoothly with the others. They were pre-built, but were put together in orbit.
The other thing a project like this is going to take is money. And a lot of it. The ISS may have cost 150 billion dollars. That's a staggering amount of money. That does appear to take into account the cost of Space Shuttle flights. Now, this site says that a mission to Mars would be cheaper:
To put that number in perspective, just over 10 years ago NASA estimated the cost to send astronauts to Mars. Their rough estimates put the price of a human Mars mission in the ballpark of $40 billion US dollars.
Small change, clearly.
A mission to Mars would require a decently-sized rocket. The ISS is about 357 feet long. That's roughly the size of a Saturn V rocket. Now, if you built the rocket in orbit, it might not need to be so large, because it would already be in orbit.