You're going to use a Form 4797 to report the sale. Both sides. Remember that you're basically selling all the stuff you've been depreciating and then the land, too.
https://www.irs.gov/pub/irs-pdf/i4797.pdfAs part of the gain or loss calculation, you'll going to need to recognize the depreciation you've taken and any selling expenses. E.g., if you bought the place for $100K and sold it for $200K, you don't have a $100K gain.
Rather, you need to add any deprecation you've taken to the gain. And you need to subtract any selling expenses you've paid from the gain.
E.g. if you have $20K of accumulated depreciation that means you have $20K more gain. If you have $10K of selling expenses, that means you have $10K less gain.
Also, if you have passive suspended losses for the property, these may be unlocked when you sell the property.