FreeImage woes are better than RMagick woes.
First I tried installing FreeImage using this article:
http://seattlerb.rubyforge.org/ImageScience.html
Unfortunately, I get an error with make:
1 2 3 4 |
Source/Metadata/Exif.cpp:498: error: cast from 'BYTE*' to 'DWORD' loses precision make[1]: *** [Source/Metadata/Exif.o] Error 1 make[1]: Leaving directory `/usr/local/src/FreeImage' make: *** [default] Error 2 |
And If I proceeded with sudo make install, another error:
1 2 3 4 5 6 7 8 |
make -f Makefile.gnu install make[1]: Entering directory `/usr/local/src/FreeImage' install -m 644 -o root -g root Source/FreeImage.h /usr/include install -m 644 -o root -g root libfreeimage.a /usr/lib install: cannot stat `libfreeimage.a': No such file or directory make[1]: *** [install] Error 1 make[1]: Leaving directory `/usr/local/src/FreeImage' make: *** [install] Error 2 |
After Googling awhile I found another repo for FreeImage.
So Let's try this again:
1 2 3 4 5 6 |
cd /usr/local/src sudo wget http://ftp.cica.es/ubuntu/ubuntu/pool/universe/f/freeimage/freeimage_3.9.3.orig.tar.gz sudo tar -xvf freeimage_3.9.3.orig.tar.gz cd freeimage-3.9.3.repacked/FreeImage make sudo make install |
Then I did:
1 2 |
gem install -y rubyinline gem install -y image_science |
Now off to my attachment_fu and crossing my fingers that it works.... Yup it works.
I'm not sure if freeimage_3.9.3.orig.tar.gz is the latest version but I'm happy enough that it works with attachment_fu.
I really have no idea why I got the errors above but one thing is for sure: It didn't work for me!
[ Last updated: August 03, 2007 @ 11:06 AM ]
6 Responses to...
“FreeImage on my Slice”
Sorry, comments are closed for this article.




Hey, thanks a lot for posting this. I just ran into it while setting up a new machine.
One edit you might want to make is on line 6 it has
sudo make
which probably wants to be sudo make install.
I'm sure 99.75% of the ppl reading this will know that, but they'll also want to cut and paste :P
Thanks again.
Posted: August 2nd, 2007 at 10:19 PM
I'm glad it helped. I also fixed line 6 to read sudo make install :) Thanks.
Posted: August 3rd, 2007 at 11:08 AM
I've been bashing my head against this problem for the last half hour. Thank you so much!
Posted: August 20th, 2007 at 02:56 PM
Glad it helped.
Posted: August 20th, 2007 at 05:41 PM
OUCH. Sorry about the problems. I wish you'd had filed a bug so I could have helped. Matt Mower and I just worked out some changes to help and I added them to my instructions at: http://seattlerb.rubyforge.org/ImageScience.html (with props to this page)
Posted: August 22nd, 2007 at 03:51 PM
Hi Ryan, that's great. I wasn't sure if it was an actual bug or just me doing some goofy thing. Thanks for the fix. :)
Posted: August 22nd, 2007 at 08:47 PM