[Etherboot-developers] Fwd: Error in make
Brought to you by:
marty_connor,
stefanhajnoczi
|
From: Marty C. <md...@th...> - 2001-03-06 21:57:39
|
Here's an interesting bug detected by rom-o-matic.net. It appears this fellow is trying to generate a ROM image with -DANSIESC turned on. All goes well until: gcc -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 -o bin32/ansiesc.o -c ansiesc.c ansiesc.c: In function `docommand': ansiesc.c:172: warning: implicit declaration of function `tftp' which is here: static void docommand(unsigned char ch) { if (ch == '#') { /* include file */ if (!in_download) { in_download = 1; download(args[0],downloadmotd); /* line 172 */ in_download = 0; } } now "download" is defined in etherboot.h as: #ifndef DOWNLOAD_PROTO_NFS #undef DOWNLOAD_PROTO_TFTP #define DOWNLOAD_PROTO_TFTP /* default booting protocol */ #endif #ifdef DOWNLOAD_PROTO_TFTP #define download(fname,loader) tftp((fname),(loader)) #endif #ifdef DOWNLOAD_PROTO_NFS #define download(fname,loader) nfs((fname),(loader)) #endif unfortunately, there is no function prototype for tftp anywhere in sight, so we get the "implicit declaration error" noted above. I'm guessing we need function prototypes for tftp() and nfs() in ansiesc.c. later on we get: gcc -O2 -o bin/makerom makerom.c ld -N -Ttext 0x94000 -e _start -o bin32/3c90x.tmp bin32/start32.o bin32/config-3c90x.o bin32/3c90x.o bin32/pci.o bin32/bootlib.a bin32/bootlib.a(ansiesc.o): In function `docommand': /tmp/ROM12QbeH/ansiesc.c:172: undefined reference to `tftp' make: *** [bin32/3c90x.tmp] Error 1 make: Leaving directory `/tmp/ROM12QbeH' One structural thought I had was to perhaps put the tftp code that is currently in main.c into its own file "tftp.c" much like the nfs code is in "nfs.c", for modularity. We'd still need function prototypes, of course. Anyway, the option "-DANSIESC" seemed to trigger the problem. Before I get too deep into debugging it, does anybody else want to give it a go? Marty ---------------- Begin Forwarded Message ---------------- Date: 3/6/2001 2:40 AM Received: 3/6/2001 2:52 AM From: pau...@sv... To: web...@en... Build failed. Status = 2. Following is the output from make: make: Entering directory `/tmp/ROM12QbeH' gcc -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 -DINCLUDE_3C90X -o bin32/3c90x.o -c 3c90x.c gcc -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 -DINCLUDE_3C90X -o bin32/config-3c90x.o -c config.c gcc -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 -o bin32/pci.o -c pci.c /tmp/ccudNRVk.s: Assembler messages: /tmp/ccudNRVk.s:140: Warning: indirect lcall without `*' /tmp/ccudNRVk.s:244: Warning: indirect lcall without `*' /tmp/ccudNRVk.s:312: Warning: indirect lcall without `*' /tmp/ccudNRVk.s:379: Warning: indirect lcall without `*' /tmp/ccudNRVk.s:448: Warning: indirect lcall without `*' /tmp/ccudNRVk.s:516: Warning: indirect lcall without `*' /tmp/ccudNRVk.s:584: Warning: indirect lcall without `*' /tmp/ccudNRVk.s:656: Warning: indirect lcall without `*' gcc -E -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 start32.S | as -o bin32/start32.o {standard input}: Assembler messages: {standard input}:360: Warning: indirect ljmp without `*' gcc -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 -o bin32/main.o -c main.c gcc -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 -o bin32/osloader.o -c osloader.c gcc -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 -o bin32/nfs.o -c nfs.c gcc -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 -o bin32/misc.o -c misc.c gcc -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 -o bin32/ansiesc.o -c ansiesc.c ansiesc.c: In function `docommand': ansiesc.c:172: warning: implicit declaration of function `tftp' gcc -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 -o bin32/bootmenu.o -c bootmenu.c gcc -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 -o bin32/md5.o -c md5.c gcc -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 -o bin32/floppy.o -c floppy.c gcc -E -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 serial.S | as -o bin32/serial.o gcc -DIMAGE_MENU -DMOTD -DASK_BOOT=3 -DANS_DEFAULT=ANS_NETWORK -DEMERGENCYDISKBOOT -DSIZEINDICATOR -DBACKOFF_LIMIT=7 -DELF_IMAGE -DIMAGE_MULTIBOOT -DCONSOLE_CRT -DCOMCONSOLE=0x3F8 -DCONSPEED=9600 -DCOMPARM=0x03 -DANSIESC -DGFX -DTRY_FLOPPY_FIRST=0 -DUSE_INTERNAL_BUFFER -O2 -g -fstrength-reduce -fomit-frame-pointer -m386 -malign-jumps=1 -malign-loops=1 -malign-functions=1 -Wall -W -Wno-format -Wno-unused -DVERSION_MAJOR=4 -DVERSION_MINOR=7 -DVERSION=\"4.7.21\" -DRELOC=0x94000 -o bin32/timer.o -c timer.c ar rv bin32/bootlib.a bin32/main.o bin32/osloader.o bin32/nfs.o bin32/misc.o bin32/ansiesc.o bin32/bootmenu.o bin32/md5.o bin32/floppy.o bin32/serial.o bin32/timer.o a - bin32/main.o a - bin32/osloader.o a - bin32/nfs.o a - bin32/misc.o a - bin32/ansiesc.o a - bin32/bootmenu.o a - bin32/md5.o a - bin32/floppy.o a - bin32/serial.o a - bin32/timer.o ranlib bin32/bootlib.a gcc -O2 -o bin/makerom makerom.c ld -N -Ttext 0x94000 -e _start -o bin32/3c90x.tmp bin32/start32.o bin32/config-3c90x.o bin32/3c90x.o bin32/pci.o bin32/bootlib.a bin32/bootlib.a(ansiesc.o): In function `docommand': /tmp/ROM12QbeH/ansiesc.c:172: undefined reference to `tftp' make: *** [bin32/3c90x.tmp] Error 1 make: Leaving directory `/tmp/ROM12QbeH' Please let us know that this happened. ----------------- End Forwarded Message ----------------- --- Try: http://rom-o-matic.net/ to make Etherboot images instantly. Name: Martin D. Connor US Mail: Entity Cyber, Inc.; P.O. Box 391827; Cambridge, MA 02139; USA Voice: (617) 491-6935, Fax: (617) 491-7046 Email: md...@th... Web: http://www.thinguin.org/ |