Confirmed users
180
edits
No edit summary |
|||
| Line 1: | Line 1: | ||
= Build Qt5 Mozilla for Raspberry Pi = | = Build Qt5 Mozilla for Raspberry Pi = | ||
== Prepare | == Build crosstool-ng toolchain == | ||
Install crosstool-ng using this tutorial: | |||
http://www.bootc.net/archives/2012/05/26/how-to-build-a-cross-compiler-for-your-raspberry-pi | |||
In addition to step 13. enable C++ | |||
== Prepare target wheezy armhf chroot == | |||
==== Download raspbian public key from root ==== | |||
<pre> | |||
sudo su | |||
wget http://archive.raspbian.org/raspbian.public.key;apt-key add raspbian.public.key | |||
CTRL^D | |||
sudo apt-get install qemu-user-static | |||
</pre> | |||
==== Debootstrap wheezy chroot ==== | |||
<pre> | <pre> | ||
export CHROOTPATH=$HOME/wheezy-armhf | |||
export CHROOTPATH=$HOME/ | export CHROOTPREFIX=whrp | ||
export CHROOTPREFIX= | sudo debootstrap --verbose --arch=armhf --keyring /etc/apt/trusted.gpg --include=apt wheezy $CHROOTPATH http://archive.raspbian.org/raspbian | ||
sudo debootstrap --arch= | |||
sudo cp /usr/bin/qemu-arm-static $CHROOTPATH/usr/bin/ | |||
sudo cp -f /etc/apt/apt.conf $CHROOTPATH/etc/apt/ | sudo cp -f /etc/apt/apt.conf $CHROOTPATH/etc/apt/ | ||
sudo cp -f /etc/apt/apt.conf.d/* $CHROOTPATH/etc/apt/apt.conf.d/ | sudo cp -f /etc/apt/apt.conf.d/* $CHROOTPATH/etc/apt/apt.conf.d/ | ||
| Line 14: | Line 34: | ||
</pre> | </pre> | ||
==== | ==== Install required packages inside chroot ==== | ||
<pre> | <pre> | ||
sudo chroot $CHROOTPATH adduser | sudo chroot $CHROOTPATH apt-get update | ||
sudo chroot $CHROOTPATH apt-get install -y --force-yes sudo adduser python2.7 bash-completion | |||
</pre> | </pre> | ||
==== make chroot alias ==== | ==== make chroot alias ==== | ||
<pre> | <pre> | ||
echo "alias o"$CHROOTPREFIX"chroot='sudo chroot $CHROOTPATH su - | echo "alias o"$CHROOTPREFIX"chroot='sudo chroot $CHROOTPATH su - " >> ~/.bashrc | ||
. ~/.bashrc | . ~/.bashrc | ||
</pre> | </pre> | ||
| Line 35: | Line 49: | ||
==== Make chroot shell different from host ==== | ==== Make chroot shell different from host ==== | ||
<pre> | <pre> | ||
echo "PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]-"$CHROOTPREFIX":\[\033[01;34m\]\w\[\033[00m\]\$ '" >> $CHROOTPATH/ | echo "PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]-"$CHROOTPREFIX":\[\033[01;34m\]\w\[\033[00m\]\$ '" >> $CHROOTPATH/root/.bashrc | ||
</pre> | </pre> | ||
==== Make sure that proc mounted in order to avoid some warnings ==== | ==== Make sure that proc mounted in order to avoid some warnings ==== | ||
<pre> | <pre> | ||
echo "sudo mount -t proc proc /proc" >> $CHROOTPATH/ | echo "sudo mount -t proc proc /proc" >> $CHROOTPATH/root/.bashrc | ||
</pre> | </pre> | ||
| Line 52: | Line 67: | ||
. /etc/bash_completion | . /etc/bash_completion | ||
fi | fi | ||
" >> $CHROOTPATH/ | " >> $CHROOTPATH/root/.bashrc | ||
</pre> | </pre> | ||