[2024-feb-29] Sad news: Eric Layton aka Nocturnal Slacker aka vtel57 passed away on Feb 26th, shortly after hospitalization. He was one of our Wiki's most prominent admins. He will be missed.

Welcome to the Slackware Documentation Project

This is an old revision of the document!


Goal: I wanted to setup a Slackware chroot in order to build 32 bit packages on my 64 bit system.

Obtaining a Slackware installation of your desired architecture

For a 32 bit chroot I downloaded installation disks 1 and 2 from http://www.slackware.com/getslack/ via torrent.

Installing the packages

Create a folder which will contain the chroot.

Mount the installation ISO(s). After they have been mounted the packages in them (found under the slackware folder) can be installed to the chroot folder with:

installpkg –root /<chroot-target> a/*.t?z ap/*.t?z l/*.t?z n/*.t?z

installpkg –root /<chroo-target> d/*.t?z k/*.t?z t/*.t?z tcl/*.t?z

(additional sets can be installed in a similar way)

Chroot

After the chroot folder has been populated with packages we can proceed to chroot into it (https://wiki.archlinux.org/index.php/Chroot#Using_chroot).

Updating packages

After that I setup slackpkg and updated the packages (configure_a_package_manager).

Mounting partitions

I needed to mount the partition which contained the SlackBuilds for which I wanted to make a package, I used the command:

mount -B /<slackware-host-mount-point> /<chroot-mount-point>

(http://www.thegeekstuff.com/2013/01/mount-umount-examples/)

Then I built the package by executing the Slackbuild as follows:

ARCH=i686 ./<my-package>.SlackBuild

Exit and unmounting

Finally I exited the chroot by pressing Ctrl+d, and unmounted all mount points by running as root:

umount -a

Then remounted the mount points in /etc/fstab with:

mount -a

 howtos:general_admin:setting_up_a_slackware_chroot ()