Nowadays it's not nearly as bad as it used to be. The biggest culprit was and still is the UI, and in fact any graphics or sound functionality, simply because there are no C++ standard libraries for that. However, there are OS independend libraries around for that purpose. Everything that is in the C++ standard libraries, including STL and BOOST, should work out of the box on any OS without changing the code, unless the compiler you're using is not adhering to the standard (in which case you should consult your compilers compatibility documentation).
GOTOs are a bit like wire coat hangers: they tend to breed in the darkness, such that where there once were few, eventually there are many, and the program's architecture collapses beneath them. (Fran Poretto)