delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1998/09/16/17:49:22

From: root AT jacob DOT remcomp DOT fr (root)
Subject: Re: libkernel32a.lib
16 Sep 1998 17:49:22 -0700 :
Message-ID: <m0zJGnJ-0002iAC.cygnus.gnu-win32@jacob.remcomp.fr>
References: <Pine DOT SUN DOT 3 DOT 93 DOT 980914231821 DOT 22075G-100000 AT modi DOT xraylith DOT wisc DOT edu>
To: khan AT xraylith DOT wisc DOT edu (Mumit Khan)
Cc: gnu-win32 AT cygnus DOT com

TryEnterCriticalSection is not defined in the version of kernel32.dll under
windows 95.

Now, if Mumit would add an entry to the import libraries, this would make
the linker happy but... at run time your program would not load and you 
would get a dialog box with
foo.exe is linked to missing export TryEnterCriticalSection.

You have to use windows NT 4.0 or higher to get that function. 
The correct solution for this problem is obvious:

Mumit would have to duplicate all import libraries, to account for the fact
that the APIs differ: one for windows 95 users, and the other for Windows NT
3.5, and yet another for windows NT 4.0. With the appearing of windows NT 5.0 the
set of needed libraries would increase by yet another one.

Then, Mumit would have to look at all the (approx 3000) APIs of the basic 
win32 API and see if the exist under all systems.

Another, solution, is the one that lcc-win32 has used: If a function exists,
it is included in the import library. If you use TryEnterCriticalSection with
lcc-win32 you will see no errors at link time, but your program will NOT load
under windows 95/windows NT 3.51.

This choice is based in time considerations: I can't do anything else. I can't
have 3 or 4 different sets of import libraries... I think that situation with
gcc is very similar. We are earning no big bucks with this (personally I'm not
earning anything at all!!!) so we have a limited resource pool to do the
enormous amount of work a compiler system requires.

If you have problems with this approach, I recommend you to spend the US$ 2.000
and get Visual Studio professional 6.0.

There, you will get everything you need and much (MUCH) more.

Yours sincerely

-- 
Jacob Navia	Logiciels/Informatique
41 rue Maurice Ravel			Tel 01 48.23.51.44
93430 Villetaneuse 			Fax 01 48.23.95.39
France
-
For help on using this list (especially unsubscribing), 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