Select Category
Sitemap Help Contact
print article

Install ImageMagick via SSH

For packages with SSH access.

Follow the steps below to install the ImageMagick software in your webspace.

ImageMagick┬« is a software suite to create, edit, compose, or convert bitmap images. It can read and write images in a variety of formats (over 100) including DPX, EXR, GIF, JPEG, JPEG-2000, PDF, PhotoCD, PNG, Postscript, SVG, and TIFF. Use ImageMagick to resize, flip, mirror, rotate, distort, shear and transform images, adjust image colors, apply various special effects, or draw text, lines, polygons, ellipses and B├ęzier curves.

Step 2
You will now have to download the ImageMagick source code from the website by using the wget command.
(uiserver):u12345678:~ > wget
=> `ImageMagick.tar.gz'
Connecting to||:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 12,919,110 (12M) [application/x-gzip]

87% [=============================================> ] 11,244,648 2.66M/s ETA 00:00
Step 3
When the tar.gz file has finished downloading, use the tar command to uncompress the file.
(uiserver):u12345678:~ > tar xfvz ImageMagick.tar.gz


ImageMagick-6.7.4-1/utilities/composite.1 ImageMagick-6.7.4-1/utilities/convert.1 ImageMagick-6.7.4-1/utilities/ ImageMagick-6.7.4-1/utilities/ ImageMagick-6.7.4-1/utilities/conjure.1 ImageMagick-6.7.4-1/utilities/montage.1 ImageMagick-6.7.4-1/utilities/
(uiserver):u12345678:~ >
Step 4
Use the cd command to change directories to the ImageMagick folder created by uncompressing the tar.gz file.
(uiserver):u12346578:~ > cd ImageMagick-6.7.4-1/
(uiserver):u12345678:~/ImageMagick-6.7.4-1 >
Step 5
Use the pwd to print the working directory. This will output the full folder path to get to the ImageMagick-X.X folder. We need the full folder path so that we can use it to specify where ImageMagick should be installed.
(uiserver):u12345678:~/ImageMagick-6.7.4-1 > pwd
(uiserver):u12345678:~/ImageMagick-6.7.4-1 >
Step 6
We now need to run the ./configure command to prepare for code compilation. You will not be able to install ImageMagick without specifying an install location because you do not have permissions to install to the default location on the server. So in this step we use the folder structure obtained from the last step and use the --prefix= option to specify where ImageMagic should be installed. The htdocs folder is the root of your webspace. In the example below, we specify to install ImageMagick in an ImageMagick subfolder.
(uiserver):u12345678:~/ImageMagick-6.7.4-1 > ./configure --prefix=/kunden/homepages/30/d339922114/htdocs/ImageMagick

LDFLAGS = -L/usr/lib
MAGICK_LDFLAGS = -L/usr/local/lib -L/usr/lib
LIBS = -lMagickCore -llcms -lfreetype -ljpeg -lpng12 -lfontconfig -lXext -lXt -lSM -lICE -lX11 -lbz2 -lxml2 -lz -lm -lpthread
CXX = g++
CXXFLAGS = -g -O2 -pthread

(uiserver):u59908830:~/ImageMagick-6.7.4-1 >
Step 7
Next, use the make command to compile the source code.
(uiserver):u12345678:~/ImageMagick-6.7.4-1 > make

CC utilities/import.o
CCLD utilities/import
CC utilities/mogrify.o
CCLD utilities/mogrify
CC utilities/montage.o
CCLD utilities/montage
CC utilities/stream.o
CCLD utilities/stream
make[1]: Leaving directory `/homepages/30/d339922114/htdocs/ImageMagick-6.7.4-1'
(uiserver):u12345678:~/ImageMagick-6.7.4-1 >
Step 8
Finally, use make install command to install the software to the ImageMagick folder (or whatever location you specified in step 6).
(uiserver):u12345678:~/ImageMagick-6.7.4-1 > make install


/usr/bin_us/install -c -m 644 wand/MagickWand.h wand/animate.h wand/compare.h wand/composite.h wand/conjure.h wand/convert.h wand/deprecate.h wand/display.h wand/drawing-wand.h wand/identify.h wand/import.h wand/magick-image.h wand/magick-property.h wand/magick-wand.h wand/magick_wand.h wand/mogrify.h wand/montage.h wand/pixel-iterator.h wand/pixel-wand.h wand/stream.h wand/wand-view.h '/kunden/homepages/30/d339629174/htdocs/ImageMagick/include/ImageMagick/wand'
make[2]: Leaving directory `/homepages/30/d339629174/htdocs/ImageMagick-6.7.4-1'
make[1]: Leaving directory `/homepages/30/d339629174/htdocs/ImageMagick-6.7.4-1'
(uiserver):u12345678:~/ImageMagick-6.7.4-1 >

When the command prompt returns after issuing the make install command, the installation is finished. You can now delete the tar.gz file and the ImageMagick-6.7.4-1 folder if you wish.

For additional information, you may want to reference: