开发者

Troubles with compiling with FLTK framework

I seem to have problems compiling FLTK programms using anything other than the fltk-config script.

I have copied the source from the "Hello world" program in the tutorial. When I run fltk-config --compi开发者_Go百科le hello.cpp it prints out

g++ -I/usr/local/include -I/usr/local/include/FL/images -mwindows -DWIN32 -DUSE_OPENGL32 -D_LARGEFILE_SOURCE -D_LARGEFILE32_SOURCE -o 'hello' 'hello.cpp' -mwindows /usr/local/lib/libfltk.a -lole32 -luuid -lcomct132

and compiles just fine. But when I print in the same thing myself, it says, that ld.exe cannot find -lcomct132.

I use FLTK 1.3.0 compiled on MinGW under WinXP.


I bet that the fltk-config script is setting environment variables that you have not configured. Check the FLTK documentation and see the proper environment variables you need to set to compile without the helper script.

Edit: Did some research

Apparently you're not the only one that has linking problems. I found a similar problem on the forum here and on the fltk.general newsgroup. The consensus seems to be that order of the linking arguments are important, and that using the fltk-config script is the easiest way to proceed.


I didn't get this specific error, but I did have problem with the "lcomct132". Maybe your error has something related to it. So, in my case, here it was the SOLUTION:

  • The "132" is in fact only "32". The "1" isn't a number but smallcase letter L. So it is "lcomctl32" !
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜