source: trunk/src/Odin32API/odinexe.cpp@ 976

Last change on this file since 976 was 976, checked in by sandervl, 26 years ago

Creation of source files with entrypoints for Win32 apps compiled in OS/2

File size: 1.1 KB
Line 
1/*
2 * Win32 Odin32 Application executable entrypoint
3 *
4 * Copyright 1999 Sander van Leeuwen (sandervl@xs4all.nl)
5 *
6 *
7 * Project Odin Software License can be found in LICENSE.TXT
8 *
9 */
10#include <os2.h>
11#include <win32type.h>
12#include <odinlx.h>
13#include <exceptions.h>
14
15//Win32 app entrypoint:
16int WIN32API WinMain(HINSTANCE hInstance,
17 HINSTANCE hPrevInstance,
18 LPSTR lpCmdLine,
19 int nCmdShow);
20
21extern "C" {
22 //Win32 resource table (produced by wrc)
23 extern DWORD _Resource_PEResTab;
24}
25//******************************************************************************
26//******************************************************************************
27int main(int argc, char *argv[])
28{
29 WINEXCEPTION_FRAME exceptFrame;
30
31 OS2SetExceptionHandler(&exceptFrame);
32 RegisterLxExe(WinMain, (PVOID)&_Resource_PEResTab);
33 OS2UnsetExceptionHandler(&exceptFrame);
34}
35//******************************************************************************
36//******************************************************************************
Note: See TracBrowser for help on using the repository browser.