To those suggesting other distros, the thing is I want to do this as an exercise in how to build a Pacman-based Arch-based distro "from scratch". Also, these old boxes aren't going to be useful for "general purpose" tasks, but they could be useful for network appliances or other ideas I have that would benefit from a "JeOS" philosophy. Arch is a lot "slimmer" than many mainstream distros but even with that, its default install can easily be around 700MB.
Although I'll admit Alpine looks interesting...
The other thing I've looked at doing is actual LFS but using Pacman for the package manager.
]]>I've seen some posts on here exploring Arch on older machines, and it looks like at one time there was even an i586 branch, but none of that effort seems to have been brought forward. There hasn't been much discussion on this topic since around 2010, back when mainline Arch still widely supported i686.
I'm not afraid to get my hands dirty with patching, editing compiler flags, etc. and I've successfully gone through LFS a few times before. Some may say "use a different distro" or "it's not worth the time" but honestly this is just as much a "because-I-can" and "because-I-want-to-learn-and-try-it" geek project as much as it is to build a JeOS type environment for these boards to do something useful with them, while using the distro I prefer and that I'm most familiar with.
What I'm really seeking is some advice or a guide on how to "bootstrap" Arch Linux from source. My idea would be that I could use a VM and install a distro that is supported on the older architecture (say, i486 Gentoo) and then from there build the necessary core packages for Arch. Along the way, I could also optimize the builds to exclude things I may not need. So yes, I'd be messing with PKGBUILDs a lot, which is fine. Yes, it may come off as "another distro" but it would still be Arch at its core, just like Arch Arm or Arch32. If I can figure out a thorough process I'd even be happy to write a Wiki page describing how someone else might go about doing "LFS but with Arch". Obviously this has been done before (arch32, ArchLinuxArm, and in the past ArchPPC and Arch i586), so I'm just looking to see "how it was done" so I can replicate the process and hopefully provide some solid documentation to the community on how to go about doing something like this.
Yes, of course, if you do this you become responsible for recompiling and updating packages. Yes, this can be a pain. But that's another exercise I'd love to mess around with (how to automate that process as much as possible). For now my goal is to compile the packages that I need for my scenario, but I'm not eliminating the possibility of revisiting these old architectures on a broader scale... Of course I know this is unsupported (especially with i686 being deprecated in mainline) but my question is more about the process and where to get started.
This is the high-level abstract process I would imagine I would need to accomplish, loosely based on LFS:
1. Build a toolchain (maybe using LFS) that can compile for the desired target architecture (i586).
2. After setting up the system to use the new toolchain, get Pacman compiled for the same architecture using the new toolchain.
3. Figure out which packages need to be built for a baseline system.
4. Grab all the PKGBUILDs for those packages and modify them as desired (adding the target architecture, modifying any configure options to trim down installed size, etc.) LFS is a good guide on this.
5. Get makepkg to use the new toolchain, then compile a minimal dev environment using makepkg.
6. Install this minimal dev environment into a chroot.
7. From there I should be able to build any packages I need targeting the desired architecture using normal procedures.
8. To bootstrap a new system, setup a pacman repo on my internal web server, and then use pacstrap to install the core packages after pointing "core" to my own repo. (I've successfully built my own customized live Arch iso's, so I could build an i586 iso to boot systems from, or more likely just use pacstrap to install to a CF card and handle all the setup out-of-system - this is actually how I got the Alix boards to boot already using arch32.)
Does this sound like a reasonable strategy? Any other tips (other than "don't bother", please)?
]]>