Unable to use SDL2 with SDL_ttf.h

15 views
Skip to first unread message

Paul King

unread,
Mar 30, 2023, 1:09:38 AM3/30/23
to emscripten-discuss
Hi all,

I am trying to compile an SDL2 project using on the command line using emcc. In the my makefile I have the following lines:

debug:
emcc $(wildcard src/*.cpp) \
-sUSE_SDL=2
-o ./out/build/x64-debug \
-lSDL2 \
-lSDL2_image \
-lSDL2_ttf \
-lSDL2_mixer

emcc =02 *.o -o paultris.js ./out/build/x64-debug

when I type make I get the following error:

Capture.PNG

I don't why it is unable to find the header file as I have specifically told cmake to use lSDL2_ttf. Is there anything else that I need to include in the makefile?

Regards,
Paul King

Denis Mihailovich

unread,
Mar 31, 2023, 11:34:28 AM3/31/23
to emscripten-discuss
May be "-s USE_SDL_TTF=2"?

четверг, 30 марта 2023 г. в 08:09:38 UTC+3, paulk...@gmail.com:
Reply all
Reply to author
Forward
0 new messages