Techminded

Getting swftools on Linux (Ubuntu)

Get the source code and dependencies

Swftools package that provides pdf2swf tool currently available only for Ubuntu Hardy that is long time all not about us. So to get it we will build it from source. First of all navigate to the dir you are going to store sources, suggest somewhere they will not be deleted, e.g. /usr/local/src. cd to it and download the sources.

$sudo su
#cd /usr/local/src
#wget http://swftools.org/swftools-0.9.1.tar.gz
#tar xvzf swftools-0.9.1.tar.gz
#wget http://download.savannah.gnu.org/releases-noredirect/freetype/freetype-2.3.12.tar.gz
#tar jpegsrc.v7.tar.gz

By the time you reading version number as far as url may differs. We downloaded also jpegsrc library as it's swftool's dependency. We should install also freetype library and xpdf reader as they also required. Also install checkinstall if you haven't done it already. This tool will help us to build .deb packages from built sources.

#apt-get install libfreetype6 libfreetype6-dev xpdf-reader checkinstall

Build & Install

Let's build jpegsrc first:

#cd jpeg-7
#configure --prefix=/usr
#make
#checkinstall -D
#cd ../

pay attention to prefix configure option this will switch building to use /usr tree instead /usr/local that is less painfull. Checkinstall will ask you some questions, feel free to type and choose anything. After this it will make .deb package from your built sources and install it to the system. Then do the same for swftools:

 

#cd swftools-0.9.1
#configure --prefix=/usr
#make
#checkinstall -D
#cd ../

That's actually it:)

Links

Bit more tricky way is described here: https://designbye.wordpress.com/2010/02/23/installing-swftools-and-pdf2swf-on-ubuntu-linux/

Comments