When programming in languages such as C/C++, there are bound to be certain pieces of the software which are dependent on the operating system platform.
To make sure such software work smoothly on all platforms, it appears crucial to have (preferably) automated testing on all platforms from day one.
This will help in avoiding problems later on. Also, it could help to avoid including specialized libraries which only work on certain platforms.
Python’s PEP-531 is an interesting example of a policy where, alongside testing on multiple platforms, it is encouraged to only depend on older libraries which presumably have wider support.