> Solved it. Apparantely Ubuntu 9.10 has a libfltk.so which it > interprets as -lfltk and also has a fltk-config command.
Yes - a few distro's are putting fltk libs in their distributions now, though often older versions, so you do need to for that. Note also that if you pass "-lfltk" (or indeed -lanylib !) to the gcc tools, it will search for the file "libfltk.*" (or libanylib.*). If it finds both a ".a" and a ".so" version of the lib in question, it will always preferentially link to the ".so" version. That's the gcc default - always use the shared libs. This is a nuisance for me, as I much prefer static linking of the fltk objects. To force the ".a" to be picked up, you need to give its name explicitly to override the default linking behaviour. This I find annoying... > Since the default parameters of the fltk manual install are > set to /usr/local, the newly installed fltk-config wasn't > being called. I rambled on about this very topic in another thread about 5 minutes ago: but in general, I would not bother installing fltk at all - simply use it from the build folder, thereby ignoring whatever older versions the distro may already have installed to "help" you. This work works well, if you are static linking the fltk objects (as I always recommend anyway.) To make this work, I have a stack of symlinks for fltk-config variants, that point to the actual fltk-config scripts in each build tree (I have many versions of fltk on the go in parallel for testing...) E.g.; ln -s /home/builds/fltk-1.3/fltk-config fltk1-3-config ln -s /home/builds/fltk-1.1/fltk-config fltk1-1-config Etc... > So I manually called it through the terminal > and also had the include files changed as follows: If you use the tree-specific fltk-config, it will set the paths correctly for you. > <Program> > #include </usr/local/include/FL/Fl.H> > #include </usr/local/include/FL/Fl_Window.H> > #include </usr//local/include/FL/Fl_Box.H> No, NEVER do this - always give the paths as <FL/whatever.H> then over ridethe include file search order when invoking the compiler / linker. Of course, fltk-config will do this for you, or you can put "-I/home/builds/fltk-1.3/" on your compiler line, and that folder will then be searched *before* the stock /usr locations, thus resolving your problem. SELEX Galileo Ltd Registered Office: Sigma House, Christopher Martin Road, Basildon, Essex SS14 3EL A company registered in England & Wales. Company no. 02426132 ******************************************************************** This email and any attachments are confidential to the intended recipient and may also be privileged. If you are not the intended recipient please delete it from your system and notify the sender. You should not copy it or use it for any purpose nor disclose or distribute its contents to any other person. ******************************************************************** _______________________________________________ fltk mailing list [email protected] http://lists.easysw.com/mailman/listinfo/fltk

