Using your Makefile, I get linker errors. This is the command and some of the messages.
cc -lSDL2 -lSDL2_ttf st.c -o st
/usr/bin/ld: /tmp/ccISkhgJ.o: in function `vec':
st.c:(.text+0x25d): undefined reference to `SDL_SetRenderDrawColor'
/usr/bin/ld: st.c:(.text+0x295): undefined reference to `SDL_RenderDrawLine'
/usr/bin/ld: /tmp/ccISkhgJ.o: in function `chars':
st.c:(.text+0x3d3): undefined reference to `TTF_SetFontSize'
The problems are:
The libraries need to go after st.c.
The math library is needed.
I had success compiling using this command:
cc st.c -lSDL2 -lSDL2_ttf -lm -o st
Hello,
Great job, I'm excited to see this! (CC @sebras)
Using your Makefile, I get linker errors. This is the command and some of the messages.
The problems are:
I had success compiling using this command:
cc st.c -lSDL2 -lSDL2_ttf -lm -o st