Shell Makefile
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
configs musl version bump to 1.1.14 Mar 11, 2016
patches/busybox
COPYING Update COPYING Jul 22, 2013
Makefile Add --with-sysroot option to binutils Mar 10, 2016
README.md musl version bump to 1.1.14 Mar 11, 2016
createdev.sh add /sys creation Mar 11, 2016
download_prereq.sh

README.md

SnackLinux

Visit snacklinux.org for downloads, wiki and more information about SnackLinux.

Building SnackLinux from source

Note: Be sure to run ./createdev.sh once to create the correct /dev files if you are building SnackLinux from source. It's recommended to build SnackLinux on a 32-bit host, so there's no need to mess around with multilib packages.

Toolchain
Prebuilt
  1. Download the musl 1.1.6 cross compiler here. See also http://musl.codu.org/
  2. Add it to your path with export PATH=$PATH:/path/to/toolchain/bin
Build your own

Compile your own toolchain with musl-cross

Compiling SnackLinux from source is done through the Makefile

Linux - 4.4.5
make kernel
musl - 1.1.14
make musl
BusyBox - 1.23.2
make busybox
Bash - 4.3
make bash
Binutils 2.26 (optional)
make binutils

Syslinux 5.01

make syslinux

Installing to rootfs directory

make install

If you would also like to install binutils, use:

make binutils-install
Booting

Prerequisites:

#Base files (/etc)
git clone https://github.com/snacsnoc/snacklinux-base.git
cp -R snacklinux-base/rootfs/* /opt/snacklinux_rootfs/
#fbpkg (package manager)
git clone https://github.com/snacsnoc/fbpkg.git
cp fbpkg/src/fbpkg /opt/snacklinux_rootfs/usr/bin
ISO

Run make iso. The output ISO will be in iso/

Note: you do not have to have the toolchain to create the ISO

qemu

Create a gzipped rootfs by running:

cd /opt/snacklinux_rootfs/; find . -print | cpio -o -H newc --quiet | gzip -6 > ../rootfs.gz 

Then boot in qemu:

qemu-system-i386 -m 256 -kernel bzImage -initrd rootfs.gz -append "root=/dev/ram rdinit=/sbin/init"

Packages

Read the Packages page for building packages. For SnackLinux's package manager fbpkg, see here.

Hacking

Edit anything in /opt/snacklinux_rootfs, it is the root filesystem. The kernel can also be recompiled to fit your needs.

The boot/isolinux directory is where ISOLINUX resides, edit the menu to adjust to your needs.

Thanks

Mike Chirico for http://souptonuts.sourceforge.net/cdrom.htm

Tiny Core Linux distribution for inspiration and documentation http://tinycorelinux.net

Linux From Scratch for excellent documentation http://www.linuxfromscratch.org/

The Arch Linux wiki https://wiki.archlinux.org/

Here are links to the software used in SnackLinux:

syslinux

linux

busybox

bash

fbpkg

binutils

musl