I think it's about 90+ % the pickup. The split design, wide flat coils that are wired in series.
Then comes the placement, some non Fender P Basses vary from the traditional position and that's why they have a slightly different "flavor profile" than the Fenders, but not too much.
I've owned many P Bass variants over the last 48 years and as long as they hold to the pickup tradition they all had the P Bass "Thing"
As to the Mix question, P Basses have a sort of double O sound like Look or Book where as the Jazz Bass has a sort of short A type sound, like in the word Awesome, which, I believe, is due to the single pickup . Being wired in series there are more low mids, where as a 2 pickup Bass will have cancellation of the strings common frequencies.
Though I have owned String Rays which don't have that Basic single pickup tone flavor, but due to the active electronics the comparison is moot.
This phenomenon makes it more difficult but not impossable for [me] to mix a 2 pickup Bass, the denser the mix the less bass tone comes through.... Of course there are ALWAYS exceptions to any given situation during a mix session. (the wood the bass is made from contributes a bit but not as much as the strings) I may just raise the volume of the bass until it can be heard but more likely than not I'll use radical low end EQ on the instruments that are conflicting with the Bass sound.
As a player and recording engineer, I will almost always record with a P Bass or variant before I reach for a Jazz or any other Bass.
I've owned everything from an Fender American Deluxe P Bass to a SX P style and many Fender American Standards, MIM, MIJs & CIC and even the ones that have a bridge pickup still have that P Bass thing going on.
I just bought a Squire Vintage Modern PJ and it's great sounding and VERY well made, I would hazard to say it's as good as my last Fender Am. P Bass Standard though I do prefer the graphite neck rods and better wood but for the $$ the Squire is great.