Re: How to compile tictactoe widget example in tutorial



You need to compile and link *both* the .c files into *one*
executable. Also, please don't get into the habit of using pkg-config
--cflags --libs, even if it happens to work most of the time on Linux.
Specify C compiler flags and libraries separately in the appropriate
locations on the command line.

I.e.:

gcc -Wall -g  `pkg-config --cflags gtk+-2.0` tictactoe.c
test_tictactoe.c -o ttt `pkg-config --libs gtk+-2.0`

--tml



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]