Yes. Static will be one value. Many other things are undefined or new to the standard. (When are they initialized, if they are global? Is the code for static initialization inside a function thread safe?) But, yes, you can only count on one.
The only clarification here is outside the standard, but it has practical value if you create a shared library (.so or .dll): you cannot statically (privately) link your C ++ class library to a shared library. Otherwise, it would make two copies if you do it in two different shared libraries. (This comment applies to everything related to the library, and not just static variables. If you do, then everything is duplicated.)
Edit: On many platforms (such as Linux and Windows), this can be used to purposefully βhideβ your static variable. If you do not make your function / class accessible outside the dll / so (using the declspec attribute or the visibility attribute), you can ensure that your dll / has its own copy of the whole class. This method can help reduce unwanted interactions between libraries. However, in your case, it sounds as if you really want only one thing that will happen if your class has the appropriate visibility in all your libraries (only in one and other libraries associated with this library).
Change again to refer to standard
If a function with an external link is declared embedded in one translation unit, it must be declared embedded in all translation units in which it is displayed; no diagnostics required. The built-in function with external communication must have the same address in all translation units. A static local variable in an external inline function always refers to the same object .
7.1.2.4, C ++ 14
Rob l source share