Does a minor obtained in a graduate school matter?
As you kind of alluded to in your example, the answer to this question depends a lot on what kind of "long run" you are planning to pursue.

First, in a career where your minor subject is irrelevant, then no, your minor likely will not matter. Sounds obvious, but this is likely the case for many people.

Further, in a career where your minor subject becomes your main focus, such as a mathematician transitioning to a position in philosophy, then you will likely need to demonstrate your qualifications with more than just your PhD minor. Your minor may be noticed when looking for your first academic appointment, but in the long run, it will be much less helpful than publications in philosophy, recommendations from fellow academics in philosophy, coursework in philosophy subjects etc.

There are a few situations where the minor could be helpful, such as if you are applying for an entry-level job in some interdisciplinary field. However, there are many more situations where the minor is either irrelevant or insufficient to prove your qualifications.