mingw32 - noncygwin32 gcc - libwinserve.a

Earnie Boyd earnie_boyd@hotmail.com
Tue Oct 14 06:21:00 GMT 1997


>From: Colin Peters <colin@bird.fu.is.saga-u.ac.jp>
>To: "'Earnie Boyd'" <earnie_boyd@hotmail.com>
>Subject: RE: mingw32 - noncygwin32 gcc - libwinserve.a
>Date: Tue, 14 Oct 1997 13:23:59 +0900
>
>Earnie Boyd[SMTP:earnie_boyd@hotmail.com] wrote:
>>I have ported rman-3.0.3a12 using cygwin32 without much ado.  I have 
>>ported mingw32 and gcc without the cygwin layer and "for grins" tried 
to 
>>port rman-3.0.3a12 vanilla WNT3.51.  I used the object file rman.o 
from 
>>the cygwin32 build and try to create rman.exe.  I have the paths set 
so 
>>that none of the gnuwin32 paths are searched.
>>
>>I resolved undefined references by adding the following libraries:
>>
>>   -lg -liberty -lwinserve
>>
>>   libg.a took care of a lot of _impure_ptr and __swbuf references.
>>
>>   libiberty.a took care of the __progname reference introduced by 
>>libg.a.
>>
>>   libwinserve.a took care of the _sbrk reference.
>>
>>Now I have an executable without the cygwin.dll reference.  However, 
>>when I execute I get an this error "The dynamic link library 
>>winserve.dll could not be found in the specified path...".
>
>It might be more straightforward to compile the rman.o object file
>in a mingw32 environment, though you may have to work around missing
>system calls (if any) in the source. I'm not sure that the approach
>you are taking will work.
>

---snip---


Thanks for your reply Colin.  I have recompiled with the mingw32 
environment and the program works fine.

I had previously copied all of the include files from cygwin to a 
directory I called "cinclude" and added it to the gcc search path.
I had to, however, mutz with combining the sys/types.h file from cygwin.  
This led to also futzing with time.h.  But I finally got the things 
compiled and linked and working.

I have found a bug in the mingw32 version of gcc though:
If you have spaces in a -Dmacro='"this that something"' gcc comes back 
with:

gcc: that: No such file or directory
gcc: something": Invalid argument

this happens with both MSDOS and BASH so it is not a shell thing.  The 
work around was to do a #define in the program.


??TOTALLY UNRELATED?? Is there an escape character such as the \ in BASH 
for MSDOS?  I ask this because the Makefile script has "%s(%s)" as part 
of a macro definition and in MSDOS you end up with s) as it tries to 
resolve %s(% as an environment variable.

Thanks again,

-        \\||//
---o0O0--Earnie--0O0o----
-earnie_boyd@hotmail.com-
------ooo0O--O0ooo-------


______________________________________________________
Get Your Private, Free Email at http://www.hotmail.com
-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".



More information about the Cygwin mailing list