For the mind that is set on the flesh is hostile to God, for it does not submit to God's law; indeed, it cannot.  Those who are in the flesh cannot please God. (ESV)
I have heard many people over the years refer to people whom they know as being good people. They will say that these "good people" as not being Christians, but they are good people. Have you ever used similar words to describe people who do not know Christ as Savior? Is it possible for someone who does not belong to God to be "good?"
These verses are going to shed some light on the true condition of mankind. In verse 6 Paul has made a very clear distinction between those who set their minds on the flesh and those who set their minds on the Spirit of God. Rather than the Apostle Paul giving us a middle ground he makes it clear that the two kinds of people are very different.
What is the problem? Why can't a non-believing person be good? Paul says the reason is their mind is set on the flesh. A mind that is set on the flesh is hostile to God. Your neighbor, co-worker, or family member might do things that appear to be good. God is concerned with far more than outward appearances. He is concerned with the heart. A non-believing heart is a hostile heart.
Even if our non-believing friends were to duplicate every action of a Spirit filled believer in Jesus Christ they would not be able to please God. Why? Because they are bound to a pursuit of the flesh. That means that even their motivation for "doing good" is not sincere. We must fundamentally understand that non-believing people are hostile to God and need to repent.
Be careful to encourage your non-believing friends to surrender their rebellious heart to the Savior, repent of their sins, and believe on the Lord Jesus for salvation. God does not want behavior modification, he wants to make our dead, hostile flesh alive in Christ Jesus.