Imagemagick+Jmagick安装

需要准备的安装包
jasper-1.701.0.zip    
jmagick-6.4.0-src.tar.gz 
ImageMagick-6.4.0-0.tar.gz 
tiff-v3.6.1.tar.gz
freetype-2.2.1.tar.gz       
jbigkit-1.5.tar.gz     
jpegsrc.v6b.tar.gz
libpng-1.2.5.tar.bz2
ImageMagick和JMagick的版本需要一致,不然安装时会报错"Unable to find ImageMagick library”
 
1、支持JP2,JPC格式
unzip jasper-1.701.0.zip&&cd jasper-1.701.0
./configure --enable-shared
make&&make install
 
2、支持JPEG格式
tar zxvf jpegsrc.v6b.tar.gz&&cd jpeg-6b
./configure --enable-shared
make&&make install
 
3、支持tiff格式
tar zxvf tiff-v3.6.1.tar.gz&&cd tiff-v3.6.1
./configure
make&&make install
 
4、支持freetype2
tar zxvf freetype-2.1.7.tar.gz&&cd freetype-2.1.7
./configure
make&&make install
 
5、支持png格式
tar zxvf libpng-1.2.5.tar.gz&&cd libpng-1.2.5
cp scripts/makefile.linux ./makefile
make&&make install
 
6、支持JBIG格式
tar zxvf jbigkit-1.5.tar.gz&&cd jbigkit
make&&make test
cp -r libjbig /usr/local/include/
cd /usr/local/include/libjbig
cp jbig.h /usr/local/include
cp libjbig.a /usr/local/lib
 
7、安装Imagemagick
tar -xzf ImageMagick-6.4.0-0.tar.gz && cd ImageMagick-6.4.0
./configure --prefix=/usr/local/ImageMagick/
make && make install
 
8、安装jdk
mkdir /usr/java
chmod +x jdk-6u32-linux-i586.bin
sh �Cx jdk-6u32-linux-i586.bin
 
9、安装Jmagick
ln -s /usr/java/jdk1.6.0_32/bin/java /usr/bin
ln -s /usr/java/jdk1.6.0_32/bin/javac /usr/bin
ln -s /usr/java/jdk1.6.0_32/bin/javap /usr/bin
ln -s /usr/java/jdk1.6.0_32/bin/javah /usr/bin
ln -s /usr/java/jdk1.6.0_32/bin/jar /usr/bin
tar -xzf jmagick-6.4.0-src.tar.gz && cd 6.4.0
./configure --prefix=/usr/local/JMagick --with-java-home=/usr/java/jdk1.6.0_32/
报错,提示"Unable to find ImageMagick header files”
./configure --prefix=/usr/local/JMagick --with-java-home=/usr/java/jdk1.6.0_32/ --with-magick-home=/usr/local/ImageMagick/
make && make install
 
安装好所有之后,测试
/usr/local/ImageMagick/bin/convert --version
Version: ImageMagick 6.4.0 05/17/12 Q16 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2008 ImageMagick Studio LLC

你可能感兴趣的:(安装,包)