[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.
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | Next revisionBoth sides next revision | ||
howtos:general_admin:setting_up_a_slackware_chroot [2015/04/09 05:57 (UTC)] – add link to mkchroot script aaditya | howtos:general_admin:setting_up_a_slackware_chroot [2015/10/29 06:44 (UTC)] – Added fstab section. dugan | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | === Setting up a Slackware chroot === | + | ==== Setting up a Slackware chroot |
- | //Goal:// I wanted | + | There are multiple reasons why you might want to set up a Slackware chroot: |
+ | * building | ||
+ | * building -stable packages on a -current system | ||
+ | * building (and testing) packages for SBo on a clean system | ||
- | == Obtaining | + | For this guide, we'll create |
- | For a 32 bit chroot I downloaded | + | === Obtaining |
- | == Installing the packages == | + | Start with a Slackware installation DVD. Download it from from http:// |
- | Create a folder which will contain | + | === Installing |
- | Mount the installation ISO(s). After they have been mounted the packages in them (found under the // | + | == Automatically == |
- | '' | + | You can create your chroot |
- | '' | + | == Manually == |
- | (additional sets can be installed in a similar way) | + | First, create |
- | An elegant script for the above: [[http://dawoodfall.net/ | + | <code bash> |
- | == Chroot == | + | Mount the installation ISO: |
- | After the chroot folder | + | <code bash> |
+ | mount -o loop slackware-14.1-install-dvd.iso / | ||
+ | cd / | ||
+ | </ | ||
+ | |||
+ | After the ISO has been mounted, the packages | ||
+ | |||
+ | <code bash> | ||
+ | installpkg --root / | ||
+ | </ | ||
+ | |||
+ | Then unmount the ISO: | ||
+ | |||
+ | <code bash> | ||
+ | umount / | ||
+ | </ | ||
+ | |||
+ | === Mounting the Chroot === | ||
+ | |||
+ | To have the chroot mounted permanently, | ||
+ | |||
+ | < | ||
+ | /dev | ||
+ | /proc chroot_folder/ | ||
+ | /sys | ||
+ | / | ||
+ | </ | ||
+ | |||
+ | If you don't want to reboot at this point, then you can mount the chroot manually: | ||
+ | |||
+ | <code bash> | ||
+ | mount / | ||
+ | </ | ||
+ | |||
+ | Also, refer to: ([[howtos: | ||
+ | |||
+ | === Chrooting into the Chroot === | ||
+ | |||
+ | Now that the chroot is set up, you can chroot into it: | ||
+ | |||
+ | <code bash> | ||
=== Updating packages === | === Updating packages === | ||
- | After that I setup slackpkg and updated | + | After that, you can run slackpkg and update |
- | === Mounting partitions | + | === Exiting |
- | I needed to mount the partition which contained the SlackBuilds for which I wanted to make a package, I used the command: | + | When you're done, exited |
- | '' | + | === One Use: Building 32-bit Packages === |
- | (http:// | + | == Mounting partitions == |
- | Then I built the package | + | I use a chroot to build 32-bit packages on a 64-bit system. I needed to mount the partition which contained the SlackBuilds for which I wanted to make a package, As my Slackware host mount point is (in this example) at / |
- | '' | + | <code bash> |
+ | </code> | ||
- | === Exit and unmounting === | + | (http:// |
+ | |||
+ | Then I built the package by executing the Slackbuild as follows: | ||
- | Finally I exited the chroot by pressing | + | <code bash> |
+ | ARCH=i686 ./my_package.SlackBuild< | ||
- | == Links == | + | === Links === |
http:// | http:// |