Message-ID: <362E596F.F1F99127@clover.c2d.fedex.com> Date: Wed, 21 Oct 1998 17:00:16 -0500 From: Walter Moore X-Mailer: Mozilla 4.06 [en] (Win98; I) MIME-Version: 1.0 To: djgpp AT delorie DOT com Subject: Re: RSXNTDJ compile error References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Reply-To: djgpp AT delorie DOT com When I try to run a program I compiled with RSXNTDJ and djgpp, This is what I get: > bash$ ./lpcli > Exiting due to signal SIGILL > Invalid Opcode at eip=00000001 > eax=00401000 ebx=0000c1e9 ecx=00008818 edx=0102001c esi=0000010b edi=00004000 > ebp=00002e01 esp=00003ff8 cs=089f ds=08a7 es=08a7 fs=0897 gs=08a7 ss=0897 > Call frame traceback EIPs: > 0x00000001 > When I compile with the djgpp ld.exe, this is what I get as output from my make file: > gcc -O -Zdll -Zwin32 -Zcrtdll=crtrsxnt -g -DDEBUG -DCLIENT -c autogen.c > gcc -O -Zdll -Zwin32 -Zcrtdll=crtrsxnt -g -DDEBUG -DCLIENT -c env.c > gcc -O -Zdll -Zwin32 -Zcrtdll=crtrsxnt -g -DDEBUG -DCLIENT -c error.c > gcc -O -Zdll -Zwin32 -Zcrtdll=crtrsxnt -g -DDEBUG -DCLIENT -c initvars.c > gcc -O -Zdll -Zwin32 -Zcrtdll=crtrsxnt -g -DDEBUG -DCLIENT -c net.c > gcc -O -Zdll -Zwin32 -Zcrtdll=crtrsxnt -g -DDEBUG -DCLIENT -c options.c > gcc -O -Zdll -Zwin32 -Zcrtdll=crtrsxnt -g -DDEBUG -DCLIENT -c output.c > gcc -O -Zdll -Zwin32 -Zcrtdll=crtrsxnt -g -DDEBUG -DCLIENT -c readline.c > gcc -O -Zdll -Zwin32 -Zcrtdll=crtrsxnt -g -DDEBUG -DCLIENT -c writen.c > gcc -O -Zdll -Zwin32 -Zcrtdll=crtrsxnt -g -DDEBUG -DCLIENT -c lpcli.c > gcc -O -Zdll -Zwin32 -Zcrtdll=crtrsxnt -g -DDEBUG -DCLIENT -c strcli.c > gcc -O -Zdll -Zwin32 -Zcrtdll=crtrsxnt -g -DDEBUG -DCLIENT -o lpcli lpcli.o strcli.o autogen.o env.o error.o initvars.o net.o options.o output.o readline.o writen.o -Ic:/djgpp/src/loadplan/LPserver.works -lwsock32 > d:/djgpp/contrib/rsxntdj/lib/dll0w32.o(.data+0x28):fake: undefined reference to > `_os2dll' > env.o: In function `print_args': > env.c:181: undefined reference to `optind' > env.c:183: undefined reference to `optind' > env.o: In function `print_env': > env.c:200: undefined reference to `environ' > env.c:200: undefined reference to `environ' > options.o: In function `process_options': > options.c:69: undefined reference to `optind' > options.c:77: undefined reference to `optind' > options.o: In function `do_option': > options.c:220: undefined reference to `optarg' > options.c:256: undefined reference to `optarg' > options.c:264: undefined reference to `optarg' > options.c:265: undefined reference to `optarg' > I'm assuming that this means the getopt() routine is not being compiled in. Any ideas why? thanks, Walter