Refocus it.
2007 Feb 6 at 09:31 » Tagged as :photography, wordpress,
The other day, I was scratching around trying to install the iterative refocus plugin for GIMP. The errors were many. After fixing many of them, I came across what looked like an insurmountable error related to a missing library. Well the libraries are there, they were installed using fink and can be found in the /sw/lib folder. Unfortunately the linker only looks for them in the /usr/local/lib/ folder.
A partial solution was found on the fink FAQ. They suggest moving /usr/local/ out of the way. That's only a partial solution. gcc continues to ignore the -L directive. So I made symbolic links in /usr/local to the /sw/lib and /sw/include directories. The installation then progressed a few steps further before screeching to a halt again. This time the sand in the grease was provided by some pango packages.
I installed all the pango packages along with freetype and libintl but the make system still insisted on looking for libintl.3.dylib instead of libintl.dylib. I made another symbolic link (clutching at straws now). Predictably it fails.
gcc -g -O2 -Wall -o refocus-it main-cmd.o getopt.o getopt1.o ../src/librefocus-it.a -lm -lm/usr/bin/ld: Undefined symbols:
_bindtextdomain
_gettext
_textdomain
locate told me that libintl.3.dylib file is a part of the gimp libraries. So I created a symbolic link (still don't know why the linker doesn't look for the libraries in the right place)
sudo ln -s /Applications/Imaging/Gimp.app/Contents/Resources/lib/libintl.3.dylib libintl.3.dylib
That didn't make the problem go away. In the end I decided to edit config.h and removed the #define ENABLE_NLS and #define HAVE_SETLOCALE lines. That cleared up the compilation problems!
Hopefully make install will not produce any errors. It didn't. But why did it place the plug in /plug-in/ folder instead of in the /Applications/Imaging/Gimp.app/Contents/Resources/lib/gimp/2.0/plug-ins as it should? After all I have been through, it's a simple matter to push it there. Now comes the million beer question: does the iterative refocus plug in actually on my macbook? yes.