Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sources DOT redhat DOT com Delivered-To: mailing list cygwin AT sources DOT redhat DOT com X-Originating-IP: [210.18.2.242] From: "Ajay Neti" To: cygwin AT cygwin DOT com Cc: ajaykumarn AT infy DOT com Subject: Cannot compile using gcc (GetModuleHandleA error) Date: Mon, 07 May 2001 15:40:16 Mime-Version: 1.0 Content-Type: text/plain; format=flowed Message-ID: X-OriginalArrivalTime: 07 May 2001 15:40:16.0375 (UTC) FILETIME=[0371E870:01C0D70C] Hi, I have extracted the gcc zip file from cygwin site, and I am trying to compile the following C file on Windows 98 :- int main(int argc, char** argv) { int a= 3+2; return 0; } The compiler command I give and the error I get are :- D:\dev>gcc -I D:\Cygnus\usr\include -L C:\Windows\System hello.c /cygdrive/d/CYGNUS/USR/BIN/../lib/libcygwin.a(_cygwin_crt0_common.o)(.text+0xe6) :_cygwin_crt0_common.cc: undefined reference to `GetModuleHandleA AT 4' collect2: ld returned 1 exit status Any ideas on how to fix this? I saw some of the archived messages on this mail list, and I tried to link to various *32 libraries as indicated there, but I always ended up with the same error. Thanks a bunch, Ajay _________________________________________________________________________ Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com. -- Want to unsubscribe from this list? Check out: http://cygwin.com/ml/#unsubscribe-simple