开发者

SVN name conflicts and multiple versions

I have a C++ project deve开发者_StackOverflowloped under both Windows (VS2010) and Linux (Eclipse). The non-portable portion of the source is isolated in one non-portable file (NonPortable.cpp). I would like to use SVN to manage the source. Everything works, I can check-in/out/commit from both Windows and Linux, but I don't know how to handle that NonPortable.cpp file. Is there a way to keep both versions and tell the SVN to work with the appropriate one?

I've been using Subversive SVN in Eclipse and VisualSVN in VS.

Thanks.


NonPortable.cpp file should have all the code of all the compilers for all the OS'es, and everything should be organized with predefined macros. Each compiler defines a set of macros to deal with such situations. For VS2010 check out this page and macros such as _WIN32 and _MSC_VER.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜