I am trying to compile a c application with the gtk 3.0 library with tcc. The documentation says the command to run to compile is
gcc `pkg-config --cflags gtk+-3.0` -o [executable name] [source file] `pkg-config --libs gtk+-3.0`
I am trying to use tcc to compile, and it from what I can tell, the syntax should be the same. However, where gcc compiles it fine, when I use tcc, compilation fails with the error:
tcc: error: undefined symbol 'main'
I isolated the problem to the -pthread flag inserted by pkg-config --cflags gtk+-3.0
Thus, running a simple "Hello, World" c program and compiling with
tcc -pthread -o [executable name] [source file]
results in the same error. Am I compiling wrong, is it a compiler bug, or something else?