There are non-contract obligations too. You can incur obligations upon yourself by causing someone else's condition of dependency. For instance, if someone carelessly caused you to lose the use of your arms, they would, as a matter of strict moral liability, be duty-bound to pay for the surgeries or therapies or whatever to restore the use of your arms, or compensate you for the lifelong loss of your arms.
Parental obligation arises in this manner: the parents caused the child to come into existence --- in, obviously, a dependent state --- therefore they owe him or her parental support.
Nor can they invoke a "right" to abortion even if the pregnancy were caused by a non-consenting act, e.g. rape. Upon the onset of his existence, the unborn child has the same right to self-ownership, and therefore has the right not to be assaulted and killed. The developing child has the same right to simply go on living without being slain.
After the child's birth, that parent's only duty would be to arrange for somebody else to support the child, i.e. adoption.
I’m actually neutral on abortion. Reason: In the case of rape, the unwilling parent has incurred no such obligation. And if it’s not rape, it’s not clear that causing a being to come to life creates any such obligation. Perhaps it does, and perhaps it doesn’t. I have been unable to prove or disprove that theory, and no one has been able to convince me one way or the other.