Gentoo
From Openmoko
m (→Installation: Replace <pre><tt> with wikitext, use oredered list, remove "e.g." before each cmd.) |
|||
Line 19: | Line 19: | ||
== Installation == | == Installation == | ||
− | + | <ol> | |
− | : | + | <li>Partition your sd card if needed (don`t make swap partitions, ensure card isn't mounted): </li> |
− | + | fdisk /dev/mmcblk0 | |
− | : | + | |
− | + | <li>Make ext2 or ext3 filesystem: </li> | |
− | : | + | mkfs.ext2 /dev/mmcblk0p1 |
− | + | ||
− | + | <li>Mount partition: </li> | |
− | + | mount /dev/mmcblk0p1 /media/card | |
− | : | + | |
− | + | <li>Copy stage and portage from host to moko (e.g. on localhost): </li> | |
− | tar -xjpf /media/card/stage3-armv4tl-*.tar.bz2 -C /media/card | + | scp stage3-armv4tl-*.tar.bz2 portage-*.tar.bz2 root@openmoko:/media/card |
− | tar -xjpf /media/card/portage-*.tar.bz2 -C /media/card/usr | + | |
− | < | + | <li>Unpack stage and portage: </li> |
− | + | tar -xjpf /media/card/stage3-armv4tl-*.tar.bz2 -C /media/card | |
− | : | + | tar -xjpf /media/card/portage-*.tar.bz2 -C /media/card/usr |
− | + | ||
− | : | + | <li>Cleanup removing tar.bz2: </li> |
− | + | rm /media/card/stage3-armv4tl-*.tar.bz2 /media/card/portage-*.tar.bz2 | |
− | : | + | |
− | + | <li>Chroot: </li> | |
− | : | + | chroot /media/card /bin/bash |
− | + | ||
− | : | + | <li>Update chroot environment: </li> |
− | + | source /etc/profile; env-update | |
− | : | + | |
− | + | <li>Set timezone: </li> | |
− | : | + | cp /usr/share/zoneinfo/YOURZONE /etc/localtime |
− | + | ||
− | : | + | <li>Set hostname: </li> |
− | + | nano /etc/conf.d/hostname | |
− | : | + | |
− | + | <li>Remove console font changing (small is beautiful ;]): </li> | |
− | ln -s /etc/init.d/net.lo /etc/init.d/net.usb0 | + | nano /etc/conf.d/consolefont (hash consolefont= line) |
− | echo "config_usb0=( \"192.168.0.202 netmask 255.255.255.0\" )" > /etc/conf.d/net | + | |
− | echo "routes_usb0=\"default via 192.168.0.200\"" >> /etc/conf.d/net | + | <li>Setup fstab: </li> |
− | echo "nameserver 192.168.0.200" > /etc/resolv.conf | + | nano /etc/fstab |
− | < | + | |
− | + | <li>Edit inittab (hash out c3, c4, c5, c6, s0, s1 lines): </li> | |
− | : | + | nano /etc/inittab |
− | + | ||
− | : | + | <li>Setup usb networking: </li> |
− | + | ln -s /etc/init.d/net.lo /etc/init.d/net.usb0 | |
− | + | echo "config_usb0=( \"192.168.0.202 netmask 255.255.255.0\" )" > /etc/conf.d/net | |
− | + | echo "routes_usb0=\"default via 192.168.0.200\"" >> /etc/conf.d/net | |
− | + | echo "nameserver 192.168.0.200" > /etc/resolv.conf | |
− | + | ||
− | + | <li>Enable sshd: </li> | |
− | + | rc-update add sshd default | |
+ | |||
+ | <li>Change root password: </li> | ||
+ | passwd | ||
+ | |||
+ | <li>Leave chroot: </li> | ||
+ | exit | ||
+ | |||
+ | <li>Copy kernel. </li> | ||
+ | <li>Copy modules. </li> | ||
+ | <li>Setup uboot for booting from sd card. </li> | ||
+ | <li>Reboot. </li> | ||
+ | <li>Setup/emerge rest of the system. </li> | ||
== Emerging binary packages == | == Emerging binary packages == |
Revision as of 10:54, 16 September 2008
![]() |
Languages: |
English • العربية • Български • Česky • Dansk • Deutsch • Esperanto • Eesti • Español • فارسی • Suomi • Français • עברית • Magyar • Italiano • 한국어 • Nederlands • Norsk (bokmål) • Polski • Português • Română • Русский • Svenska • Slovenčina • Українська • 中文(中国大陆) • 中文(台灣) • Euskara • Català |
Contents |
Overview
Gentoo armv4tl-softfloat-linux-gnueabi optimalized for Openmoko (-Os -march=armv4t -mtune=arm920t) on 2008.0/arm profile (glibc based, sane bootstrapable toolchain)
(embedded uclibc/arm profile armv4tl-softfloat-linux-uclibcgnueabi in plans)
Screenshot (hosted at ImageShack)
Read first
http://www.gentoo.org/doc/en/handbook/handbook-arm.xml (Skip points 2 and 3)
Needed things
- Gentoo stage: http://torindel.sezamkowa.net/openmoko/armv4tl-softfloat-linux-gnueabi/~arm/
- Portage snapshot: look for mirror on: http://www.gentoo.org/main/en/mirrors2.xml and get snapshots/portage-DATE.tar.bz2
- Kernel and modules
- Any working Openmoko distro
Installation
- Partition your sd card if needed (don`t make swap partitions, ensure card isn't mounted):
- Make ext2 or ext3 filesystem:
- Mount partition:
- Copy stage and portage from host to moko (e.g. on localhost):
- Unpack stage and portage:
- Cleanup removing tar.bz2:
- Chroot:
- Update chroot environment:
- Set timezone:
- Set hostname:
- Remove console font changing (small is beautiful ;]):
- Setup fstab:
- Edit inittab (hash out c3, c4, c5, c6, s0, s1 lines):
- Setup usb networking:
- Enable sshd:
- Change root password:
- Leave chroot:
- Copy kernel.
- Copy modules.
- Setup uboot for booting from sd card.
- Reboot.
- Setup/emerge rest of the system.
- Binary package sites
- http://tinderbox.dev.gentoo.org/embedded/openmoko/armv4tl-softfloat-linux-gnueabi/
- http://torindel.sezamkowa.net/openmoko/armv4tl-softfloat-linux-gnueabi/~arm/packages/All
- Add PORTAGE_BINHOST to make.conf
- e.g.
echo "PORTAGE_BINHOST=\"http://torindel.sezamkowa.net/openmoko/armv4tl-softfloat-linux-gnueabi/~arm/packages/All\"" >> /etc/make.conf
- Update environment
- e.g.
source /etc/profiles; env-update
- Setup install mask if you don't want compiler headers/docs etc (mask headers only if you'll be always using binary packages)
- e.g.
export INSTALL_MASK="*.h"
- Emerge packages with -kG
- e.g.
emerge -kG syslog-ng
fdisk /dev/mmcblk0
mkfs.ext2 /dev/mmcblk0p1
mount /dev/mmcblk0p1 /media/card
scp stage3-armv4tl-*.tar.bz2 portage-*.tar.bz2 root@openmoko:/media/card
tar -xjpf /media/card/stage3-armv4tl-*.tar.bz2 -C /media/card tar -xjpf /media/card/portage-*.tar.bz2 -C /media/card/usr
rm /media/card/stage3-armv4tl-*.tar.bz2 /media/card/portage-*.tar.bz2
chroot /media/card /bin/bash
source /etc/profile; env-update
cp /usr/share/zoneinfo/YOURZONE /etc/localtime
nano /etc/conf.d/hostname
nano /etc/conf.d/consolefont (hash consolefont= line)
nano /etc/fstab
nano /etc/inittab
ln -s /etc/init.d/net.lo /etc/init.d/net.usb0 echo "config_usb0=( \"192.168.0.202 netmask 255.255.255.0\" )" > /etc/conf.d/net echo "routes_usb0=\"default via 192.168.0.200\"" >> /etc/conf.d/net echo "nameserver 192.168.0.200" > /etc/resolv.conf
rc-update add sshd default
passwd
exit
Emerging binary packages
Binary package wishlist
As i'll be adding some packages to ftp above you might want to ask for some package here: GentooPackageWishList