ericshliao
01-21-2008, 04:20 AM
I am trying to build iPDF from source code with the scratchbox toolchain. Because I am a newbie in Linux and GCC, I run into many errors. I wonder if somebody can provide step by step tutorial on building iPDF. Thanx.
ericshliao
01-23-2008, 09:16 AM
Alright, I made it with official SDK. Here is my steps:
1. Setup an Debian Linux.
2. In command prompt, execute "svn co http://developer.irexnet.com/repo/". It will download the whole directory structur of iPDF source code. The newest version should be in "applications/ipdf/trunk". Copy the "trunk" directory to, say "/tmp".
3. Download the official SDK package. Unpack it to "/". You should see a "/usr/local/arm" after unpacking. If you unpack it to somewhere else, error may occur during compile. The official SDK already contains needed libs, such as gtk, poppler, eripc, scribble... It will be easier to compile iPDF on official SDK than on unofficial toolchain of scratchbox.
3. Type "export PATH=/usr/local/arm/oe/bin:$PATH".
4. Type "export CC=arm-linux-gcc".
5. Type "export CXX=arm-linux-g++".
6. In "/tmp/trunk", run "./autogen.sh". This script will generate several files and run "./configure" with proper parameter for you. If error occurred, it means that your Debian Linux lacks some package. The error message will give you hints on which package are required. Use "Synaptic Package Manager" or "apt-get" to install the required packages. I prefer "SPM", because I can search it with key words. Some of the required packages are CVS, autoconf, automake...
7. Run "make".
8. Run "make install".
9. If everything goes well, you will find a newly built file "ipdf" emerged in "/usr/bin". It should be an executable file on iLiad (I havn't tested it). If you would like it appears in "/tmp", modify the string "--prefix=/usr" in the last line of "autogen.sh" to "--prefix=/tmp".
Adam B.
01-23-2008, 11:15 AM
I've found that when you make install, it's good to setup a staging directory.
I've created a folder in my home directory called "staging".
That way, I can run "make DESTDIR=~/staging/ipdf install", and it will put all the necessary files in that folder, so it doesn't overwrite any internal files.