From 4e51199f1103d2d9daa563b63d0e8f22c36fbe8a Mon Sep 17 00:00:00 2001 From: Leo Tenenbaum Date: Wed, 25 Nov 2020 09:17:00 -0500 Subject: got windows build to work --- main.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'main.c') diff --git a/main.c b/main.c index 6ba157b..063f7eb 100644 --- a/main.c +++ b/main.c @@ -1,6 +1,10 @@ #include "base.h" no_warn_start +#if _WIN32 +#include +#else #include +#endif no_warn_end #include #include @@ -24,7 +28,12 @@ static void die(char const *fmt, ...) { } +#if _WIN32 +INT WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, + PSTR lpCmdLine, INT nCmdShow) { +#else int main(void) { +#endif setlocale(LC_ALL, ""); // allow unicode if (SDL_Init(SDL_INIT_VIDEO|SDL_INIT_TIMER) < 0) die("%s", SDL_GetError()); @@ -84,7 +93,7 @@ int main(void) { glClear(GL_COLOR_BUFFER_BIT); glColor3f(1,1,1); - text_render(font, u8"hőello☐øλㄔ☺☹", 50, 50); + text_render(font, "hellσ! öθ☺", 50, 50); if (text_has_err()) { printf("Text error: %s\n", text_get_err()); break; -- cgit v1.2.3