Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2000-02-17 22:38:31 +0300
committerChristopher Faylor <me@cgf.cx>2000-02-17 22:38:31 +0300
commit369d8a8fd5e887eca547bf34bccfdf755c9e5397 (patch)
tree5c5dc851bf01a5938662571357ffd5d7bb152a79 /winsup/w32api
parent4415a7ef3e26c669f5f7c5c7efbf7b6ea9b7e2f4 (diff)
import winsup-2000-02-17 snapshot
Diffstat (limited to 'winsup/w32api')
-rw-r--r--winsup/w32api/README91
-rw-r--r--winsup/w32api/include/excpt.h17
2 files changed, 108 insertions, 0 deletions
diff --git a/winsup/w32api/README b/winsup/w32api/README
new file mode 100644
index 000000000..9868968be
--- /dev/null
+++ b/winsup/w32api/README
@@ -0,0 +1,91 @@
+ Free headers and libraries for the Win32 API
+
+ Written by Anders Norlander
+ Send bug reports and questions to anorland@hem2.passagen.se
+ URL: http://www.acc.umu.se/~anorland/gnu-win32/
+
+* License
+
+ You are free to use, modify and copy this package. No restrictions
+ are imposed on programs or object files compiled with this library.
+
+ You may not restrict the the usage of this library.
+
+ You may distribute this library as part of another package or as a
+ modified package if and only if you do *not* restrict the usage of
+ the portions consisting of this (optionally modified) library.
+
+ If distributed as part of another package, please notify the author
+ of what you are going to do. If distributed as a modified package,
+ this file *must* be included.
+
+ This library is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+
+* What is it?
+
+ This is a free set of headers and import libraries for the Win32
+ API. The library differs from the GNU Windows32 library in that I
+ have tried to use a file structure that mirrors Microsoft's. I
+ don't like having *all* definitions in one single header as in the
+ GNU Windows32 library, I want a clean separation between different
+ parts of the API.
+
+ Daniel Guerrero Miralles contributed the DirectX 6.1 import
+ libraries and DirectX GUID definitions.
+
+ See the files NOTES and TODO for what needs to be done.
+
+* Size does matter
+
+ Since the WIN32 API is severely bloated (as most MS products seem to
+ be) the headers are designed to be as compact as possible, while
+ still being readable, in order to minimize parsing time.
+
+ The convention is to omit parameter names for function prototypes,
+ no excessive white space. Struct/union members are indented with tab
+ characters to make them readable. Comment only when necessary.
+
+ If you are contributing a patch please follow the above mentioned
+ convention. Make sure your editor does not convert tabs to spaces.
+
+* What do I need to use it?
+
+ The library is intended for use with egcs 1.1 or later but it is
+ possible to use with some other tools as well (although it is not
+ very useful). LCC-Win32, MSVC and Borland C++ 5.01 or higher may
+ work as well. The import libraries are for GNU tools only.
+
+ The library requires egcs 1.1 or later, since the `#pragma pack'
+ feature is used. Mumit Khan provides egcs patches and binaries for
+ win32 at `http://www.xraylith.wisc.edu/~khan/software/gnu-win32/'.
+
+ If you are going to use C++ COM objects, you will need a version of
+ egcs that recognizes the `comobject' attribute and then define
+ HAVE_COMOBJECT when compiling your program. Antonio Mendes de
+ Oliveira Neto has a prebuilt version at
+ `http://li.facens.br/EGCS-WIN32/english/index.html'. Note that this
+ is very experimental. If you want to use COM objects in C++ but with
+ C interfaces you must define CINTERFACE.
+
+ Objective-C programs cannot use COM functionality because of
+ conflicts between the interface define and the Objective-C
+ @interface directive. There is also a conflict between the windows
+ Obj-C BOOL types. To avoid this conflict you should use WINBOOL in
+ all places where you would use BOOL in a C/C++ windows program. If
+ you include any windows headers *after* `windows.h' you must use the
+ method outlined below:
+
+ /* non-windows includes */
+ #include <objc/objc.h>
+ ...
+ /* windows specific headers */
+ #include <windows.h>
+ #define BOOL WINBOOL
+ #include <commctrl.h>
+ ...
+ #undef BOOL
+ ...
+ /* include other headers */
+
diff --git a/winsup/w32api/include/excpt.h b/winsup/w32api/include/excpt.h
new file mode 100644
index 000000000..39621a8f6
--- /dev/null
+++ b/winsup/w32api/include/excpt.h
@@ -0,0 +1,17 @@
+#ifndef _EXCPT_H
+#define _EXCPT_H
+
+/* FIXME: This will make some code compile. The programs will most
+ likely crash when an exception is raised, but at least they will
+ compile. */
+#ifdef __GNUC__
+#define __try
+#define __except(x) if (0) /* don't execute handler */
+#define __finally
+
+#define _try __try
+#define _except __except
+#define _finally __finally
+#endif
+
+#endif