delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1996/12/05/08:05:54

From: dhighley AT halcyon DOT com ("David Highley")
Subject: Re: Problems With Undefined In Simple Program
5 Dec 1996 08:05:54 -0800 :
Sender: daemon AT cygnus DOT com
Approved: cygnus DOT gnu-win32 AT cygnus DOT com
Distribution: cygnus
Message-ID: <9612051454.AA04263.cygnus.gnu-win32@mail1.halcyon.com>
Mime-Version: 1.0
Original-To: "Ketan.Shah" <ketan DOT shah AT citicorp DOT com>
Original-Cc: <gnu-win32 AT cygnus DOT com>
X-Msmail-Priority: Normal
X-Priority: 3
X-Mailer: Microsoft Internet Mail 4.70.1155
Original-Sender: owner-gnu-win32 AT cygnus DOT com

Ketan,

Thank you for pointing me to the documentation.  I have not had time to
read through it, but I think it will answer my questions.

                                                     Regards,

 ___________________________________________________________
| David Highley              | Alias: Tree Huggers QA Lab   |
| Highley Recommended, Inc.  | Phone: (206) 669-0081        |
| 2927 SW 339th Street       | FAX    (206) 838-8509        |
| Federal Way, WA 98023-7732 | E-mail: dhighley AT halcyon DOT com |
|             http://www.halcyon.com/dhighley/              |
|____________________________|______________________________|



----------
> From: Ketan.Shah <ketan DOT shah AT citicorp DOT com>
> To: dhighley AT halcyon DOT com
> Subject: Re: Problems With Undefined In Simple Program
> Date: Wednesday, December 04, 1996 2:09 PM
> 
>      Hi,
>      
>      Check http://www.fu.is.saga-u.ac.jp/~colin/use-link.html for linking

>      details. Order in which you place your libs is important. Extracted
:
>      
>     
---------------------------------------------------------------------
>      The crt0.o file contains a call to main. If your main.o (or do.o, or

>      even the foo library) contains a main function then crt0 will
>      call that function to start your application. But what if you have 
>      written an application with WinMain instead of main? The
>      answer is the main function in libmingw32.a is called, and that 
>      function calls WinMain (after performing the extra setup
>      required). Everything is fine if WinMain is defined in one of your 
>      object files, but if it's in the foo library then you're in
trouble...
>      it won't get linked. In that case you need to type: 
>      
>      gcc -o test.exe main.o do.o -lmingw32 -lfoo
>      
>      This makes sure that the call to WinMain from the mingw32 library
can 
>      be resolved by the WinMain function in your foo
>      library... Isn't this fun?
> ------------------------------------------------------------
> 
>         You would probably need to use -lcygwin instead of -lmingw32
> 
> Ketan Shah
> 
> 
> ______________________________ Reply Separator 
> _________________________________
> Subject: Problems With Undefined In Simple Program
> Author:  owner-gnu-win32(a)cygnus.com at 
> INTERNET/O=AF1/C=US/A=MCI/P=CITICORP
> Date:    12/4/96 11:54 AM
> 
> 
> X-Msmail-Priority: Normal
> X-Priority: 3
> Precedence: bulk
> 
> I'm trying to compile a simple program on a Win95 system to get around
the 
> broken cat command and I have not been able to resolve one undefined.
> WinMain AT 16
> 
> This also leads me to think that gcc is defaulting to 16 bit mode.  This
is 
> my first attempt to compile any program in the cygnus ported environment.

> I have done an nm on all libraries in the directory:
> H-i386-cygwin32/i386-cygwin32/lib
> 
> Last I am using beta version 16.  I need to be able to create command
that 
> will recombine split files.   Thank you for any help you can provide.
>      
>                                                      Regards,
>      
>  ___________________________________________________________
> | David Highley              | Alias: Tree Huggers QA Lab   | 
> | Highley Recommended, Inc.  | Phone: (206) 669-0081        | 
> | 2927 SW 339th Street       | FAX    (206) 838-8509        | 
> | Federal Way, WA 98023-7732 | E-mail: dhighley AT halcyon DOT com | 
> |             http://www.halcyon.com/dhighley/              | 
> |____________________________|______________________________|
>      
>      
> -
> For help on using this list, send a message to 
> "gnu-win32-request AT cygnus DOT com" with one line of text: "help".
-
For help on using this list, send a message to
"gnu-win32-request AT cygnus DOT com" with one line of text: "help".

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019