Difference between revisions of "Compile on the Pandora"

From Pandora Wiki
Jump to: navigation, search
(Created page with "torpor described how to [http://www.gp32x.com/board/index.php?/topic/53964-cross-compiling-is-bollocks-toolchains-are-bollocks-use-your-pandora-to-build-apps/ build apps directly...")
 
Line 37: Line 37:
 
   opkg install libsdl-1.2-dev libsdl-gfx-dev libsdl-image-1.2-dev libsdl-mixer-dev libsdl-net-1.2-dev libsdl-ttf-2.0-dev
 
   opkg install libsdl-1.2-dev libsdl-gfx-dev libsdl-image-1.2-dev libsdl-mixer-dev libsdl-net-1.2-dev libsdl-ttf-2.0-dev
  
10. I had trouble with libsdl-image-1.2-dev and libpng, so did something like this:
+
10. I had trouble with libsdl-image-1.2-dev and libpng, so did something like this (there might be some errors):
  
 
   opkg info libsdl-image-1.2-dev      # to see the deps
 
   opkg info libsdl-image-1.2-dev      # to see the deps
 
   opkg install libz-dev libpng-dev libjpeg-dev libtiff-dev libpng12-dev libc6-dev libsdl-1.2-dev
 
   opkg install libz-dev libpng-dev libjpeg-dev libtiff-dev libpng12-dev libc6-dev libsdl-1.2-dev
 
   opkg install --nodeps libsdl-image-1.2-dev
 
   opkg install --nodeps libsdl-image-1.2-dev
 +
  ln -s libpng.so.3 /usr/lib/libpng.so
  
 
11. Install optional extra stuff, if you want them:
 
11. Install optional extra stuff, if you want them:

Revision as of 17:18, 27 March 2011

torpor described how to build apps directly on the Pandora.

Please note that as of March 2011, you will break your install if you follow those instructions directly! The angstrom "unstable" distribution is well named.

You can try the following:

1. I found that the www.angstrom-distribution.org repo was very slow, so changed the config files in /etc/opkg/ to use us.feeds.angstrom-distribution.org instead.

2. Enable sshd, and ssh in from another machine. This helps keep control when things break. To get root:

 sudo bash

3. Set up a root overlay on your SD card. This gives you a way to try again when things break, and has other benefits. I added /home/ to the overlay also.

4. Mount the overlay. Check this worked, with "mount" or "df".

5. Get new fresh package lists:

 opkg update

6. ncurses packaging seems to be broken, and ncurses is important! So, do this first (in the overlay), or be prepared for everything to break later:

 opkg install libncurses5

7. Install dev packages:

 opkg install gcc gcc-symlinks make binutils cpp cpp-symlinks g++ g++-symlinks libstdc++-dev

8. Try to compile "hello world". Mine didn't find libgcc_s, this fixed it:

 opkg install libgcc1   # not sure if this was needed
 ln -s /lib/libgcc_s.so.1 /usr/lib/gcc/arm-angstrom-linux-gnueabi/4.3.3/libgcc_s.so

9. Install extra dev libs:

 opkg install libgles-omap3-dev
 opkg install libsdl-1.2-dev libsdl-gfx-dev libsdl-image-1.2-dev libsdl-mixer-dev libsdl-net-1.2-dev libsdl-ttf-2.0-dev

10. I had trouble with libsdl-image-1.2-dev and libpng, so did something like this (there might be some errors):

 opkg info libsdl-image-1.2-dev      # to see the deps
 opkg install libz-dev libpng-dev libjpeg-dev libtiff-dev libpng12-dev libc6-dev libsdl-1.2-dev
 opkg install --nodeps libsdl-image-1.2-dev
 ln -s libpng.so.3 /usr/lib/libpng.so

11. Install optional extra stuff, if you want them:

 opkg install vim vim-syntax
 opkg install libgles-omap3-demos
 opkg install screen git rsync


The above was from memory, I didn't re-test it because it took too long even the first time! If you find other problems or quirks, please correct it.