Ahh, architecture...my specialty. As mentioned, it is due to your camera's sensor not being parallel to the side of the building (i.e. pointing the camera upward and not perfectly horizontally). To summarize, you have three options for correcting this:
- Move further away from the building, keep the camera level and crop the bottom half off of the image. Obviously, this causes an enormous loss in resolution and angle of view.
- Frame loosely and use software to correct the distortion. The software is correcting the image by essentially pulling the bottom inward and back. You'll end up with proper verticals, but the building will look squatter than it should. Essentially, you're trading one form of distortion for another.
- Purchase and learn to use a tilt-shift lens. This yields the most geometrically correct image with the highest resolution; however, such lenses are expensive, slow to use and have a learning curve.
An image at 24mm with 10mm of shift and 1.5 degrees of tilt: