About seven years ago, the church allowed the future rap star to homestead in its basement. He was able to return the favor when he found out the congregation was being evicted from the building.

“He rescued this church,” said pastor Marie Cooper. “There’s no doubt he will be rewarded by God.”

DMX could use the help. He’s presently appealing a 15-day jail sentence in Buffalo for driving with a suspended license and possessing marijuana. He received another pot possession charge when he allegedly showed up for jail processing with weed stashed in a cigarette pack.

He is also awaiting trial in Harrison, N.Y., on a felony weapon charge and yet another misdemeanor drug charge.

Despite the legal entanglements, DMX hasn’t forgotten the church that sheltered him in hard times before he became a star.

The rapper’s business manager, Horace Madison, said DMX wants to help the church buy a vacant building across the street for a soup kitchen and homeless shelter.

“I just have to make sure he’s not overextending himself,” Madison said.