I tune by ear against either a piano, or guitar, or banjo, depending on who I am playing with.
I do not tune my open strings to the corresponding notes on a piano, for example. Instead,
I tune my open string to a corresponding major chord on whatever instrument is the dominant
chordal instrument in the band. I also check the 12th fret against that same chord, and adjust
until both open and octave are good.
I believe the bass needs a little bit of "stretching" just as pianos do, flattening the lowest
notes. I also adjust intonation by ear, so that both open and 12th fret sound good against a chord.
That is after all how it's going to be heard in the end.
I've had the opportunity to hear, and play with, some instruments that sounded incredible, mainly
because of their tuning. I think it's the single best thing you can do for your sound.
I don't have perfect pitch, though, and I'm completely lost without some reference. I can tune a bass
to itself once I get it in the ballpark with some kind of reference. But for actually playing a song,
I tune to "the band".