Archived

This topic is now archived and is closed to further replies.

Caesar

DJGPP project fails to compile

Recommended Posts

Caesar    126
Hi, I know this may be a little bit off topic and that DOS DJGPP is now obsolete, but I tried to a school project and I don''t know how to manage the projects there. Assume I have ie 3 files, mylib.h mylib.cpp main.cpp i the mylib.h i have a lock of course (#ifndef MYLIB_H #define MYLIB_H ...code... #endif) and I include it in the mylib.cpp like #include"mylib.cpp". When i tried to compile those, I got a "XXXXX already defiend in mylib.h), this is the way it works under MSVC but how about djgpp (RHIDE)? Thanks

Share this post


Link to post
Share on other sites
Caesar    126
umm, i have only a class definition there, and even if i cut-past it into the cpp file, in stil keeps telling already defined (for methods)

Share this post


Link to post
Share on other sites
GumpusPMaximus    122
if you''re using rhide, make sure your header files aren''t included in the project(in the window with the list of files that make up the project)

i''d also advise using dev-c++ w/ mingw(mingw is included) if you want to use a free c/c++ compiler+ide



Share this post


Link to post
Share on other sites