This is a collection of Packages and a usable Gentoo-based rootfs for little-endian FPU-less(softfloat) MIPS32 processors running Linux. The rootfs is ~2.1GB in size unpacked, it does NOT contain a portage tree. All packages have been built with the following C(XX)FLAGS: C(XX)FLAGS="-O3 -march=mips32 -mtune=mips32 --param l1-cache-size=16 --param \ l1-cache-line-size=32 --param l2-cache size=0 -msoft-float -pipe" Toolchain tuple is "mipsel-softfloat-linux-gnu-" To recreate the toolchain for cross-compiling on Gentoo, follow these instructions (on the host): emerge crossdev EXTRA_ECONF="--with-mips-plt --with-arch=mips32 --with-tune=mips32 \ --with-llsc --with-float=soft" crossdev -t mipsel-softfloat-linux-gnu \ -v -b --b 2.39 --g 13.0.9999 --k 6.0 --l 2.36-r5 --ex-gdb --without-headers Patches to gcc and glibc are available at /etc/portage/patches/sys-{devel|libs}/* as well as patches I used to fix build errors in a few other packages. * Qemu-user / systemd-nspawn instructions: - build qemu-user for target mipsel on your host machine - copy qemu-mipsel to /usr/local/bin *AND* /path/to/mips32elsf-root/usr/local/bin - run the following command as root: echo ':mipsel:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x08\x00:\xff\xff\xff\xff\xff\xff\xff\x00\x00\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff\xff:/usr/local/bin/qemu-mipsel:' > /proc/sys/fs/binfmt_misc/register systemd-nspawn -D /path/to/mips32elsf-root -b -M mips32elsf Don't forget to clone a portage tree into /var/db/repos/gentoo to be able to actually emerge anything, a single "emerge --sync" should suffice. Root password is "admin" (without the quotes, obviously), account "user" has password "user". Happy hacking, Manuel Lauss 04-Dec-2022 Contents: - complete Gentoo system for little-endian FPU-less MIPS32r1, capable of building packages natively. Tested on real MIPS hardware. - X/mesa (fbdev+software rendering), a few Window Managers, GTK+-2 and 3 - lighttp, (t)ftp, cups, networking tools (hostapd, ...) - games: ScummVM, prboom - a few media libs Changes in 20221204: - built with portage 2022-12-04 - systemd-merged-usr + app-alternatives - gcc-13-20221202, binutils-2.39, glibc-2.36, gdb-12.2 - python-3.11 only ----------------------------------------------------------------------- Changes in 20220617: - built with portage tree synced on 2022-06-11 - new gentoo paths for portage tree, distfiles. - all packages built with gcc-11.3.0 - updated toolchain: * gcc-11.3.0 * gcc-12.2.1 from 2022-06-16 * glibc-2.35-r4 patched to git head from 2022-06-11 * binutils-2.38 - added python-3.10 and 3.11_beta, with 3.10 as default target - temporarily dropped llvm/clang again, will come back later - reverted allmost all packages back to released (non-git snapshot) versions. Changes in 20180110: - built with portage tree synced on 2018-01-09 - updated toolchain: * gcc-7.2.0-r1, updated to gcc-7-branch as of 2018-01-09. * binutils-9999, gdb-9999 master branches as of 2018-01-09 12:00 UTC. * glibc-2.26-r5, update to upstream master as of 2018-01-09 12:00 UTC. - xorg-server and mesa git master builds as of 2018-01-10. - removed a lot of orphaned files - removed a few more packages Changes in 20171220: - built with portage tree synced on 2017-12-19. - updated toolchain: * gcc-7-branch of 2017-12-20 (7.3 pre) * binutils, gdb master branch as of 2017-12-20 12:00 UTC * glibc master branch as of 2017-12-20 12:00 UTC (2.27 pre). - full rebuild with above toolchain - xorg-server master - temporarily dropped LLVM and clang due to unresolvable build failures - temporarily dropped XFCE due to build failures - python 3.5 and 3.6 added, also running on kernels without the getentropy syscall available. Removed python2.7 as far as was possible. It's still there, but 3.6 is preferred now. - removed a few packages. Changes in 20170313: - built with portage 2017-03-11 - git head builds of: binutils, gdb (20170312) llvm-5, clang (20170311) mesa gcc-6.3.1 (20170312) glibc-2.25+ (20170312) - enabled LTO for select few packages. Mesa software rendering of glxgears on my 700MHz Testsystem jumped from 6fps to 9fps due to LTO. See /etc/portage/env/* for more. - enabled GOLD linker again, this time it's usable, and it's required to build latest systemd, llvm, clang natively. Default is still the BFD linker though, as GOLD still breaks some packages (procps for example). - full rebuild with gcc-6.3.1 - latest X.org (20170312) Changes in 20160619: - built with portage 2016-06-17 - git head builds of: binutils, gdb (2016-06-17) gcc-5.4 (gcc-5 branch 2016-06-17) glibc-2.24 (git head of 2016-06-19) llvm/clang svn head of 2016-06-17 - X.Org stack (git head of 2016-06-17) - full rebuild with gcc-5.4 - dropped a ton of packages (Qt5, samba, ...) Changes in 150829: - built with portage 2015-08-28 - git head builds of: binutils, gdb (2015-08-29) gcc-5.2.0-branch (2015-08-26) clang-3.8 (svn 2015-08-27) glibc-2.22 (2015-08-27) - X.org stack (git 2015-08-27) - full rebuild with gcc-5.2 - added Qt5 - dropped RazorQt, LXDE Changes in 150119: - built with portage 2015-01-17 - updated GCC-4.9, binutils, gdb, llvm/clang and glibc to their respective git heads (19.01.2015) - rebuilt the whole system with the above toolchain. The whole system now works with unpatched Linux-3.19-rc kernels which do MIPS ABI checks. - Had to drop GOLD linker since it doesn't yet create .MIPS.abiflags sections and other bugs (systemd uses gold if it is available). Changes in 141117: - built with portage 2014-11-16 - updated GCC-4.9, binutils, gdb, glibc and llvm/clang to their respective branch heads (2014-11-17). Patches to the portage versions are in /etc/portage/patches/sys-*/ - enabled gold linker on MIPS, although a few quick tests show it doesn't really work right, lots of link errors when mixing ld and gold built object files. Caveat emptor! - added X11 overlay (xorg git) - firefox stays at version 31, since linker (both ld and gold) die in the final link of libxul.so due to memory exhaustion. Changes in 140527: - removed debugging symbols, as they were getting larger - based on portage 2014-07-24 - gcc-4.9.0, llvm/clang-3.5svn, binutils-9999, glibc-2.20, gdb-9999 branches from 2014-05-27 0800UTC - gcc-4.8.3 (as a patched 4.8.2 branch version) - added LLVM/clang. - added firefox 29.0.1 - added enlightenment-17/18, RazorQT - switched to systemd, as it boots a _lot_ faster on my targets than openrc - OpenRC still available though (and confirmed working) Changes in 130609: - based on portage 130608 (portage tree not included) - gcc-4.8.0 patched to pre-4.8.2 level (gcc-4_8-branch from 2013-06-02) - binutils-git from 130530 - glibc-2.17p5 and linux-headers-3.9 - gdb-7.6 - rebuilt almost entire system with gcc-4.8.2-pre Changes in 120908: - based on portage 120908 (portage tree not included) - gcc-4.7.1 (patch 1.3) plus fixes for PR54369 and PR54494 - gcc-4.6.3 with above PR-fixes - binutils-git from 20120902 - glibc-2.16.0 and linux-headers-3.5 Changes in 120624: - based on portage snapshot from 120622 - gcc-4.7.1 (PATCH VER 1.0) - glibc-2.15-r2 + install fix from timesys (PATCH VER 18) - binutils-2.22-r1 (PATCH VER 1.4) - dropped firefox due to inability to build in-tree versions - tons of rebuilds (perl-5.16, etc) Changes in 111227: - based on portage snapshot from 111224 - binutils-2.22-r1 + fix for MIPS RLD_MAP versioning (affects firefox and other packages using version scripts; thanks to David Daney!). - gcc-4.6.2 - glibc-2.14.1-r1 rebuilt all packages with the above toolchain and CFLAGS - firefox-9.0 Changes in 111008: - based on portage snapshot from 111008 - binutils-git from 111007 to work around udev and kernel build failures - firefox-7.0.1 - rebuilt most packages due to libpng-1.5 and other library updates - python built against Linux-3.x Changes in 110717: - based on portage snapshot from 110715 - binutils-2.21.1, gcc-4.5.2 (4.6.1 also available), glibc-2.13-r4 (+ latest glibc-ports.git) - python-2.7 may only work with linux-3.0+. I fixed the build to detect linux3 as linux2 but since I built on linux-3.0-rc only the plat-linux3/ directory was created. If you use linux-2.x, just make a plat-linux2 symlink pointing to it. - assorted rebuilds Changes in 110116: - based on portage snapshot 110115 - binutils-2.21 - gcc-4.5.2 with MIPS PLT default enabled - glibc-2.12.2 with glibc-ports git snapshot from 110115 - qt-embedded 4.7.1 (in /opt, w. qmake for amd64) Changes in 100504: - portage 100503 - KDE-4.4.2 - a few rebuilds Changes since 100307: - based on portage snapshot 2010-mar-22 - added KDE-4.4.1 (packages tarball, not installed) - more patches for gcc (gcc bz#43323) - debug symbols for select apps/libraries. Eventually there will be debug syms for all packages. Since they are not really needed unless debugging issues, I've packaged them separately. Just untar at the root of the fs. Changes since 100222: - based on portage snapshot 2010-mar-07 - rebuilt whole system with gcc-4.4.3 (files dated 24-feb-2010 and newer) - removed a few stray libraries and binaries (general system cleanup) - added a small local overlay with patched ebuilds at /etc/portage/overlay - added special cflags for qt-core at /etc/portage/env/* - temporarily removed the qt4 packages Changes since 100204: - based portage snapshot 2010-feb-22 - built qt-*-4.6.2 packages (X-based) (with a modified qt4-build eclass to get rid of Qt floatmath support) - added a cross-built qt-embedded version of qt 4.6.2 (no X, but tslib) - perl-5.10 transition + rebuild of all packages depending on perl - rebuilt few other packages with the default CFLAGS