Date: Thu, 6 May 1999 10:06:02 +0300 (IDT) From: Eli Zaretskii X-Sender: eliz AT is To: Jari Tuominen cc: djgpp AT delorie DOT com Subject: Re: Mysterious _GLOBAL_OFFSET_TABLE_ In-Reply-To: <001301be970f$644b1b60$9cf2e5c1@jairn-tietokone> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: djgpp AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk On Wed, 5 May 1999, Jari Tuominen wrote: > kernel32.o(.text+0x168):kernel32.c: more undefined references to = > `_GLOBAL_OFFSET_TABLE_' follow > kernel32.o(.text+0x301):kernel32.c: undefined reference to `___main' > > C:\jtm\bin\JTMOS\KERNEL32>type c:\jtm\bin\bat\mk.bat > @echo off > gcc -fpic -w -c %1.c -Wall -O > rem -fstrength-reduce -fomit-frame-pointer -nostdinc > ld %1.o -o %1.bin -oformat binary -Ttext 0x10000 -Tdata 0x20000 -Tbss = > 0x20000 > > ....................... > What is this _GLOBAL_OFFSET_TABLE_? It is there because you used -fpic. Read the docs of -fpic in the GCC manual (the node in gcc.info is called "Code Gen Options"). Are you sure you need -fpic? And please don't post in HTML, it makes it very difficult to read.