Difference between revisions of "Scratchbox development"

From Navit's Wiki
Jump to: navigation, search
(New page: Developers may need to compile the source within the scratchbox environment. You need to have Scratchbox and the Nokia SDK installed. These are freely available from [http://maemo.org Maem...)
 
Line 6: Line 6:
  
 
<tt>
 
<tt>
: export SBOX_DEFAULT_AUTOMAKE=1.9
+
export SBOX_DEFAULT_AUTOMAKE=1.9
: ./autogen.sh
+
./autogen.sh
: ./configure --prefix=/usr --disable-binding-python --disable-gui-sdl --enable-avoid-float  
+
./configure --prefix=/usr --disable-binding-python --disable-gui-sdl --enable-avoid-float  
 
  --enable-avoid-unaligned --enable-svg2png-scaling="32,48" --enable-svg2png-scaling-flag="32,48"  
 
  --enable-avoid-unaligned --enable-svg2png-scaling="32,48" --enable-svg2png-scaling-flag="32,48"  
 
  --enable-svg2png-scaling-nav="8,16,32,48"
 
  --enable-svg2png-scaling-nav="8,16,32,48"
: make
+
make
: make install
+
make install
 
</tt>
 
</tt>
 
If you don't want/need the sample map then add --disable-samplemap to the above command.
 
If you don't want/need the sample map then add --disable-samplemap to the above command.

Revision as of 23:14, 26 February 2009

Developers may need to compile the source within the scratchbox environment. You need to have Scratchbox and the Nokia SDK installed. These are freely available from Maemo Place the source inside the scratchbox environment using

svn co https://

, log in to scratchbox, cd to the source directory and execute the following commands:

export SBOX_DEFAULT_AUTOMAKE=1.9
./autogen.sh
./configure --prefix=/usr --disable-binding-python --disable-gui-sdl --enable-avoid-float 
--enable-avoid-unaligned --enable-svg2png-scaling="32,48" --enable-svg2png-scaling-flag="32,48" 
--enable-svg2png-scaling-nav="8,16,32,48"
make
make install

If you don't want/need the sample map then add --disable-samplemap to the above command.

As of SVN 1843 you need to get libgpsbt-dev before compiling. Execute fakeroot apt-get install libgpsbt-dev in scratchbox.

The above will build Navit along with pre-scaled icons. Prescaling the icons is known to greatly improve rendering of the gui/internal displays.

navit/xpm/navit_svg2png uses ksvg2png to pre-build the icons. If you don't have kde installed (which you wouldn't have inside scratchbox) then you will need to install librsvg2. Execute fakeroot apt-get librsvg2 in scratchbox. The Makefile in navit/xpm will automatically use one of rsvg-convert, ksvg2png or Inkscape, depending on which is installed in your development environment.

A debian directory is available so that you can build your own packages. Download and unpack in your top Navit source directory. Build a .deb file by using fakeroot ./debian/rules binary after running the initial autogen and configure at least once. The .deb file will appear in the directory above where you are. This works best after you have done at least one build using the full set of commands above.

To install librsvg2 inside Scratchbox require you to get the source code and install from there. I obtained mine from the Ubuntu sources. Unpack the directory and then do the usual ./configure && fakeroot make install inside Scratchbox. You need to do this ./configure && fakeroot make install for each Scratchbox target that you want to build with. This same process applies to other tools that you want to add the Scratchbox, e.g. ddd (symbolic debugger), splint (code checker), etc.