That is precisely right. The compact concept is the basis of Government, not the basis of the rights that Government is supposed to secure.
The fact that the founding fathers accepted Locke's view that Government is a social compact, does not mean that they endorsed everything he wrote, or even considered much of what he wrote as relevant. The basic concept, not the author or his treatment of related topics, is the point. The concept in our Declaration of Independence has nothing to do with hero worship, or endorsement of any social view not discussed.
For the full text of what the Declaration actually says, see Declaration Of Independence.
William Flax