Referring to a 25 year old framework in a discussion of modern C++ best practices really doesn't help your case though
Why? Things haven't changed that much really. Some new stuff came along but the old is very much still there. There's still a lot of software using MFC today. I'm not saying you should use it in new projects or anything like that, but it's still there, still works and the rules of how it works didn't change, so I think it's a perfectly valid point in this discussion. I'm not talking about some obscure tech that fell out of use. It's (sadly) very much alive.
and even humble MFC had a main(), they just didn't call it that. I think it was _tmain() or wmain().
Right, well, it's, again, a little bit more complicated. Yes, that framework provides a _tWinMain that called AfxWinMain and that's one way to make an MFC app, but you can also skip that and start the event pump another way. Anyways, I don't want to get into MFC discussion, that wasn't the point :P The point was you don't need a main() or any other function to initialize global statics and run some code in their constructors. Another example is global statics in dynamically loaded libraries. I hope this one is less controversial :)
The best practice in the regulated field I work in is to use the "construct on first use" paradigm.
I think we have a misunderstanding coming from that name, but the thing it names is a perfectly valid strategy, I agree.
Global (static) objects are bad when they have interdependence upon each other.
I absolutely agree. If I seemed to advocate for using static globals let me be very clear - I'm not. They have their uses, sure, but also the order of initialization problem you mentioned, so that's something to take into account in your app design. If it matters - don't do it, if it doesn't - go ahead. I was merely trying to convey how they work on a technical level.
that's why it is often better to use global static pointers to those object and construct them in a well-defined order in main().
See, I think this is the point of confusion we had. If you use global pointers then those pointers get initialized (zeroed) in the way I was taking about. The pointers, not the objects that they later point to and you can obviously assign to them in main() or wherever else in a controlled order that you like. The pointers themselves though are originally initialized for you in an unspecified order. It doesn't really matter in that scenario of course as you overwrite them later in a way you see fit. The gist of it is that the pointers are the global static objects we're talking about here, not the things they later point to.
I suspect we'll continue to agree to disagree. LOL
I think we actually agree. We just misunderstood each other on some technicalities ;)