I'm sorry this has happened to you. A third degree tear is a serious injury (5 to 10% of births) and you're going to need as much support as you can get for the next few months. You are recovering from birth as well as starting a rehabilitation process to heal a serious wound.
For soreness, freeze maternity pads and use for 10 min 3 times a day (my wound only healed after 2 months). Ask your GP if you can apply Lidocaine to help with discomfort.
Do pelvic floor exercises 5 to 6 times every day (or follow what the physio is telling you to do) for 6 months.
The positive (if it can be called positive) is that you are only 5 weeks postpartum. It is very early (I'm surprised they've already mentioned surgery). Physio will help a lot. Although you might not get back full control of your bladder, things will improve a lot over the next year and you will not stay as you are.
You should feel a first real improvement around 3 months (until then, don't despair, it will feel the same day after day) and again around 6 months. It takes that long for pelvic floor muscles to regain their strength + if there's nerve damage, it's more likely to recover during the first 6 months too (although nerve damage may be permanent).
So after 6 months you should feel much more yourself.
After 9 months the physio told me it was still early and I definitely still had improvement up to 18 months after birth. So take it easy, rehabilitation is long.
These injuries are taboo and suffering a serious birth injury AND speaking out about it goes against the idea that women should sacrifice everything to have a baby.
You should find support at the Birth trauma association, the Masic Foundation (they are a very new charity so might be more useful if you carry on suffering long term but no harm signalling new mothers need help too in my view) and Facebook (have a search for serious childbirth injury or 3d and 4th degree tears).
Depending on how you feel, you may also want to see a perinatal mental health service. They've heard it all before and can help you process the trauma you've suffered.
Good luck