From 697dc565a9cbfeec271a8ee6daa07faf502350e0 Mon Sep 17 00:00:00 2001 From: Joshua Ashton Date: Mon, 15 Jun 2020 22:05:35 +0100 Subject: [PATCH] demos: Use WinMain instead of wmain on Win32 We're going to want to build as a GUI app, so we need to use real WinMain on Windows for this. Signed-off-by: Joshua Ashton --- demos/gears.c | 6 +++++- demos/triangle.c | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/demos/gears.c b/demos/gears.c index 2045b3cd..bee91da6 100644 --- a/demos/gears.c +++ b/demos/gears.c @@ -878,7 +878,11 @@ static int cxg_main(void) } #ifdef _WIN32 -int wmain(void) +int WINAPI WinMain( + HINSTANCE hInstance, + HINSTANCE hPrevInstance, + LPSTR lpCmdLine, + int nCmdShow) #else int main(void) #endif diff --git a/demos/triangle.c b/demos/triangle.c index bac1cdc5..cc8af2e6 100644 --- a/demos/triangle.c +++ b/demos/triangle.c @@ -393,7 +393,11 @@ static int cxt_main(void) } #ifdef _WIN32 -int wmain(void) +int WINAPI WinMain( + HINSTANCE hInstance, + HINSTANCE hPrevInstance, + LPSTR lpCmdLine, + int nCmdShow) #else int main(void) #endif