From: Richard Lanyon Newsgroups: comp.os.msdos.djgpp Subject: Undefined reference to `main' Date: Fri, 17 Jul 1998 15:01:56 +0100 Organization: Oxford University Lines: 25 Message-ID: Reply-To: Richard Lanyon NNTP-Posting-Host: plato.wadham.ox.ac.uk Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk Yes, that's the error message I get when compiling... P:\>make dsweep gcc -Wall -o dsweep.exe -Lc:\tdt\drivers\apos\c\ -Lc:\tdt\drivers\xbdrv\c\ dsweep.o rglio.o -lgpp -lm c:/djgpp/lib/crt0.o(.data+0x92):crt0.s: undefined reference to `main' c:/djgpp/lib/libc.a(crt1.o)(.text+0x312):crt1.c: undefined reference to `main' make.exe: *** [dsweep] Error 1 It's not just that I've misdefined "main", either - I'm using the vanilla "int main(int argc, char *argv[])". In any case, nm shows that main is defined in the object file, the relevant line of nm's output being 000000d0 T _main so what've I done? Richard Beware! Beware! His flashing eyes, his floating hair!