Makefile -------------------- CC = i586-mingw32msvc-g++ -O2 -Wall -mms-bitfields -mwindows LD = i586-mingw32msvc-ld PKG_CONFIG_PATH = ../win32-dev/lib/pkgconfig MAKE = make CFLAGS := $(shell PKG_CONFIG_PATH=$(PKG_CONFIG_PATH)) -I/usr/include/mysql LIBS := $(shell PKG_CONFIG_PATH=$(PKG_CONFIG_PATH)) -L../win32-dev/lib CXXFLAGS = -c sql.exe: TestProg.cpp $(CC) -o $@ $(CFLAGS) TestProg.cpp $(LIBS) ------------------ Linker Error while compiling --------------------------------------------->>>>>> praveer@praveer-desktop:~/Projects/windows-side-devel/src/to_be_removed$ make i586-mingw32msvc-g++ -O2 -Wall -mms-bitfields -mwindows -o sql.exe -I/usr/include/mysql TestProg.cpp -L../win32-dev/lib /tmp/ccxejdwG.o:TestProg.cpp:(.text+0x71): undefined reference to `_mysql_init@4' /tmp/ccxejdwG.o:TestProg.cpp:(.text+0x95): undefined reference to `_mysql_real_connect@32' /tmp/ccxejdwG.o:TestProg.cpp:(.text+0xb7): undefined reference to `_mysql_close@4' /tmp/ccxejdwG.o:TestProg.cpp:(.text+0xd7): undefined reference to `_mysql_select_db@8' /tmp/ccxejdwG.o:TestProg.cpp:(.text+0xf6): undefined reference to `_mysql_query@8' /tmp/ccxejdwG.o:TestProg.cpp:(.text+0x10f): undefined reference to `_mysql_store_result@4' /tmp/ccxejdwG.o:TestProg.cpp:(.text+0x11b): undefined reference to `_mysql_num_rows@4' /tmp/ccxejdwG.o:TestProg.cpp:(.text+0x163): undefined reference to `_mysql_fetch_field@4' /tmp/ccxejdwG.o:TestProg.cpp:(.text+0x179): undefined reference to `_mysql_fetch_row@4' /tmp/ccxejdwG.o:TestProg.cpp:(.text+0x19b): undefined reference to `_mysql_num_fields@4' /tmp/ccxejdwG.o:TestProg.cpp:(.text+0x239): undefined reference to `_mysql_fetch_row@4' /tmp/ccxejdwG.o:TestProg.cpp:(.text+0x259): undefined reference to `_mysql_free_result@4' /tmp/ccxejdwG.o:TestProg.cpp:(.text+0x27d): undefined reference to `_mysql_close@4' /tmp/ccxejdwG.o:TestProg.cpp:(.text+0x2b9): undefined reference to `_mysql_close@4' collect2: ld returned 1 exit status make: *** [sql.exe] Error 1 <<<<<<<<<-----------------------------------