From: "Kecskemeti Balazs" Newsgroups: comp.os.msdos.djgpp Subject: Problem with headers (again) Date: Sat, 30 Jan 1999 12:24:42 +0100 Organization: MatavNet Lines: 54 Message-ID: <78uq84$h9s$1@bolka.matav.net> NNTP-Posting-Host: ppp132.tiszanet.hu X-Trace: bolka.matav.net 917695556 17724 195.228.98.132 (30 Jan 1999 11:25:56 GMT) X-Complaints-To: abuse AT matav DOT net NNTP-Posting-Date: 30 Jan 1999 11:25:56 GMT X-Newsreader: Microsoft Outlook Express 4.72.2106.4 X-MimeOLE: Produced By Microsoft MimeOLE V4.72.2106.4 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Hi! I asked this question a while ago, but i got no useful reponses (except Eli Zaretskii, thanks), but i still don't know what do i do wrong. So: I got problems with header files. The compiler complains about multiple declarations (_lot_ of error messages, multiple declaration errors for all variables in prog.hpp), and i don't know, why. I did this: prog.hpp : ------------- /* my header file */ #ifndef PROG_HPP #define PROG_HPP /* ...stuff... */ #endif prog.cc : ------------ /* secondary module */ #include #include "prog.hpp" /* ...stuff... */ testprog.cc : ----------------- /* main module */ #include "prog.hpp" /* ... stuff ... */ int main() { /* ... stuff ... */ } I also used an external COFF file. So i typed this: gcc testprog.cc prog.cc extmod.o -o testprog.exe I really didn't declare things more than once. Please help me with this thing, because i can't figure out what's wrong with the above. Thanks in advance. Kecskemeti Balazs balazs AT tiszanet DOT hu