Thu Jul 25 20:22:54 UTC 2024

Enjoy your shiny new vmlinuz-6.9.11-generic!
Thanks again to LuckyCyborg for teaching me about the path of least resistance.
a/grub-2.12-x86_64-14.txz:  Rebuilt.
  Don't mention 09_slackware_linux in the /etc/default/grub comments.
a/kernel-generic-6.9.11-x86_64-1.txz:  Upgraded.
a/kernel-huge-6.9.11-x86_64-1.txz:  Upgraded.
a/kernel-modules-6.9.11-x86_64-1.txz:  Upgraded.
a/mkinitrd-1.4.11-x86_64-35.txz:  Rebuilt.
d/kernel-headers-6.9.11-x86-1.txz:  Upgraded.
d/rust-1.80.0-x86_64-1.txz:  Upgraded.
k/kernel-source-6.9.11-noarch-1.txz:  Upgraded.
l/xapian-core-1.4.26-x86_64-1.txz:  Upgraded.
isolinux/initrd.img:  Rebuilt.
kernels/*:  Upgraded.
usb-and-pxe-installers/usbboot.img:  Rebuilt.
This commit is contained in:
Patrick J Volkerding 2024-07-25 20:22:54 +00:00 committed by Eric Hameleers
parent 3fb0490c72
commit bca17f28cc
73 changed files with 339 additions and 5801 deletions

View file

@ -11,9 +11,34 @@
<description>Tracking Slackware development in git.</description>
<language>en-us</language>
<id xmlns="http://www.w3.org/2005/Atom">urn:uuid:c964f45e-6732-11e8-bbe5-107b4450212f</id>
<pubDate>Thu, 25 Jul 2024 05:34:53 GMT</pubDate>
<lastBuildDate>Thu, 25 Jul 2024 05:57:22 GMT</lastBuildDate>
<pubDate>Thu, 25 Jul 2024 20:22:54 GMT</pubDate>
<lastBuildDate>Thu, 25 Jul 2024 21:16:39 GMT</lastBuildDate>
<generator>maintain_current_git.sh v 1.17</generator>
<item>
<title>Thu, 25 Jul 2024 20:22:54 GMT</title>
<pubDate>Thu, 25 Jul 2024 20:22:54 GMT</pubDate>
<link>https://git.slackware.nl/current/tag/?h=20240725202254</link>
<guid isPermaLink="false">20240725202254</guid>
<description>
<![CDATA[<pre>
Enjoy your shiny new vmlinuz-6.9.11-generic!
Thanks again to LuckyCyborg for teaching me about the path of least resistance.
a/grub-2.12-x86_64-14.txz: Rebuilt.
Don't mention 09_slackware_linux in the /etc/default/grub comments.
a/kernel-generic-6.9.11-x86_64-1.txz: Upgraded.
a/kernel-huge-6.9.11-x86_64-1.txz: Upgraded.
a/kernel-modules-6.9.11-x86_64-1.txz: Upgraded.
a/mkinitrd-1.4.11-x86_64-35.txz: Rebuilt.
d/kernel-headers-6.9.11-x86-1.txz: Upgraded.
d/rust-1.80.0-x86_64-1.txz: Upgraded.
k/kernel-source-6.9.11-noarch-1.txz: Upgraded.
l/xapian-core-1.4.26-x86_64-1.txz: Upgraded.
isolinux/initrd.img: Rebuilt.
kernels/*: Upgraded.
usb-and-pxe-installers/usbboot.img: Rebuilt.
</pre>]]>
</description>
</item>
<item>
<title>Thu, 25 Jul 2024 05:34:53 GMT</title>
<pubDate>Thu, 25 Jul 2024 05:34:53 GMT</pubDate>

View file

@ -1,3 +1,20 @@
Thu Jul 25 20:22:54 UTC 2024
Enjoy your shiny new vmlinuz-6.9.11-generic!
Thanks again to LuckyCyborg for teaching me about the path of least resistance.
a/grub-2.12-x86_64-14.txz: Rebuilt.
Don't mention 09_slackware_linux in the /etc/default/grub comments.
a/kernel-generic-6.9.11-x86_64-1.txz: Upgraded.
a/kernel-huge-6.9.11-x86_64-1.txz: Upgraded.
a/kernel-modules-6.9.11-x86_64-1.txz: Upgraded.
a/mkinitrd-1.4.11-x86_64-35.txz: Rebuilt.
d/kernel-headers-6.9.11-x86-1.txz: Upgraded.
d/rust-1.80.0-x86_64-1.txz: Upgraded.
k/kernel-source-6.9.11-noarch-1.txz: Upgraded.
l/xapian-core-1.4.26-x86_64-1.txz: Upgraded.
isolinux/initrd.img: Rebuilt.
kernels/*: Upgraded.
usb-and-pxe-installers/usbboot.img: Rebuilt.
+--------------------------+
Thu Jul 25 05:34:53 UTC 2024
testing/packages/grub-2.12-x86_64-13.txz: Rebuilt.
Support the GRUB_DISABLE_KERNEL_SYMLINKS variable in 10_linux.

View file

@ -1,36 +1,36 @@
Thu Jul 25 05:35:33 UTC 2024
Thu Jul 25 20:27:20 UTC 2024
Here is the file list for this directory. If you are using a
mirror site and find missing or extra files in the disk
subdirectories, please have the archive administrator refresh
the mirror.
drwxr-xr-x 12 root root 4096 2024-07-25 05:34 .
drwxr-xr-x 12 root root 4096 2024-07-25 20:22 .
-rw-r--r-- 1 root root 1133358 2024-07-24 22:43 ./:wq
-rw-r--r-- 1 root root 5767 2022-02-02 22:44 ./ANNOUNCE.15.0
-rw-r--r-- 1 root root 16617 2022-02-02 23:27 ./CHANGES_AND_HINTS.TXT
-rw-r--r-- 1 root root 1162820 2024-07-25 02:45 ./CHECKSUMS.md5
-rw-r--r-- 1 root root 195 2024-07-25 02:45 ./CHECKSUMS.md5.asc
-rw-r--r-- 1 root root 1162915 2024-07-25 05:35 ./CHECKSUMS.md5
-rw-r--r-- 1 root root 195 2024-07-25 05:35 ./CHECKSUMS.md5.asc
-rw-r--r-- 1 root root 17976 1994-06-10 02:28 ./COPYING
-rw-r--r-- 1 root root 35147 2007-06-30 04:21 ./COPYING3
-rw-r--r-- 1 root root 19573 2016-06-23 20:08 ./COPYRIGHT.TXT
-rw-r--r-- 1 root root 616 2006-10-02 04:37 ./CRYPTO_NOTICE.TXT
-rw-r--r-- 1 root root 1135821 2024-07-25 05:34 ./ChangeLog.txt
-rw-r--r-- 1 root root 1136576 2024-07-25 20:22 ./ChangeLog.txt
drwxr-xr-x 3 root root 4096 2013-03-20 22:17 ./EFI
drwxr-xr-x 2 root root 4096 2024-07-18 19:17 ./EFI/BOOT
drwxr-xr-x 2 root root 4096 2024-07-25 20:19 ./EFI/BOOT
-rw-r--r-- 1 root root 1200128 2024-06-23 18:50 ./EFI/BOOT/bootx64.efi
-rw-r--r-- 1 root root 78 2013-09-23 20:35 ./EFI/BOOT/grub-embedded.cfg
-rw-r--r-- 1 root root 893 2018-04-17 21:17 ./EFI/BOOT/grub.cfg
-rw-r--r-- 2 root root 15098368 2024-07-18 18:29 ./EFI/BOOT/huge.s
-rw-r--r-- 2 root root 53684088 2024-07-18 19:17 ./EFI/BOOT/initrd.img
-rw-r--r-- 2 root root 15262208 2024-07-25 17:47 ./EFI/BOOT/huge.s
-rw-r--r-- 2 root root 53711920 2024-07-25 20:19 ./EFI/BOOT/initrd.img
-rwxr-xr-x 1 root root 2504 2019-07-05 18:54 ./EFI/BOOT/make-grub.sh
-rw-r--r-- 1 root root 10722 2013-09-21 19:02 ./EFI/BOOT/osdetect.cfg
-rw-r--r-- 1 root root 1273 2013-08-12 21:08 ./EFI/BOOT/tools.cfg
-rw-r--r-- 1 root root 1521594 2024-07-25 02:44 ./FILELIST.TXT
-rw-r--r-- 1 root root 1521706 2024-07-25 05:35 ./FILELIST.TXT
-rw-r--r-- 1 root root 1572 2012-08-29 18:27 ./GPG-KEY
-rw-r--r-- 1 root root 913372 2024-07-25 02:44 ./PACKAGES.TXT
-rw-r--r-- 1 root root 913372 2024-07-25 20:26 ./PACKAGES.TXT
-rw-r--r-- 1 root root 8034 2022-02-02 03:36 ./README.TXT
-rw-r--r-- 1 root root 3629 2024-07-18 19:02 ./README.initrd
-rw-r--r-- 1 root root 3629 2024-07-25 19:59 ./README.initrd
-rw-r--r-- 1 root root 34114 2023-12-11 20:35 ./README_CRYPT.TXT
-rw-r--r-- 1 root root 8754 2022-03-30 19:05 ./README_LVM.TXT
-rw-r--r-- 1 root root 19646 2023-12-11 20:36 ./README_RAID.TXT
@ -619,16 +619,16 @@ drwxr-xr-x 2 root root 4096 2024-06-26 20:09 ./extra/xv
-rw-r--r-- 1 root root 233 2024-06-26 19:07 ./extra/xv/xv-5.2.0-x86_64-1.txt
-rw-r--r-- 1 root root 1098636 2024-06-26 19:07 ./extra/xv/xv-5.2.0-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-06-26 19:07 ./extra/xv/xv-5.2.0-x86_64-1.txz.asc
drwxr-xr-x 3 root root 4096 2024-07-18 19:17 ./isolinux
drwxr-xr-x 3 root root 4096 2024-07-25 20:19 ./isolinux
-rw-r--r-- 1 root root 6185 2022-02-03 06:53 ./isolinux/README.TXT
-rw-r--r-- 1 root root 788 2007-03-17 19:50 ./isolinux/README_SPLIT.TXT
-rw-r--r-- 1 root root 1474560 2024-06-23 18:50 ./isolinux/efiboot.img
-rw-r--r-- 1 root root 574 2013-10-24 00:19 ./isolinux/f2.txt
-rw-r--r-- 2 root root 53684088 2024-07-18 19:17 ./isolinux/initrd.img
-rw-r--r-- 2 root root 53711920 2024-07-25 20:19 ./isolinux/initrd.img
-rw-r--r-- 1 root root 50 2003-01-18 00:02 ./isolinux/iso.sort
-rw-r--r-- 1 root root 24576 2016-05-27 20:36 ./isolinux/isolinux.bin
-rw-r--r-- 1 root root 578 2013-03-27 03:29 ./isolinux/isolinux.cfg
-rw-r--r-- 1 root root 682 2024-07-18 19:02 ./isolinux/message.txt
-rw-r--r-- 1 root root 682 2024-07-25 19:59 ./isolinux/message.txt
drwxr-xr-x 2 root root 4096 2003-03-17 07:31 ./isolinux/sbootmgr
-rwxr-xr-x 1 root root 36064 1995-05-12 01:23 ./isolinux/sbootmgr/RAWRITE.EXE
-rw-r--r-- 1 root root 2138 1997-12-01 01:21 ./isolinux/sbootmgr/RAWRITE12.DOC
@ -639,12 +639,12 @@ lrwxrwxrwx 1 root root 11 2009-08-23 23:37 ./isolinux/sbootmgr/RAWRITE13
-rw-r--r-- 1 root root 1291 2003-03-17 07:31 ./isolinux/sbootmgr/README.TXT
-rw-r--r-- 1 root root 110592 2003-03-16 08:38 ./isolinux/sbootmgr/sbootmgr.dsk
-rw-r--r-- 1 root root 2879 2020-12-07 20:48 ./isolinux/setpkg
drwxr-xr-x 5 root root 4096 2024-07-18 19:02 ./kernels
-rw-r--r-- 1 root root 36 2024-07-18 19:02 ./kernels/VERSIONS.TXT
drwxr-xr-x 2 root root 4096 2024-07-18 18:29 ./kernels/huge.s
-rw-r--r-- 1 root root 1757016 2024-07-18 18:28 ./kernels/huge.s/System.map.gz
-rw-r--r-- 2 root root 15098368 2024-07-18 18:29 ./kernels/huge.s/bzImage
-rw-r--r-- 1 root root 265095 2024-07-18 16:36 ./kernels/huge.s/config
drwxr-xr-x 5 root root 4096 2024-07-25 19:59 ./kernels
-rw-r--r-- 1 root root 36 2024-07-25 19:59 ./kernels/VERSIONS.TXT
drwxr-xr-x 2 root root 4096 2024-07-25 17:47 ./kernels/huge.s
-rw-r--r-- 1 root root 1757106 2024-07-25 17:47 ./kernels/huge.s/System.map.gz
-rw-r--r-- 2 root root 15262208 2024-07-25 17:47 ./kernels/huge.s/bzImage
-rw-r--r-- 1 root root 265061 2024-07-25 16:15 ./kernels/huge.s/config
drwxr-xr-x 2 root root 4096 2011-03-25 03:15 ./kernels/memtest
-rw-r--r-- 1 root root 60 2011-03-24 00:19 ./kernels/memtest/README
-rw-r--r-- 1 root root 150024 2013-10-17 04:15 ./kernels/memtest/memtest
@ -663,13 +663,13 @@ drwxr-xr-x 2 root root 4096 2022-02-03 07:02 ./patches
-rw-r--r-- 1 root root 575 2022-02-03 07:02 ./patches/FILE_LIST
-rw-r--r-- 1 root root 14 2022-02-03 07:02 ./patches/MANIFEST.bz2
-rw-r--r-- 1 root root 224 2022-02-03 07:02 ./patches/PACKAGES.TXT
drwxr-xr-x 17 root root 4096 2024-07-25 02:44 ./slackware64
-rw-r--r-- 1 root root 356306 2024-07-25 02:44 ./slackware64/CHECKSUMS.md5
-rw-r--r-- 1 root root 195 2024-07-25 02:44 ./slackware64/CHECKSUMS.md5.asc
-rw-r--r-- 1 root root 441233 2024-07-25 02:43 ./slackware64/FILE_LIST
-rw-r--r-- 1 root root 4702905 2024-07-25 02:43 ./slackware64/MANIFEST.bz2
drwxr-xr-x 17 root root 4096 2024-07-25 20:26 ./slackware64
-rw-r--r-- 1 root root 356306 2024-07-25 20:26 ./slackware64/CHECKSUMS.md5
-rw-r--r-- 1 root root 195 2024-07-25 20:26 ./slackware64/CHECKSUMS.md5.asc
-rw-r--r-- 1 root root 441233 2024-07-25 20:25 ./slackware64/FILE_LIST
-rw-r--r-- 1 root root 4718442 2024-07-25 20:26 ./slackware64/MANIFEST.bz2
lrwxrwxrwx 1 root root 15 2009-08-23 23:34 ./slackware64/PACKAGES.TXT -> ../PACKAGES.TXT
drwxr-xr-x 2 root root 32768 2024-07-25 02:43 ./slackware64/a
drwxr-xr-x 2 root root 32768 2024-07-25 20:25 ./slackware64/a
-rw-r--r-- 1 root root 327 2022-02-15 18:16 ./slackware64/a/aaa_base-15.1-x86_64-2.txt
-rw-r--r-- 1 root root 10720 2022-02-15 18:16 ./slackware64/a/aaa_base-15.1-x86_64-2.txz
-rw-r--r-- 1 root root 163 2022-02-15 18:16 ./slackware64/a/aaa_base-15.1-x86_64-2.txz.asc
@ -796,9 +796,9 @@ drwxr-xr-x 2 root root 32768 2024-07-25 02:43 ./slackware64/a
-rw-r--r-- 1 root root 291 2023-05-14 00:12 ./slackware64/a/grep-3.11-x86_64-1.txt
-rw-r--r-- 1 root root 271096 2023-05-14 00:12 ./slackware64/a/grep-3.11-x86_64-1.txz
-rw-r--r-- 1 root root 163 2023-05-14 00:12 ./slackware64/a/grep-3.11-x86_64-1.txz.asc
-rw-r--r-- 1 root root 269 2024-07-10 17:33 ./slackware64/a/grub-2.12-x86_64-11.txt
-rw-r--r-- 1 root root 12607524 2024-07-10 17:33 ./slackware64/a/grub-2.12-x86_64-11.txz
-rw-r--r-- 1 root root 195 2024-07-10 17:33 ./slackware64/a/grub-2.12-x86_64-11.txz.asc
-rw-r--r-- 1 root root 269 2024-07-25 18:11 ./slackware64/a/grub-2.12-x86_64-14.txt
-rw-r--r-- 1 root root 12769004 2024-07-25 18:11 ./slackware64/a/grub-2.12-x86_64-14.txz
-rw-r--r-- 1 root root 195 2024-07-25 18:11 ./slackware64/a/grub-2.12-x86_64-14.txz.asc
-rw-r--r-- 1 root root 314 2023-08-20 19:07 ./slackware64/a/gzip-1.13-x86_64-1.txt
-rw-r--r-- 1 root root 117772 2023-08-20 19:07 ./slackware64/a/gzip-1.13-x86_64-1.txz
-rw-r--r-- 1 root root 163 2023-08-20 19:07 ./slackware64/a/gzip-1.13-x86_64-1.txz.asc
@ -837,15 +837,15 @@ drwxr-xr-x 2 root root 32768 2024-07-25 02:43 ./slackware64/a
-rw-r--r-- 1 root root 422 2024-07-24 18:24 ./slackware64/a/kernel-firmware-20240723_b37d247-noarch-1.txt
-rw-r--r-- 1 root root 335718356 2024-07-24 18:24 ./slackware64/a/kernel-firmware-20240723_b37d247-noarch-1.txz
-rw-r--r-- 1 root root 195 2024-07-24 18:24 ./slackware64/a/kernel-firmware-20240723_b37d247-noarch-1.txz.asc
-rw-r--r-- 1 root root 489 2024-07-18 18:30 ./slackware64/a/kernel-generic-6.9.10-x86_64-1.txt
-rw-r--r-- 1 root root 14592124 2024-07-18 18:30 ./slackware64/a/kernel-generic-6.9.10-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-07-18 18:30 ./slackware64/a/kernel-generic-6.9.10-x86_64-1.txz.asc
-rw-r--r-- 1 root root 481 2024-07-18 18:29 ./slackware64/a/kernel-huge-6.9.10-x86_64-1.txt
-rw-r--r-- 1 root root 16292624 2024-07-18 18:29 ./slackware64/a/kernel-huge-6.9.10-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-07-18 18:29 ./slackware64/a/kernel-huge-6.9.10-x86_64-1.txz.asc
-rw-r--r-- 1 root root 576 2024-07-18 18:35 ./slackware64/a/kernel-modules-6.9.10-x86_64-1.txt
-rw-r--r-- 1 root root 57948280 2024-07-18 18:35 ./slackware64/a/kernel-modules-6.9.10-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-07-18 18:35 ./slackware64/a/kernel-modules-6.9.10-x86_64-1.txz.asc
-rw-r--r-- 1 root root 489 2024-07-25 17:49 ./slackware64/a/kernel-generic-6.9.11-x86_64-1.txt
-rw-r--r-- 1 root root 14455480 2024-07-25 17:49 ./slackware64/a/kernel-generic-6.9.11-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-07-25 17:49 ./slackware64/a/kernel-generic-6.9.11-x86_64-1.txz.asc
-rw-r--r-- 1 root root 481 2024-07-25 17:47 ./slackware64/a/kernel-huge-6.9.11-x86_64-1.txt
-rw-r--r-- 1 root root 16457540 2024-07-25 17:47 ./slackware64/a/kernel-huge-6.9.11-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-07-25 17:47 ./slackware64/a/kernel-huge-6.9.11-x86_64-1.txz.asc
-rw-r--r-- 1 root root 576 2024-07-25 17:54 ./slackware64/a/kernel-modules-6.9.11-x86_64-1.txt
-rw-r--r-- 1 root root 57961444 2024-07-25 17:54 ./slackware64/a/kernel-modules-6.9.11-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-07-25 17:54 ./slackware64/a/kernel-modules-6.9.11-x86_64-1.txz.asc
-rw-r--r-- 1 root root 509 2024-03-14 19:05 ./slackware64/a/kmod-32-x86_64-1.txt
-rw-r--r-- 1 root root 120388 2024-03-14 19:05 ./slackware64/a/kmod-32-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-03-14 19:05 ./slackware64/a/kmod-32-x86_64-1.txz.asc
@ -891,8 +891,8 @@ drwxr-xr-x 2 root root 32768 2024-07-25 02:43 ./slackware64/a
-rw-r--r-- 1 root root 405 2024-01-23 19:48 ./slackware64/a/lzlib-1.14-x86_64-1.txt
-rw-r--r-- 1 root root 58032 2024-01-23 19:48 ./slackware64/a/lzlib-1.14-x86_64-1.txz
-rw-r--r-- 1 root root 163 2024-01-23 19:48 ./slackware64/a/lzlib-1.14-x86_64-1.txz.asc
-rw-r--r-- 1 root root 10071 2024-07-18 19:03 ./slackware64/a/maketag
-rw-r--r-- 1 root root 10071 2024-07-18 19:03 ./slackware64/a/maketag.ez
-rw-r--r-- 1 root root 10071 2024-07-25 19:59 ./slackware64/a/maketag
-rw-r--r-- 1 root root 10071 2024-07-25 19:59 ./slackware64/a/maketag.ez
-rw-r--r-- 1 root root 591 2024-06-20 17:40 ./slackware64/a/mcelog-200-x86_64-1.txt
-rw-r--r-- 1 root root 356572 2024-06-20 17:40 ./slackware64/a/mcelog-200-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-06-20 17:40 ./slackware64/a/mcelog-200-x86_64-1.txz.asc
@ -902,9 +902,9 @@ drwxr-xr-x 2 root root 32768 2024-07-25 02:43 ./slackware64/a
-rw-r--r-- 1 root root 378 2023-09-23 18:06 ./slackware64/a/minicom-2.9-x86_64-1.txt
-rw-r--r-- 1 root root 336888 2023-09-23 18:06 ./slackware64/a/minicom-2.9-x86_64-1.txz
-rw-r--r-- 1 root root 163 2023-09-23 18:06 ./slackware64/a/minicom-2.9-x86_64-1.txz.asc
-rw-r--r-- 1 root root 527 2023-11-21 21:14 ./slackware64/a/mkinitrd-1.4.11-x86_64-34.txt
-rw-r--r-- 1 root root 621832 2023-11-21 21:14 ./slackware64/a/mkinitrd-1.4.11-x86_64-34.txz
-rw-r--r-- 1 root root 163 2023-11-21 21:14 ./slackware64/a/mkinitrd-1.4.11-x86_64-34.txz.asc
-rw-r--r-- 1 root root 527 2024-07-25 00:01 ./slackware64/a/mkinitrd-1.4.11-x86_64-35.txt
-rw-r--r-- 1 root root 621720 2024-07-25 00:01 ./slackware64/a/mkinitrd-1.4.11-x86_64-35.txz
-rw-r--r-- 1 root root 195 2024-07-25 00:01 ./slackware64/a/mkinitrd-1.4.11-x86_64-35.txz.asc
-rw-r--r-- 1 root root 668 2021-02-13 11:11 ./slackware64/a/mlocate-0.26-x86_64-4.txt
-rw-r--r-- 1 root root 106260 2021-02-13 11:11 ./slackware64/a/mlocate-0.26-x86_64-4.txz
-rw-r--r-- 1 root root 163 2021-02-13 11:11 ./slackware64/a/mlocate-0.26-x86_64-4.txz.asc
@ -1004,7 +1004,7 @@ drwxr-xr-x 2 root root 32768 2024-07-25 02:43 ./slackware64/a
-rw-r--r-- 1 root root 378 2024-06-28 19:01 ./slackware64/a/sysvinit-scripts-15.1-noarch-20.txt
-rw-r--r-- 1 root root 17764 2024-06-28 19:01 ./slackware64/a/sysvinit-scripts-15.1-noarch-20.txz
-rw-r--r-- 1 root root 195 2024-06-28 19:01 ./slackware64/a/sysvinit-scripts-15.1-noarch-20.txz.asc
-rw-r--r-- 1 root root 1590 2024-07-18 19:03 ./slackware64/a/tagfile
-rw-r--r-- 1 root root 1590 2024-07-25 19:59 ./slackware64/a/tagfile
-rw-r--r-- 1 root root 395 2023-07-18 18:38 ./slackware64/a/tar-1.35-x86_64-1.txt
-rw-r--r-- 1 root root 774812 2023-07-18 18:38 ./slackware64/a/tar-1.35-x86_64-1.txz
-rw-r--r-- 1 root root 163 2023-07-18 18:38 ./slackware64/a/tar-1.35-x86_64-1.txz.asc
@ -1326,7 +1326,7 @@ drwxr-xr-x 2 root root 20480 2024-07-25 02:43 ./slackware64/ap
-rw-r--r-- 1 root root 506 2022-05-15 17:09 ./slackware64/ap/zsh-5.9-x86_64-1.txt
-rw-r--r-- 1 root root 3156392 2022-05-15 17:09 ./slackware64/ap/zsh-5.9-x86_64-1.txz
-rw-r--r-- 1 root root 163 2022-05-15 17:09 ./slackware64/ap/zsh-5.9-x86_64-1.txz.asc
drwxr-xr-x 2 root root 20480 2024-07-23 19:00 ./slackware64/d
drwxr-xr-x 2 root root 20480 2024-07-25 20:25 ./slackware64/d
-rw-r--r-- 1 root root 360 2024-03-30 21:20 ./slackware64/d/Cython-3.0.10-x86_64-1.txt
-rw-r--r-- 1 root root 4305292 2024-03-30 21:20 ./slackware64/d/Cython-3.0.10-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-03-30 21:20 ./slackware64/d/Cython-3.0.10-x86_64-1.txz.asc
@ -1443,9 +1443,9 @@ drwxr-xr-x 2 root root 20480 2024-07-23 19:00 ./slackware64/d
-rw-r--r-- 1 root root 279 2021-02-13 09:57 ./slackware64/d/intltool-0.51.0-x86_64-6.txt
-rw-r--r-- 1 root root 48024 2021-02-13 09:57 ./slackware64/d/intltool-0.51.0-x86_64-6.txz
-rw-r--r-- 1 root root 163 2021-02-13 09:57 ./slackware64/d/intltool-0.51.0-x86_64-6.txz.asc
-rw-r--r-- 1 root root 332 2024-07-18 18:36 ./slackware64/d/kernel-headers-6.9.10-x86-1.txt
-rw-r--r-- 1 root root 1195552 2024-07-18 18:36 ./slackware64/d/kernel-headers-6.9.10-x86-1.txz
-rw-r--r-- 1 root root 195 2024-07-18 18:36 ./slackware64/d/kernel-headers-6.9.10-x86-1.txz.asc
-rw-r--r-- 1 root root 332 2024-07-25 17:54 ./slackware64/d/kernel-headers-6.9.11-x86-1.txt
-rw-r--r-- 1 root root 1195484 2024-07-25 17:54 ./slackware64/d/kernel-headers-6.9.11-x86-1.txz
-rw-r--r-- 1 root root 195 2024-07-25 17:54 ./slackware64/d/kernel-headers-6.9.11-x86-1.txz.asc
-rw-r--r-- 1 root root 312 2024-07-21 05:08 ./slackware64/d/libgccjit-14.1.0-x86_64-2.txt
-rw-r--r-- 1 root root 10430760 2024-07-21 05:08 ./slackware64/d/libgccjit-14.1.0-x86_64-2.txz
-rw-r--r-- 1 root root 195 2024-07-21 05:08 ./slackware64/d/libgccjit-14.1.0-x86_64-2.txz.asc
@ -1538,9 +1538,9 @@ drwxr-xr-x 2 root root 20480 2024-07-23 19:00 ./slackware64/d
-rw-r--r-- 1 root root 386 2024-07-22 03:05 ./slackware64/d/ruby-3.3.4-x86_64-2.txt
-rw-r--r-- 1 root root 9386540 2024-07-22 03:05 ./slackware64/d/ruby-3.3.4-x86_64-2.txz
-rw-r--r-- 1 root root 195 2024-07-22 03:05 ./slackware64/d/ruby-3.3.4-x86_64-2.txz.asc
-rw-r--r-- 1 root root 426 2024-06-13 18:38 ./slackware64/d/rust-1.79.0-x86_64-1.txt
-rw-r--r-- 1 root root 111459708 2024-06-13 18:38 ./slackware64/d/rust-1.79.0-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-06-13 18:38 ./slackware64/d/rust-1.79.0-x86_64-1.txz.asc
-rw-r--r-- 1 root root 426 2024-07-25 18:49 ./slackware64/d/rust-1.80.0-x86_64-1.txt
-rw-r--r-- 1 root root 112531916 2024-07-25 18:49 ./slackware64/d/rust-1.80.0-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-07-25 18:49 ./slackware64/d/rust-1.80.0-x86_64-1.txz.asc
-rw-r--r-- 1 root root 352 2024-07-22 18:15 ./slackware64/d/rust-bindgen-0.69.4-x86_64-2.txt
-rw-r--r-- 1 root root 1699788 2024-07-22 18:15 ./slackware64/d/rust-bindgen-0.69.4-x86_64-2.txz
-rw-r--r-- 1 root root 195 2024-07-22 18:15 ./slackware64/d/rust-bindgen-0.69.4-x86_64-2.txz.asc
@ -1599,15 +1599,15 @@ drwxr-xr-x 2 root root 4096 2016-04-01 21:41 ./slackware64/f
-rw-r--r-- 1 root root 1075 2018-03-01 07:54 ./slackware64/f/maketag
-rw-r--r-- 1 root root 1075 2018-03-01 07:54 ./slackware64/f/maketag.ez
-rw-r--r-- 1 root root 32 2018-03-01 07:54 ./slackware64/f/tagfile
drwxr-xr-x 2 root root 4096 2024-07-18 20:05 ./slackware64/k
drwxr-xr-x 2 root root 4096 2024-07-25 20:25 ./slackware64/k
-rwxr-xr-x 1 root root 2897 2009-06-24 22:06 ./slackware64/k/install-packages
-rw-r--r-- 1 root root 446 2006-09-18 10:41 ./slackware64/k/install.end
-rw-r--r-- 1 root root 317 2024-07-18 18:23 ./slackware64/k/kernel-source-6.9.10-noarch-1.txt
-rw-r--r-- 1 root root 139968256 2024-07-18 18:23 ./slackware64/k/kernel-source-6.9.10-noarch-1.txz
-rw-r--r-- 1 root root 195 2024-07-18 18:23 ./slackware64/k/kernel-source-6.9.10-noarch-1.txz.asc
-rw-r--r-- 1 root root 1170 2024-07-18 19:03 ./slackware64/k/maketag
-rw-r--r-- 1 root root 1170 2024-07-18 19:03 ./slackware64/k/maketag.ez
-rw-r--r-- 1 root root 18 2024-07-18 19:03 ./slackware64/k/tagfile
-rw-r--r-- 1 root root 317 2024-07-25 17:39 ./slackware64/k/kernel-source-6.9.11-noarch-1.txt
-rw-r--r-- 1 root root 139969332 2024-07-25 17:39 ./slackware64/k/kernel-source-6.9.11-noarch-1.txz
-rw-r--r-- 1 root root 195 2024-07-25 17:39 ./slackware64/k/kernel-source-6.9.11-noarch-1.txz.asc
-rw-r--r-- 1 root root 1170 2024-07-25 19:59 ./slackware64/k/maketag
-rw-r--r-- 1 root root 1170 2024-07-25 19:59 ./slackware64/k/maketag.ez
-rw-r--r-- 1 root root 18 2024-07-25 19:59 ./slackware64/k/tagfile
drwxr-xr-x 2 root root 86016 2024-07-18 20:05 ./slackware64/kde
-rw-r--r-- 1 root root 382 2024-02-15 20:27 ./slackware64/kde/akonadi-23.08.5-x86_64-1.txt
-rw-r--r-- 1 root root 2559504 2024-02-15 20:27 ./slackware64/kde/akonadi-23.08.5-x86_64-1.txz
@ -2781,7 +2781,7 @@ drwxr-xr-x 2 root root 86016 2024-07-18 20:05 ./slackware64/kde
-rw-r--r-- 1 root root 517 2024-02-15 21:47 ./slackware64/kde/zanshin-23.08.5-x86_64-1.txt
-rw-r--r-- 1 root root 686104 2024-02-15 21:47 ./slackware64/kde/zanshin-23.08.5-x86_64-1.txz
-rw-r--r-- 1 root root 163 2024-02-15 21:47 ./slackware64/kde/zanshin-23.08.5-x86_64-1.txz.asc
drwxr-xr-x 2 root root 102400 2024-07-25 02:43 ./slackware64/l
drwxr-xr-x 2 root root 102400 2024-07-25 20:25 ./slackware64/l
-rw-r--r-- 1 root root 329 2022-03-06 20:00 ./slackware64/l/GConf-3.2.6-x86_64-8.txt
-rw-r--r-- 1 root root 928144 2022-03-06 20:00 ./slackware64/l/GConf-3.2.6-x86_64-8.txz
-rw-r--r-- 1 root root 163 2022-03-06 20:00 ./slackware64/l/GConf-3.2.6-x86_64-8.txz.asc
@ -4098,9 +4098,9 @@ drwxr-xr-x 2 root root 102400 2024-07-25 02:43 ./slackware64/l
-rw-r--r-- 1 root root 257 2023-11-15 21:58 ./slackware64/l/woff2-20231106_0f4d304-x86_64-1.txt
-rw-r--r-- 1 root root 52124 2023-11-15 21:58 ./slackware64/l/woff2-20231106_0f4d304-x86_64-1.txz
-rw-r--r-- 1 root root 163 2023-11-15 21:58 ./slackware64/l/woff2-20231106_0f4d304-x86_64-1.txz.asc
-rw-r--r-- 1 root root 413 2024-03-09 19:36 ./slackware64/l/xapian-core-1.4.25-x86_64-1.txt
-rw-r--r-- 1 root root 2222996 2024-03-09 19:36 ./slackware64/l/xapian-core-1.4.25-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-03-09 19:36 ./slackware64/l/xapian-core-1.4.25-x86_64-1.txz.asc
-rw-r--r-- 1 root root 413 2024-07-25 17:48 ./slackware64/l/xapian-core-1.4.26-x86_64-1.txt
-rw-r--r-- 1 root root 2244240 2024-07-25 17:48 ./slackware64/l/xapian-core-1.4.26-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-07-25 17:48 ./slackware64/l/xapian-core-1.4.26-x86_64-1.txz.asc
-rw-r--r-- 1 root root 520 2023-07-21 19:03 ./slackware64/l/xxHash-0.8.2-x86_64-1.txt
-rw-r--r-- 1 root root 94428 2023-07-21 19:03 ./slackware64/l/xxHash-0.8.2-x86_64-1.txz
-rw-r--r-- 1 root root 163 2023-07-21 19:03 ./slackware64/l/xxHash-0.8.2-x86_64-1.txz.asc
@ -5793,13 +5793,13 @@ drwxr-xr-x 2 root root 4096 2024-05-05 18:37 ./slackware64/y
-rw-r--r-- 1 root root 1488844 2024-05-05 17:22 ./slackware64/y/nethack-3.6.7-x86_64-2.txz
-rw-r--r-- 1 root root 195 2024-05-05 17:22 ./slackware64/y/nethack-3.6.7-x86_64-2.txz.asc
-rw-r--r-- 1 root root 26 2020-12-30 21:55 ./slackware64/y/tagfile
drwxr-xr-x 18 root root 4096 2024-07-25 02:44 ./source
-rw-r--r-- 1 root root 622621 2024-07-25 02:44 ./source/CHECKSUMS.md5
-rw-r--r-- 1 root root 195 2024-07-25 02:44 ./source/CHECKSUMS.md5.asc
-rw-r--r-- 1 root root 868082 2024-07-25 02:44 ./source/FILE_LIST
-rw-r--r-- 1 root root 29757789 2024-07-25 02:44 ./source/MANIFEST.bz2
drwxr-xr-x 18 root root 4096 2024-07-25 20:27 ./source
-rw-r--r-- 1 root root 622900 2024-07-25 20:27 ./source/CHECKSUMS.md5
-rw-r--r-- 1 root root 195 2024-07-25 20:27 ./source/CHECKSUMS.md5.asc
-rw-r--r-- 1 root root 868426 2024-07-25 20:27 ./source/FILE_LIST
-rw-r--r-- 1 root root 29933126 2024-07-25 20:27 ./source/MANIFEST.bz2
-rw-r--r-- 1 root root 828 2022-02-02 04:43 ./source/README.TXT
drwxr-xr-x 124 root root 4096 2024-06-23 18:42 ./source/a
drwxr-xr-x 124 root root 4096 2024-07-25 18:05 ./source/a
-rw-r--r-- 1 root root 339 2023-09-28 19:06 ./source/a/FTBFSlog
drwxr-xr-x 2 root root 4096 2022-02-15 18:15 ./source/a/aaa_base
-rw-r--r-- 1 root root 11041 2022-02-15 04:49 ./source/a/aaa_base/_aaa_base.tar.gz
@ -6210,19 +6210,21 @@ drwxr-xr-x 2 root root 4096 2022-09-07 16:29 ./source/a/grep/scripts
-rw-r--r-- 1 root root 104 2022-09-07 16:29 ./source/a/grep/scripts/egrep
-rw-r--r-- 1 root root 104 2022-09-07 16:29 ./source/a/grep/scripts/fgrep
-rw-r--r-- 1 root root 743 2018-02-27 06:13 ./source/a/grep/slack-desc
drwxr-xr-x 2 root root 4096 2024-06-27 18:42 ./source/a/grub
drwxr-xr-x 2 root root 4096 2024-07-25 05:21 ./source/a/grub
-rw-r--r-- 1 root root 1167 2023-12-21 19:26 ./source/a/grub/0001-00_header-add-GRUB_COLOR_-variables.patch
-rw-r--r-- 1 root root 444 2024-01-02 19:45 ./source/a/grub/0001-skip-new-and-orig-files-in-etc-grub.d.patch
-rw-r--r-- 1 root root 766 2023-12-21 19:30 ./source/a/grub/0003-support-dropins-for-default-configuration.patch
-rw-r--r-- 1 root root 376 2024-06-26 17:44 ./source/a/grub/0004-add-GRUB_DISABLE_KERNEL_SYMLINKS-variable.patch
-rw-r--r-- 1 root root 1103 2018-05-16 15:18 ./source/a/grub/0198-align-struct-efi_variable-better.patch
-rw-r--r-- 1 root root 6576 2024-06-27 18:41 ./source/a/grub/09_slackware_linux
-rw-r--r-- 1 root root 483 2024-07-25 05:21 ./source/a/grub/10_linux.disable_kernel_symlinks.patch
-rw-r--r-- 1 root root 616 2024-07-24 19:14 ./source/a/grub/10_linux.osname.patch
-rw-r--r-- 1 root root 1320 2023-12-21 07:17 ./source/a/grub/b835601c7639ed1890f2d3db91900a8506011a8e.patch
-rw-r--r-- 1 root root 688 2024-06-23 22:41 ./source/a/grub/doinst.sh
-rw-r--r-- 1 root root 1607 2024-06-25 18:33 ./source/a/grub/etc.default.grub
-rw-r--r-- 1 root root 1576 2024-07-25 18:07 ./source/a/grub/etc.default.grub
-rw-r--r-- 1 root root 6675608 2023-12-20 16:53 ./source/a/grub/grub-2.12.tar.xz
-rw-r--r-- 1 root root 566 2023-12-20 16:53 ./source/a/grub/grub-2.12.tar.xz.sig
-rwxr-xr-x 1 root root 9082 2024-07-10 17:31 ./source/a/grub/grub.SlackBuild
-rwxr-xr-x 1 root root 8885 2024-07-25 18:06 ./source/a/grub/grub.SlackBuild
-rw-r--r-- 1 root root 1458 2016-12-25 09:49 ./source/a/grub/grub.dejavusansmono.gfxterm.font.diff
-rw-r--r-- 1 root root 619 2012-09-29 04:34 ./source/a/grub/initrd_naming.patch
-rw-r--r-- 1 root root 721 2023-12-21 19:34 ./source/a/grub/slack-desc
@ -6460,7 +6462,7 @@ drwxr-xr-x 2 root root 4096 2023-09-23 18:05 ./source/a/minicom
-rwxr-xr-x 1 root root 5460 2024-05-10 21:27 ./source/a/minicom/minicom.SlackBuild
-rw-r--r-- 1 root root 570 2004-09-04 21:17 ./source/a/minicom/minicom.users.gz
-rw-r--r-- 1 root root 833 2020-07-25 17:50 ./source/a/minicom/slack-desc
drwxr-xr-x 2 root root 4096 2023-11-20 18:48 ./source/a/mkinitrd
drwxr-xr-x 2 root root 4096 2024-07-24 19:05 ./source/a/mkinitrd
-rw-r--r-- 1 root root 468 2019-12-15 18:10 ./source/a/mkinitrd/0001-Fix-LUKSTRIM-with-C-T-and-UUID.patch.gz
-rw-r--r-- 1 root root 420 2021-07-16 18:07 ./source/a/mkinitrd/0002-bail-if-temp-dir-is-not-created.patch.gz
-rw-r--r-- 1 root root 217 2021-10-12 18:52 ./source/a/mkinitrd/0003-blacklist.40-usb_modeswitch.rules.patch.gz
@ -6471,23 +6473,25 @@ drwxr-xr-x 2 root root 4096 2023-11-20 18:48 ./source/a/mkinitrd
-rw-r--r-- 1 root root 369 2023-02-28 21:23 ./source/a/mkinitrd/0008-fix-check-if-BASEDEV-is-a-partition-of-a-RAID-volume.patch.gz
-rw-r--r-- 1 root root 184 2023-08-09 21:27 ./source/a/mkinitrd/0009-exclude-99-nfs.rules.patch.gz
-rw-r--r-- 1 root root 620 2023-11-20 18:50 ./source/a/mkinitrd/0010-fix-test-for-jfs-xfs-repair-tools.patch.gz
-rw-r--r-- 1 root root 3752 2022-12-02 02:24 ./source/a/mkinitrd/README.initrd
-rw-r--r-- 1 root root 4184 2024-07-24 19:30 ./source/a/mkinitrd/README.initrd
-rw-r--r-- 1 root root 2700 2023-03-31 17:12 ./source/a/mkinitrd/_initrd-tree.tar.gz
-rw-r--r-- 1 root root 2444679 2021-01-01 13:27 ./source/a/mkinitrd/busybox-1.32.1.tar.bz2
-rw-r--r-- 1 root root 121 2021-01-01 13:27 ./source/a/mkinitrd/busybox-1.32.1.tar.bz2.sig
-rw-r--r-- 1 root root 29119 2024-05-14 18:22 ./source/a/mkinitrd/busybox-dot-config
-rw-r--r-- 1 root root 373 2024-07-24 19:01 ./source/a/mkinitrd/doinst.sh
-rw-r--r-- 1 root root 1678 2019-01-23 20:47 ./source/a/mkinitrd/geninitrd
-rw-r--r-- 1 root root 818 2024-07-24 23:57 ./source/a/mkinitrd/geninitrd.default
-rw-r--r-- 1 root root 12735 2022-04-26 19:12 ./source/a/mkinitrd/init
-rw-r--r-- 1 root root 29903 2009-12-18 05:10 ./source/a/mkinitrd/keymaps.tar.gz
-rw-r--r-- 1 root root 28806 2022-04-26 19:13 ./source/a/mkinitrd/mkinitrd
-rw-r--r-- 1 root root 9549 2022-04-26 19:12 ./source/a/mkinitrd/mkinitrd.8
-rwxr-xr-x 1 root root 7784 2023-11-20 20:10 ./source/a/mkinitrd/mkinitrd.SlackBuild
-rwxr-xr-x 1 root root 8007 2024-07-24 19:02 ./source/a/mkinitrd/mkinitrd.SlackBuild
-rw-r--r-- 1 root root 7449 2022-04-26 19:12 ./source/a/mkinitrd/mkinitrd.conf.5
-rw-r--r-- 1 root root 529 2017-06-29 16:52 ./source/a/mkinitrd/mkinitrd.conf.sample
-rw-r--r-- 1 root root 535 2020-04-26 23:53 ./source/a/mkinitrd/mkinitrd.tempfile.to.mktemp.patch.gz
-rw-r--r-- 1 root root 5693 2019-03-03 21:16 ./source/a/mkinitrd/mkinitrd_command_generator.8
-rw-r--r-- 1 root root 29073 2021-03-28 18:22 ./source/a/mkinitrd/mkinitrd_command_generator.sh
-rw-r--r-- 1 root root 1448 2019-03-03 21:57 ./source/a/mkinitrd/setup.01.mkinitrd
-rw-r--r-- 1 root root 1899 2024-07-25 00:01 ./source/a/mkinitrd/setup.01.mkinitrd
-rw-r--r-- 1 root root 983 2018-02-27 06:13 ./source/a/mkinitrd/slack-desc
drwxr-xr-x 2 root root 4096 2022-09-06 18:27 ./source/a/mlocate
-rw-r--r-- 1 root root 388 2017-03-16 18:04 ./source/a/mlocate/doinst.sh.gz
@ -7962,7 +7966,7 @@ drwxr-xr-x 2 root root 4096 2024-07-09 17:32 ./source/d/ruby
-rw-r--r-- 1 root root 15906058 2024-07-09 00:27 ./source/d/ruby/ruby-3.3.4.tar.lz
-rwxr-xr-x 1 root root 4550 2024-07-21 22:50 ./source/d/ruby/ruby.SlackBuild
-rw-r--r-- 1 root root 838 2024-01-31 01:32 ./source/d/ruby/slack-desc
drwxr-xr-x 2 root root 4096 2024-06-13 17:14 ./source/d/rust
drwxr-xr-x 2 root root 4096 2024-07-25 17:45 ./source/d/rust
drwxr-xr-x 2 root root 4096 2024-02-04 19:06 ./source/d/rust-bindgen
-rw-r--r-- 1 root root 2417095 2024-02-04 19:05 ./source/d/rust-bindgen/cargo-rust-bindgen-0.69.4.tar.lz
-rwxr-xr-x 1 root root 898 2024-02-04 19:05 ./source/d/rust-bindgen/fetch-sources.sh
@ -7971,9 +7975,9 @@ drwxr-xr-x 2 root root 4096 2024-02-04 19:06 ./source/d/rust-bindgen
-rw-r--r-- 1 root root 844 2022-12-07 17:56 ./source/d/rust-bindgen/slack-desc
-rw-r--r-- 1 root root 944 2024-04-03 16:29 ./source/d/rust/0004-compiler-Use-wasm-ld-for-wasm-targets.patch
-rw-r--r-- 1 root root 261 2020-11-19 19:46 ./source/d/rust/link_libffi.diff.gz
-rwxr-xr-x 1 root root 10619 2024-06-13 17:14 ./source/d/rust/rust.SlackBuild
-rw-r--r-- 1 root root 1670 2024-06-13 17:14 ./source/d/rust/rust.url
-rw-r--r-- 1 root root 168489936 2024-06-13 14:03 ./source/d/rust/rustc-1.79.0-src.tar.lz
-rwxr-xr-x 1 root root 10619 2024-07-25 17:40 ./source/d/rust/rust.SlackBuild
-rw-r--r-- 1 root root 1665 2024-07-25 17:45 ./source/d/rust/rust.url
-rw-r--r-- 1 root root 206030821 2024-07-25 12:01 ./source/d/rust/rustc-1.80.0-src.tar.lz
-rw-r--r-- 1 root root 910 2018-02-27 06:49 ./source/d/rust/slack-desc
drwxr-xr-x 2 root root 4096 2022-09-06 18:27 ./source/d/sassc
-rw-r--r-- 1 root root 23784 2020-10-27 01:21 ./source/d/sassc/sassc-3.6.2.tar.lz
@ -8049,9 +8053,9 @@ drwxr-xr-x 2 root root 4096 2018-02-27 06:13 ./source/f
-rw-r--r-- 1 root root 960 2018-02-27 06:13 ./source/f/slack-desc.linux-faqs
-rw-r--r-- 1 root root 801 2018-02-27 06:13 ./source/f/slack-desc.linux-howtos
drwxr-xr-x 3 root root 4096 2024-05-25 17:39 ./source/installer
-rw-r--r-- 1 root root 50749 2024-07-12 17:12 ./source/installer/ChangeLog.txt
-rw-r--r-- 1 root root 50853 2024-07-25 20:06 ./source/installer/ChangeLog.txt
-rw-r--r-- 1 root root 6849 2018-03-11 00:53 ./source/installer/README
-rwxr-xr-x 1 root root 80300 2024-05-27 18:06 ./source/installer/build_installer.sh
-rwxr-xr-x 1 root root 80336 2024-07-25 20:06 ./source/installer/build_installer.sh
-rwxr-xr-x 1 root root 2252 2023-12-11 20:39 ./source/installer/installer.SlackBuild
-rw-r--r-- 1 root root 1376 2020-02-29 06:16 ./source/installer/module-blacklist
-rwxr-xr-x 1 root root 5290 2023-12-11 20:18 ./source/installer/repack_installer.SlackBuild
@ -8069,10 +8073,10 @@ drwxr-xr-x 2 root root 4096 2022-02-05 19:51 ./source/installer/sources/d
-rw-r--r-- 1 root root 833 2021-09-08 21:53 ./source/installer/sources/dnsmasq/dnsmasq-2.86.tar.xz.asc
-rw-r--r-- 1 root root 543 2010-01-22 21:33 ./source/installer/sources/dnsmasq/dnsmasq.leasedir.diff.gz
-rw-r--r-- 1 root root 246 2017-07-07 18:28 ./source/installer/sources/dnsmasq/dnsmasq.libidn2.diff.gz
drwxr-xr-x 2 root root 4096 2020-12-06 08:43 ./source/installer/sources/dropbear
drwxr-xr-x 2 root root 4096 2024-07-25 20:03 ./source/installer/sources/dropbear
-rw-r--r-- 1 root root 266 2008-03-13 13:43 ./source/installer/sources/dropbear/doinst.sh.gz
-rw-r--r-- 1 root root 2134491 2020-10-29 13:39 ./source/installer/sources/dropbear/dropbear-2020.81.tar.lz
-rwxr-xr-- 1 root root 4772 2020-12-06 08:43 ./source/installer/sources/dropbear/dropbear.Slackbuild
-rwxr-xr-- 1 root root 4740 2024-07-25 20:03 ./source/installer/sources/dropbear/dropbear.Slackbuild
-rw-r--r-- 1 root root 743 2020-12-06 08:21 ./source/installer/sources/dropbear/dropbear_emptypass.patch
-rw-r--r-- 1 root root 155 2018-01-14 05:13 ./source/installer/sources/dropbear/localoptions.h
-rw-r--r-- 1 root root 1912 2020-12-06 08:33 ./source/installer/sources/dropbear/rc.dropbear.new
@ -8094,19 +8098,19 @@ drwxr-xr-x 2 root root 4096 2024-05-28 17:53 ./source/installer/sources/i
drwxr-xr-x 2 root root 4096 2024-07-12 17:12 ./source/installer/sources/nano
-rw-r--r-- 1 root root 1667392 2024-07-12 09:24 ./source/installer/sources/nano/nano-8.1.tar.xz
-rw-r--r-- 1 root root 833 2024-07-12 09:24 ./source/installer/sources/nano/nano-8.1.tar.xz.sig
drwxr-xr-x 5 root root 4096 2024-07-18 16:35 ./source/k
-rwxr-xr-x 1 root root 8119 2023-11-15 21:04 ./source/k/build-all-kernels.sh
drwxr-xr-x 2 root root 4096 2024-07-18 16:56 ./source/k/kernel-configs
-rw-r--r-- 1 root root 261188 2024-07-18 16:56 ./source/k/kernel-configs/config-generic-6.9.10
-rw-r--r-- 1 root root 265095 2024-07-18 16:36 ./source/k/kernel-configs/config-generic-6.9.10.x64
-rw-r--r-- 1 root root 261188 2024-07-18 16:56 ./source/k/kernel-configs/config-huge-6.9.10
-rw-r--r-- 1 root root 265095 2024-07-18 16:36 ./source/k/kernel-configs/config-huge-6.9.10.x64
-rwxr-xr-x 1 root root 7441 2020-06-11 19:56 ./source/k/kernel-generic.SlackBuild
-rwxr-xr-x 1 root root 3779 2019-09-29 23:48 ./source/k/kernel-headers.SlackBuild
-rwxr-xr-x 1 root root 6513 2023-12-01 21:09 ./source/k/kernel-modules.SlackBuild
-rwxr-xr-x 1 root root 10927 2023-01-25 19:02 ./source/k/kernel-source.SlackBuild
-rw-r--r-- 1 root root 989 2024-07-18 11:37 ./source/k/linux-6.9.10.tar.sign
-rw-r--r-- 1 root root 144133252 2024-07-18 11:37 ./source/k/linux-6.9.10.tar.xz
drwxr-xr-x 5 root root 4096 2024-07-25 16:13 ./source/k
-rwxr-xr-x 1 root root 8211 2024-07-15 03:24 ./source/k/build-all-kernels.sh
drwxr-xr-x 2 root root 4096 2024-07-25 16:17 ./source/k/kernel-configs
-rw-r--r-- 1 root root 261174 2024-07-25 16:17 ./source/k/kernel-configs/config-6.9.11-generic.ia32
-rw-r--r-- 1 root root 265061 2024-07-25 16:14 ./source/k/kernel-configs/config-6.9.11-generic.x64
-rw-r--r-- 1 root root 261174 2024-07-25 16:17 ./source/k/kernel-configs/config-6.9.11-huge.ia32
-rw-r--r-- 1 root root 265061 2024-07-25 16:15 ./source/k/kernel-configs/config-6.9.11-huge.x64
-rwxr-xr-x 1 root root 7304 2024-07-11 22:15 ./source/k/kernel-generic.SlackBuild
-rwxr-xr-x 1 root root 3778 2024-07-12 01:18 ./source/k/kernel-headers.SlackBuild
-rwxr-xr-x 1 root root 6522 2024-07-11 22:02 ./source/k/kernel-modules.SlackBuild
-rwxr-xr-x 1 root root 10495 2024-07-12 01:18 ./source/k/kernel-source.SlackBuild
-rw-r--r-- 1 root root 989 2024-07-25 08:15 ./source/k/linux-6.9.11.tar.sign
-rw-r--r-- 1 root root 144133664 2024-07-25 08:15 ./source/k/linux-6.9.11.tar.xz
drwxr-xr-x 2 root root 4096 2023-01-04 20:50 ./source/k/patches-revert-i686
-rw-r--r-- 1 root root 1132 2023-01-03 00:53 ./source/k/patches-revert-i686/0001-x86-ioremap-Fix-page-aligned-size-calculation-in-__i.patch.gz
-rw-r--r-- 1 root root 246 2023-01-04 20:50 ./source/k/patches-revert-i686/README
@ -12515,11 +12519,11 @@ drwxr-xr-x 2 root root 4096 2023-11-15 21:14 ./source/l/woff2
-rw-r--r-- 1 root root 743 2020-02-16 23:10 ./source/l/woff2/slack-desc
-rw-r--r-- 1 root root 33322 2023-11-06 06:00 ./source/l/woff2/woff2-20231106_0f4d304.tar.lz
-rwxr-xr-x 1 root root 3958 2023-11-15 21:19 ./source/l/woff2/woff2.SlackBuild
drwxr-xr-x 2 root root 4096 2024-03-09 19:35 ./source/l/xapian-core
drwxr-xr-x 2 root root 4096 2024-07-25 17:47 ./source/l/xapian-core
-rw-r--r-- 1 root root 872 2018-10-30 21:09 ./source/l/xapian-core/slack-desc
-rw-r--r-- 1 root root 3205904 2024-03-07 23:41 ./source/l/xapian-core/xapian-core-1.4.25.tar.xz
-rw-r--r-- 1 root root 833 2024-03-07 23:41 ./source/l/xapian-core/xapian-core-1.4.25.tar.xz.asc
-rwxr-xr-x 1 root root 4287 2022-01-02 00:46 ./source/l/xapian-core/xapian-core.SlackBuild
-rw-r--r-- 1 root root 3246304 2024-07-18 18:42 ./source/l/xapian-core/xapian-core-1.4.26.tar.xz
-rw-r--r-- 1 root root 833 2024-07-18 18:42 ./source/l/xapian-core/xapian-core-1.4.26.tar.xz.asc
-rwxr-xr-x 1 root root 4118 2024-07-25 17:47 ./source/l/xapian-core/xapian-core.SlackBuild
drwxr-xr-x 2 root root 4096 2023-07-21 19:03 ./source/l/xxHash
-rw-r--r-- 1 root root 974 2020-06-23 19:09 ./source/l/xxHash/slack-desc
-rw-r--r-- 1 root root 689724 2023-07-21 10:01 ./source/l/xxHash/xxHash-0.8.2.tar.lz
@ -15271,9 +15275,9 @@ drwxr-xr-x 2 root root 4096 2024-04-17 18:00 ./source/x/x11/src/lib
-rw-r--r-- 1 root root 274108 2022-12-08 16:04 ./source/x/x11/src/lib/libXau-1.0.11.tar.xz
-rw-r--r-- 1 root root 602848 2024-03-10 17:41 ./source/x/x11/src/lib/libXaw-1.0.16.tar.xz
-rw-r--r-- 1 root root 482040 2024-03-02 19:03 ./source/x/x11/src/lib/libXaw3d-1.6.6.tar.xz
-rw-r--r-- 1 root root 265596 2022-12-04 22:07 ./source/x/x11/src/lib/libXcomposite-0.4.6.tar.xz
-rw-r--r-- 1 root root 289536 2024-03-02 21:01 ./source/x/x11/src/lib/libXcursor-1.2.2.tar.xz
-rw-r--r-- 1 root root 257532 2022-12-04 23:12 ./source/x/x11/src/lib/libXdamage-1.1.6.tar.xz
-rw-r--r-- 1 root root 265596 2022-12-04 22:07 ./source/x/x11/src/lib/libXcomposite-0.4.6.tar.xz
-rw-r--r-- 1 root root 289536 2024-03-02 21:01 ./source/x/x11/src/lib/libXcursor-1.2.2.tar.xz
-rw-r--r-- 1 root root 257532 2022-12-04 23:12 ./source/x/x11/src/lib/libXdamage-1.1.6.tar.xz
-rw-r--r-- 1 root root 297596 2024-03-02 21:37 ./source/x/x11/src/lib/libXdmcp-1.1.5.tar.xz
-rw-r--r-- 1 root root 212200 2010-10-31 16:46 ./source/x/x11/src/lib/libXevie-1.0.3.tar.xz
-rw-r--r-- 1 root root 341092 2024-02-04 21:43 ./source/x/x11/src/lib/libXext-1.3.6.tar.xz
@ -16013,16 +16017,13 @@ drwxr-xr-x 2 root root 4096 2023-02-19 18:29 ./source/y/nethack
-rwxr-xr-x 1 root root 4972 2024-05-05 17:20 ./source/y/nethack/nethack.SlackBuild
-rw-r--r-- 1 root root 59 2023-02-19 18:28 ./source/y/nethack/nethack.url
-rw-r--r-- 1 root root 1031 2020-12-30 21:50 ./source/y/nethack/slack-desc
drwxr-xr-x 4 root root 4096 2024-07-25 05:35 ./testing
-rw-r--r-- 1 root root 7785 2024-07-25 05:35 ./testing/CHECKSUMS.md5
-rw-r--r-- 1 root root 195 2024-07-25 05:35 ./testing/CHECKSUMS.md5.asc
-rw-r--r-- 1 root root 9836 2024-07-25 05:35 ./testing/FILE_LIST
-rw-r--r-- 1 root root 1484944 2024-07-25 05:35 ./testing/MANIFEST.bz2
-rw-r--r-- 1 root root 4156 2024-07-25 05:35 ./testing/PACKAGES.TXT
drwxr-xr-x 2 root root 4096 2024-07-25 05:35 ./testing/packages
-rw-r--r-- 1 root root 269 2024-07-25 05:24 ./testing/packages/grub-2.12-x86_64-13.txt
-rw-r--r-- 1 root root 12761276 2024-07-25 05:24 ./testing/packages/grub-2.12-x86_64-13.txz
-rw-r--r-- 1 root root 195 2024-07-25 05:24 ./testing/packages/grub-2.12-x86_64-13.txz.asc
drwxr-xr-x 4 root root 4096 2024-07-25 20:27 ./testing
-rw-r--r-- 1 root root 3548 2024-07-25 20:27 ./testing/CHECKSUMS.md5
-rw-r--r-- 1 root root 195 2024-07-25 20:27 ./testing/CHECKSUMS.md5.asc
-rw-r--r-- 1 root root 4603 2024-07-25 20:27 ./testing/FILE_LIST
-rw-r--r-- 1 root root 1422882 2024-07-25 20:27 ./testing/MANIFEST.bz2
-rw-r--r-- 1 root root 3046 2024-07-25 20:27 ./testing/PACKAGES.TXT
drwxr-xr-x 2 root root 4096 2024-07-25 18:06 ./testing/packages
-rw-r--r-- 1 root root 489 2024-07-24 18:32 ./testing/packages/kernel-generic-6.10.1-x86_64-1.txt
-rw-r--r-- 1 root root 14513484 2024-07-24 18:32 ./testing/packages/kernel-generic-6.10.1-x86_64-1.txz
-rw-r--r-- 1 root root 195 2024-07-24 18:32 ./testing/packages/kernel-generic-6.10.1-x86_64-1.txz.asc
@ -16038,29 +16039,7 @@ drwxr-xr-x 2 root root 4096 2024-07-25 05:35 ./testing/packages
-rw-r--r-- 1 root root 317 2024-07-24 18:18 ./testing/packages/kernel-source-6.10.1-noarch-1.txt
-rw-r--r-- 1 root root 140971964 2024-07-24 18:18 ./testing/packages/kernel-source-6.10.1-noarch-1.txz
-rw-r--r-- 1 root root 195 2024-07-24 18:18 ./testing/packages/kernel-source-6.10.1-noarch-1.txz.asc
-rw-r--r-- 1 root root 527 2024-07-25 00:01 ./testing/packages/mkinitrd-1.4.11-x86_64-35.txt
-rw-r--r-- 1 root root 621720 2024-07-25 00:01 ./testing/packages/mkinitrd-1.4.11-x86_64-35.txz
-rw-r--r-- 1 root root 195 2024-07-25 00:01 ./testing/packages/mkinitrd-1.4.11-x86_64-35.txz.asc
drwxr-xr-x 5 root root 4096 2024-07-24 23:37 ./testing/source
drwxr-xr-x 2 root root 4096 2024-07-25 05:21 ./testing/source/grub
-rw-r--r-- 1 root root 1167 2023-12-21 19:26 ./testing/source/grub/0001-00_header-add-GRUB_COLOR_-variables.patch
-rw-r--r-- 1 root root 444 2024-01-02 19:45 ./testing/source/grub/0001-skip-new-and-orig-files-in-etc-grub.d.patch
-rw-r--r-- 1 root root 766 2023-12-21 19:30 ./testing/source/grub/0003-support-dropins-for-default-configuration.patch
-rw-r--r-- 1 root root 376 2024-06-26 17:44 ./testing/source/grub/0004-add-GRUB_DISABLE_KERNEL_SYMLINKS-variable.patch
-rw-r--r-- 1 root root 1103 2018-05-16 15:18 ./testing/source/grub/0198-align-struct-efi_variable-better.patch
-rw-r--r-- 1 root root 6576 2024-06-27 18:41 ./testing/source/grub/09_slackware_linux
-rw-r--r-- 1 root root 483 2024-07-25 05:21 ./testing/source/grub/10_linux.disable_kernel_symlinks.patch
-rw-r--r-- 1 root root 616 2024-07-24 19:14 ./testing/source/grub/10_linux.osname.patch
-rw-r--r-- 1 root root 1320 2023-12-21 07:17 ./testing/source/grub/b835601c7639ed1890f2d3db91900a8506011a8e.patch
-rw-r--r-- 1 root root 688 2024-06-23 22:41 ./testing/source/grub/doinst.sh
-rw-r--r-- 1 root root 1607 2024-06-25 18:33 ./testing/source/grub/etc.default.grub
-rw-r--r-- 1 root root 6675608 2023-12-20 16:53 ./testing/source/grub/grub-2.12.tar.xz
-rw-r--r-- 1 root root 566 2023-12-20 16:53 ./testing/source/grub/grub-2.12.tar.xz.sig
-rwxr-xr-x 1 root root 8885 2024-07-25 05:22 ./testing/source/grub/grub.SlackBuild
-rw-r--r-- 1 root root 1458 2016-12-25 09:49 ./testing/source/grub/grub.dejavusansmono.gfxterm.font.diff
-rw-r--r-- 1 root root 619 2012-09-29 04:34 ./testing/source/grub/initrd_naming.patch
-rw-r--r-- 1 root root 721 2023-12-21 19:34 ./testing/source/grub/slack-desc
-rw-r--r-- 1 root root 431 2024-06-26 18:21 ./testing/source/grub/update-grub
drwxr-xr-x 3 root root 4096 2024-07-25 18:05 ./testing/source
drwxr-xr-x 5 root root 4096 2024-07-24 20:52 ./testing/source/k
-rwxr-xr-x 1 root root 8211 2024-07-15 03:24 ./testing/source/k/build-all-kernels.sh
drwxr-xr-x 2 root root 4096 2024-07-24 17:01 ./testing/source/k/kernel-configs
@ -16087,40 +16066,9 @@ drwxr-xr-x 2 root root 4096 2023-11-15 21:07 ./testing/source/k/slack-desc
-rw-r--r-- 1 root root 778 2018-02-27 06:16 ./testing/source/k/slack-desc/slack-desc.kernel-source
-rw-r--r-- 1 root root 778 2018-02-27 06:16 ./testing/source/k/slack-desc/slack-desc.kernel-source.vanilla
-rw-r--r-- 1 root root 935 2023-11-17 19:41 ./testing/source/k/slack-desc/slack-desc.kernel-template
drwxr-xr-x 2 root root 4096 2024-07-24 19:05 ./testing/source/mkinitrd
-rw-r--r-- 1 root root 468 2019-12-15 18:10 ./testing/source/mkinitrd/0001-Fix-LUKSTRIM-with-C-T-and-UUID.patch.gz
-rw-r--r-- 1 root root 420 2021-07-16 18:07 ./testing/source/mkinitrd/0002-bail-if-temp-dir-is-not-created.patch.gz
-rw-r--r-- 1 root root 217 2021-10-12 18:52 ./testing/source/mkinitrd/0003-blacklist.40-usb_modeswitch.rules.patch.gz
-rw-r--r-- 1 root root 498 2022-01-25 03:31 ./testing/source/mkinitrd/0004-check-if-BASEDEV-is-a-partition-of-a-RAID-volume.patch.gz
-rw-r--r-- 1 root root 342 2022-01-26 20:32 ./testing/source/mkinitrd/0005-support-modules-compressed-with-xz.patch.gz
-rw-r--r-- 1 root root 349 2022-04-26 19:01 ./testing/source/mkinitrd/0006-coreutils-9.1-ensure-target-dir-exists.patch.gz
-rw-r--r-- 1 root root 306 2022-07-09 17:58 ./testing/source/mkinitrd/0007-kmod30.patch.gz
-rw-r--r-- 1 root root 369 2023-02-28 21:23 ./testing/source/mkinitrd/0008-fix-check-if-BASEDEV-is-a-partition-of-a-RAID-volume.patch.gz
-rw-r--r-- 1 root root 184 2023-08-09 21:27 ./testing/source/mkinitrd/0009-exclude-99-nfs.rules.patch.gz
-rw-r--r-- 1 root root 620 2023-11-20 18:50 ./testing/source/mkinitrd/0010-fix-test-for-jfs-xfs-repair-tools.patch.gz
-rw-r--r-- 1 root root 4184 2024-07-24 19:30 ./testing/source/mkinitrd/README.initrd
-rw-r--r-- 1 root root 2700 2023-03-31 17:12 ./testing/source/mkinitrd/_initrd-tree.tar.gz
-rw-r--r-- 1 root root 2444679 2021-01-01 13:27 ./testing/source/mkinitrd/busybox-1.32.1.tar.bz2
-rw-r--r-- 1 root root 121 2021-01-01 13:27 ./testing/source/mkinitrd/busybox-1.32.1.tar.bz2.sig
-rw-r--r-- 1 root root 29119 2024-05-14 18:22 ./testing/source/mkinitrd/busybox-dot-config
-rw-r--r-- 1 root root 373 2024-07-24 19:01 ./testing/source/mkinitrd/doinst.sh
-rw-r--r-- 1 root root 1678 2019-01-23 20:47 ./testing/source/mkinitrd/geninitrd
-rw-r--r-- 1 root root 818 2024-07-24 23:57 ./testing/source/mkinitrd/geninitrd.default
-rw-r--r-- 1 root root 12735 2022-04-26 19:12 ./testing/source/mkinitrd/init
-rw-r--r-- 1 root root 29903 2009-12-18 05:10 ./testing/source/mkinitrd/keymaps.tar.gz
-rw-r--r-- 1 root root 28806 2022-04-26 19:13 ./testing/source/mkinitrd/mkinitrd
-rw-r--r-- 1 root root 9549 2022-04-26 19:12 ./testing/source/mkinitrd/mkinitrd.8
-rwxr-xr-x 1 root root 8007 2024-07-24 19:02 ./testing/source/mkinitrd/mkinitrd.SlackBuild
-rw-r--r-- 1 root root 7449 2022-04-26 19:12 ./testing/source/mkinitrd/mkinitrd.conf.5
-rw-r--r-- 1 root root 529 2017-06-29 16:52 ./testing/source/mkinitrd/mkinitrd.conf.sample
-rw-r--r-- 1 root root 535 2020-04-26 23:53 ./testing/source/mkinitrd/mkinitrd.tempfile.to.mktemp.patch.gz
-rw-r--r-- 1 root root 5693 2019-03-03 21:16 ./testing/source/mkinitrd/mkinitrd_command_generator.8
-rw-r--r-- 1 root root 29073 2021-03-28 18:22 ./testing/source/mkinitrd/mkinitrd_command_generator.sh
-rw-r--r-- 1 root root 1899 2024-07-25 00:01 ./testing/source/mkinitrd/setup.01.mkinitrd
-rw-r--r-- 1 root root 983 2018-02-27 06:13 ./testing/source/mkinitrd/slack-desc
drwxr-xr-x 2 root root 4096 2024-07-18 19:17 ./usb-and-pxe-installers
drwxr-xr-x 2 root root 4096 2024-07-25 20:19 ./usb-and-pxe-installers
-rw-r--r-- 1 root root 31203 2011-03-21 21:21 ./usb-and-pxe-installers/README_PXE.TXT
-rw-r--r-- 1 root root 9197 2013-09-25 04:33 ./usb-and-pxe-installers/README_USB.TXT
-rw-r--r-- 1 root root 574 2013-03-27 04:59 ./usb-and-pxe-installers/pxelinux.cfg_default
-rw-r--r-- 1 root root 69846016 2024-07-18 19:17 ./usb-and-pxe-installers/usbboot.img
-rw-r--r-- 1 root root 70038528 2024-07-25 20:19 ./usb-and-pxe-installers/usbboot.img
-rw-r--r-- 1 root root 16314 2022-03-24 20:54 ./usb-and-pxe-installers/usbimg2disk.sh

View file

@ -1,7 +1,7 @@
Slackware initrd mini HOWTO
by Patrick Volkerding, volkerdi@slackware.com
Thu Jul 18 19:02:59 UTC 2024
Thu Jul 25 19:59:29 UTC 2024
This document describes how to create and install an initrd, which may be
required to use the 4.x kernel. Also see "man mkinitrd".
@ -33,16 +33,16 @@ flexible to ship a generic kernel and a set of kernel modules for it.
The easiest way to make the initrd is to use the mkinitrd script included
in Slackware's mkinitrd package. We'll walk through the process of
upgrading to the generic 6.9.10 Linux kernel using the packages
upgrading to the generic 6.9.11 Linux kernel using the packages
found in Slackware's slackware/a/ directory.
First, make sure the kernel, kernel modules, and mkinitrd package are
installed (the current version numbers might be a little different, so
this is just an example):
installpkg kernel-generic-6.9.10-x86_64-1.txz
installpkg kernel-modules-6.9.10-x86_64-1.txz
installpkg mkinitrd-1.4.11-x86_64-34.txz
installpkg kernel-generic-6.9.11-x86_64-1.txz
installpkg kernel-modules-6.9.11-x86_64-1.txz
installpkg mkinitrd-1.4.11-x86_64-35.txz
Change into the /boot directory:
@ -52,7 +52,7 @@ Now you'll want to run "mkinitrd". I'm using ext4 for my root filesystem,
and since the disk controller requires no special support the ext4 module
will be the only one I need to load:
mkinitrd -c -k 6.9.10 -m ext4
mkinitrd -c -k 6.9.11 -m ext4
This should do two things. First, it will create a directory
/boot/initrd-tree containing the initrd's filesystem. Then it will
@ -61,10 +61,10 @@ you could make some additional changes in /boot/initrd-tree/ and
then run mkinitrd again without options to rebuild the image. That's
optional, though, and only advanced users will need to think about that.
Here's another example: Build an initrd image using Linux 6.9.10
Here's another example: Build an initrd image using Linux 6.9.11
kernel modules for a system with an ext4 root partition on /dev/sdb3:
mkinitrd -c -k 6.9.10 -m ext4 -f ext4 -r /dev/sdb3
mkinitrd -c -k 6.9.11 -m ext4 -f ext4 -r /dev/sdb3
4. Now that I've built an initrd, how do I use it?

View file

@ -1,5 +1,5 @@
Welcome to 09Slackware6407 version 15.1 (Linux kernel 6.9.10)!
Welcome to 09Slackware6407 version 15.1 (Linux kernel 6.9.11)!
If you need to pass extra parameters to the kernel, enter them at the prompt
below after the name of the kernel to boot (e.g., huge.s).

View file

@ -1,3 +1,3 @@
These kernels are version 6.9.10.
These kernels are version 6.9.11.

View file

@ -1072,15 +1072,4 @@ gzip ./source/x/ibus/doinst.sh
gzip ./source/x/ibus/emoji-test.txt
gzip ./source/x/xcm/xcm.udev.rules.diff
gzip ./source/x/libva/doinst.sh
gzip ./testing/source/mkinitrd/0005-support-modules-compressed-with-xz.patch
gzip ./testing/source/mkinitrd/mkinitrd.tempfile.to.mktemp.patch
gzip ./testing/source/mkinitrd/0006-coreutils-9.1-ensure-target-dir-exists.patch
gzip ./testing/source/mkinitrd/0001-Fix-LUKSTRIM-with-C-T-and-UUID.patch
gzip ./testing/source/mkinitrd/0008-fix-check-if-BASEDEV-is-a-partition-of-a-RAID-volume.patch
gzip ./testing/source/mkinitrd/0007-kmod30.patch
gzip ./testing/source/mkinitrd/0004-check-if-BASEDEV-is-a-partition-of-a-RAID-volume.patch
gzip ./testing/source/mkinitrd/0009-exclude-99-nfs.rules.patch
gzip ./testing/source/mkinitrd/0002-bail-if-temp-dir-is-not-created.patch
gzip ./testing/source/mkinitrd/0003-blacklist.40-usb_modeswitch.rules.patch
gzip ./testing/source/mkinitrd/0010-fix-test-for-jfs-xfs-repair-tools.patch
gzip ./testing/source/k/patches-revert-i686/0001-x86-ioremap-Fix-page-aligned-size-calculation-in-__i.patch

View file

@ -66,9 +66,9 @@ system. :^) Press ENTER when you are done." 21 76 10 \
"jfsutils" "Utilities for IBM's Journaled Filesystem" "on" \
"kbd" "Change keyboard and console mappings" "on" \
"kernel-firmware" "Linux kernel firmware -- REQUIRED" "on" \
"kernel-generic" "Generic 6.9.10 kernel (needs an initrd)" "on" \
"kernel-huge" "Loaded 6.9.10 Linux kernel" "on" \
"kernel-modules" "Linux 6.9.10 kernel modules -- REQUIRED" "on" \
"kernel-generic" "Generic 6.9.11 kernel (needs an initrd)" "on" \
"kernel-huge" "Loaded 6.9.11 Linux kernel" "on" \
"kernel-modules" "Linux 6.9.11 kernel modules -- REQUIRED" "on" \
"kmod" "Kernel module utilities -- REQUIRED" "on" \
"lbzip2" "Parallel bzip2 compressor" "on" \
"less" "A text pager utility - REQUIRED" "on" \

View file

@ -66,9 +66,9 @@ system. :^) Press ENTER when you are done." 21 76 10 \
"jfsutils" "Utilities for IBM's Journaled Filesystem" "on" \
"kbd" "Change keyboard and console mappings" "on" \
"kernel-firmware" "Linux kernel firmware -- REQUIRED" "on" \
"kernel-generic" "Generic 6.9.10 kernel (needs an initrd)" "on" \
"kernel-huge" "Loaded 6.9.10 Linux kernel" "on" \
"kernel-modules" "Linux 6.9.10 kernel modules -- REQUIRED" "on" \
"kernel-generic" "Generic 6.9.11 kernel (needs an initrd)" "on" \
"kernel-huge" "Loaded 6.9.11 Linux kernel" "on" \
"kernel-modules" "Linux 6.9.11 kernel modules -- REQUIRED" "on" \
"kmod" "Kernel module utilities -- REQUIRED" "on" \
"lbzip2" "Parallel bzip2 compressor" "on" \
"less" "A text pager utility - REQUIRED" "on" \

View file

@ -21,7 +21,7 @@ from series K. Use the UP/DOWN keys to scroll through the list, and \
the SPACE key to deselect any items you don't want to install. \
Press ENTER when you are \
done." 11 70 1 \
"kernel-source" "Linux 6.9.10 kernel source" "on" \
"kernel-source" "Linux 6.9.11 kernel source" "on" \
2> $TMP/SeTpkgs
if [ $? = 1 -o $? = 255 ]; then
rm -f $TMP/SeTpkgs

View file

@ -21,7 +21,7 @@ from series K. Use the UP/DOWN keys to scroll through the list, and \
the SPACE key to deselect any items you don't want to install. \
Press ENTER when you are \
done." 11 70 1 \
"kernel-source" "Linux 6.9.10 kernel source" "on" \
"kernel-source" "Linux 6.9.11 kernel source" "on" \
2> $TMP/SeTpkgs
if [ $? = 1 -o $? = 255 ]; then
rm -f $TMP/SeTpkgs

View file

@ -37,8 +37,8 @@ GRUB_DISABLE_OS_PROBER="false"
# Disable the submenus:
GRUB_DISABLE_SUBMENU="true"
# When using 09_slackware_linux, this option skips making menu entries for the
# symbolic links to kernels. Some folks don't like the extra (redundant) menu
# entries, while others like having an unversioned menu entry that doesn't
# require "update-grub" after installing new kernels. Your call.
# This option skips making menu entries for the symbolic links to kernels.
# Some folks don't like the extra (redundant) menu entries, while others
# like having an unversioned menu entry that doesn't require "update-grub"
# after installing new kernels. Your call.
#GRUB_DISABLE_KERNEL_SYMLINKS="true"

View file

@ -28,7 +28,7 @@ PKGNAM=grub
VERSION=${VERSION:-$(echo $PKGNAM-*.tar.xz | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
# Better to use _ than ~ in the package filenames version:
PKGVER=$(echo $VERSION | tr '~' '_')
BUILD=${BUILD:-11}
BUILD=${BUILD:-14}
# If you use stack-protector, then grub will not work with legacy BIOS:
STACKPROTECT=${STACKPROTECT:---enable-stack-protector=no}
@ -36,7 +36,7 @@ STACKPROTECT=${STACKPROTECT:---enable-stack-protector=no}
# Automatically determine the architecture we're building on:
if [ -z "$ARCH" ]; then
case "$(uname -m)" in
i?86) ARCH=i586 ;;
i?86) ARCH=i686 ;;
arm*) readelf /usr/bin/file -A | grep -E -q "Tag_CPU.*[4,5]" && ARCH=arm || ARCH=armv7hl ;;
# Unless $ARCH is already set, use uname -m for all other archs:
*) ARCH=$(uname -m) ;;
@ -54,32 +54,15 @@ fi
NUMJOBS=${NUMJOBS:-" -j$(expr $(nproc) + 1) "}
if [ "$ARCH" = "i386" ]; then
SLKCFLAGS="-march=i386 -mcpu=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i486" ]; then
SLKCFLAGS="-march=i486 -mtune=i686"
if [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-mtune=generic"
EFI32_FLAGS=" --with-platform=efi --target=i386 --program-prefix= "
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i586" ]; then
SLKCFLAGS="-march=i586 -mtune=i686"
EFI32_FLAGS=" --with-platform=efi --target=i386 --program-prefix= "
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-march=i686"
EFI32_FLAGS=" --with-platform=efi --target=i386 --program-prefix= "
LIBDIRSUFFIX=""
elif [ "$ARCH" = "s390" ]; then
SLKCFLAGS=""
LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS=""
SLKCFLAGS="-mtune=generic"
EFI32_FLAGS=" --with-platform=efi --target=i386 --program-prefix= "
EFI_FLAGS=" --with-platform=efi --target=x86_64 --program-prefix= "
LIBDIRSUFFIX="64"
elif [ "$ARCH" = "armv7hl" ]; then
SLKCFLAGS="-march=armv7-a -mfpu=vfpv3-d16"
LIBDIRSUFFIX=""
else
SLKCFLAGS=""
LIBDIRSUFFIX=""
@ -106,7 +89,7 @@ find . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \+
# Use /boot/initrd.gz as a valid initrd name:
# Accept /boot/initrd.gz as a valid initrd name (obsolete?):
cat $CWD/initrd_naming.patch | patch -p1 --verbose || exit 1
# Support DejaVuSansMono font (dejavusansmono.pf2) by default:
@ -131,6 +114,12 @@ cat $CWD/0004-add-GRUB_DISABLE_KERNEL_SYMLINKS-variable.patch | patch -p1 --verb
# Fix 2.12 release with upstream commit (won't compile otherwise):
cat $CWD/b835601c7639ed1890f2d3db91900a8506011a8e.patch | patch -p1 --verbose || exit 1
# For Slackware, opt-out of having our operating system renamed:
cat $CWD/10_linux.osname.patch | patch -p1 --verbose || exit 1
# Skip symlinks to kernels according to GRUB_DISABLE_KERNEL_SYMLINKS:
cat $CWD/10_linux.disable_kernel_symlinks.patch | patch -p1 --verbose || exit 1
# Still won't compile. Someday they'll remember how to cut a new release.
touch grub-core/extra_deps.lst
@ -172,11 +161,12 @@ fi
# Always end with regular build:
build_grub || exit 1
# Add custom 09_slackware_linux config. Thanks to Richard Cranium for the
# initial version, and Daedra for making it POSIX compliant:
cp -a $CWD/09_slackware_linux $PKG/etc/grub.d/09_slackware_linux
chown root:root $PKG/etc/grub.d/09_slackware_linux
chmod 755 $PKG/etc/grub.d/09_slackware_linux
## NOT USED (but we'll leave the file here for now)
## Add custom 09_slackware_linux config. Thanks to Richard Cranium for the
## initial version, and Daedra for making it POSIX compliant:
#cp -a $CWD/09_slackware_linux $PKG/etc/grub.d/09_slackware_linux
#chown root:root $PKG/etc/grub.d/09_slackware_linux
#chmod 755 $PKG/etc/grub.d/09_slackware_linux
# Preserve files in /etc/grub.d/:
for file in $PKG/etc/grub.d/*_* ; do

View file

@ -76,7 +76,7 @@ initrd. Here's an example section of lilo.conf showing how this is
done:
# Linux bootable partition config begins
image = /boot/vmlinuz-generic-@KERNEL_VERSION@
image = /boot/vmlinuz-@KERNEL_VERSION@-generic
initrd = /boot/initrd.gz
root = /dev/sda6
label = @LILO_KERNEL_NAME@
@ -93,6 +93,19 @@ Other bootloaders such as syslinux also support the use of an initrd.
See the documentation for those programs for details on using an
initrd with them.
Some, such as GRUB, require the initrd to be named similarly to the
kernel. So, for this kernel:
/boot/vmlinuz-@KERNEL_VERSION@-generic
You would want to rename your initrd to this:
/boot/initrd-@KERNEL_VERSION@-generic.img
In fact, if you use the geninitrd script to make your initrd (which it
will pretty much do automatically for the generic kernel) it will name
it this way, and will make a compatibilty symlink initrd.gz.
---------

View file

@ -1,6 +1,6 @@
#!/bin/bash
# Copyright 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2015, 2016, 2017, 2018, 2021, 2022, 2023 Patrick J. Volkerding, Sebeka, MN, USA
# Copyright 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2015, 2016, 2017, 2018, 2021, 2022, 2023, 2024 Patrick J. Volkerding, Sebeka, MN, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@ -25,12 +25,12 @@ cd $(dirname $0) ; CWD=$(pwd)
PKGNAM=mkinitrd
VERSION=${VERSION:-1.4.11}
BB=1.32.1
BUILD=${BUILD:-34}
BUILD=${BUILD:-35}
# Automatically determine the architecture we're building on:
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
i?86) export ARCH=i586 ;;
i?86) export ARCH=i686 ;;
arm*) export ARCH=arm ;;
# Unless $ARCH is already set, use uname -m for all other archs:
*) export ARCH=$( uname -m ) ;;
@ -168,6 +168,10 @@ case "$( uname -m )" in
esac
chown root:root $PKG/etc/mkinitrd.conf.sample
chmod 644 $PKG/etc/mkinitrd.conf.sample
mkdir -p $PKG/etc/default
cp -a $CWD/geninitrd.default $PKG/etc/default/geninitrd.new
chown root:root $PKG/etc/default/geninitrd.new
chmod 644 $PKG/etc/default/geninitrd.new
mkdir -p $PKG/usr/doc/mkinitrd-$VERSION
sed $CWD/README.initrd \
@ -187,8 +191,8 @@ find $PKG | xargs file | grep -e "executable" -e "shared object" \
| grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
mkdir -p $PKG/install
cat $CWD/doinst.sh > $PKG/install/doinst.sh
cat $CWD/slack-desc > $PKG/install/slack-desc
cd $PKG
/sbin/makepkg -l y -c n $TMP/mkinitrd-$VERSION-$ARCH-$BUILD.txz

View file

@ -1,37 +1,51 @@
#!/bin/sh
#BLURB="Generate /boot/initrd.gz for the generic kernel"
# Start with the version for vmlinuz-generic-smp:
KERNEL_SYMLINK="boot/vmlinuz-generic-smp"
if [ -L $KERNEL_SYMLINK ]; then
KERNEL_VERSION_LIST=$(strings $KERNEL_SYMLINK | grep '([^ ]*@[^ ]*) #' | cut -f1 -d' ')
# Load defaults:
if [ -r etc/default/geninitrd ]; then
. etc/default/geninitrd
fi
# Next add the version for vmlinuz-generic:
KERNEL_SYMLINK="boot/vmlinuz-generic"
if [ -L $KERNEL_SYMLINK ]; then
if [ -z $KERNEL_VERSION_LIST ]; then
KERNEL_VERSION_LIST=$(strings $KERNEL_SYMLINK | grep '([^ ]*@[^ ]*) #' | cut -f1 -d' ')
else
KERNEL_VERSION_LIST="$KERNEL_VERSION_LIST:$(strings $KERNEL_SYMLINK | grep '([^ ]*@[^ ]*) #' | cut -f1 -d' ')"
fi
if [ -z "$KERNEL_SYMLINK" ]; then
KERNEL_SYMLINK="boot/vmlinuz-generic"
elif [ "$(echo $KERNEL_SYMLINK | cut -b 1)" = "/" ]; then # trim to make a relative path
KERNEL_SYMLINK="$(echo $KERNEL_SYMLINK | cut -b 2-)"
fi
# Proper plural(s):
if echo $KERNEL_VERSION_LIST | grep -q : ; then
KERNEL=kernels
else
KERNEL=kernel
# Find the kernel version:
if [ -r $KERNEL_SYMLINK ]; then
KERNEL_VERSION=$(strings $KERNEL_SYMLINK | grep '([^ ]*@[^ ]*) #' | cut -f1 -d' ')
fi
# Assume the kernel "name" aka flavor is just the second part of the symlink name:
KERNEL_NAME="$(echo $KERNEL_SYMLINK | rev | cut -f 1 -d - | rev)"
# Sometimes mkinitrd_command_generator.sh does not detect LVM properly. Until I
# get to the bottom of that, it's safer to just always include LVM support.
LVM_OPTION="-L"
# Generate the initrd:
if [ ! -z $KERNEL_VERSION_LIST ]; then
if [ ! -z $KERNEL_VERSION ]; then
dialog --title "GENERATING INITIAL RAMDISK" --infobox \
"Generating an initial ramdisk for use with the $KERNEL_VERSION_LIST generic \
${KERNEL}. The initial ramdisk contains kernel modules needed to mount the \
"Generating an initial ramdisk for use with the $KERNEL_VERSION kernel. \
The initial ramdisk contains kernel modules needed to mount the \
root partition, and must be regenerated whenever the kernel is updated. To \
regenerate the initrd, select this setup script from within pkgtool, or run \
'geninitrd' which will produce an initial ramdisk (/boot/initrd.gz) for the \
installed generic ${KERNEL}." 9 68
chroot . /usr/share/mkinitrd/mkinitrd_command_generator.sh -k $KERNEL_VERSION_LIST | chroot . bash 1> /dev/null 2> /dev/null
installed kernel." 8 70
chroot . /usr/share/mkinitrd/mkinitrd_command_generator.sh -k $KERNEL_VERSION -a "$LVM_OPTION -o /boot/initrd-${KERNEL_VERSION}-${KERNEL_NAME}.img" | chroot . bash 1> /dev/null 2> /dev/null
fi
if [ "$GENINITRD_NAMED_SYMLINK" = "true" ]; then
( cd boot
rm -f initrd-${KERNEL_NAME}.img
ln -sf initrd-${KERNEL_VERSION}-${KERNEL_NAME}.img initrd-${KERNEL_NAME}.img
)
fi
if [ "$GENINITRD_INITRD_GZ_SYMLINK" = "true" ]; then
( cd boot
rm -f initrd.gz
ln -sf initrd-${KERNEL_VERSION}-${KERNEL_NAME}.img initrd.gz
)
fi

View file

@ -26,16 +26,16 @@ cd $(dirname $0) ; CWD=$(pwd)
PKGNAM=rust
SRCNAM="${PKGNAM}c"
VERSION=${VERSION:-1.79.0}
VERSION=${VERSION:-1.80.0}
BUILD=${BUILD:-1}
# Set this to YES to build with the system LLVM, or NO to use the bundled LLVM.
SYSTEM_LLVM=${SYSTEM_LLVM:-NO}
# Bootstrap variables (might not be kept updated for latest Rust):
RSTAGE0_VERSION=${RSTAGE0_VERSION:-1.78.0}
RSTAGE0_DIR=${RSTAGE0_DIR:-2024-05-02}
CSTAGE0_VERSION=${CSTAGE0_VERSION:-1.78.0}
RSTAGE0_VERSION=${RSTAGE0_VERSION:-1.79.0}
RSTAGE0_DIR=${RSTAGE0_DIR:-2024-06-13}
CSTAGE0_VERSION=${CSTAGE0_VERSION:-1.79.0}
CSTAGE0_DIR=${CSTAGE0_DIR:-$RSTAGE0_DIR}
# Automatically determine the architecture we're building on:

View file

@ -1,5 +1,5 @@
# Source code (repacked to .tar.lz):
VERSION=1.79.0
VERSION=1.80.0
rm -f rustc-${VERSION}-src.tar.*
lftpget https://static.rust-lang.org/dist/rustc-${VERSION}-src.tar.gz
lftpget https://static.rust-lang.org/dist/rustc-${VERSION}-src.tar.gz.asc
@ -17,11 +17,11 @@ fi
# should be able to compile the next released version of Rust.
#
# To find the expected date/versions for bootstrap binaries to be able to
# update the settings below, look at src/stage0.json in the Rust sources.
# update the settings below, look at src/stage0 in the Rust sources.
exit 0
BOOTSTRAP_DATE=2024-05-02
BOOTSTRAP_VERSION=1.78.0
BOOTSTRAP_DATE=2024-06-13
BOOTSTRAP_VERSION=1.79.0
BOOTSTRAP_CARGO=$BOOTSTRAP_VERSION
# i686 bootstrap:

View file

@ -1,3 +1,6 @@
Thu Jul 25 20:06:25 UTC 2024
Updated compiler flags for i686 and x86_64.
+--------------------------+
Fri Jul 12 17:12:33 UTC 2024
Upgrade to nano-8.1.
+--------------------------+

View file

@ -166,11 +166,11 @@ case $ARCH in
ARCHQUADLET="-gnueabihf" ;;
aarch64) SLKCFLAGS="-O2"
ARCHQUADLET="" ;;
i?86) SLKCFLAGS="-O2 -march=i686 -mtune=i686"
i?86) SLKCFLAGS="-O2 -march=pentium4 -mtune=generic"
ARCHQUADLET="" ;;
s390*) SLKCFLAGS="-O2"
ARCHQUADLET="" ;;
x86_64) SLKCFLAGS="-O2 -fPIC"
x86_64) SLKCFLAGS="-O2 -march=x86-64 -mtune=generic -fPIC"
ARCHQUADLET="" ;;
esac

View file

@ -38,7 +38,7 @@ PROGS="dropbear dbclient dropbearkey dropbearconvert scp ssh"
# Automatically determine the architecture we're building on:
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
i?86) export ARCH=i586 ;;
i?86) export ARCH=i686 ;;
arm*) export ARCH=arm ;;
# Unless $ARCH is already set, use uname -m for all other archs:
*) export ARCH=$( uname -m ) ;;
@ -58,14 +58,11 @@ NUMJOBS=${NUMJOBS:-" -j$(expr $(nproc) + 1) "}
TMP=${TMP:-/tmp}
PKG=$TMP/package-$PKGNAM
if [ "$ARCH" = "i586" ]; then
SLKCFLAGS="-O2 -march=i586 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "s390" ]; then
SLKCFLAGS="-O2"
if [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=pentium4 -mtune=generic"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
SLKCFLAGS="-O2 -march=x86-64 -mtune=generic -fPIC"
LIBDIRSUFFIX="64"
else
SLKCFLAGS="-O2"

View file

@ -1,6 +1,6 @@
#!/bin/sh
# Copyright 2018, 2021, 2022, 2023 Patrick J. Volkerding, Sebeka, Minnesota, USA
# Copyright 2018, 2021, 2022, 2023, 2024 Patrick J. Volkerding, Sebeka, Minnesota, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@ -67,12 +67,12 @@ for recipe in $RECIPES ; do
if [ "$recipe" = "x86_64" ]; then
# Recipe for x86_64:
export CONFIG_SUFFIX=".x64"
unset LOCALVERSION
#unset LOCALVERSION
OUTPUT=${OUTPUT:-${TMP}/output-x86_64-${VERSION}}
elif [ "$recipe" = "IA32" ]; then
# Recipe for IA32:
unset CONFIG_SUFFIX
unset LOCALVERSION
export CONFIG_SUFFIX=".ia32"
#unset LOCALVERSION
OUTPUT=${OUTPUT:-${TMP}/output-ia32-${VERSION}}
else
echo "Error: recipe ${recipe} not implemented"
@ -86,8 +86,8 @@ for recipe in $RECIPES ; do
echo
# Build kernel-source package:
KERNEL_SOURCE_PACKAGE_NAME=$(PRINT_PACKAGE_NAME=YES KERNEL_CONFIG="config-generic${LOCALVERSION}-${VERSION}${LOCALVERSION}${CONFIG_SUFFIX}" VERSION=$VERSION BUILD=$BUILD ./kernel-source.SlackBuild)
KERNEL_CONFIG="config-generic${LOCALVERSION}-${VERSION}${LOCALVERSION}${CONFIG_SUFFIX}" VERSION=$VERSION BUILD=$BUILD ./kernel-source.SlackBuild
KERNEL_SOURCE_PACKAGE_NAME=$(PRINT_PACKAGE_NAME=YES KERNEL_CONFIG="config-${VERSION}${LOCALVERSION}-generic${CONFIG_SUFFIX}" VERSION=$VERSION BUILD=$BUILD ./kernel-source.SlackBuild)
KERNEL_CONFIG="config-${VERSION}${LOCALVERSION}-generic${CONFIG_SUFFIX}" VERSION=$VERSION BUILD=$BUILD ./kernel-source.SlackBuild
mkdir -p $OUTPUT
mv ${TMP}/${KERNEL_SOURCE_PACKAGE_NAME} $OUTPUT || exit 1
if [ "${INSTALL_PACKAGES}" = "YES" ]; then
@ -100,8 +100,8 @@ for recipe in $RECIPES ; do
( cd $TMP/package-kernel-source
sh install/doinst.sh
)
KERNEL_HUGE_PACKAGE_NAME=$(PRINT_PACKAGE_NAME=YES KERNEL_NAME=huge KERNEL_SOURCE=$TMP/package-kernel-source/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-huge${LOCALVERSION}-${VERSION}${LOCALVERSION}${CONFIG_SUFFIX} CONFIG_SUFFIX=${CONFIG_SUFFIX} KERNEL_OUTPUT_DIRECTORY=$OUTPUT/kernels/huge$(echo ${LOCALVERSION} | tr -d -).s BUILD=$BUILD ./kernel-generic.SlackBuild)
KERNEL_NAME=huge KERNEL_SOURCE=$TMP/package-kernel-source/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-huge${LOCALVERSION}-${VERSION}${LOCALVERSION}${CONFIG_SUFFIX} CONFIG_SUFFIX=${CONFIG_SUFFIX} KERNEL_OUTPUT_DIRECTORY=$OUTPUT/kernels/huge$(echo ${LOCALVERSION} | tr -d -).s BUILD=$BUILD ./kernel-generic.SlackBuild
KERNEL_HUGE_PACKAGE_NAME=$(PRINT_PACKAGE_NAME=YES KERNEL_NAME=huge KERNEL_SOURCE=$TMP/package-kernel-source/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-${VERSION}${LOCALVERSION}-huge${CONFIG_SUFFIX} CONFIG_SUFFIX=${CONFIG_SUFFIX} KERNEL_OUTPUT_DIRECTORY=$OUTPUT/kernels/huge.s BUILD=$BUILD ./kernel-generic.SlackBuild)
KERNEL_NAME=huge KERNEL_SOURCE=$TMP/package-kernel-source/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-${VERSION}${LOCALVERSION}-huge${CONFIG_SUFFIX} CONFIG_SUFFIX=${CONFIG_SUFFIX} KERNEL_OUTPUT_DIRECTORY=$OUTPUT/kernels/huge.s BUILD=$BUILD ./kernel-generic.SlackBuild
if [ -r ${TMP}/${KERNEL_HUGE_PACKAGE_NAME} ]; then
mv ${TMP}/${KERNEL_HUGE_PACKAGE_NAME} $OUTPUT
else
@ -113,8 +113,8 @@ for recipe in $RECIPES ; do
fi
# Build kernel-generic package:
KERNEL_GENERIC_PACKAGE_NAME=$(PRINT_PACKAGE_NAME=YES KERNEL_NAME=generic KERNEL_SOURCE=$TMP/package-kernel-source/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-generic${LOCALVERSION}-${VERSION}${LOCALVERSION}${CONFIG_SUFFIX} CONFIG_SUFFIX=${CONFIG_SUFFIX} KERNEL_OUTPUT_DIRECTORY=$OUTPUT/kernels/generic$(echo ${LOCALVERSION} | tr -d -).s BUILD=$BUILD ./kernel-generic.SlackBuild)
KERNEL_NAME=generic KERNEL_SOURCE=$TMP/package-kernel-source/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-generic${LOCALVERSION}-${VERSION}${LOCALVERSION}${CONFIG_SUFFIX} CONFIG_SUFFIX=${CONFIG_SUFFIX} KERNEL_OUTPUT_DIRECTORY=$OUTPUT/kernels/generic$(echo ${LOCALVERSION} | tr -d -).s BUILD=$BUILD ./kernel-generic.SlackBuild
KERNEL_GENERIC_PACKAGE_NAME=$(PRINT_PACKAGE_NAME=YES KERNEL_NAME=generic KERNEL_SOURCE=$TMP/package-kernel-source/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-${VERSION}${LOCALVERSION}-generic${CONFIG_SUFFIX} CONFIG_SUFFIX=${CONFIG_SUFFIX} KERNEL_OUTPUT_DIRECTORY=$OUTPUT/kernels/generic.s BUILD=$BUILD ./kernel-generic.SlackBuild)
KERNEL_NAME=generic KERNEL_SOURCE=$TMP/package-kernel-source/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-${VERSION}${LOCALVERSION}-generic${CONFIG_SUFFIX} CONFIG_SUFFIX=${CONFIG_SUFFIX} KERNEL_OUTPUT_DIRECTORY=$OUTPUT/kernels/generic.s BUILD=$BUILD ./kernel-generic.SlackBuild
if [ -r ${TMP}/${KERNEL_GENERIC_PACKAGE_NAME} ]; then
mv ${TMP}/${KERNEL_GENERIC_PACKAGE_NAME} $OUTPUT
else
@ -159,7 +159,11 @@ for recipe in $RECIPES ; do
if [ -r /etc/mkinitrd.conf ]; then
mkinitrd -F /etc/mkinitrd.conf -k ${INITRD_VERSION}${INITRD_LOCALVERSION}
else # try this?
sh /usr/share/mkinitrd/mkinitrd_command_generator.sh -k ${INITRD_VERSION}${INITRD_LOCALVERSION} | sed "s/-c -k/-k/g" | bash
sh /usr/share/mkinitrd/mkinitrd_command_generator.sh -k ${INITRD_VERSION}${INITRD_LOCALVERSION} -a "-o /boot/initrd-${INITRD_VERSION}${INITRD_LOCALVERSION}-generic.img" | sed "s/-c -k/-k/g" | bash
if [ -r /boot/initrd-${INITRD_VERSION}${INITRD_LOCALVERSION}-generic.img ]; then
# Good old compat symlink :-)
ln -sf initrd-${INITRD_VERSION}${INITRD_LOCALVERSION}-generic.img /boot/initrd.gz
fi
fi
fi

View file

@ -1,6 +1,6 @@
#
# Automatically generated file; DO NOT EDIT.
# Linux/x86 6.9.10 Kernel Configuration
# Linux/x86 6.9.11 Kernel Configuration
#
CONFIG_CC_VERSION_TEXT="gcc (GCC) 14.1.0"
CONFIG_CC_IS_GCC=y
@ -374,9 +374,9 @@ CONFIG_PARAVIRT_CLOCK=y
# CONFIG_M586MMX is not set
# CONFIG_M686 is not set
# CONFIG_MPENTIUMII is not set
CONFIG_MPENTIUMIII=y
# CONFIG_MPENTIUMIII is not set
# CONFIG_MPENTIUMM is not set
# CONFIG_MPENTIUM4 is not set
CONFIG_MPENTIUM4=y
# CONFIG_MK6 is not set
# CONFIG_MK7 is not set
# CONFIG_MK8 is not set
@ -393,8 +393,8 @@ CONFIG_MPENTIUMIII=y
# CONFIG_MCORE2 is not set
# CONFIG_MATOM is not set
CONFIG_X86_GENERIC=y
CONFIG_X86_INTERNODE_CACHE_SHIFT=6
CONFIG_X86_L1_CACHE_SHIFT=6
CONFIG_X86_INTERNODE_CACHE_SHIFT=7
CONFIG_X86_L1_CACHE_SHIFT=7
CONFIG_X86_INTEL_USERCOPY=y
CONFIG_X86_USE_PPRO_CHECKSUM=y
CONFIG_X86_TSC=y
@ -488,6 +488,7 @@ CONFIG_MTRR_SANITIZER_SPARE_REG_NR_DEFAULT=1
CONFIG_X86_PAT=y
CONFIG_ARCH_USES_PG_UNCACHED=y
CONFIG_X86_UMIP=y
CONFIG_CC_HAS_IBT=y
CONFIG_X86_INTEL_TSX_MODE_OFF=y
# CONFIG_X86_INTEL_TSX_MODE_ON is not set
# CONFIG_X86_INTEL_TSX_MODE_AUTO is not set
@ -10736,7 +10737,6 @@ CONFIG_CMA_ALIGNMENT=8
# CONFIG_DMA_MAP_BENCHMARK is not set
CONFIG_SGL_ALLOC=y
CONFIG_CHECK_SIGNATURE=y
# CONFIG_FORCE_NR_CPUS is not set
CONFIG_CPU_RMAP=y
CONFIG_DQL=y
CONFIG_GLOB=y

View file

@ -1,6 +1,6 @@
#
# Automatically generated file; DO NOT EDIT.
# Linux/x86 6.9.10 Kernel Configuration
# Linux/x86 6.9.11 Kernel Configuration
#
CONFIG_CC_VERSION_TEXT="gcc (GCC) 14.1.0"
CONFIG_CC_IS_GCC=y
@ -10816,7 +10816,6 @@ CONFIG_CMA_ALIGNMENT=8
CONFIG_SGL_ALLOC=y
CONFIG_IOMMU_HELPER=y
CONFIG_CHECK_SIGNATURE=y
# CONFIG_FORCE_NR_CPUS is not set
CONFIG_CPU_RMAP=y
CONFIG_DQL=y
CONFIG_GLOB=y

View file

@ -1,6 +1,6 @@
#
# Automatically generated file; DO NOT EDIT.
# Linux/x86 6.9.10 Kernel Configuration
# Linux/x86 6.9.11 Kernel Configuration
#
CONFIG_CC_VERSION_TEXT="gcc (GCC) 14.1.0"
CONFIG_CC_IS_GCC=y
@ -374,9 +374,9 @@ CONFIG_PARAVIRT_CLOCK=y
# CONFIG_M586MMX is not set
# CONFIG_M686 is not set
# CONFIG_MPENTIUMII is not set
CONFIG_MPENTIUMIII=y
# CONFIG_MPENTIUMIII is not set
# CONFIG_MPENTIUMM is not set
# CONFIG_MPENTIUM4 is not set
CONFIG_MPENTIUM4=y
# CONFIG_MK6 is not set
# CONFIG_MK7 is not set
# CONFIG_MK8 is not set
@ -393,8 +393,8 @@ CONFIG_MPENTIUMIII=y
# CONFIG_MCORE2 is not set
# CONFIG_MATOM is not set
CONFIG_X86_GENERIC=y
CONFIG_X86_INTERNODE_CACHE_SHIFT=6
CONFIG_X86_L1_CACHE_SHIFT=6
CONFIG_X86_INTERNODE_CACHE_SHIFT=7
CONFIG_X86_L1_CACHE_SHIFT=7
CONFIG_X86_INTEL_USERCOPY=y
CONFIG_X86_USE_PPRO_CHECKSUM=y
CONFIG_X86_TSC=y
@ -488,6 +488,7 @@ CONFIG_MTRR_SANITIZER_SPARE_REG_NR_DEFAULT=1
CONFIG_X86_PAT=y
CONFIG_ARCH_USES_PG_UNCACHED=y
CONFIG_X86_UMIP=y
CONFIG_CC_HAS_IBT=y
CONFIG_X86_INTEL_TSX_MODE_OFF=y
# CONFIG_X86_INTEL_TSX_MODE_ON is not set
# CONFIG_X86_INTEL_TSX_MODE_AUTO is not set
@ -10736,7 +10737,6 @@ CONFIG_CMA_ALIGNMENT=8
# CONFIG_DMA_MAP_BENCHMARK is not set
CONFIG_SGL_ALLOC=y
CONFIG_CHECK_SIGNATURE=y
# CONFIG_FORCE_NR_CPUS is not set
CONFIG_CPU_RMAP=y
CONFIG_DQL=y
CONFIG_GLOB=y

View file

@ -1,6 +1,6 @@
#
# Automatically generated file; DO NOT EDIT.
# Linux/x86 6.9.10 Kernel Configuration
# Linux/x86 6.9.11 Kernel Configuration
#
CONFIG_CC_VERSION_TEXT="gcc (GCC) 14.1.0"
CONFIG_CC_IS_GCC=y
@ -10816,7 +10816,6 @@ CONFIG_CMA_ALIGNMENT=8
CONFIG_SGL_ALLOC=y
CONFIG_IOMMU_HELPER=y
CONFIG_CHECK_SIGNATURE=y
# CONFIG_FORCE_NR_CPUS is not set
CONFIG_CPU_RMAP=y
CONFIG_DQL=y
CONFIG_GLOB=y

View file

@ -1,6 +1,6 @@
#!/bin/sh
# Copyright 2018, 2020 Patrick J. Volkerding, Sebeka, Minnesota, USA
# Copyright 2018, 2020, 2024 Patrick J. Volkerding, Sebeka, Minnesota, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@ -23,11 +23,11 @@
# To use this script, point it to a Linux kernel source tree and a .config
# file by setting the appropriate environment variables:
#
# KERNEL_SOURCE=/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-generic-4.14.23 ./kernel-generic.SlackBuild
# KERNEL_SOURCE=/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-6.9.9-generic.x64 ./kernel-generic.SlackBuild
#
# It can also build the huge (or any other) kernel:
#
# KERNEL_NAME=huge KERNEL_SOURCE=/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-huge-4.14.23 ./kernel-generic.SlackBuild
# KERNEL_NAME=huge KERNEL_SOURCE=/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-6.9.9-huge.x64 ./kernel-generic.SlackBuild
#
# By default, it will call the package "kernel-generic" and use the source and
# .config already in /usr/src/linux (if possible).
@ -42,7 +42,7 @@ BUILD=${BUILD:-1}
if [ ! -r "${KERNEL_CONFIG}" ]; then
echo "Error: the KERNEL_CONFIG environment variable needs to be set to the"
echo ".config file to be used to build this kernel. Example:"
echo "KERNEL_NAME=generic KERNEL_SOURCE=/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-generic-4.14.23 ./kernel-generic.SlackBuild"
echo "KERNEL_NAME=generic KERNEL_SOURCE=/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-6.9.9-generic.x64 ./kernel-generic.SlackBuild"
exit 1
fi
if [ ! -d "${KERNEL_SOURCE}" ]; then
@ -80,7 +80,7 @@ if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
make oldconfig 1> /dev/null 2> /dev/null
make prepare 1> /dev/null 2> /dev/null
PACKAGE_ARCH=$(cat kernel/bounds.s | grep -w "\-march=.*" | tr " " "\n" | grep -w "\-march=.*" | cut -f 2 -d = | tr - _)
echo "kernel-${KERNEL_NAME}${LOCALVERSION}-$(echo ${VERSION} | tr - _)$(echo ${LOCALVERSION} | tr - _)-${PACKAGE_ARCH}-$BUILD.txz"
echo "kernel-${KERNEL_NAME}-$(echo ${VERSION} | tr - _)$(echo ${LOCALVERSION} | tr - _)-${PACKAGE_ARCH}-$BUILD.txz"
exit 0
fi
@ -131,14 +131,14 @@ fi
fi
echo "Preparing the package in $PKG..."
mkdir -p $PKG/boot
cp -a --verbose System.map $PKG/boot/System.map-${KERNEL_NAME}${LOCALVERSION}-${VERSION}${LOCALVERSION}
cp -a --verbose .config $PKG/boot/config-${KERNEL_NAME}${LOCALVERSION}-${VERSION}${LOCALVERSION}${CONFIG_SUFFIX}
cp -a --verbose arch/${KERNEL_ARCH}/boot/bzImage $PKG/boot/vmlinuz-${KERNEL_NAME}${LOCALVERSION}-${VERSION}${LOCALVERSION}
cp -a --verbose System.map $PKG/boot/System.map-${VERSION}${LOCALVERSION}-${KERNEL_NAME}${CONFIG_SUFFIX}
cp -a --verbose .config $PKG/boot/config-${VERSION}${LOCALVERSION}-${KERNEL_NAME}${CONFIG_SUFFIX}
cp -a --verbose arch/${KERNEL_ARCH}/boot/bzImage $PKG/boot/vmlinuz-${VERSION}${LOCALVERSION}-${KERNEL_NAME}
# Make symlinks:
ln -sf System.map-${KERNEL_NAME}${LOCALVERSION}-${VERSION}${LOCALVERSION} $PKG/boot/System.map
ln -sf config-${KERNEL_NAME}${LOCALVERSION}-${VERSION}${LOCALVERSION}${CONFIG_SUFFIX} $PKG/boot/config
ln -sf vmlinuz-${KERNEL_NAME}${LOCALVERSION}-${VERSION}${LOCALVERSION} $PKG/boot/vmlinuz
ln -sf vmlinuz-${KERNEL_NAME}${LOCALVERSION}-${VERSION}${LOCALVERSION} $PKG/boot/vmlinuz-${KERNEL_NAME}${LOCALVERSION}
ln -sf System.map-${VERSION}${LOCALVERSION}-${KERNEL_NAME}${CONFIG_SUFFIX} $PKG/boot/System.map
ln -sf config-${VERSION}${LOCALVERSION}-${KERNEL_NAME}${CONFIG_SUFFIX} $PKG/boot/config
ln -sf vmlinuz-${VERSION}${LOCALVERSION}-${KERNEL_NAME} $PKG/boot/vmlinuz-${KERNEL_NAME}
ln -sf vmlinuz-${VERSION}${LOCALVERSION}-${KERNEL_NAME} $PKG/boot/vmlinuz
) || exit 1
# Fetch the kernel architecture from the source tree:
@ -146,13 +146,12 @@ cd ${KERNEL_SOURCE}
PACKAGE_ARCH=$(cat kernel/bounds.s | grep -w "\-march=.*" | tr " " "\n" | grep -w "\-march=.*" | cut -f 2 -d = | tr - _)
mkdir $PKG/install
if [ -r $CWD/slack-desc/slack-desc.kernel-${KERNEL_NAME}${LOCALVERSION}.${PACKAGE_ARCH} ]; then
cat $CWD/slack-desc/slack-desc.kernel-${KERNEL_NAME}${LOCALVERSION}.${PACKAGE_ARCH} > $PKG/install/slack-desc
if [ -r $CWD/slack-desc/slack-desc.kernel-${KERNEL_NAME}.${PACKAGE_ARCH} ]; then
cat $CWD/slack-desc/slack-desc.kernel-${KERNEL_NAME}.${PACKAGE_ARCH} > $PKG/install/slack-desc
else
cat $CWD/slack-desc/slack-desc.kernel-template | sed "s/%PACKAGE_NAME%/kernel-${KERNEL_NAME}${LOCALVERSION}/g" > $PKG/install/slack-desc
fi
# Make the package:
cd $PKG
/sbin/makepkg -l y -c n $TMP/kernel-${KERNEL_NAME}${LOCALVERSION}-$(echo ${VERSION} | tr - _)$(echo ${LOCALVERSION} | tr - _)-${PACKAGE_ARCH}-$BUILD.txz
/sbin/makepkg -l y -c n $TMP/kernel-${KERNEL_NAME}-$(echo ${VERSION} | tr - _)$(echo ${LOCALVERSION} | tr - _)-${PACKAGE_ARCH}-$BUILD.txz

View file

@ -87,4 +87,3 @@ cat $CWD/slack-desc/slack-desc.kernel-headers > $PKG/install/slack-desc
# Make the package:
cd $PKG
/sbin/makepkg -l y -c n $TMP/kernel-headers-$(echo ${VERSION} | tr - _)$(echo ${LOCALVERSION} | tr - _)-${HEADERS_ARCH}-$BUILD.txz

View file

@ -1,6 +1,6 @@
#!/bin/sh
# Copyright 2018, 2020, 2022 Patrick J. Volkerding, Sebeka, Minnesota, USA
# Copyright 2018, 2020, 2022, 2024 Patrick J. Volkerding, Sebeka, Minnesota, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@ -23,7 +23,7 @@
# To use this script, point it to a Linux kernel source tree and a .config
# file by setting the appropriate environment variables:
#
# KERNEL_SOURCE=/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-generic-4.14.23 ./kernel-modules.SlackBuild
# KERNEL_SOURCE=/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-6.9.9-generic.x64 ./kernel-modules.SlackBuild
#
# By default, it will use the source and .config already in /usr/src/linux (if possible).
@ -51,7 +51,7 @@ export INSTALL_MOD_STRIP=$STRIP_DEBUG
if [ ! -r "${KERNEL_CONFIG}" ]; then
echo "Error: the KERNEL_CONFIG environment variable needs to be set to the"
echo ".config file to be used to build these modules. Example:"
echo "KERNEL_SOURCE=/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-generic-4.14.23 ./kernel-modules.SlackBuild"
echo "KERNEL_SOURCE=/usr/src/linux KERNEL_CONFIG=./kernel-configs/config-6.9.9-generic.x64 ./kernel-modules.SlackBuild"
exit 1
fi
if [ ! -d "${KERNEL_SOURCE}" ]; then
@ -143,4 +143,3 @@ PACKAGE_ARCH=$(cat kernel/bounds.s | grep -w "\-march=.*" | tr " " "\n" | grep -
# Make the package:
cd $PKG
/sbin/makepkg -l y -c n $TMP/kernel${KERNEL_NAME}-modules${LOCALVERSION}-$(echo ${VERSION} | tr - _)$(echo ${LOCALVERSION} | tr - _)-${PACKAGE_ARCH}-$BUILD.txz

View file

@ -1,6 +1,6 @@
#!/bin/sh
# Copyright 2018, 2020, 2021, 2023 Patrick J. Volkerding, Sebeka, Minnesota, USA
# Copyright 2018, 2020, 2021, 2023, 2024 Patrick J. Volkerding, Sebeka, Minnesota, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@ -94,12 +94,6 @@ apply_patches() {
fi
}
# Kernel extraversion, such as "-smp" on 32-bit. There's usually no need to set
# this unless you're using something unusual. We use it to find which .config
# file to use, but we'll then use whatever CONFIG_LOCALVERSION is set to
# inside the .config.
LOCALVERSION=${LOCALVERSION:-""}
# If KERNEL_CONFIG (name of kernel .config file in ./kernel-configs to use)
# has not been passed to this script, then we will select one. We will prefer
# to use a generic, SMP-supporting .config with a version number exactly
@ -108,24 +102,22 @@ LOCALVERSION=${LOCALVERSION:-""}
if [ -z "${KERNEL_CONFIG}" ]; then # figure out the best matching .config
if [ "$ARCH" = "x86_64" ]; then
CONFIG_SUFFIX=".x64"
elif [ "$ARCH" = "i586" ]; then
CONFIG_SUFFIX=".ia32"
elif [ "$ARCH" = "i686" ]; then
CONFIG_SUFFIX=".ia32"
fi
if [ -z "${LOCALVERSION}" ]; then
if echo $ARCH | grep -q -E "i?86$" ; then
# Default to SMP extraversion on 32-bit:
LOCALVERSION="-smp"
fi
fi
if [ -r "$CWD/kernel-configs/config-generic${LOCALVERSION}-${VERSION}$LOCALVERSION${CONFIG_SUFFIX}" ]; then
if [ -r "$CWD/kernel-configs/config-${VERSION}${LOCALVERSION}-generic${CONFIG_SUFFIX}" ]; then
# Exact match!
KERNEL_CONFIG="config-generic${LOCALVERSION}-${VERSION}${LOCALVERSION}${CONFIG_SUFFIX}"
KERNEL_CONFIG="config-${VERSION}${LOCALVERSION}-generic${CONFIG_SUFFIX}"
else # no exact match, so find newest with the same name:
FIND_MATCH="$(/bin/ls -t $CWD/kernel-configs/config-generic${LOCALVERSION}-*${LOCALVERSION}${CONFIG_SUFFIX} 2> /dev/null | head -n 1)"
FIND_MATCH="$(/bin/ls -t $CWD/kernel-configs/config-*${LOCALVERSION}-generic${CONFIG_SUFFIX} 2> /dev/null | head -n 1)"
if [ -r "${FIND_MATCH}" ]; then
KERNEL_CONFIG="$(basename ${FIND_MATCH})"
unset FIND_MATCH
else
echo "Error: no matching .config file could be found for this kernel. Tried:"
echo " $CWD/kernel-configs/config-generic${LOCALVERSION}-${VERSION}${LOCALVERSION}${CONFIG_SUFFIX} (not found)"
echo " $CWD/kernel-configs/config-${VERSION}${LOCALVERSION}-generic${CONFIG_SUFFIX} (not found)"
exit 1
fi
fi
@ -186,9 +178,9 @@ echo "Untarring $CWD/linux-${VERSION}.tar.?z in $PKG/usr/src..."
( cd $PKG/usr/src/linux-${VERSION}
echo "Making oldconfig..."
make oldconfig
if [ ! -r $CWD/kernel-configs/config-generic${LOCALVERSION}-${VERSION}${LOCALVERSION}${CONFIG_SUFFIX} ]; then
echo "Saving new .config as: $CWD/kernel-configs/config-generic${LOCALVERSION}-${VERSION}${LOCALVERSION}${CONFIG_SUFFIX}"
cp -a .config $CWD/kernel-configs/config-generic${LOCALVERSION}-${VERSION}${LOCALVERSION}${CONFIG_SUFFIX}
if [ ! -r $CWD/kernel-configs/config-${VERSION}${LOCALVERSION}-generic${CONFIG_SUFFIX} ]; then
echo "Saving new .config as: $CWD/kernel-configs/config-${VERSION}${LOCALVERSION}-generic${CONFIG_SUFFIX}"
cp -a .config $CWD/kernel-configs/config-${VERSION}${LOCALVERSION}-generic${CONFIG_SUFFIX}
fi
# If CONFIG_PREEMPT=y and CONFIG_PREEMPT_DYNAMIC=y, then set a default preempt
@ -233,4 +225,3 @@ cat $CWD/slack-desc/slack-desc.kernel-source > $PKG/install/slack-desc
# Make the package:
cd $PKG
/sbin/makepkg -l y -c n $TMP/kernel-source-$(echo ${PACKAGE_VERSION} | tr - _)$(echo ${LOCALVERSION} | tr - _)-noarch-$BUILD.txz

View file

@ -33,8 +33,7 @@ NUMJOBS=${NUMJOBS:-" -j$(expr $(nproc) + 1) "}
MARCH=$( uname -m )
if [ -z "$ARCH" ]; then
case "$MARCH" in
i?86) export ARCH=i586 ;;
armv7hl) export ARCH=$MARCH ;;
i?86) export ARCH=i686 ;;
arm*) export ARCH=arm ;;
# Unless $ARCH is already set, use uname -m for all other archs:
*) export ARCH=$MARCH ;;
@ -49,18 +48,12 @@ if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
exit 0
fi
if [ "$ARCH" = "i586" ]; then
SLKCFLAGS="-O2 -march=i586 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "s390" ]; then
SLKCFLAGS="-O2"
if [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=pentium4 -mtune=generic"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
SLKCFLAGS="-O2 -march=x86-64 -mtune=generic -fPIC"
LIBDIRSUFFIX="64"
elif [ "$ARCH" = "armv7hl" ]; then
SLKCFLAGS="-O2 -march=armv7-a -mfpu=vfpv3-d16"
LIBDIRSUFFIX=""
else
SLKCFLAGS="-O2"
LIBDIRSUFFIX=""

View file

@ -1,41 +0,0 @@
From 21e5bcf22ab1a9f08c63e2a0212219d7482f77c1 Mon Sep 17 00:00:00 2001
From: Christian Hesse <mail@eworm.de>
Date: Wed, 10 Mar 2021 18:42:25 +0100
Subject: [PATCH] 00_header: add GRUB_COLOR_* variables
---
util/grub-mkconfig.in | 2 ++
util/grub.d/00_header.in | 8 ++++++++
2 files changed, 10 insertions(+)
diff --git a/util/grub-mkconfig.in b/util/grub-mkconfig.in
index f8cbb8d7a..1189d95f9 100644
--- a/util/grub-mkconfig.in
+++ b/util/grub-mkconfig.in
@@ -246,6 +246,8 @@ export GRUB_DEFAULT \
GRUB_BACKGROUND \
GRUB_THEME \
GRUB_GFXPAYLOAD_LINUX \
+ GRUB_COLOR_NORMAL \
+ GRUB_COLOR_HIGHLIGHT \
GRUB_INIT_TUNE \
GRUB_SAVEDEFAULT \
GRUB_ENABLE_CRYPTODISK \
diff --git a/util/grub.d/00_header.in b/util/grub.d/00_header.in
index 93a90233e..c5955df00 100644
--- a/util/grub.d/00_header.in
+++ b/util/grub.d/00_header.in
@@ -125,6 +125,14 @@ cat <<EOF
EOF
+if [ x$GRUB_COLOR_NORMAL != x ] && [ x$GRUB_COLOR_HIGHLIGHT != x ] ; then
+ cat << EOF
+set menu_color_normal=$GRUB_COLOR_NORMAL
+set menu_color_highlight=$GRUB_COLOR_HIGHLIGHT
+
+EOF
+fi
+
serial=0;
gfxterm=0;
for x in ${GRUB_TERMINAL_INPUT} ${GRUB_TERMINAL_OUTPUT}; do

View file

@ -1,10 +0,0 @@
--- ./util/grub-mkconfig_lib.in.orig 2023-12-05 08:46:53.000000000 -0600
+++ ./util/grub-mkconfig_lib.in 2024-01-02 13:44:41.164913702 -0600
@@ -191,6 +191,7 @@
case "$1" in
*.dpkg-*) return 1 ;; # debian dpkg
*.rpmsave|*.rpmnew) return 1 ;;
+ *.new|*.orig) return 1 ;; # slackware incoming or backed up config file
README*|*/README*) return 1 ;; # documentation
*.sig) return 1 ;; # signatures
esac

View file

@ -1,28 +0,0 @@
From ac560966d09295663fa9516d8d137e0c0fd04c06 Mon Sep 17 00:00:00 2001
From: Christian Hesse <mail@eworm.de>
Date: Mon, 12 Jun 2023 07:42:01 +0200
Subject: [PATCH 1/1] support dropins for default configuration
---
util/grub-mkconfig.in | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/util/grub-mkconfig.in b/util/grub-mkconfig.in
index 1a945085c..4338dceef 100644
--- a/util/grub-mkconfig.in
+++ b/util/grub-mkconfig.in
@@ -160,6 +160,11 @@ fi
if test -f ${sysconfdir}/default/grub ; then
. ${sysconfdir}/default/grub
fi
+for dropin in ${sysconfdir}/default/grub.d/*.cfg ; do
+ if test -f "${dropin}" ; then
+ . "${dropin}"
+ fi
+done
if [ "x${GRUB_DISABLE_UUID}" = "xtrue" ]; then
if [ -z "${GRUB_DISABLE_LINUX_UUID}" ]; then
--
2.41.0

View file

@ -1,12 +0,0 @@
--- ./util/grub-mkconfig.in.orig 2022-11-14 09:52:54.000000000 -0600
+++ ./util/grub-mkconfig.in 2024-06-26 12:44:00.986119802 -0500
@@ -255,7 +255,8 @@
GRUB_ENABLE_CRYPTODISK \
GRUB_BADRAM \
GRUB_OS_PROBER_SKIP_LIST \
- GRUB_DISABLE_SUBMENU
+ GRUB_DISABLE_SUBMENU \
+ GRUB_DISABLE_KERNEL_SYMLINKS
if test "x${grub_cfg}" != "x"; then
rm -f "${grub_cfg}.new"

View file

@ -1,36 +0,0 @@
From 2485633ada06c11c07a34a696a92b14e58f1e846 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 27 Feb 2018 13:55:35 -0500
Subject: [PATCH 198/250] align struct efi_variable better...
---
include/grub/efiemu/runtime.h | 2 +-
include/grub/types.h | 1 +
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/include/grub/efiemu/runtime.h b/include/grub/efiemu/runtime.h
index 9b6b729f4cc..856774a7c34 100644
--- a/include/grub/efiemu/runtime.h
+++ b/include/grub/efiemu/runtime.h
@@ -33,5 +33,5 @@ struct efi_variable
grub_uint32_t namelen;
grub_uint32_t size;
grub_efi_uint32_t attributes;
-} GRUB_PACKED;
+} GRUB_PACKED GRUB_ALIGNED(8);
#endif /* ! GRUB_EFI_EMU_RUNTIME_HEADER */
diff --git a/include/grub/types.h b/include/grub/types.h
index b93e4820194..f6a9723971d 100644
--- a/include/grub/types.h
+++ b/include/grub/types.h
@@ -29,6 +29,7 @@
#else
#define GRUB_PACKED __attribute__ ((packed))
#endif
+#define GRUB_ALIGNED(x) __attribute__((aligned (x)))
#ifdef GRUB_BUILD
# define GRUB_CPU_SIZEOF_VOID_P BUILD_SIZEOF_VOID_P
--
2.14.3

View file

@ -1,196 +0,0 @@
#! /bin/sh
set -e
# grub-mkconfig helper script.
# Copyright (C) 2006,2007,2008,2009,2010 Free Software Foundation, Inc.
#
# GRUB is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# GRUB is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GRUB. If not, see <http://www.gnu.org/licenses/>.
#
# Save this file in /etc/grub.d/09_slackware_linux
prefix="/usr"
exec_prefix="${prefix}"
datarootdir="${prefix}/share"
. "${datarootdir}/grub/grub-mkconfig_lib"
export TEXTDOMAIN=grub
export TEXTDOMAINDIR="${datarootdir}/locale"
CLASS="--class gnu-linux --class gnu --class os"
if [ "${GRUB_DISTRIBUTOR}" = "" ] ; then
OS=Linux
else
OS="${GRUB_DISTRIBUTOR} Linux"
CLASS="--class $(echo "${GRUB_DISTRIBUTOR}" | tr '[:upper:]' '[:lower:]') ${CLASS}"
fi
# loop-AES arranges things so that /dev/loop/X can be our root device, but
# the initrds that Linux uses don't like that.
case ${GRUB_DEVICE} in
/dev/loop/*|/dev/loop[0-9])
GRUB_DEVICE=$(losetup "${GRUB_DEVICE}" | sed -e "s/^[^(]*(\([^)]\+\)).*/\1/")
;;
esac
if [ "${GRUB_DEVICE_UUID}" = "" ] || [ "${GRUB_DISABLE_LINUX_UUID}" = "true" ] \
|| ! test -e "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" ; then
LINUX_ROOT_DEVICE=${GRUB_DEVICE}
else
LINUX_ROOT_DEVICE=UUID=${GRUB_DEVICE_UUID}
fi
linux_entry ()
{
os="$1"
tag="$2"
version="$3"
recovery="$4"
args="$5"
if ${recovery} ; then
title="$(gettext "%s, with Linux %s [%s] (recovery mode)")"
else
title="$(gettext "%s, with Linux %s [%s]")"
fi
printf "menuentry \"${title}\" ${CLASS} {\n" "${os}" "${version}" "${tag}"
save_default_entry | sed -e "s/^/\t/"
# Use ELILO's generic "efifb" when it's known to be available.
# FIXME: We need an interface to select vesafb in case efifb can't be used.
if [ "$GRUB_GFXPAYLOAD_LINUX" = "" ]; then
if grep -qx "CONFIG_FB_EFI=y" /boot/config-"${version}" 2> /dev/null \
&& grep -qx "CONFIG_VT_HW_CONSOLE_BINDING=y" /boot/config-"${version}" 2> /dev/null; then
cat << EOF
set gfxpayload=keep
EOF
fi
else
cat << EOF
set gfxpayload=$GRUB_GFXPAYLOAD_LINUX
EOF
fi
if [ -z "${prepare_boot_cache}" ]; then
prepare_boot_cache="$(prepare_grub_to_access_device "${GRUB_DEVICE_BOOT}" | sed -e "s/^/\t/")"
fi
printf '%s\n' "${prepare_boot_cache}"
cat << EOF
echo $(printf "$(gettext "Loading Linux %s ...")" "${version}")
linux ${rel_dirname}/${basename} root=${linux_root_device_thisversion} ro ${args}
EOF
if test -n "${initrd}" ; then
cat << EOF
echo $(gettext "Loading initial ramdisk ...")
initrd ${initrd}
EOF
fi
cat << EOF
}
EOF
}
process_list() {
mylist="$1"
tag="$2"
initrd_allowed="$3"
# Version-sort the kernels
sorted_kernels=$(echo "$mylist" | tr ' ' '\n' | version_sort -r)
# Use portable command substitution
kernels=$(echo "$sorted_kernels" | tr ' ' '\n')
for kernel in $kernels; do
# Skip symbolic links to kernels if requested:
if [ -L "$kernel" -a "$GRUB_DISABLE_KERNEL_SYMLINKS" = "true" ]; then
continue
fi
printf "Found linux image: %s\n" "$kernel" >&2
basename=$(basename "$kernel")
dirname=$(dirname "$kernel")
rel_dirname=$(make_system_path_relative_to_its_root "$dirname")
version=$(echo "$basename" | sed -e "s,^[^0-9]*-,,g")
alt_version=$(echo "$version" | sed -e "s,\.old$,,g")
linux_root_device_thisversion="${LINUX_ROOT_DEVICE}"
initrd=
actual_initrd=
if [ "${initrd_allowed}" = "true" ]; then
for i in ${GRUB_EARLY_INITRD_LINUX_STOCK} \
${GRUB_EARLY_INITRD_LINUX_CUSTOM}; do
if [ -e "${dirname}/${i}" ]; then
if [ -z "$initrd" ]; then
initrd="$rel_dirname/$i"
else
initrd="$initrd $rel_dirname/$i"
fi
fi
done
for i in "initrd-${tag}-${version}.gz" "initrd-${tag}.gz" \
"initrd-${version}.gz" "initrd.gz" \
"initrd.img-${version}" "initrd-${version}.img" \
"initrd-${version}" "initrd.img-${alt_version}" \
"initrd-${alt_version}.img" "initrd-${alt_version}"; do
if [ -e "${dirname}/${i}" ]; then
actual_initrd="true"
if [ -z "$initrd" ]; then
initrd="$rel_dirname/$i"
else
initrd="$initrd $rel_dirname/$i"
fi
break
fi
done
if [ -n "${initrd}" ]; then
printf "Found initrd image: %s\n" "${initrd}" >&2
fi
if [ -z "$actual_initrd" ]; then
# "UUID=" magic is parsed by initrds. Since there's no initrd, it can't work here.
linux_root_device_thisversion=${GRUB_DEVICE}
fi
else
# "UUID=" magic is parsed by initrds. Since there's no initrd, it can't work here.
linux_root_device_thisversion=${GRUB_DEVICE}
fi
linux_entry "${OS}" "${tag}" "${version}" false \
"${GRUB_CMDLINE_LINUX} ${GRUB_CMDLINE_LINUX_DEFAULT}"
if [ "x${GRUB_DISABLE_RECOVERY}" != "xtrue" ]; then
linux_entry "${OS}" "${tag}" "${version}" true \
"single ${GRUB_CMDLINE_LINUX}"
fi
done
}
prepare_boot_cache=
list=$(for i in /boot/vmlinu[xz]-generic-* /boot/vmlinu[xz]-generic /vmlinu[xz]-generic-* ; do
if grub_file_is_not_garbage "$i" ; then printf "%s " "$i"; fi
done)
process_list "${list}" "generic" "true"
list=$(for i in /boot/vmlinu[xz]-custom-* /boot/vmlinu[xz]-custom /vmlinu[xz]-custom-* ; do
if grub_file_is_not_garbage "$i" ; then printf "%s " "$i"; fi
done)
process_list "${list}" "custom" "true"
list=$(for i in /boot/vmlinu[xz]-huge-* /boot/vmlinu[xz]-huge /vmlinu[xz]-huge-* ; do
if grub_file_is_not_garbage "$i" ; then printf "%s " "$i"; fi
done)
process_list "${list}" "huge" "false"

View file

@ -1,34 +0,0 @@
From b835601c7639ed1890f2d3db91900a8506011a8e Mon Sep 17 00:00:00 2001
From: Oskari Pirhonen <xxc3ncoredxx@gmail.com>
Date: Thu, 21 Dec 2023 01:17:35 -0600
Subject: build: Include grub-core/extra_deps.lst in dist
Fixes build failure due to the extra_deps.lst file not existing in the
tarball. Found while trying to package GRUB 2.12 for Gentoo.
make[3]: *** No rule to make target '/var/tmp/portage/sys-boot/grub-2.12/work/grub-2.12/grub-core/extra_deps.lst', needed by 'syminfo.lst'. Stop.
Fixes: 89fbe0cac (grub-core/Makefile.am: Make path to extra_deps.lst relative to $(top_srcdir)/grub-core)
Fixes: 154dcb1ae (build: Allow explicit module dependencies)
Signed-off-by: Oskari Pirhonen <xxc3ncoredxx@gmail.com>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
---
conf/Makefile.extra-dist | 1 +
1 file changed, 1 insertion(+)
diff --git a/conf/Makefile.extra-dist b/conf/Makefile.extra-dist
index 5e7126f..d9e2b8c 100644
--- a/conf/Makefile.extra-dist
+++ b/conf/Makefile.extra-dist
@@ -21,6 +21,7 @@ EXTRA_DIST += conf/i386-cygwin-img-ld.sc
EXTRA_DIST += grub-core/Makefile.core.def
EXTRA_DIST += grub-core/Makefile.gcry.def
+EXTRA_DIST += grub-core/extra_deps.lst
EXTRA_DIST += grub-core/genmoddep.awk
EXTRA_DIST += grub-core/genmod.sh.in
EXTRA_DIST += grub-core/gensyminfo.sh.in
--
cgit v1.1

View file

@ -1,29 +0,0 @@
config() {
NEW="$1"
OLD="$(dirname $NEW)/$(basename $NEW .new)"
# If there's no config file by that name, mv it over:
if [ ! -r $OLD ]; then
mv $NEW $OLD
elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then
# toss the redundant copy
rm $NEW
fi
# Otherwise, we leave the .new copy for the admin to consider...
}
preserve_perms() {
NEW="$1"
OLD="$(dirname $NEW)/$(basename $NEW .new)"
if [ -e $OLD ]; then
cp -a $OLD ${NEW}.incoming
cat $NEW > ${NEW}.incoming
mv ${NEW}.incoming $NEW
fi
config $NEW
}
# Process config files in etc/grub.d/:
for file in etc/grub.d/*.new ; do
preserve_perms $file
done
config etc/default/grub.new

View file

@ -1,44 +0,0 @@
# If you change this file, run grub-mkconfig -o /boot/grub/grub.cfg
# afterwards to update /boot/grub/grub.cfg.
GRUB_DEFAULT=0
#GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=false
GRUB_TIMEOUT=10
GRUB_DISTRIBUTOR=$( sed 's/Slackware /Slackware-/' /etc/slackware-version )
GRUB_CMDLINE_LINUX_DEFAULT=""
GRUB_CMDLINE_LINUX=""
# Uncomment to disable graphical terminal (grub-pc only):
#GRUB_TERMINAL=console
# The resolution used on graphical terminal.
# Note that you can use only modes which your graphic card supports via VBE.
# You can see them in real GRUB with the command `vbeinfo'.
#GRUB_GFXMODE=640x480
#GRUB_GFXMODE=1024x768x32
# Font used on the graphical terminal:
#GRUB_FONT=/usr/share/grub/dejavusansmono.pf2
# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux:
#GRUB_DISABLE_LINUX_UUID=true
# Uncomment to disable generation of recovery mode menu entries:
GRUB_DISABLE_RECOVERY="true"
# Search for other operating systems with os-prober.
# If you don't want this, you can do any of these things to disable it:
# - change to "true"
# - comment it out, since disabled is the default
# - remove the executable bit from /etc/grub.d/30_os-prober
GRUB_DISABLE_OS_PROBER="false"
# Disable the submenus:
GRUB_DISABLE_SUBMENU="true"
# When using 09_slackware_linux, this option skips making menu entries for the
# symbolic links to kernels. Some folks don't like the extra (redundant) menu
# entries, while others like having an unversioned menu entry that doesn't
# require "update-grub" after installing new kernels. Your call.
#GRUB_DISABLE_KERNEL_SYMLINKS="true"

View file

@ -1,260 +0,0 @@
#!/bin/bash
# Copyright 2013, 2016, 2017, 2018, 2019, 2023, 2024 Patrick J. Volkerding, Sebeka, Minnesota, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
# permitted provided that the following conditions are met:
#
# 1. Redistributions of this script must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# Modified 2016 by Eric Hameleers <alien@slackware.com> for Slackware Live Edition.
cd $(dirname $0) ; CWD=$(pwd)
PKGNAM=grub
VERSION=${VERSION:-$(echo $PKGNAM-*.tar.xz | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
# Better to use _ than ~ in the package filenames version:
PKGVER=$(echo $VERSION | tr '~' '_')
BUILD=${BUILD:-13}
# If you use stack-protector, then grub will not work with legacy BIOS:
STACKPROTECT=${STACKPROTECT:---enable-stack-protector=no}
# Automatically determine the architecture we're building on:
if [ -z "$ARCH" ]; then
case "$(uname -m)" in
i?86) ARCH=i686 ;;
arm*) readelf /usr/bin/file -A | grep -E -q "Tag_CPU.*[4,5]" && ARCH=arm || ARCH=armv7hl ;;
# Unless $ARCH is already set, use uname -m for all other archs:
*) ARCH=$(uname -m) ;;
esac
export ARCH
fi
# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
# the name of the created package would be, and then exit. This information
# could be useful to other scripts.
if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
echo "$PKGNAM-$PKGVER-$ARCH-$BUILD.txz"
exit 0
fi
NUMJOBS=${NUMJOBS:-" -j$(expr $(nproc) + 1) "}
if [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-mtune=generic"
EFI32_FLAGS=" --with-platform=efi --target=i386 --program-prefix= "
LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-mtune=generic"
EFI32_FLAGS=" --with-platform=efi --target=i386 --program-prefix= "
EFI_FLAGS=" --with-platform=efi --target=x86_64 --program-prefix= "
LIBDIRSUFFIX="64"
else
SLKCFLAGS=""
LIBDIRSUFFIX=""
fi
# Don't use icecream:
PATH=$(echo $PATH | sed "s|/usr/libexec/icecc/bin||g" | tr -s : | sed "s/^://g" | sed "s/:$//g")
TMP=${TMP:-/tmp}
PKG=$TMP/package-$PKGNAM
rm -rf $PKG
mkdir -p $TMP $PKG
cd $TMP
rm -rf $PKGNAM-$VERSION
tar xvf $CWD/$PKGNAM-$VERSION.tar.xz || exit 1
cd $PKGNAM-$VERSION || exit 1
chown -R root:root .
find . \
\( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
-exec chmod 755 {} \+ -o \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \+
# Accept /boot/initrd.gz as a valid initrd name (obsolete?):
cat $CWD/initrd_naming.patch | patch -p1 --verbose || exit 1
# Support DejaVuSansMono font (dejavusansmono.pf2) by default:
cat $CWD/grub.dejavusansmono.gfxterm.font.diff | patch -p1 --verbose || exit 1
# Fix alignment error with gcc8:
cat $CWD/0198-align-struct-efi_variable-better.patch | patch -p1 --verbose || exit 1
# Skip processing any files in /etc/grub.d/ that end in .new or .orig:
cat $CWD/0001-skip-new-and-orig-files-in-etc-grub.d.patch | patch -p1 --verbose || exit 1
# From Arch, add a couple more GRUB_COLOR options:
cat $CWD/0001-00_header-add-GRUB_COLOR_-variables.patch | patch -p1 --verbose || exit 1
# Also from Arch, support drop-in config bits in /etc/default/grub.d/:
cat $CWD/0003-support-dropins-for-default-configuration.patch | patch -p1 --verbose || exit 1
# Support GRUB_DISABLE_KERNEL_SYMLINKS variable in /etc/default/grub.
# If this is not defined, it is assumed to be false.
cat $CWD/0004-add-GRUB_DISABLE_KERNEL_SYMLINKS-variable.patch | patch -p1 --verbose || exit 1
# Fix 2.12 release with upstream commit (won't compile otherwise):
cat $CWD/b835601c7639ed1890f2d3db91900a8506011a8e.patch | patch -p1 --verbose || exit 1
# For Slackware, opt-out of having our operating system renamed:
cat $CWD/10_linux.osname.patch | patch -p1 --verbose || exit 1
# Skip symlinks to kernels according to GRUB_DISABLE_KERNEL_SYMLINKS:
cat $CWD/10_linux.disable_kernel_symlinks.patch | patch -p1 --verbose || exit 1
# Still won't compile. Someday they'll remember how to cut a new release.
touch grub-core/extra_deps.lst
# Regenerate build system to fix dependency on outdated automake:
autoreconf -vif
build_grub() {
EFI_DO="$*"
# Configure:
CFLAGS="$SLKCFLAGS" \
./configure \
--prefix=/usr \
--libdir=/usr/lib${LIBDIRSUFFIX} \
--sysconfdir=/etc \
--localstatedir=/var \
--infodir=/usr/info \
--mandir=/usr/man \
--disable-werror \
--with-dejavufont=/usr/share/fonts/TTF/DejaVuSans.ttf \
$STACKPROTECT \
$EFI_DO || exit 1
# Build and install:
make clean || exit 1
make $NUMJOBS || make || exit 1
make install DESTDIR=$PKG || exit 1
# Clear $EFI_DO :
unset EFI_DO
}
# Build 32bit and 64bit efi targets if requested:
if [ -n "$EFI32_FLAGS" ]; then
build_grub $EFI32_FLAGS || exit 1
fi
if [ -n "$EFI_FLAGS" ]; then
build_grub $EFI_FLAGS || exit 1
fi
# Always end with regular build:
build_grub || exit 1
## NOT USED (but we'll leave the file here for now)
## Add custom 09_slackware_linux config. Thanks to Richard Cranium for the
## initial version, and Daedra for making it POSIX compliant:
#cp -a $CWD/09_slackware_linux $PKG/etc/grub.d/09_slackware_linux
#chown root:root $PKG/etc/grub.d/09_slackware_linux
#chmod 755 $PKG/etc/grub.d/09_slackware_linux
# Preserve files in /etc/grub.d/:
for file in $PKG/etc/grub.d/*_* ; do
mv ${file} ${file}.new
done
# Add an update-grub script ala Ubuntu:
cp -a $CWD/update-grub $PKG/usr/sbin/update-grub
chown root:root $PKG/usr/sbin/update-grub
chmod 755 $PKG/usr/sbin/update-grub
# Since every other grub command is of the form "grub-{command}", add a symlink
# so that "grub-update" also works:
ln -sf update-grub $PKG/usr/sbin/grub-update
# Strip binaries:
( cd $PKG
find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
)
# Put bash-completion file in system directory:
mkdir -p $PKG/usr/share/bash-completion/completions/
mv $PKG/etc/bash_completion.d/grub \
$PKG/usr/share/bash-completion/completions/grub
rmdir --parents $PKG/etc/bash_completion.d 2>/dev/null
# Install default options file:
mkdir -p $PKG/etc/default/grub.d
cat $CWD/etc.default.grub > $PKG/etc/default/grub.new
# Add a hint:
echo "Files in this directory must end in .cfg to be processed." > $PKG/etc/default/grub.d/README
# Create a directory for grub.cfg:
mkdir -p $PKG/boot/grub
# Add fonts, if found on the system:
FONT_SIZE=${FONT_SIZE:-19}
if [ -r /usr/share/fonts/TTF/unifont.ttf ]; then
$PKG/usr/bin/grub-mkfont -o $PKG/usr/share/grub/unifont.pf2 -abv \
-s $FONT_SIZE /usr/share/fonts/TTF/unifont.ttf
fi
if [ -r /usr/share/fonts/TTF/DejaVuSansMono.ttf ]; then
$PKG/usr/bin/grub-mkfont -o $PKG/usr/share/grub/dejavusansmono.pf2 -abv \
-s $FONT_SIZE /usr/share/fonts/TTF/DejaVuSansMono.ttf
fi
# Add a documentation directory:
mkdir -p $PKG/usr/doc/${PKGNAM}-$VERSION
cp -a \
AUTHORS BUGS COPYING* INSTALL NEWS README* THANKS TODO \
$PKG/usr/doc/${PKGNAM}-$VERSION
# Compress and if needed symlink the man pages:
if [ -d $PKG/usr/man ]; then
( cd $PKG/usr/man
for manpagedir in $(find . -type d -name "man*") ; do
( cd $manpagedir
for eachpage in $( find . -type l -maxdepth 1) ; do
ln -s $( readlink $eachpage ).gz $eachpage.gz
rm $eachpage
done
gzip -9 *.?
)
done
)
fi
# Compress info files, if any:
if [ -d $PKG/usr/info ]; then
( cd $PKG/usr/info
rm -f dir
gzip -9 *
)
fi
# If there's a ChangeLog, installing at least part of the recent history
# is useful, but don't let it get totally out of control:
if [ -r ChangeLog ]; then
DOCSDIR=$(echo $PKG/usr/doc/${PKGNAM}-$VERSION)
cat ChangeLog | head -n 1000 > $DOCSDIR/ChangeLog
touch -r ChangeLog $DOCSDIR/ChangeLog
fi
mkdir -p $PKG/install
cat $CWD/doinst.sh > $PKG/install/doinst.sh
cat $CWD/slack-desc > $PKG/install/slack-desc
cd $PKG
/sbin/makepkg -l y -c n $TMP/$PKGNAM-$PKGVER-$ARCH-$BUILD.txz

View file

@ -1,41 +0,0 @@
--- ./util/grub.d/00_header.in.orig 2012-05-03 18:04:39.000000000 -0500
+++ ./util/grub.d/00_header.in 2013-09-17 01:43:37.870841064 -0500
@@ -143,7 +143,7 @@
EOF
else
for dir in "${pkgdatadir}" "`echo '/@bootdirname@/@grubdirname@' | sed "s,//*,/,g"`" /usr/share/grub ; do
- for basename in unicode unifont ascii; do
+ for basename in unicode unifont dejavusansmono ascii; do
path="${dir}/${basename}.pf2"
if is_path_readable_by_grub "${path}" > /dev/null ; then
font_path="${path}"
@@ -156,7 +156,7 @@
if [ -n "${font_path}" ] ; then
cat << EOF
if [ x\$feature_default_font_path = xy ] ; then
- font=unicode
+ font=dejavusansmono
else
EOF
# Make the font accessible
@@ -169,7 +169,7 @@
EOF
else
cat << EOF
-if loadfont unicode ; then
+if loadfont dejavusansmono ; then
EOF
fi
fi
diff -Naur grub-2.02~beta2.orig/util/grub-install.c grub-2.02~beta2/util/grub-install.c
--- grub-2.02~beta2.orig/util/grub-install.c 2013-12-24 08:40:31.000000000 -0800
+++ grub-2.02~beta2/util/grub-install.c.new 2015-01-27 22:07:56.714000000 -0800
@@ -827,7 +827,7 @@
grub_util_host_init (&argc, &argv);
product_version = xstrdup (PACKAGE_VERSION);
pkgdatadir = grub_util_get_pkgdatadir ();
- label_font = grub_util_path_concat (2, pkgdatadir, "unicode.pf2");
+ label_font = grub_util_path_concat (2, pkgdatadir, "dejavusansmono.pf2");
argp_parse (&argp, argc, argv, 0, 0, 0);

View file

@ -1,13 +0,0 @@
diff -Naur grub-2.00.orig/util/grub.d/10_linux.in grub-2.00/util/grub.d/10_linux.in
--- grub-2.00.orig/util/grub.d/10_linux.in 2012-04-18 23:24:38.000000000 +0200
+++ grub-2.00/util/grub.d/10_linux.in 2012-06-30 07:53:03.765625589 +0200
@@ -198,7 +198,8 @@
"initramfs-genkernel-${version}" \
"initramfs-genkernel-${alt_version}" \
"initramfs-genkernel-${GENKERNEL_ARCH}-${version}" \
- "initramfs-genkernel-${GENKERNEL_ARCH}-${alt_version}"; do
+ "initramfs-genkernel-${GENKERNEL_ARCH}-${alt_version}" \
+ "initrd.gz"; do
if test -e "${dirname}/${i}" ; then
initrd="$i"
break

View file

@ -1,19 +0,0 @@
# HOW TO EDIT THIS FILE:
# The "handy ruler" below makes it easier to edit a package description. Line
# up the first '|' above the ':' following the base package name, and the '|'
# on the right side marks the last column you can put a character in. You must
# make exactly 11 lines for the formatting to be correct. It's also
# customary to leave one space after the ':'.
|-----handy-ruler------------------------------------------------------|
grub: grub (the GRand Unified Bootloader)
grub:
grub: GNU GRUB, the GRand Unified Bootloader, is a flexible and powerful
grub: boot loader program for a wide range of architectures.
grub:
grub: Homepage: https://www.gnu.org/software/grub/
grub:
grub:
grub:
grub:
grub:

View file

@ -1,10 +0,0 @@
#!/bin/sh
# This is a simple script to update grub from the configuration file.
# Please note that after upgrading to a new grub version, you should
# first use "grub-install" to reinstall the bootloader, similar to this:
# grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=GRUB --recheck
# or this:
# grub-install --target=i386-pc --recheck /dev/sdX
set -e
exec grub-mkconfig -o /boot/grub/grub.cfg "$@"

View file

@ -1,31 +0,0 @@
--- ./init.orig 2018-04-18 13:55:09.661574866 -0500
+++ ./init 2019-12-15 12:09:45.337013433 -0600
@@ -219,11 +219,15 @@
fi
LUKSLIST_DEFERRED=""
- LUKSLIST=$(echo $LUKSDEV | tr -s ':' ' ')
+ for dev in $(echo $LUKSDEV | tr -s ':' ' ') ; do
+ LUKSLIST="$LUKSLIST $(findfs $dev)"
+ done
+
+ for dev in $(echo $LUKSTRIM | tr -s ':' ' ') ; do
+ TRIMLIST="$TRIMLIST $(findfs $dev)"
+ done
+
for LUKSDEV in $LUKSLIST ; do
- if echo $LUKSDEV | grep -q "LABEL=" || echo $LUKSDEV | grep -q "UUID=" ; then
- LUKSDEV=$(findfs $LUKSDEV)
- fi
if /sbin/cryptsetup isLuks ${LUKSDEV} 1>/dev/null 2>/dev/null ; then
if echo $ROOTDEV | grep -q "LABEL=" || echo $ROOTDEV | grep -q "UUID=" ; then
CRYPTDEV="luks$(basename $LUKSDEV)"
@@ -232,7 +236,7 @@
else
CRYPTDEV="luks$(basename $LUKSDEV)"
fi
- if echo $LUKSTRIM | grep -wq $LUKSDEV 2>/dev/null ; then
+ if echo "$TRIMLIST" | grep -wq "$LUKSDEV" 2>/dev/null ; then
LUKSOPTS="--allow-discards"
else
LUKSOPTS=""

View file

@ -1,16 +0,0 @@
--- ./mkinitrd.orig 2021-04-27 13:53:00.500036921 -0500
+++ ./mkinitrd 2021-07-16 13:04:05.246136283 -0500
@@ -237,6 +237,13 @@
# Then copy all remaining libs our initrd files link against:
COUNT=1
PRFX=$(mktemp --suffix -ldd)
+
+ # Make sure a temporary directory was actually created:
+ if [ -z "${PRFX}" ]; then
+ echo "ERROR: Could not create a temp directory"
+ exit 1
+ fi
+
TMPFILE=${PRFX}${COUNT}
find $SOURCE_TREE -type f -exec ldd {} 2>/dev/null \; | unify_libs > $TMPFILE

View file

@ -1,10 +0,0 @@
--- ./mkinitrd.orig 2021-10-12 13:50:48.059708275 -0500
+++ ./mkinitrd 2021-10-12 13:51:36.482705596 -0500
@@ -69,6 +69,7 @@
check-mtp-device \
check-ptp-camera \
udev-configure-printer \
+ rules.d/40-usb_modeswitch.rules \
rules.d/60-openobex.rules \
rules.d/73-seat-late.rules \
rules.d/85-regulatory.rules \

View file

@ -1,23 +0,0 @@
--- ./mkinitrd_command_generator.sh.orig 2021-03-28 13:22:55.628927615 -0500
+++ ./mkinitrd_command_generator.sh 2022-01-24 21:29:00.382517371 -0600
@@ -302,12 +302,19 @@
fi
# Finally, we should check if base device is
- # a real block device or a RAID volume:
+ # a real block device or a RAID volume:
for MD in $(cat /proc/mdstat | grep -w active | cut -d' ' -f1) ; do
if [ "$BASEDEV" = "/dev/$MD" ]; then
USING_RAID=1
break
fi
+ done
+ # Additional check in case $BASEDEV is a partition of /dev/$MD:
+ for BLK in $(sfdisk -ld /dev/$MD 2> /dev/null | grep "^/dev" | cut -d " " -f 1); do
+ if [ "$BASEDEV" = "$BLK" ]; then
+ USING_RAID=1
+ break
+ fi
done
}

View file

@ -1,11 +0,0 @@
--- ./mkinitrd.orig 2021-04-27 13:53:00.500036921 -0500
+++ ./mkinitrd 2022-01-26 14:31:33.134016601 -0600
@@ -755,7 +755,7 @@
fi
if ! grep -Eq " $(basename $SRCMOD .ko)(\.| |$)" $SOURCE_TREE/load_kernel_modules 2>/dev/null ; then
- LINE="$(echo "modprobe -v $(basename ${SRCMOD%%.gz} .ko)" )"
+ LINE="$(echo "modprobe -v $(basename ${SRCMOD%%.ko*})" )"
# Test to see if arguments should be passed
# Over-ride the previously defined LINE variable if so

View file

@ -1,12 +0,0 @@
--- ./mkinitrd.orig 2022-01-26 14:33:29.000000000 -0600
+++ ./mkinitrd 2022-04-26 13:55:17.511004239 -0500
@@ -778,6 +778,9 @@
echo "$LINE" >> $SOURCE_TREE/load_kernel_modules
fi
+ # Ensure that the destination directory for the module exists:
+ mkdir -p "$(dirname $SOURCE_TREE/$SRCMOD)"
+
# Try to add the module to the initrd-tree. This should be done
# even if it exists there already as we may have changed compilers
# or otherwise caused the modules in the initrd-tree to need

View file

@ -1,14 +0,0 @@
--- ./mkinitrd.orig 2022-07-09 12:56:10.493030210 -0500
+++ ./mkinitrd 2022-07-09 12:57:38.848032187 -0500
@@ -702,9 +702,9 @@
cp -a /sbin/$i $SOURCE_TREE/sbin ;
done
-# Make sure modules.builtin and modules.order are there (for kmod):
+# Make sure modules.builtin, modules.builtin.modinfo, and modules.order are there (for kmod):
for kver in $(echo ${KERNEL_VERSION} | tr ':' '\n') ; do
- cp /lib/modules/$kver/modules.{builtin,order} \
+ cp /lib/modules/$kver/modules.{builtin,builtin.modinfo,order} \
$SOURCE_TREE/lib/modules/$kver
done

View file

@ -1,23 +0,0 @@
--- ./mkinitrd_command_generator.sh.orig 2023-02-28 15:19:08.085991698 -0600
+++ ./mkinitrd_command_generator.sh 2023-02-28 15:22:03.264982008 -0600
@@ -308,11 +308,15 @@
USING_RAID=1
break
fi
- done
- # Additional check in case $BASEDEV is a partition of /dev/$MD:
- for BLK in $(sfdisk -ld /dev/$MD 2> /dev/null | grep "^/dev" | cut -d " " -f 1); do
- if [ "$BASEDEV" = "$BLK" ]; then
- USING_RAID=1
+ # Additional check in case $BASEDEV is a partition of /dev/$MD:
+ for BLK in $(sfdisk -ld /dev/$MD 2> /dev/null | grep "^/dev" | cut -d " " -f 1); do
+ if [ "$BASEDEV" = "$BLK" ]; then
+ USING_RAID=1
+ break
+ fi
+ done
+ # Break out of outer loop if needed.
+ if [ "$USING_RAID" = "1" ]; then
break
fi
done

View file

@ -1,10 +0,0 @@
--- ./mkinitrd.orig 2023-08-09 16:25:06.849157479 -0500
+++ ./mkinitrd 2023-08-09 16:26:00.890154489 -0500
@@ -76,6 +76,7 @@
rules.d/60-openobex.rules \
rules.d/73-seat-late.rules \
rules.d/85-regulatory.rules \
+ rules.d/99-nfs.rules \
"
print_usage() {

View file

@ -1,26 +0,0 @@
--- ./mkinitrd.orig 2023-11-20 12:49:33.502016341 -0600
+++ ./mkinitrd 2023-11-20 12:50:30.142017608 -0600
@@ -60,6 +60,8 @@
# Modified by Piter Punk <piterpunk@slackware.com> 25 April 2022
# Add support to specify additional filesystems to be mounted by
# initrd. Useful for those that have a separated '/usr'
+# Modified by Patrick Volkerding <volkerdi@slackware.com> 20 Movember 2023
+# Add jfs/xfs repair tools if used for $ROOTFS
MKINITRD_VERSION=1.4.11
@@ -773,10 +775,11 @@
/sbin/modprobe --set-version $kver --show-depends --ignore-install $MODULE 2>/dev/null \
| grep "^insmod " | cut -f 2 -d ' ' | while read SRCMOD; do
- # If jfs or xfs filesystems are in use, add the repair tools to the initrd:
- if [ "$(basename $SRCMOD .ko)" = "jfs" ]; then
+ # If the root filesystem is jfs, add the repair tools to the initrd:
+ if [ "$ROOTFS" = "jfs" ]; then
cp -a /sbin/jfs_fsck $SOURCE_TREE/sbin/
- elif [ "$(basename $SRCMOD .ko)" = "xfs" ]; then
+ # If the root filesystem is xfs, add the repair tools to the initrd:
+ elif [ "$ROOTFS" = "xfs" ]; then
cp -a /sbin/xfs_repair $SOURCE_TREE/sbin/
fi

View file

@ -1,112 +0,0 @@
Slackware initrd mini HOWTO
by Patrick Volkerding, volkerdi@slackware.com
@DATE@
This document describes how to create and install an initrd, which may be
required to use some features of the kernel. Also see "man mkinitrd".
1. What is an initrd?
2. Why do I need an initrd?
3. How do I build the initrd?
4. Now that I've built an initrd, how do I use it?
1. What is an initrd?
Initrd stands for "initial ramdisk". An initial ramdisk is a very small
Linux filesystem that is loaded into RAM and mounted as the kernel boots,
and before the main root filesystem is mounted.
2. Why do I need an initrd?
The usual reason to use an initrd is because you need to load kernel
modules before mounting the root partition. Usually these modules are
required to support the filesystem used by the root partition (ext3,
reiserfs, xfs), or perhaps the controller that the hard drive is attached
to (SCSI, RAID, etc). Essentially, there are so many different options
available in modern Linux kernels that it isn't practical to try to ship
many different kernels to try to cover everyone's needs. It's a lot more
flexible to ship a generic kernel and a set of kernel modules for it.
3. How do I build the initrd?
The easiest way to make the initrd is to use the mkinitrd script included
in Slackware's mkinitrd package. We'll walk through the process of
upgrading to the generic @KERNEL_VERSION@ Linux kernel using the packages
found in Slackware's slackware/a/ directory.
First, make sure the kernel, kernel modules, and mkinitrd package are
installed (the current version numbers might be a little different, so
this is just an example):
installpkg kernel-generic-@KERNEL_VERSION@-@ARCH@-@BUILD@.tgz
installpkg kernel-modules-@KERNEL_VERSION@-@ARCH@-@BUILD@.tgz
installpkg mkinitrd-@MKINITRD_VERSION@-@ARCH@-@BUILD@.tgz
Change into the /boot directory:
cd /boot
Now you'll want to run "mkinitrd". I'm using ext4 for my root
filesystem, and since mkinitrd should figure out any other modules
it requires, I shouldn't need to specify any others:
mkinitrd -c -k @KERNEL_VERSION@ -m ext4
This should do two things. First, it will create a directory
/boot/initrd-tree containing the initrd's filesystem. Then it will
create an initrd (/boot/initrd.gz) from this tree. If you wanted to,
you could make some additional changes in /boot/initrd-tree/ and
then run mkinitrd again without options to rebuild the image. That's
optional, though, and only advanced users will need to think about that.
Here's another example: Build an initrd image using Linux @KERNEL_VERSION@
kernel modules for a system with an ext3 root partition on /dev/sdb3:
mkinitrd -c -k @KERNEL_VERSION@ -m ext3 -f ext3 -r /dev/sdb3
4. Now that I've built an initrd, how do I use it?
Now that you've got an initrd (/boot/initrd.gz), you'll want to load
it along with the kernel at boot time. If you use LILO for your boot
loader you'll need to edit /etc/lilo.conf and add a line to load the
initrd. Here's an example section of lilo.conf showing how this is
done:
# Linux bootable partition config begins
image = /boot/vmlinuz-@KERNEL_VERSION@-generic
initrd = /boot/initrd.gz
root = /dev/sda6
label = @LILO_KERNEL_NAME@
read-only
# Linux bootable partition config ends
The initrd is loaded by the "initrd = /boot/initrd.gz" line.
Just add the line right below the line for the kernel image you use.
Save the file, and then run LILO again ('lilo' at the command line).
You'll need to run lilo every time you edit lilo.conf or rebuild the
initrd.
Other bootloaders such as syslinux also support the use of an initrd.
See the documentation for those programs for details on using an
initrd with them.
Some, such as GRUB, require the initrd to be named similarly to the
kernel. So, for this kernel:
/boot/vmlinuz-@KERNEL_VERSION@-generic
You would want to rename your initrd to this:
/boot/initrd-@KERNEL_VERSION@-generic.img
In fact, if you use the geninitrd script to make your initrd (which it
will pretty much do automatically for the generic kernel) it will name
it this way, and will make a compatibilty symlink initrd.gz.
---------
Have fun!

File diff suppressed because it is too large Load diff

View file

@ -1,33 +0,0 @@
#!/bin/bash
# Copyright 2019 Patrick J. Volkerding, Sebeka, Minnesota, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
# permitted provided that the following conditions are met:
#
# 1. Redistributions of this script must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# This is a simple script to regenerate the initial ramdisk when a new
# kernel is installed. It will generate /boot/initrd.gz which will be
# suitable for *most* uses for whatever kernel is linked to the
# /boot/vmlinuz-generic (or /boot/vmlinuz-generic-smp) symlink. The
# linked kernel must be named properly with the kernel version in the
# filename (the same naming scheme as the kernels shipped in Slackware).
#
# If you use an encrypted root, you'll need to make your initrd manually.
cd $(dirname $0)/../..
chroot . /var/lib/pkgtools/setup/setup.01.mkinitrd

View file

@ -1,367 +0,0 @@
#!/bin/ash
#
# /init: init script to load kernel modules from an initramfs
# This requires that your kernel supports initramfs!!!
#
# Copyright 2004 Slackware Linux, Inc., Concord, CA, USA
# Copyright 2007, 2008, 2009, 2010, 2012 Patrick J. Volkerding, Sebeka, MN, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
# permitted provided that the following conditions are met:
#
# 1. Redistributions of this script must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
##################################################################################
# With a generic kernel, you need to load the modules needed to mount the
# root partition. This might mean a SCSI, RAID, or other drive controller
# module, as well as the module to support the root filesystem. Once the
# root partition is mounted all the other modules will be available so you
# don't need to load them here.
#
# Config files used by this script:
#
# /rootdev Contains the name of the root device, such as: /dev/hda1
#
# /rootfs Contains the root filesystem type, such as: xfs
#
# /initrd-name Contains the name of the initrd file.
#
# /resumedev Contains the name of the device to resume from hibernation.
#
# /luksdev Contains colon separated list of luks encrypted devices to
# be unlocked.
#
# /lukstrim Contains colon separated list of luks encrypted devices to
# pass '--allow-discards' when unlocking
#
# /lukskey Contains the path to a LUKS key-file for automatic unlock
# Format: LABEL=<partition_label>:/path/to/file
# UUID=<partition_uuid>:/path/to/file
#
# /wait-for-root Contains a number - the init script will wait this amount
# of seconds before creating device nodes.
#
# /keymap Contains the name for a custom keyboard map
#
# Optional:
#
# /load_kernel_modules
# A script that uses modprobe to load the desired modules.
#
# There's an example in here. To actually use it, you'll
# need to make it executable:
#
# chmod 755 load_kernel_modules
##################################################################################
# Changelog
# 10-Dec-2012 <mozes@slackware.com>
# * Added support for the official Kernel parameters to select root filesystem
# type ('rootfstype') and pause before attempting to mount the root filesystem
# ('rootdelay'). The original parameters may continue to be used.
##################################################################################
INITRD=$(cat /initrd-name)
ROOTDEV=$(cat /rootdev)
ROOTFS=$(cat /rootfs)
LUKSDEV=$(cat /luksdev)
LUKSTRIM=$(cat /lukstrim 2>/dev/null)
LUKSKEY=$(cat /lukskey)
RESUMEDEV=$(cat /resumedev)
WAIT=$(cat /wait-for-root)
KEYMAP=$(cat /keymap)
INIT=/sbin/init
PATH="/sbin:/bin:/usr/sbin:/usr/bin"
# Mount /proc and /sys:
mount -n proc /proc -t proc
mount -n sysfs /sys -t sysfs
mount -n tmpfs /run -t tmpfs -o mode=0755,size=32M,nodev,nosuid,noexec
if grep devtmpfs /proc/filesystems 1>/dev/null 2>/dev/null ; then
DEVTMPFS=1
mount -n devtmpfs /dev -t devtmpfs -o size=8M
fi
# Parse command line
for ARG in $(cat /proc/cmdline); do
case $ARG in
0|1|2|3|4|5|6|S|s|single)
RUNLEVEL=$ARG
;;
init=*)
INIT=$(echo $ARG | cut -f2 -d=)
;;
luksdev=/dev/*)
LUKSDEV=$(echo $ARG | cut -f2 -d=)
;;
lukskey=*)
LUKSKEY=$(echo $ARG | cut -f2- -d=)
;;
rescue)
RESCUE=1
;;
resume=*)
RESUMEDEV=$(echo $ARG | cut -f2- -d=)
;;
root=/dev/*)
ROOTDEV=$(echo $ARG | cut -f2 -d=)
;;
root=LABEL=*)
ROOTDEV=$(echo $ARG | cut -f2- -d=)
;;
root=UUID=*)
ROOTDEV=$(echo $ARG | cut -f2- -d=)
;;
rootfs=*|rootfstype=*)
ROOTFS=$(echo $ARG | cut -f2 -d=)
;;
rootflags=*)
ROOTFLAGS=$(echo $ARG | cut -f2- -d=)
;;
waitforroot=*|rootdelay=*)
WAIT=$(echo $ARG | cut -f2 -d=)
;;
esac
done
# If udevd is available, use it to generate block devices
# else use mdev to read sysfs and generate the needed devices
if [ -x /sbin/udevd -a -x /sbin/udevadm ]; then
/sbin/udevd --daemon --resolve-names=never
/sbin/udevadm trigger --subsystem-match=block --action=add
/sbin/udevadm settle --timeout=10
else
[ "$DEVTMPFS" != "1" ] && mdev -s
fi
# Load kernel modules (ideally this was already done by udev):
if [ ! -d /lib/modules/$(uname -r) ]; then
echo "No kernel modules found for Linux $(uname -r)."
elif [ -x ./load_kernel_modules ]; then # use load_kernel_modules script:
echo "${INITRD}: Loading kernel modules from initrd image:"
. ./load_kernel_modules
else # load modules (if any) in order:
if ls /lib/modules/$(uname -r)/*.*o 1> /dev/null 2> /dev/null ; then
echo "${INITRD}: Loading kernel modules from initrd image:"
for module in /lib/modules/$(uname -r)/*.*o ; do
/sbin/modprobe $module
done
unset module
fi
fi
# Sometimes the devices need extra time to be available.
# A root filesystem on USB is a good example of that.
sleep $WAIT
# Load a custom keyboard mapping:
if [ -n "$KEYMAP" ]; then
echo "${INITRD}: Loading '$KEYMAP' keyboard mapping:"
tar xzOf /etc/keymaps.tar.gz ${KEYMAP}.bmap | loadkmap
fi
if [ "$RESCUE" = "" ]; then
# Initialize RAID:
if [ -x /sbin/mdadm ]; then
# If /etc/mdadm.conf is present, udev should DTRT on its own;
# If not, we'll make one and go from there:
if [ ! -r /etc/mdadm.conf ]; then
/sbin/mdadm -E -s >/etc/mdadm.conf
/sbin/mdadm -S -s
/sbin/mdadm -A -s
# This seems to make the kernel see partitions more reliably:
fdisk -l /dev/md* 1> /dev/null 2> /dev/null
fi
fi
# Unlock any encrypted partitions necessary to access the
# root filesystem, such as encrypted LVM Physical volumes, disk
# partitions or mdadm arrays.
# Unavailable devices such as LVM Logical Volumes will need to be
# deferred until they become available after the vgscan.
if [ -x /sbin/cryptsetup ]; then
# Determine if we have to use a LUKS keyfile:
if [ ! -z "$LUKSKEY" ]; then
mkdir /mountkey
KEYPART=$(echo $LUKSKEY |cut -f1 -d:)
KEYNAME=$(echo $KEYPART |cut -f2 -d=)
LUKSPATH="/mountkey$(echo $LUKSKEY |cut -f2 -d:)"
# Catch possible mount failure:
if blkid |grep "TYPE=\"vfat\"" |grep $KEYNAME 1>/dev/null 2>&1 ; then
MOUNTOPTS="-t vfat -o shortname=mixed"
else
MOUNTOPTS="-t auto"
fi
mount $MOUNTOPTS $(findfs $KEYPART) /mountkey 2>/dev/null
# Check if we can actually use this file:
if [ ! -f $LUKSPATH ]; then
LUKSKEY=""
else
echo ">>> Using LUKS key file: '$LUKSKEY'"
LUKSKEY="-d $LUKSPATH"
fi
fi
LUKSLIST_DEFERRED=""
LUKSLIST=$(echo $LUKSDEV | tr -s ':' ' ')
for LUKSDEV in $LUKSLIST ; do
if echo $LUKSDEV | grep -q "LABEL=" || echo $LUKSDEV | grep -q "UUID=" ; then
LUKSDEV=$(findfs $LUKSDEV)
fi
if /sbin/cryptsetup isLuks ${LUKSDEV} 1>/dev/null 2>/dev/null ; then
if echo $ROOTDEV | grep -q "LABEL=" || echo $ROOTDEV | grep -q "UUID=" ; then
CRYPTDEV="luks$(basename $LUKSDEV)"
elif [ "x$ROOTDEV" = "x$(basename $ROOTDEV)" ]; then
CRYPTDEV="$ROOTDEV"
else
CRYPTDEV="luks$(basename $LUKSDEV)"
fi
if echo $LUKSTRIM | grep -wq $LUKSDEV 2>/dev/null ; then
LUKSOPTS="--allow-discards"
else
LUKSOPTS=""
fi
if [ -z "${LUKSOPTS}" ]; then
echo "Unlocking LUKS encrypted device '${LUKSDEV}' as luks mapped device '$CRYPTDEV':"
else
echo "Unlocking LUKS encrypted device '${LUKSDEV}' as luks mapped device '$CRYPTDEV' with '$LUKSOPTS':"
fi
/sbin/cryptsetup ${LUKSOPTS} ${LUKSKEY} luksOpen ${LUKSDEV} ${CRYPTDEV} </dev/tty0 >/dev/tty0 2>&1
if [ "$ROOTDEV" = "$LUKSDEV" -o "$ROOTDEV" = "$CRYPTDEV" ] ; then
ROOTDEV="/dev/mapper/$CRYPTDEV"
fi
else
LUKSLIST_DEFERRED="${LUKSLIST_DEFERRED} ${LUKSDEV}"
fi
done
fi
# Initialize LVM:
if [ -x /sbin/vgchange ]; then
mkdir -p /var/lock/lvm # this avoids useless warnings
/sbin/vgchange -ay --ignorelockingfailure 2>/dev/null
/sbin/udevadm settle --timeout=10
fi
# Unlock any LUKS encrypted devices that were deferred above but have now
# become available due to the vgscan (i.e. filesystems on LVM Logical Volumes)
if [ -x /sbin/cryptsetup -a -n "${LUKSLIST_DEFERRED}" ]; then
for LUKSDEV in ${LUKSLIST_DEFERRED} ; do
if /sbin/cryptsetup isLuks ${LUKSDEV} 1>/dev/null 2>/dev/null ; then
if echo $ROOTDEV | grep -q "LABEL=" || echo $ROOTDEV | grep -q "UUID=" ; then
CRYPTDEV="luks$(basename $LUKSDEV)"
elif [ "x$ROOTDEV" = "x$(basename $ROOTDEV)" ]; then
CRYPTDEV="$ROOTDEV"
else
CRYPTDEV="luks$(basename $LUKSDEV)"
fi
echo "Unlocking LUKS encrypted device '${LUKSDEV}' as luks mapped device '$CRYPTDEV':"
/sbin/cryptsetup ${LUKSKEY} luksOpen ${LUKSDEV} ${CRYPTDEV} </dev/tty0 >/dev/tty0 2>&1
if [ "$ROOTDEV" = "$LUKSDEV" -o "$ROOTDEV" = "$CRYPTDEV" ] ; then
ROOTDEV="/dev/mapper/$CRYPTDEV"
fi
else
echo "LUKS device '${LUKSDEV}' unavailable for unlocking!"
fi
done
/sbin/udevadm settle --timeout=10
fi
# Scan for btrfs multi-device filesystems:
if [ -x /sbin/btrfs ]; then
/sbin/btrfs device scan
fi
# Find root device if a label or UUID was given:
if echo $ROOTDEV | grep -q "LABEL=" || \
echo $ROOTDEV | grep -q "UUID=" ; then
ROOTDEV=$(findfs $ROOTDEV)
fi
# Clean up after LUKS unlock using a keyfile:
if grep -q mountkey /proc/mounts 2>/dev/null ; then
umount -l /mountkey
rmdir /mountkey 2>/dev/null
fi
# Resume state from swap
if [ "$RESUMEDEV" != "" ]; then
# Find resume device if a label or UUID was given:
if echo $RESUMEDEV | grep -q "LABEL=" || \
echo $RESUMEDEV | grep -q "UUID=" ; then
RESUMEDEV=$(findfs $RESUMEDEV)
elif ls -l $RESUMEDEV | grep -q "^l" ; then
RESUMEDEV=$(readlink -f $RESUMEDEV)
fi
echo "Trying to resume from $RESUMEDEV"
RESMAJMIN=$(ls -l $RESUMEDEV | tr , : | awk '{ print $5$6 }')
echo $RESMAJMIN > /sys/power/resume
fi
# Switch to real root partition:
/sbin/udevadm settle --timeout=10
echo 0x0100 > /proc/sys/kernel/real-root-dev
mount -o ro${ROOTFLAGS:+,$ROOTFLAGS} -t $ROOTFS $ROOTDEV /mnt
if [ ! -r /mnt/sbin/init ]; then
echo "ERROR: No /sbin/init found on rootdev (or not mounted). Trouble ahead."
echo " You can try to fix it. Type 'exit' when things are done."
echo
/bin/sh
fi
else
echo
echo "RESCUE mode"
echo
echo " You can try to fix or rescue your system now. If you want"
echo " to boot into your fixed system, mount your root filesystem"
echo " read-only under /mnt:"
echo
echo " # mount -o ro -t filesystem root_device /mnt"
echo
echo " Type 'exit' when things are done."
echo
/bin/sh
fi
# Mount additional filesystems
if [ -f /addfstab ]; then
while read DEV MNTPNT FS OPTS DUMP PASSNO ; do
if echo $DEV | grep -qE '(LABEL|UUID)=' ; then
DEV=$(findfs $DEV)
fi
echo $DEV "/mnt/"$MNTPNT $FS "ro,"$OPTS $DUMP $PASSNO >> /etc/fstab
done < /addfstab
mount -a
fi
# Need to make sure OPTIONS+="db_persist" exists for all dm devices
# That should be handled in /sbin/mkinitrd now
/sbin/udevadm info --cleanup-db
/sbin/udevadm control --exit
unset ERR
mount -o move /proc /mnt/proc
mount -o move /sys /mnt/sys
mount -o move /run /mnt/run
[ "$DEVTMPFS" = "1" ] && mount -o move /dev /mnt/dev
echo "${INITRD}: exiting"
exec switch_root /mnt $INIT $RUNLEVEL

View file

@ -1,834 +0,0 @@
#!/bin/bash
# Copyright 2004 Slackware Linux, Inc., Concord, CA, USA
# Copyright 2004 Patrick J. Volkerding, Concord, CA, USA
# Copyright 2007, 2008, 2009, 2010, 2011, 2015, 2016, 2017 Patrick J. Volkerding, Sebeka, MN, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
# permitted provided that the following conditions are met:
#
# 1. Redistributions of this script must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ''AS IS'' AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# Modified by Robby Workman <rworkman@slackware.com> 26 November 2007
# to add support for mkinitrd.conf - No additional license terms added
# Modified by Alan Hicks <alan@slackware.com> 27 November 2007 to enable
# passing arguments to kernel modules - No additional license terms added
# volkerdi - feel free to remove these :)
# Modified by Eric Hameleers <alien@slackware.com> 3 April 2008
# to add support custom keymaps - No additional license terms added
# Modified by Patrick Volkerding <volkerdi@slackware.com> 17 Dec 2008
# Added support to bail out if kernel modules are requested for a kernel
# version that is not installed (thanks to Eric Hameleers), be more
# verbose about showing modules added to the initrd (thanks to
# Ellington Santos), and if "mount" returns /dev/root as the root device,
# use readlink to resolve the device pointed to by the /dev/root
# symlink, changed modprobe to use --ignore-install to avoid catching
# custom "install" lines and causing /sbin/modprobe to be copied to the
# initrd (thanks to Ken Milmore).
# Of course, license terms remain unchanged.
# Modified by Eric Hameleers <alien@slackware.com> 3 March 2010
# Add lukskey option (-K). Automatically add kernel modules listed in
# load-kernel-modules if that file is executable.
# Yada yada yada.
# Modified by Patrick Volkerding <volkerdi@slackware.com> 21 August 2012
# Add Btrfs multi-device filesystem support option (-B).
# Modified by Robby Workman <rworkman@slackware.com> 08 March 2017
# to add support for TRIM on LUKS root devs
# Modified by Patrick Volkerding <volkerdi@slackware.com> 29 June 2017
# Add support for prepending a microcode update archive (-P).
# Modified by Patrick Volkerding <volkerdi@slackware.com> 12 July 2017
# Add support for including Slackware and kernel versions in the
# output filename. Thanks to SeB.
# Modified by Patrick Volkerding <volkerdi@slackware.com> 04 Feb 2019
# Allow specifying more than one kernel version.
# Modified by Robby Workman <rworkman@slackware.com> 05 September 2019
# to add libargon2 and libgcc_s for cryptsetup LUKS2 support; add
# jfs and xfs repair tools to initrd if those filesystems are used;
# fixes and enhancements to docs
# Modified by Piter Punk <piterpunk@slackware.com> 25 April 2022
# Add support to specify additional filesystems to be mounted by
# initrd. Useful for those that have a separated '/usr'
MKINITRD_VERSION=1.4.11
COMMAND_LINE="$0 $*"
# Don't include these things from /lib/udev/ in the initrd image
LIBUDEV_BLACKLIST="\
ipod-set-info \
iphone-set-info \
check-mtp-device \
check-ptp-camera \
udev-configure-printer \
rules.d/60-openobex.rules \
rules.d/73-seat-late.rules \
rules.d/85-regulatory.rules \
"
print_usage() {
cat << EOF
Usage: mkinitrd [OPTION]
mkinitrd creates an initial ramdisk (actually an initramfs cpio+gzip
archive) used to load kernel modules that are needed to mount the
root filesystem, or other modules that might be needed before the
root filesystem is available. Other binaries may be added to the
initrd, and the script is easy to modify. Be creative. :-)
-F Use the contents of /etc/mkinitrd.conf (optional)
If this is used in conjunction with any other options passed
on the command line, the command-line options will override
the config file options. See mkinitrd.conf(5) for details.
-c Clear the existing initrd tree first
-f Filesystem to use for root partition (must be used with -r)
--help Display this message
-h Device to resume from hibernation. Needs to be the name of
the swap partition holding the hibernation image.
-k Kernel version to use
-l Custom keymap to load. Like, 'nl' or 'de-latin1-nodeadkeys'
-m A colon (:) delimited list of kernel modules to load.
Additional options may be added to use when loading the
kernel modules (but in this case the entire list must be
wrapped with double quotes). Any dependencies of requested
modules will also be added to the initrd.
-o Output image (default /boot/initrd.gz)
-r Root partition device (must be used with -f)
-s Initrd source tree (default /boot/initrd-tree/)
-u Include udev in the initrd
-w Time to wait until all disks are detected
-C A colon (:) delimited list of luks encrypted block devices to be
unlocked by the initrd using cryptsetup. All devices that must
be unlocked in order to access the root filesystem must be
specified. (Use with '-r' parameter).
-T A colon (:) delimited list of luks encrypted block devices to be
passed the "--allow-discards" option when unlocked by the initrd
using cryptsetup. This has the effect of allowing TRIM on SSD drives.
Be sure your SSD supports this feature (correctly) before enabling
it. See fstrim(8) for more information.
-L Add support for LVM partitions
-K Use a USB key (fat-formatted) to unlock the root LUKS volume
The parameter value is filename of a keyfile, as well as the label
(or uuid) of the partition this file is on. This way, you can unlock
your computer automatically if you have a USB stick with your LUKS
key inserted at boot. A passphrase will still be asked if the LUKS
key can not be found.
For example, if your USB thumb drive has a FAT partition with label
"TRAVELSTICK" and the actual keyfile is called "/keys/alien.luks",
then you need to pass: -K LABEL=TRAVELSTICK:/keys/alien.luks
-B Add /sbin/btrfs to enable scanning for a root filesystem that is
part of a Btrfs multi-device filesystem.
-M Add the files in /etc/modprobe.d/ and /lib/modprobe.d/ to the initrd
-P Prepend the output image with the microcode CPIO archive given in
arguments.
-R Add support for RAID partitions
-MNT Additional filesystems to be mounted by initrd. Multiple mount
entries can be specified in a list separated by colon (:).
-V Display version number
A simple example: Build an initrd for a reiserfs root partition:
mkinitrd -c -m reiserfs
Another example: Build an initrd image using Linux 2.6.35.4-smp kernel
modules for a system with an ext4 root partition on /dev/sdb3:
mkinitrd -c -k 2.6.35.4-smp -m mbcache:jbd:ext4 -f ext4 -r /dev/sdb3
Note that if you are already logged in with /dev/sdb3 as your /
partition, and it is running ext4, this command works just the same:
mkinitrd -c -m ext4
If run without options, mkinitrd will rebuild an initrd image using
the contents of the $SOURCE_TREE directory, or, if that directory
does not exist it will be created and populated, and then mkinitrd
will exit.
EOF
}
create_new_source_tree() {
mkdir -p $SOURCE_TREE
# Make sure the kernel module directories exist:
for kver in $(echo ${KERNEL_VERSION} | tr ':' '\n') ; do
mkdir -p $SOURCE_TREE/lib/modules/${kver}
done
# Add the initrd-tree skeleton:
( cd $SOURCE_TREE ; tar xzf /usr/share/mkinitrd/initrd-tree.tar.gz )
# Make sure we have any block devices that might be needed:
SLOPPY_DEV_LIST=$(cat /proc/partitions)
for device in $SLOPPY_DEV_LIST ; do
if [ ! -r $SOURCE_TREE/dev/$device ]; then
if [ -b /dev/$device ]; then
if [ -L /dev/$device ]; then
cp -a --parents $(readlink -e /dev/$device) $SOURCE_TREE
fi
cp -a --parents /dev/$device $SOURCE_TREE
fi
fi
done
}
clear_source_tree() {
if [ -d "$SOURCE_TREE" ]; then
rm -rf $SOURCE_TREE
fi
}
build_initrd_image() {
# Make sure we have any block devices that might be needed:
SLOPPY_DEV_LIST=$(cat /proc/partitions)
for device in $SLOPPY_DEV_LIST ; do
if [ ! -r $SOURCE_TREE/dev/$device ]; then
if [ -b /dev/$device ]; then
if [ -L /dev/$device ]; then
cp -a --parents $(readlink -e /dev/$device) $SOURCE_TREE
fi
cp -a --parents /dev/$device $SOURCE_TREE
fi
fi
done
# Use the output image name written in the initrd-tree if present:
if [ ! -z "$(cat $SOURCE_TREE/initrd-name)" ]; then
OUTPUT_IMAGE=$(cat $SOURCE_TREE/initrd-name)
if [ "$OUTPUT_IMAGE" = "$(basename $OUTPUT_IMAGE)" ]; then
OUTPUT_IMAGE=/boot/$OUTPUT_IMAGE
fi
mkdir -p $(dirname $OUTPUT_IMAGE)
fi
# Wrap the initrd as an initramfs image and move it into place:
( cd $SOURCE_TREE
rm -f $OUTPUT_IMAGE
find . | cpio -o -H newc | gzip -9c > $OUTPUT_IMAGE
)
if [ ! -z "${MICROCODE_ARCH}" ] ; then
cat ${MICROCODE_ARCH} ${OUTPUT_IMAGE} > ${OUTPUT_IMAGE}.2
mv ${OUTPUT_IMAGE}.2 ${OUTPUT_IMAGE}
fi
echo "$OUTPUT_IMAGE created."
echo "Be sure to run lilo again if you use it."
}
badconf_file() {
# This won't really help with what's *wrong* with the file,
# but it will at least give them a clue that there's a problem
echo "/etc/mkinitrd.conf is bad or does not exist."
echo "If the file does not exist, do not pass -F to mkinitrd."
exit 1
}
unify_libs() {
awk '/=. \// { print $3 }' | sort -u
}
copy_libs() {
# First copy the essential glibc files:
find /lib /lib64 -name "ld-*so*" -o -name "libnss_files*so*" -o -name "libnss_compat*so*" 2> /dev/null | xargs -I'{}' cp -P --parents '{}' $SOURCE_TREE/
# Then copy all remaining libs our initrd files link against:
COUNT=1
PRFX=$(tempfile --prefix ldd-)
TMPFILE=${PRFX}${COUNT}
find $SOURCE_TREE -type f -exec ldd {} 2>/dev/null \; | unify_libs > $TMPFILE
while [ "$COUNT" != "0" ]; do
COUNT=$((COUNT+1))
for i in $(cat ${TMPFILE}) ; do
ldd $i 2>/dev/null
done | unify_libs > ${PRFX}${COUNT}
if [ $(cat $TMPFILE ${PRFX}${COUNT} | sort |uniq -u | wc -l) -eq 0 ]; then
COUNT=0
else
TMPFILE=${PRFX}${COUNT}
fi
# emergency eject lever:
if [ "$COUNT" = "42" ]; then
COUNT=0
fi
done
for i in $(cat ${PRFX}* | sort -u) ; do
cp -P --parents ${i}* $SOURCE_TREE
done
(
cd $SOURCE_TREE
for i in $(find -L . -type l -exec readlink -m /{} \; 2>/dev/null ) ; do
cp -P --parents ${i} $SOURCE_TREE
done
)
rm ${PRFX}*
}
copy_modconf() {
mkdir -p $SOURCE_TREE/etc $SOURCE_TREE/lib
cp -a /etc/modprobe.d $SOURCE_TREE/etc
cp -a /lib/modprobe.d $SOURCE_TREE/lib/
}
# Normalize the string $1 by replacing occurences of
# recognized tags by their current values.
#
# this version take the following tags into account:
# %KVER% (kernel version)
# %SLACKVER% (slackware version)
#
function normalize_string() {
echo "$1" | sed -e "s?%KVER%?${KERNEL_VERSION}?g" \
-e "s?%SLACKVER%?$(cat /etc/slackware-version|cut -f2 -d" ")?g"
}
# If --help is given, print_usage and exit:
if echo $* | grep -wq '\--help' ; then
print_usage
exit 0
fi
# If -V given, print version and exit:
if echo $* | grep -wq '\-V' ; then
echo "mkinitrd version $MKINITRD_VERSION"
exit 0
fi
# Default values if these aren't previously set.
# Might be set from config file or by -s and -o options too.
SOURCE_TREE=${SOURCE_TREE:-/boot/initrd-tree}
OUTPUT_IMAGE=${OUTPUT_IMAGE:-""}
KERNEL_VERSION=${KERNEL_VERSION:-"$(uname -r)"}
# The initrd requires udev to function correctly:
UDEV=1
# Default actions without options:
if [ -z "$1" ]; then
# We need a sensible default for this special case:
OUTPUT_IMAGE=$(normalize_string ${OUTPUT_IMAGE:-/boot/initrd.gz})
# If the output tree doesn't exist, create it and then exit:
if [ ! -d $SOURCE_TREE ]; then
echo "Nothing found at location $SOURCE_TREE, so we will create an"
echo -n "initrd directory structure there... "
create_new_source_tree
echo "done."
echo
echo "Now cd to $SOURCE_TREE and install some modules in your"
echo "module directory (lib/modules/${KERNEL_VERSION}). Then see init"
echo "for more information (there are a few other files to edit)."
echo "Finally, run mkinitrd again once the initrd-tree is ready,"
echo "and $OUTPUT_IMAGE will be created from it."
echo
exit 0
else
# If the source tree does exist, the default is to build the initrd
# image from it and then exit:
build_initrd_image
exit 0
fi
fi # default no-option actions
# Parse for the use config file option first or else the other command
# line options can not override /etc/mkinitrd.conf.
for opt in "$@"; do
if [ "$opt" = "-F" ]; then
if [ -e /etc/mkinitrd.conf ]; then
. /etc/mkinitrd.conf || badconf_file
else
badconf_file
fi
fi
done
# Parse options:
while [ ! -z "$1" ]; do
case $1 in
-c)
CLEAR_TREE=1
shift
;;
-f)
ROOTFS="$2"
shift 2
;;
-h)
RESUMEDEV="$2"
shift 2
;;
-k)
KERNEL_VERSION="$2"
shift 2
;;
-l)
KEYMAP="$2"
shift 2
;;
-m)
MODULE_LIST="$2"
shift 2
;;
-o)
# canonicalize filename:
OUTPUT_IMAGE="$(readlink -m $2)"
shift 2
;;
-r)
ROOTDEV="$2"
shift 2
;;
-s)
# canonicalize filename:
SOURCE_TREE="$(readlink -m $2)"
shift 2
;;
-u)
UDEV=1
shift
;;
-w)
WAIT="$2"
shift 2
;;
-C)
CRYPT=1
LUKSDEV="$2"
shift 2
;;
-K)
LUKSKEY="$2"
shift 2
;;
-T)
LUKSTRIM="$2"
shift 2
;;
-L)
LVM=1
shift
;;
-B)
BTRFS=1
shift
;;
-M)
MODCONF=1
shift
;;
-P)
# canonicalize filename:
MICROCODE_ARCH="$(readlink -m $2)"
if [ ! -e "${MICROCODE_ARCH}" ] ; then
echo "Error, the microcode cpio archive ${MICROCODE_ARCH} does not exist."
exit 1
fi
shift 2
;;
-MNT)
MOUNT_LIST="$2"
shift 2
;;
-R)
RAID=1
shift
;;
*) # unknown, prevent infinite loop
shift
;;
esac
done
# Resolve TAGS (i.e %KVER%, %SLACKVER%) found in OUTPUT_IMAGE.
#
# Note:
# ----
# This must be done after all options have been handled and
# not when handling case '-o' because -k can be passed after
# -o in which case, the tag %KVER% would be replaced with the
# current kernel version instead of version passed with -k.
#
if echo "$OUTPUT_IMAGE" | grep -qE "%KVER%|%SLACKVER%" ; then
OUTPUT_IMAGE="$(normalize_string $OUTPUT_IMAGE)"
fi
# If kernel modules are needed but the kernel version is absent, exit now:
for kver in $(echo ${KERNEL_VERSION} | tr ':' '\n') ; do
if [ ! -d /lib/modules/$kver ]; then
echo "ERROR: No /lib/modules/$kver kernel modules tree found for kernel \"$kver\""
exit 1
fi
done
# If clearing source tree was requested, do that first
if [ "$CLEAR_TREE" = "1" ]; then
clear_source_tree
fi
# If there's no $SOURCE_TREE, make one now:
if [ ! -d "$SOURCE_TREE" ]; then
create_new_source_tree
fi
# If $ROOTDEV and $ROOTFS are not set, assume we want the
# values for the currently mounted /
# (unless we find that values are already set in the initrd-tree):
if [ -z "$ROOTDEV" -a -z "$(cat $SOURCE_TREE/rootdev 2>/dev/null)" ]; then
ROOTDEV=$(mount | grep ' on / ' | cut -f 1 -d ' ')
if [ "$ROOTDEV" = "/dev/root" ]; then # find real root device
ROOTDEV="/dev/$(readlink /dev/root)"
fi
fi
if [ -z "$ROOTFS" -a -z "$(cat $SOURCE_TREE/rootfs 2>/dev/null)" ]; then
ROOTFS=$(mount | grep ' on / ' | cut -f 5 -d ' ')
fi
# If needed, write them in the initrd-tree:
if [ ! -z "$ROOTDEV" ]; then
echo $ROOTDEV > $SOURCE_TREE/rootdev
fi
if [ ! -z "$ROOTFS" ]; then
echo $ROOTFS > $SOURCE_TREE/rootfs
fi
# Put a copy of the command line used to create this initrd in
# initrd-tree/command_line:
echo "$COMMAND_LINE" > $SOURCE_TREE/command_line
# If /etc/mkinitrd.conf exists, put a copy of that in there as well.
# (May or may not have been used according to the -F option, but we'll
# save a copy anyway just in case):
if [ -e /etc/mkinitrd.conf ]; then
cp -a /etc/mkinitrd.conf $SOURCE_TREE/mkinitrd.conf
fi
# If $WAIT is not set, assume we need only one second
# to have all devices done
# (unless we find that value is already set in the initrd-tree):
if [ -z "$WAIT" -a -z "$(cat $SOURCE_TREE/wait-for-root)" ]; then
WAIT=1
# ARM devices need even more time:
case "$( uname -m )" in
arm*) WAIT=4;;
esac
fi
if [ ! -z "$WAIT" ]; then
echo $WAIT > $SOURCE_TREE/wait-for-root
fi
# If no OUTPUT_IMAGE was specified, read it from the SOURCE_TREE if possible:
OUTPUT_IMAGE=$(normalize_string ${OUTPUT_IMAGE:-"$(cat $SOURCE_TREE/initrd-name)"})
# If we still have no value, apply the default:
OUTPUT_IMAGE=${OUTPUT_IMAGE:-"/boot/initrd.gz"}
# Finally, write the image name into the SOURCE_TREE:
echo "$OUTPUT_IMAGE" > $SOURCE_TREE/initrd-name
# Fill /resumedev with the swap partition holding the hibernation image
if [ ! -z "$RESUMEDEV" ]; then
echo $RESUMEDEV > $SOURCE_TREE/resumedev
fi
# Add custom keymap support if one was given
if [ ! -z "$KEYMAP" ]; then
echo $KEYMAP > $SOURCE_TREE/keymap
cp /usr/share/mkinitrd/keymaps.tar.gz $SOURCE_TREE/etc/
fi
# If LUKSDEV was set in the config file, then we need to set CRYPT=1
if [ ! -z "$LUKSDEV" ]; then
CRYPT=1
fi
# Check for LUKSTRIM
if [ ! -z "$LUKSTRIM" ]; then
echo $LUKSTRIM > $SOURCE_TREE/lukstrim
fi
# If LUKSKEY was set in the config file, then give it a warm welcome:
if [ ! -z "$LUKSKEY" ]; then
# $SOURCE_TREE/wait-for-root may have been configured earlier in the script,
# but we require at least 5 seconds for the USB stick to settle
# after insertion :
if [ ! -s $SOURCE_TREE/wait-for-root ] || [ $(cat $SOURCE_TREE/wait-for-root) -lt 5 ]; then
echo 5 > $SOURCE_TREE/wait-for-root
fi
# Several extra modules are needed to support a vfat formatted USB stick...
# assuming here we are using a western codepage.
# This possibly adds doublures, but we clean up the MODULE_LIST further down!
MODULE_LIST="${MODULE_LIST}:xhci-pci:ohci-pci:ehci-pci:xhci-hcd:ohci-hcd:ehci-hcd:uhci-hcd:usb-storage:hid:usbhid:fat:nls_cp437:nls_iso8859-1:msdos:vfat"
# Finally, write the lukskey to the initrd-tree:
echo $LUKSKEY > $SOURCE_TREE/lukskey
fi
# Include RAID support in initrd
if [ ! -z "$RAID" ]; then
if [ -r /sbin/mdadm -a -r /sbin/mdmon ]; then
mkdir -p $SOURCE_TREE/sbin
cp /sbin/mdadm $SOURCE_TREE/sbin/mdadm
cp /sbin/mdmon $SOURCE_TREE/sbin/mdmon
chmod 0755 $SOURCE_TREE/sbin/mdadm
chmod 0755 $SOURCE_TREE/sbin/mdmon
mkdir -p $SOURCE_TREE/lib/udev/rules.d
echo 'KERNEL=="dm-[0-9]*", OPTIONS+="db_persist"' > \
$SOURCE_TREE/lib/udev/rules.d/95-dm-initrd.rules
if [ -r /etc/mdadm.conf ] ; then
cp /etc/mdadm.conf $SOURCE_TREE/etc
fi
else
echo "ERROR: mdadm and/or mdmon binary is missing, RAID support not installed"
fi
fi
# Include Btrfs support in initrd
if [ ! -z "$BTRFS" ]; then
if [ -r /sbin/btrfs ]; then
mkdir -p $SOURCE_TREE/sbin
cp /sbin/btrfs $SOURCE_TREE/sbin/btrfs
chmod 0755 $SOURCE_TREE/sbin/btrfs
else
echo "ERROR: btrfs binary is missing, Btrfs support not installed"
fi
fi
# Include udev in initrd
if [ ! -z "$UDEV" ]; then
cp /sbin/udev* $SOURCE_TREE/sbin/
cp -a /lib/udev $SOURCE_TREE/lib/
# But we don't want all of /lib/udev
for file in $(echo $LIBUDEV_BLACKLIST) ; do
# Replace with a null script (avoids error spew):
cat << EOF > $SOURCE_TREE/lib/udev/$file
#!/bin/ash
# This space is intentionally left blank
EOF
done
fi
# Include LVM support in initrd
if [ ! -z "$LVM" ]; then
if [ -f /sbin/lvm ]; then
mkdir -p $SOURCE_TREE/sbin
cp /sbin/lvm $SOURCE_TREE/sbin/lvm
( cd $SOURCE_TREE/sbin
ln -s lvm vgchange 2>/dev/null
ln -s lvm vgscan 2>/dev/null )
else
echo "LVM binary is missing, LVM support isn't installed"
LVM=""
fi
fi
# Include cryptsetup (LUKS) support in initrd
if [ ! -z "$CRYPT" ]; then
if [ -e /usr/sbin/cryptsetup ]; then
mkdir -p $SOURCE_TREE/sbin
cp /usr/sbin/cryptsetup $SOURCE_TREE/sbin/cryptsetup
find /lib /lib64 /usr/lib /usr/lib64 -name "libargon2*so*" 2> /dev/null | xargs -I'{}' cp -P --parents '{}' $SOURCE_TREE/
find /lib /lib64 /usr/lib /usr/lib64 -name "libgcc_s*so*" 2> /dev/null | xargs -I'{}' cp -P --parents '{}' $SOURCE_TREE/
MODULE_LIST="${MODULE_LIST}:algif_skcipher"
if [ ! -e $SOURCE_TREE/sbin/udevadm ]; then
cat << EOF > $SOURCE_TREE/sbin/udevadm
#!/bin/sh
sleep 3
EOF
chmod 0755 $SOURCE_TREE/sbin/udevadm
fi
# Write the underlying luks device to the initrd-tree:
echo $LUKSDEV > $SOURCE_TREE/luksdev
else
echo "Cryptsetup binary is missing, CRYPT support isn't installed"
CRYPT=""
fi
fi
# Include device mapper in initrd (needed for LUKS and LVM)
if [ ! -z "$CRYPT" -o ! -z "$LVM" ]; then
cp /sbin/dmsetup $SOURCE_TREE/sbin/dmsetup
find /lib /lib64 -name "libdevmapper*so*" 2> /dev/null | xargs -I'{}' cp -P --parents '{}' $SOURCE_TREE/
if [ -z "${MODULE_LIST}" ] ; then
MODULE_LIST="dm-mod"
elif ! echo ${MODULE_LIST} | grep -q dm-mod ; then
MODULE_LIST="$MODULE_LIST:dm-mod"
fi
# Ensure that dm-snapshot is included if LVM is used:
if [ ! -z "$LVM" ]; then
if ! echo ${MODULE_LIST} | grep -q dm-snapshot ; then
MODULE_LIST="$MODULE_LIST:dm-snapshot"
fi
fi
mkdir -p $SOURCE_TREE/lib/udev/rules.d
echo 'KERNEL=="dm-[0-9]*", OPTIONS+="db_persist"' > \
$SOURCE_TREE/lib/udev/rules.d/95-dm-initrd.rules
fi
# If there is additional filesystems to be mounted, copy their configuration
# from system's /etc/fstab:
if [ ! -z "$MOUNT_LIST" ]; then
for MOUNT_POINT in $(echo $MOUNT_LIST | tr : \ ); do
grep '^[^#[:space:]]\+[[:space:]]\+'$MOUNT_POINT'[[:space:]]' /etc/fstab
done > $SOURCE_TREE/addfstab
fi
# Make module directories:
for kver in $(echo ${KERNEL_VERSION} | tr ':' '\n') ; do
if [ ! -d $SOURCE_TREE/lib/modules/$kver ]; then
mkdir -p $SOURCE_TREE/lib/modules/$kver
fi
done
# Copy kmod/modprobe stuff to initrd:
for i in kmod depmod insmod lsmod modinfo modprobe rmmod ; do
rm -f $SOURCE_TREE/sbin/$i ;
cp -a /sbin/$i $SOURCE_TREE/sbin ;
done
# Make sure modules.builtin and modules.order are there (for kmod):
for kver in $(echo ${KERNEL_VERSION} | tr ':' '\n') ; do
cp /lib/modules/$kver/modules.{builtin,order} \
$SOURCE_TREE/lib/modules/$kver
done
# If an executable $SOURCE_TREE/load_kernel_modules already exists, then
# we assume you will want to load the kernel modules mentioned in there.
# This means, you do not have to explicitly add those on the commandline:
if [ -x $SOURCE_TREE/load_kernel_modules ]; then
MODULE_LIST="${MODULE_LIST}:$(cat $SOURCE_TREE/load_kernel_modules |grep "^modprobe" |rev |cut -d/ -f1 |rev |cut -d. -f1)"
fi
# If the module list is not empty, copy the modules into place:
if [ ! -z "$MODULE_LIST" ]; then
if grep -q "#modprobe reiserfs" $SOURCE_TREE/load_kernel_modules ; then
rm -f $SOURCE_TREE/load_kernel_modules
touch $SOURCE_TREE/load_kernel_modules
chmod 755 $SOURCE_TREE/load_kernel_modules
echo "# This is a script used to load the kernel modules." >> $SOURCE_TREE/load_kernel_modules
echo "# To use it, chmod it 755, and then add the insmod" >> $SOURCE_TREE/load_kernel_modules
echo "# lines needed to load your modules, like this:" >> $SOURCE_TREE/load_kernel_modules
echo >> $SOURCE_TREE/load_kernel_modules
fi
# Sanitize the modules list first, before any further processing.
# The awk command eliminates doubles without changing the order:
MODULE_LIST=$(echo $MODULE_LIST |tr -s ':' '\n' |awk '!x[$0]++' |tr '\n' ':')
MODULE_LIST=$(echo ${MODULE_LIST%:}) # Weed out a trailing ':'
# Count number of modules
# This INDEX number gives us an easy way to find individual
# modules and their arguments, as well as tells us how many
# times to run through the list
if ! echo $MODULE_LIST | grep ':' > /dev/null ; then # only 1 module specified
INDEX=1
else
# Trim excess ':' which will screw this routine:
MODULE_LIST=$(echo $MODULE_LIST | tr -s ':')
INDEX=1
while [ ! "$(echo "$MODULE_LIST" | cut -f $INDEX -d ':' )" = "" ]; do
INDEX=$(expr $INDEX + 1)
done
INDEX=$(expr $INDEX - 1) # Don't include the null value
fi
# Repeat these tasks for all kernel versions support has been requested for:
for kver in $(echo ${KERNEL_VERSION} | tr ':' '\n') ; do
# Wrap everything in a while loop
i=0
while [ $i -ne $INDEX ]; do
i=$(( $i + 1 ))
# FULL_MOD is the module plus any arguments (if any)
# MODULE is the module name
# ARGS is any optional arguments to be passed to the kernel
FULL_MOD="$(echo "$MODULE_LIST" | cut -d ':' -f $i)"
MODULE="$(echo "$FULL_MOD" | cut -d ' ' -f 1 )"
# Test for arguments
if echo "$FULL_MOD" | grep ' ' > /dev/null; then
ARGS=" $(echo "$FULL_MOD" | cut -d ' ' -f 2- )"
else
unset ARGS
fi
# Get MODULE deps and prepare modprobe lines
/sbin/modprobe --set-version $kver --show-depends --ignore-install $MODULE 2>/dev/null \
| grep "^insmod " | cut -f 2 -d ' ' | while read SRCMOD; do
# If jfs or xfs filesystems are in use, add the repair tools to the initrd:
if [ "$(basename $SRCMOD .ko)" = "jfs" ]; then
cp -a /sbin/jfs_fsck $SOURCE_TREE/sbin/
elif [ "$(basename $SRCMOD .ko)" = "xfs" ]; then
cp -a /sbin/xfs_repair $SOURCE_TREE/sbin/
fi
if ! grep -Eq " $(basename $SRCMOD .ko)(\.| |$)" $SOURCE_TREE/load_kernel_modules 2>/dev/null ; then
LINE="$(echo "modprobe -v $(basename ${SRCMOD%%.gz} .ko)" )"
# Test to see if arguments should be passed
# Over-ride the previously defined LINE variable if so
if [ "$(basename $SRCMOD .ko)" = "$MODULE" ]; then
# SRCMOD and MODULE are same, ARGS can be passed
LINE="$LINE$ARGS"
fi
fi
if ! grep -qx "$LINE" $SOURCE_TREE/load_kernel_modules ; then
echo "$LINE" >> $SOURCE_TREE/load_kernel_modules
fi
# Try to add the module to the initrd-tree. This should be done
# even if it exists there already as we may have changed compilers
# or otherwise caused the modules in the initrd-tree to need
# replacement.
if cp -a --parents $SRCMOD $SOURCE_TREE 2>/dev/null; then
echo "OK: $SRCMOD added."
# If a module needs firmware, copy that too
/sbin/modinfo -F firmware "$SRCMOD" | sed 's/^/\/lib\/firmware\//' |
while read SRCFW; do
if cp -a --parents "$SRCFW" $SOURCE_TREE 2>/dev/null; then
echo "OK: $SRCFW added."
else
echo "WARNING: Could not find firmware \"$SRCFW\""
fi
done
else
echo "WARNING: Could not find module \"$SRCMOD\""
fi
done
done
# Pregenerate the module dependency information
/sbin/depmod -a -b $SOURCE_TREE $kver
done # repeat for all kernel versions
# Copy /{etc,lib}/modprobe.d/* if desired
if [ ! -z $MODCONF ]; then
copy_modconf
fi
fi
# Copy needed libraries
copy_libs
# Make sure all libraries have symlinks:
/sbin/ldconfig $(readlink -f $SOURCE_TREE)/lib/ 2> /dev/null
/sbin/ldconfig $(readlink -f $SOURCE_TREE)/lib64/ 2> /dev/null
/sbin/ldconfig
# And finally, build the initrd:
build_initrd_image

View file

@ -1,300 +0,0 @@
.\" -*- nroff -*-
.ds g \" empty
.ds G \" empty
.\" Like TP, but if specified indent is more than half
.\" the current line-length - indent, use the default indent.
.de Tp
.ie \\n(.$=0:((0\\$1)*2u>(\\n(.lu-\\n(.iu)) .TP
.el .TP "\\$1"
..
.TH MKINITRD 8 "25 April 2022" "Slackware Version 15.0"
.SH NAME
mkinitrd \- create or rebuilt an initrd (initial ramdisk) using initramfs (simple cpio+gzip).
.SH SYNOPSIS
.B mkinitrd
[
.B \-F
]
[
.B \-c
]
[
.B \-f filesystem
]
[
.B \-h hibernate_partition
]
[
.B \-k kernel_version1:kernel_version2:kernel_version3...
]
[
.B \-m module1:module2:module3...
]
[
.B \-o output_file
]
[
.B \-r root_device
]
[
.B \-s source_tree
]
[
.B \-u
]
[
.B \-w wait_time
]
[
.B \-C device1:device2:device3...
]
[
.B \-K luks_keyfile
]
[
.B \-P microcode_archive
]
[
.B \-B
]
[
.B \-L
]
[
.B \-R
]
[
.B \-V
]
.SH DESCRIPTION
.B mkinitrd
is used to build an initial ramdisk. An initial ramdisk is a very small
set of files that are loaded into RAM and "mounted" (as initramfs doesn't
actually use a filesystem) as the kernel boots (before the main root
filesystem is mounted). The usual reason to use an initrd is to load kernel
kernel modules in order to access the root partition. An initrd might also
be required to unlock an encrypted device. Usually these modules are
required to support the filesystem used by the root partition (e.g., ext4,
jfs, xfs), or perhaps the controller that the hard drive is attached to
(SCSI, RAID, etc). Essentially, there are so many different options
available in modern Linux kernels that it isn't practical to try to ship
many different kernels to try to cover everyone's needs. It's a lot more
flexible to ship a generic kernel and a set of kernel modules for it.
.SH OPTIONS
.TP
.B \-F
Use the contents of /etc/mkinitrd.conf as options to mkinitrd (optional).
If this is used in conjunction with any other options passed on the command
line, the command-line options will override the config file options.
.br
See mkinitrd.conf(5) for details.
.TP
.B \-c
Clear the existing initrd tree (by default in /boot/initrd-tree/) first.
If this is not done, running mkinitrd will add additional modules to the
existing initrd.
.TP
.B \-f filesystem
Specify the filesystem to use for the root partition. If this isn't given,
mount will usually figure it out. This option must be used together with the
\-r option in order to be beneficial.
.TP
.B \--help
Display a help summary.
.TP
.B \-h hibernate_partition
Specify the swap partition holding the hibernation image.
.TP
.B \-k kernel version list
Use kernel modules from the specified kernel version. mkinitrd will look
for them in /lib/modules/(kernel version). This may be a single kernel version,
or it may be a colon-delimited list of kernel versions.
.TP
.B \-l keymap
Load an alternative keyboard mapping. All supported keyboard mappings
can be found in /usr/share/mkinitrd/keymaps.tar.gz
Leave the '.bmap' out when you supply this parameter. E.g. '-l nl' will
add support for dutch keyboard mapping to the initrd.
.TP
.B \-m module list
This is a list of colon-delimited modules to build into the initrd.
Any dependencies of requested modules will also be added to the initrd.
Additional options may be added to use when loading the kernel modules
(but in this case the entire list must be wrapped with double quotes).
.TP
.B \-o output image
The file to write the initrd to. (default: /boot/initrd.gz)
.TP
.BI \-r \ root_device
Specify the device to be used as the root partition. If this isn't given, the
kernel default will be used (which is usually fine). This option must be used
together with the \-f option in order to be beneficial.
.I root_device
can be a device node path, UUID, or LABEL. See examples for \fB\-C\fR below.
.TP
.B \-s source tree
The directory to use as the source for the initrd. (default: /boot/initrd-tree/)
.TP
.B \-u
Include udev in the initrd (provided for backward compatibility, as udev is
always included in the initrd).
.TP
.B \-w
The -w option specifies how long to wait in seconds before assuming that all the
drives are spun up and ready to go.
.TP
.BI \-C \ device_list
A colon (:) delimited list of luks encrypted block devices to be unlocked by
the initrd using cryptsetup.
.I device_list
may include any of: device node path, UUID, or LABEL. All devices that must be
unlocked in order to access the root filesystem must be specified. For example:
-C /dev/sda2:/dev/sda3
.br
-C UUID=ec6dea40-c8d8-4590-850a-a757be60e45a
.br
-C LABEL=darkstar
Each unlocked device will be assigned an automatically generated luks device
name of the form luks<device> where '<device>' will be the basename of the
encrypted device node path. For example:
/dev/mapper/lukssda2
As a convenience to users, where -r specifies one of the device names listed
on the -C option it will be automatically adjusted to use the correct luks
device name. i.e.
"-C /dev/sda2 -r /dev/sda2" and
"-C /dev/sda2 -r /dev/mapper/lukssda2"
are equivalent.
.br
(Use with '-r' option).
.TP
.B \-K luks_keyfile
When using cryptsetup to encrypt your partition, you can use a keyfile instead
of a passphrase to unlock the LUKS volume. The LUKSKEY variable holds the
filename of a keyfile, as well as the label (or uuid) of the partition this
file is on. This way, you can unlock your computer automatically if you have a
USB stick with your LUKS key inserted at boot. A passphrase will still be asked
if the LUKS key can not be found.
.br
For example, if your USB thumb drive has a FAT partition with label
"TRAVELSTICK" and the actual keyfile is called "/keys/alien.luks", then
you need to set:
-K LABEL=TRAVELSTICK:/keys/alien.luks
.TP
.B \-T device list
A colon (:) delimited list of luks encrypted block devices to be passed the
"--allow-discards" option when unlocked by the initrd using cryptsetup, e.g.
-T /dev/sda2:/dev/sda4
This has the effect of allowing TRIM on SSD drives. Be sure your SSD supports
this feature (correctly) before enabling it. See fstrim(8) for more information.
.TP
.B \-P microcode_archive
This option specifies a cpio archive containing updated microcode for your CPU.
CPU manufacturers occasionally release such updates to fix bugs in the microcode
currently embedded in the CPU. The microcode archive will be prepended to the
output initrd, where the kernel will find it for early patching:
-P /boot/intel-ucode.cpio
.TP
.B \-B
This option adds the btrfs utility to the initrd so that multi-device filesystems
will be picked up by a scan (/sbin/btrfs device scan). This is needed if the
root filesystem is a Btrfs multi-device filesystem.
.TP
.B \-L
This option adds LVM support to the initrd, if the tools are
available on the system.
.TP
.B \-R
This option adds RAID support to the initrd, if a static mdadm binary is
available on the system.
.TP
.B \-M
This option add the files in /etc/modprobe.d/ and /lib/modprobe.d/ to the initrd.
.TP
.B \-MNT mount_point_list
List of filesystems to be mounted by initrd. Useful if libraries or commands that
are outside the root filesystem are needed in early boot. Multiple filesystems can
be listed separated by colon (:), e.g.
-MNT /usr:/usr/local
.TP
.B \-V
Display version information and exit.
.SH EXAMPLES
A simple example: Build an initrd for a reiserfs root partition:
mkinitrd -c -m reiserfs
Another example: Build an initrd image using Linux 2.6.33.1 kernel
modules for a system with an ext3 root partition on /dev/sdb3:
mkinitrd -c -k 2.6.33.1 -m ext3 -f ext3 -r /dev/sdb3
An example of a single encrypted partition setup:
.br
As a user convenience, the value for the "-r" option may also be specified as
"/dev/sda2" in this example:
mkinitrd -c -k 2.6.33.1 \\
-m ext4:ehci-hcd:uhci-hcd:usbhid \\
-f ext4 -r /dev/mapper/lukssda2 \\
-C /dev/sda2 \\
-l uk
Finally, A more complex example:
.br
This one is for a LVM Volume Group (rootvg) comprising of two LVM Physical
Volumes, each of which is on a LUKS encrypted partition that will need to be
unlocked before the root filesystem (/dev/rootvg/lvroot) can be accessed.
mkinitrd -c -k 2.6.29.6 \\
-m ext4:ehci-hcd:uhci-hcd:usbhid \\
-f ext4 -r /dev/rootvg/lvroot \\
-L -C /dev/sda2:/dev/sdb2 \\
-l uk
If run without options, mkinitrd will rebuild an initrd image using
the contents of the $SOURCE_TREE directory, or, if that directory
does not exist it will be created and populated, and then mkinitrd
will exit. These options are handy for building an initrd mostly
by hand. After creating /boot/initrd-tree/, you can add modules and
edit files by hand, and then rerun mkinitrd to create the initrd.
Once the initrd is created, you'll need to tell your boot loader
to load it. If you boot with LILO, you will need to add an initrd
line to /etc/lilo.conf. Here's a section of lilo.conf that shows
how to set this up:
# Linux bootable partition config begins
image = /boot/vmlinuz-generic-2.6.33.1
initrd = /boot/initrd.gz
root = /dev/sda3
label = Linux26331
read-only
# Linux bootable partition config ends
Note that the line "root = /dev/sda3" is not needed if the root device
has been configured in the initrd image.
Once you've created the initrd and editing /etc/lilo.conf, you will
need to run 'lilo' to write out the changed boot block. The next
time you reboot the initrd should be loaded along with the kernel.
Have fun!
.SH SEE ALSO
mkinitrd.conf (5)
.SH AUTHOR
Patrick J. Volkerding <volkerdi@slackware.com>

View file

@ -1,198 +0,0 @@
#!/bin/bash
# Copyright 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2015, 2016, 2017, 2018, 2021, 2022, 2023, 2024 Patrick J. Volkerding, Sebeka, MN, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
# permitted provided that the following conditions are met:
#
# 1. Redistributions of this script must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
cd $(dirname $0) ; CWD=$(pwd)
PKGNAM=mkinitrd
VERSION=${VERSION:-1.4.11}
BB=1.32.1
BUILD=${BUILD:-35}
# Automatically determine the architecture we're building on:
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
i?86) export ARCH=i686 ;;
arm*) export ARCH=arm ;;
# Unless $ARCH is already set, use uname -m for all other archs:
*) export ARCH=$( uname -m ) ;;
esac
fi
# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
# the name of the created package would be, and then exit. This information
# could be useful to other scripts.
if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
echo "$PKGNAM-$VERSION-$ARCH-$BUILD.txz"
exit 0
fi
NUMJOBS=${NUMJOBS:-" -j$(expr $(nproc) + 1) "}
TMP=${TMP:-/tmp}
PKG=$TMP/package-mkinitrd
# Write a warning to stdout if the mkinitrd script has a different version:
eval $( grep "^MKINITRD_VERSION=" $CWD/mkinitrd )
if [ "$VERSION" != "$MKINITRD_VERSION" ]; then
echo "The version of this package ($VERSION) is not equal to the version of the mkinitrd script ($MKINITRD_VERSION)."
sleep 5
fi
rm -rf $PKG
mkdir -p $TMP $PKG
cd $TMP
rm -rf busybox-$BB
tar xvf $CWD/busybox-$BB.tar.bz2 || tar xvf $CWD/busybox-$BB.tar.?z || exit 1
cd busybox-$BB || exit 1
if [ -d $CWD/fixes-$BB ]; then
for pfile in $CWD/fixes-$BB/*.patch ; do
patch -p1 < $pfile || exit 1
done
fi
chown -R root:root .
sed -e \
's#^CONFIG_PREFIX=.*#CONFIG_PREFIX="'$PKG'/usr/share/mkinitrd/initrd-tree"#' \
$CWD/busybox-dot-config > .config
make oldconfig || exit 1
make $NUMJOBS || make || exit 1
mkdir -p $PKG/usr/share/mkinitrd/initrd-tree/{bin,sbin}
make install || exit 1
rm -f $PKG/usr/share/mkinitrd/initrd-tree/linuxrc
# Copying additional files:
cp -a $CWD/mkinitrd_command_generator.sh $PKG/usr/share/mkinitrd
chown root:root $PKG/usr/share/mkinitrd/mkinitrd_command_generator.sh
chmod 755 $PKG/usr/share/mkinitrd/mkinitrd_command_generator.sh
cp -a $CWD/keymaps.tar.gz $PKG/usr/share/mkinitrd
chown root:root $PKG/usr/share/mkinitrd/keymaps.tar.gz
chmod 644 $PKG/usr/share/mkinitrd/keymaps.tar.gz
# Zip up the initrd-tree:
( cd $PKG/usr/share/mkinitrd/initrd-tree
tar xf $CWD/_initrd-tree.tar.gz
cat $CWD/init > init
# Patch init:
zcat $CWD/0001-Fix-LUKSTRIM-with-C-T-and-UUID.patch.gz | patch -p1 --verbose || exit 1
# These are useful for ARM:
mknod -m 644 dev/random c 1 8
mknod -m 644 dev/urandom c 1 9
tar czf ../initrd-tree.tar.gz .
) || exit 1
rm -rf $PKG/usr/share/mkinitrd/initrd-tree
# Add busybox docs:
mkdir -p $PKG/usr/doc/busybox-$BB
cp -a AUTHORS COPYING* INSTALL LICENSE README* TODO* \
$PKG/usr/doc/busybox-$BB
cp -a e2fsprogs/README $PKG/usr/doc/busybox-$BB/README.e2fsprogs
cp -a libbb/README $PKG/usr/doc/busybox-$BB/README.libbb
cp -a shell/README $PKG/usr/doc/busybox-$BB/README.shell
cp -a testsuite/README $PKG/usr/doc/busybox-$BB/README.testsuite
mkdir -p $PKG/sbin
cp -a $CWD/mkinitrd $PKG/sbin/mkinitrd
chown root:root $PKG/sbin/mkinitrd
chmod 755 $PKG/sbin/mkinitrd
# Patch to switch to mktemp:
( cd $PKG/sbin ; zcat $CWD/mkinitrd.tempfile.to.mktemp.patch.gz | patch --verbose || exit 1) || exit 1
# Patch mkinitrd to bail on no temp directory:
( cd $PKG/sbin ; zcat $CWD/0002-bail-if-temp-dir-is-not-created.patch.gz | patch -p1 --verbose || exit 1) || exit 1
# Don't include 40-usb_modeswitch.rules on the initrd:
( cd $PKG/sbin ; zcat $CWD/0003-blacklist.40-usb_modeswitch.rules.patch.gz | patch -p1 --verbose || exit 1) || exit 1
# Support modules compressed with xz:
( cd $PKG/sbin ; zcat $CWD/0005-support-modules-compressed-with-xz.patch.gz | patch -p1 --verbose || exit 1) || exit 1
# Ensure target directory for the module exists (cp regression workaround for coreutils-9.1):
( cd $PKG/sbin ; zcat $CWD/0006-coreutils-9.1-ensure-target-dir-exists.patch.gz | patch -p1 --verbose || exit 1) || exit 1
rm -f $PKG/sbin/mkinitrd.orig
# Use -R if we detect the root partition is a partition of a RAID device:
( cd $PKG/usr/share/mkinitrd ; zcat $CWD/0004-check-if-BASEDEV-is-a-partition-of-a-RAID-volume.patch.gz | patch -p1 --verbose || exit 1) || exit 1
rm -f $PKG/usr/share/mkinitrd/mkinitrd_command_generator.sh.orig
# Fix for kmod-30:
( cd $PKG/sbin ; zcat $CWD/0007-kmod30.patch.gz | patch -p1 --verbose || exit 1) || exit 1
# Bugfix for previous RAID partition patch:
( cd $PKG/usr/share/mkinitrd ; zcat $CWD/0008-fix-check-if-BASEDEV-is-a-partition-of-a-RAID-volume.patch.gz | patch -p1 --verbose || exit 1) || exit 1
rm -f $PKG/sbin/mkinitrd.orig
# Don't include the 99-nfs.rules on the initrd:
( cd $PKG/sbin ; zcat $CWD/0009-exclude-99-nfs.rules.patch.gz | patch -p1 --verbose || exit 1) || exit 1
rm -f $PKG/sbin/mkinitrd.orig
# Fix test for including JFS or XFS repair tools:
( cd $PKG/sbin ; zcat $CWD/0010-fix-test-for-jfs-xfs-repair-tools.patch.gz | patch -p1 --verbose || exit 1) || exit 1
rm -f $PKG/sbin/mkinitrd.orig
mkdir -p $PKG/usr/man/man{5,8}
cat $CWD/mkinitrd.conf.5 | gzip -9c > $PKG/usr/man/man5/mkinitrd.conf.5.gz
cat $CWD/mkinitrd.8 | gzip -9c > $PKG/usr/man/man8/mkinitrd.8.gz
cat $CWD/mkinitrd_command_generator.8 | gzip -9c > $PKG/usr/man/man8/mkinitrd_command_generator.8.gz
mkdir -p $PKG/var/lib/pkgtools/setup
cp -a $CWD/setup.01.mkinitrd $PKG/var/lib/pkgtools/setup
chown root:root $PKG/var/lib/pkgtools/setup/setup.01.mkinitrd
chmod 755 $PKG/var/lib/pkgtools/setup/setup.01.mkinitrd
mkdir -p $PKG/usr/sbin
cp -a $CWD/geninitrd $PKG/usr/sbin
chown root:root $PKG/usr/sbin/geninitrd
chmod 755 $PKG/usr/sbin/geninitrd
mkdir -p $PKG/etc
cp -a $CWD/mkinitrd.conf.sample $PKG/etc/mkinitrd.conf.sample
# ARM systems often need more time to find devices:
case "$( uname -m )" in
arm*) sed -e 's@#WAIT="1"@#WAIT="4"@g' \
-i $PKG/etc/mkinitrd.conf.sample;;
esac
chown root:root $PKG/etc/mkinitrd.conf.sample
chmod 644 $PKG/etc/mkinitrd.conf.sample
mkdir -p $PKG/etc/default
cp -a $CWD/geninitrd.default $PKG/etc/default/geninitrd.new
chown root:root $PKG/etc/default/geninitrd.new
chmod 644 $PKG/etc/default/geninitrd.new
mkdir -p $PKG/usr/doc/mkinitrd-$VERSION
sed $CWD/README.initrd \
-e "s,@DATE@,$(date),g" \
-e "s,@KERNEL_VERSION@,$(uname -r),g" \
-e "s,@PACKAGE_VERSION@,$(uname -r | tr - _),g" \
-e "s,@LILO_KERNEL_NAME@,$(echo $(uname -r) | tr -d . | tr -d - ),g" \
-e "s,@MKINITRD_VERSION@,$VERSION,g" \
-e "s,@ARCH@,$ARCH,g" \
-e "s,@BUILD@,$BUILD,g" \
> $PKG/usr/doc/mkinitrd-$VERSION/README.initrd
mkdir $PKG/boot
ln -sf /usr/doc/mkinitrd-$VERSION/README.initrd $PKG/boot/README.initrd
find $PKG | xargs file | grep -e "executable" -e "shared object" \
| grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
mkdir -p $PKG/install
cat $CWD/doinst.sh > $PKG/install/doinst.sh
cat $CWD/slack-desc > $PKG/install/slack-desc
cd $PKG
/sbin/makepkg -l y -c n $TMP/mkinitrd-$VERSION-$ARCH-$BUILD.txz

View file

@ -1,265 +0,0 @@
.\" mkinitrd.conf.5 Robby Workman <rworkman@slackware.com>
.\" 28 August 2010 "
.TH MKINITRD.CONF 5 "25 April 2022" "Slackware 15.0"
.SH NAME
.B mkinitrd.conf(5)
.SH SYNOPSIS
.B mkinitrd.conf - optional configuration file for
.I mkinitrd(8)
.SH DESCRIPTION
The
.I mkinitrd.conf
file contains options to be passed to
.I mkinitrd(8)
on every run if mkinitrd is executed with the -F flag.
.br
It is intended as a fast and easy way for the system administrator to
pass options to mkinitrd without having to type them on each execution.
Options passed to
.I mkinitrd(8)
on the command line will override any
values set in the config file.
.SH OPTIONS AND SYNTAX
All options are in the format of OPTION="value"
.br
Unset variables have no effect.
.TP 5
.I SOURCE_TREE
This is the location for the initrd's source tree.
.br
Defaults to "/boot/initrd-tree"
.TP 5
.I CLEAR_TREE
This option specifies whether to clear the initrd source tree prior to
creating the initrd.
.br
This requires a value of either "0" or "1" where 0=no and 1=yes
.br
Examples:
.br
CLEAR_TREE="0" # Do not clear initrd tree first
.br
CLEAR_TREE="1" # Clear initrd tree first
It is recommended to leave this unset and pass "-c" on the command line
when clearing the tree is desired. Clearing the tree is not desirable
if you wish to build support for more than one kernel into the initrd
image.
.TP 5
.I OUTPUT_IMAGE
This is the location for the initrd image that is created.
.br
Defaults to "/boot/initrd.gz"
.br
If %KVER% and/or %SLACKVER% are present in the string, they will be replaced
with $KERNEL_VERSION (e.g. "4.4.75-smp") and Slackware Version (e.g. "14.2")
respectively in the name of the generated file.
.TP 5
.I KERNEL_VERSION
This is the kernel version for which the initrd should be created.
.br
Defaults to "$(uname -r)"
.TP 5
.I KEYMAP
This is the custom keyboard map that should be loaded instead of the
default 'us' keymap.
.br
The file /usr/share/mkinitrd/keymaps.tar.gz contains all possible keymaps
to choose from (omit the '.bmap' extension in the mkinitrd command)
.br
Example: KEYMAP="nl"
.TP 5
.I MODULE_LIST
This should be a colon-separated list of modules you wish to be included
in the initrd image.
.br
Example: MODULE_LIST="ext3:mbcache:jbd"
If you have loadtime options that you need to specify when loading kernel
modules, those can be added here as well.
.br
Example: MODULE_LIST="module1:module2 option=1:module3"
.TP 5
.I LUKSDEV
Contains a colon (:) delimited list of luks encrypted block devices to be
unlocked by the initrd using cryptsetup. The list may include any of: device
node path, UUID, or LABEL. All devices that must be unlocked in order to
access the root filesystem must be specified.
.sp
Example: LUKSDEV="/dev/sda2:/dev/sda3"
.br
Example: LUKSDEV="UUID=ec6dea40-c8d8-4590-850a-a757be60e45a"
.br
Example: LUKSDEV="LABEL=darkstar"
Each unlocked device will be assigned an automatically generated luks device
name of the form luks<device> where '<device>' will be the basename of the
encrypted device. e.g.
/dev/mapper/lukssda2
As a convenience to users, if
.I ROOTDEV
(see below) specifies one of the device names listed in the
.I LUKSDEV
option, then it will be automatically adjusted to use the correct luks
device name. i.e. when specifying
.I "LUKSDEV=/dev/sda2"
then
.I "ROOTDEV=/dev/sda2"
and
.I "ROOTDEV=/dev/mapper/lukssda2"
are equivalent.
.TP 5
.I LUKSKEY
When using cryptsetup to encrypt your partition, you can use a keyfile instead
of a passphrase to unlock the LUKS volume. The LUKSKEY variable holds the
filename of a keyfile, as well as the label (or uuid) of the partition this
file is on. This way, you can unlock your computer automatically if you have a
USB stick with your LUKS key inserted at boot. A passphrase will still be asked
if the LUKS key can not be found.
.br
For example, if your USB thumb drive has a FAT partition with label
"TRAVELSTICK" and the actual keyfile is called "/keys/alien.luks", then
you need to set:
.br
LUKSKEY="LABEL=TRAVELSTICK:/keys/alien.luks"
.TP 5
.I LUKSTRIM
Contains a colon (:) delimited list of luks encrypted block devices to be
passed the "--allow-discards" option when unlocked by the initrd using
cryptsetup. This has the effect of allowing TRIM on SSD drives. Be sure
your SSD supports this feature (correctly) before enabling it.
.br
See fstrim(8) for more information.
.br
Example: LUKSTRIM="/dev/sda2:/dev/sda4"
.TP 5
.I ROOTDEV
The device on which your root filesystem is located.
May be a device node path, UUID, or LABEL. See LUKSDEV examples.
.br
Example: ROOTDEV="/dev/sda2"
If you are using cryptsetup and an encrypted root filesystem, be sure to
read the option above for LUKSDEV or Bad Things will happen.
.TP 5
.I ROOTFS
The filesystem type of your root filesystem
.br
Example: ROOTFS="ext3"
.TP 5
.I RAID
This option adds the mdadm binary to the initrd to support RAID.
Additional modules may be required, depending on your kernel
configuration. If you wish to add LVM support to the initrd, then
set this to 1; otherwise, leave it unset or set it to 0.
.br
Examples:
.br
RAID="0" # Do not add RAID support to initrd
.br
RAID="1" # Add RAID support to initrd
.TP 5
.I LVM
This option adds support for LVM partitions into the initrd.
If you wish to add LVM support to the initrd, then set this to 1;
otherwise, leave it unset or set it to 0.
.br
Examples:
.br
LVM="0" # Do not add LVM support to initrd
.br
LVM="1" # Add LVM support to initrd
.TP 5
.I UDEV
Use UDEV in the initrd.
.br
Examples:
.br
UDEV="0" # Do not use udev in the initrd
.br
UDEV="1" # Use udev in the initrd (this is the default)
.TP 5
.I WAIT
This defines the time to wait, in seconds, until all disks are detected.
.br
This is useful for allowing extra time that might be needed for slow usb disks or systems with large amounts of storage to become ready.
.br
If not defined, the default is 1 second.
.TP 5
.I RESUMEDEV
The swap partition holding your hibernation image.
.br
Example: RESUMEDEV="/dev/sda2"
.TP 5
.I MODCONF
This option defines whether to copy the module-init-tools config files
from /etc/modprobe.d/ into the initrd. This will not usually be necessary,
but if you need certain modules to be loaded with special options, and you
have this configured in a file in /etc/modprobe.d/, this is one way to
accomplish the desired goal.
.br
Examples:
.br
MODCONF="0" # Do not add /etc/modprobe.d/* to the initrd
.br
MODCONF="1" # Add /etc/modprobe.d/* to the initrd
.TP 5
.I MICROCODE_ARCH
This option specifies a cpio archive containing updated microcode for your CPU.
CPU manufacturers occasionally release such updates to fix bugs in the microcode
currently embedded in the CPU. The microcode archive will be prepended to the
output initrd, where the kernel will find it for early patching.
.br
Examples:
.br
MICROCODE_ARCH="/boot/intel-ucode.cpio"
.TP 5
.I MOUNT_LIST
Lists additional filesystems to be mounted by initrd. Useful if libraries or
commands that are outside root filesystem are needed in early boot. Multiple
filesystems can be listed separated by colon (:). Device, filesystem type and
options are copied from /etc/fstab.
.br
Example:
.br
MOUNT_LIST="/usr:/usr/local"
.SH FILES
.I /etc/mkinitrd.conf
.br
See /etc/mkinitrd.conf.sample
.SH "SEE ALSO"
.BR mkinitrd "(8)"
.SH BUGS
None known :-)
.SH MISCELLANEOUS
Support for mkinitrd.conf was added in mkinitrd-1.3.0

View file

@ -1,21 +0,0 @@
# mkinitrd.conf.sample
# See "man mkinitrd.conf" for details on the syntax of this file
#
#SOURCE_TREE="/boot/initrd-tree"
#CLEAR_TREE="0"
#OUTPUT_IMAGE="/boot/initrd.gz"
#KERNEL_VERSION="$(uname -r)"
#KEYMAP="us"
#MODULE_LIST="ext4"
#LUKSDEV="/dev/sda2"
#LUKSTRIM="/dev/sda2" # verify support with 'hdparm -I $dev | grep TRIM'
#LUKSKEY="LABEL=TRAVELSTICK:/keys/alienbob.luks"
#ROOTDEV="/dev/sda1"
#ROOTFS="ext4"
#RESUMEDEV="/dev/sda2"
#RAID="0"
#LVM="0"
#UDEV="1"
#MODCONF="0"
#MICROCODE_ARCH="/boot/intel-ucode.cpio"
#WAIT="1"

View file

@ -1,19 +0,0 @@
From bbeb9d73191c1c79f5286fd3b1fdb5611fb11301 Mon Sep 17 00:00:00 2001
From: "Patrick J. Volkerding" <volkerdi@slackware.com>
Date: Sun Apr 26 18:51:23 CDT 2020
Subject: [PATCH] Switch from tempfile to mktemp
Use the standard mktemp utility from GNU coreutils rather than the
lesser-known tempfile utility from Debian of yore.
--- mkinitrd.orig 2019-09-04 23:37:08.000000000 -0500
+++ mkinitrd 2020-04-26 18:46:22.352636100 -0500
@@ -235,7 +235,7 @@
# Then copy all remaining libs our initrd files link against:
COUNT=1
- PRFX=$(tempfile --prefix ldd-)
+ PRFX=$(mktemp --suffix -ldd)
TMPFILE=${PRFX}${COUNT}
find $SOURCE_TREE -type f -exec ldd {} 2>/dev/null \; | unify_libs > $TMPFILE

View file

@ -1,187 +0,0 @@
'\" t
.\" Title: mkinitrd_command_generator
.\" Author: Eric Hameleers
.\" Generator: DocBook XSL Stylesheets v1.78.1 <http://docbook.sf.net/>
.\" Date: 2016-02-07
.\" Manual: Slackware Tools
.\" Source: http://www.slackware.com 1.40
.\" Language: English
.\"
.TH "MKINITRD_COMMAND_GEN" "8" "2016-02-07" "http://www\&.slackware\&.com" "Slackware Tools"
.\" -----------------------------------------------------------------
.\" * Define some portability stuff
.\" -----------------------------------------------------------------
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.\" http://bugs.debian.org/507673
.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.ie \n(.g .ds Aq \(aq
.el .ds Aq '
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.\" -----------------------------------------------------------------
.\" * MAIN CONTENT STARTS HERE *
.\" -----------------------------------------------------------------
.SH "NAME"
mkinitrd_command_generator \- mkinitrd the easy way
.SH "SYNOPSIS"
.sp
.nf
mkinitrd_command_generator\&.sh [ \fIoptions\fR ] [ \fIkernel_filename\fR ]
.fi
.SH "OPTIONS"
.PP
\fB\-a \fR\fB\fIadditional params\fR\fR
.RS 4
Additional parameters to pass to mkinitrd\&.
.RE
.PP
\fB\-c | \-\-conf\fR
.RS 4
Show a suitable mkinitrd configuration file\&.
.RE
.PP
\fB\-h | \-\-help\fR
.RS 4
Show this help\&.
.RE
.PP
\fB\-i | \-\-interactive\fR
.RS 4
Navigate through menus instead of using commandline arguments\&.
.RE
.PP
\fB\-\-longhelp\fR
.RS 4
Show more detailed information/examples\&.
.RE
.PP
\fB\-k \fR\fB\fIkernelversion\fR\fR
.RS 4
Use specific kernel version\&. This may also be a colon-delimited list of kernel versions to use\&.
.RE
.PP
\fB\-m \fR\fB\fIadditional mods\fR\fR
.RS 4
Additional modules to pass to mkinitrd, separated by colons (:)\&.
.RE
.PP
\fB\-l | \-\-lilo\fR
.RS 4
Only show lilo\&.conf section (requires a kernel_filename)\&.
.RE
.PP
\fB\-r | \-\-run\fR
.RS 4
Only show
\fImkinitrd\fR
command\&.
.RE
.SH "DESCRIPTION"
.sp
This script is useful in situations where you require an initrd image to boot your computer\&.
.sp
For instance, when booting a kernel that does not have support for your storage or root filesystem built in (such as the Slackware \fIgeneric\fR kernels)\&.
.sp
When you run the script without parameters, it will examine your running system, your current kernel version and will output an example of a \fImkinitrd\fR commandline that you can use to generate an initrd image containing enough driver support to boot the computer\&.
.sp
You can make it more specific: when you add the filename of a kernel as parameter to the script, it will determine the kernel version from that kernel, and also give an example of the lines that you should add to your \fI/etc/lilo\&.conf\fR file\&.
.sp
If you want your initrd image to have a custom name instead of the default \fI/boot/initrd\&.gz\fR you can add it as another parameter to the script, as follows:
.sp
mkinitrd_command_generator\&.sh \-a "\-o \fI/boot/custom\&.gz\fR"
.sp
The arguments to the \fI\-a\fR parameter will be used as additional arguments to the \fImkinitrd\fR command\&.
.sp
If you need additional modules in the initrd image, apart from what the script determines, you can pass then to the script using the \fI\-m\fR parameter as follows:
.sp
mkinitrd_command_generator\&.sh \-m "uhci\-hcd:usbhid:hid:hid\-generic"
.sp
The above example adds support for USB keyboards to the initrd \- you may need that if you have encrypted your root partition and need to enter a passphrase using a USB keyboard\&.
.sp
Instead of copying and pasting the script\(cqs output, you can create an initrd by directly executing the output, like in this example:
.sp
.if n \{\
.RS 4
.\}
.nf
$(mkinitrd_command_generator\&.sh \-\-run /boot/vmlinuz\-generic\-4\&.4\&.1)
.fi
.if n \{\
.RE
.\}
.sp
That used the \fI\-r\fR or \fI\-\-run\fR switch to make the script only write the \fImkinitrd\fR commandline to the terminal\&.
.sp
When you want to add a section for a specific kernel to \fI/etc/lilo\&.conf\fR directly, use the \fI\-l\fR or \fI\-\-lilo\fR switch and use a command like in this example:
.sp
mkinitrd_command_generator\&.sh \-\-lilo /boot/vmlinuz\-generic\-smp\-4\&.4\&.1 >>/etc/lilo\&.conf
.sp
That command will result in the following lines being added to your \fI/etc/lilo\&.conf\fR file (example for my hardware):
.sp
.if n \{\
.RS 4
.\}
.nf
\fI# Linux bootable partition config begins\fR
\fI# initrd created with \*(Aqmkinitrd \-c \-k 4\&.4\&.1 \-m mbcache:jbd2:ext4 \-f ext4 \-r /dev/sda7 \-u \-o /boot/initrd\&.gz\fR\*(Aq
image = /boot/vmlinuz\-generic\-4\&.4\&.1
initrd = /boot/initrd\&.gz
root = /dev/sda7
label = 4\&.4\&.1
read\-only
\fI# Linux bootable partition config ends\fR
.fi
.if n \{\
.RE
.\}
.sp
The last two examples show how easy it is to configure your computer for the use of an initrd if you need one\&. The only thing left to do afterwards is running \fIlilo\fR\&.
.SH "EXIT STATUS"
.sp
.if n \{\
.RS 4
.\}
.nf
\fB0\fR Success
\fB1\fR Failure
.fi
.if n \{\
.RE
.\}
.SH "FILES"
.sp
.if n \{\
.RS 4
.\}
.nf
/usr/share/mkinitrd/mkinitrd_command_generator\&.sh
.fi
.if n \{\
.RE
.\}
.SH "BUGS"
.sp
Report bugs to Eric Hameleers <alien@slackware\&.com>
.SH "SEE ALSO"
.sp
.if n \{\
.RS 4
.\}
.nf
mkinitrd(1), lilo\&.conf(1)
.fi
.if n \{\
.RE
.\}
.SH "AUTHOR"
.PP
\fBEric Hameleers\fR
.RS 4
Author.
.RE

View file

@ -1,892 +0,0 @@
#!/bin/sh
# $Id: mkinitrd_command_generator.sh,v 1.45 2011/02/17 09:27:05 eha Exp eha $
# Copyright 2013 Patrick J. Volkerding, Sebeka, Minnesota, USA
# Copyright 2008, 2009, 2010, 2011 Eric Hameleers, Eindhoven, Netherlands
# Contact: <alien@slackware.com>
# Copyright 2008, 2009 PiterPUNK, Sao Paulo, SP, Brazil
# Contact: <piterpunk@slackware.com>
# All rights reserved.
#
# Permission to use, copy, modify, and distribute this software for
# any purpose with or without fee is hereby granted, provided that
# the above copyright notice and this permission notice appear in all
# copies.
#
# THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
# IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
# USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
# SUCH DAMAGE.
# -----------------------------------------------------------------------------
#
# Create an initrd which fits the system.
# Take into account the use of LVM/LUKS/RAID.
# Find out about any hardware drivers the system may need in an initrd when
# booting from a generic lightweight kernel.
#
# -----------------------------------------------------------------------------
# The script's revision number will be displayed in the help text:
REV=$( echo "$Revision: 1.45 $" | cut -d' ' -f2 )
# Define some essential parameter values:
USING_LVM=""
USING_LUKS=""
USING_RAID=""
MLIST=""
REALDEV="" # The device that contains the LUKS volume
BASEDEV="" # Lowest level device (raw block device or RAID volume)
FSTAB=${FSTAB:-"/etc/fstab"} # so we can test with alternate fstab files
# These are needed by -c and -i options:
SOURCE_TREE=${SOURCE_TREE:-"/boot/initrd-tree"}
CLEAR_TREE=${CLEAR_TREE:-1}
KEYMAP=${KEYMAP:-"us"}
UDEV=${UDEV:-1}
# ARM devices need more time:
case "$( uname -m )" in
arm*) WAIT_DEFAULT=4;;
*) WAIT_DEFAULT=1;;
esac
WAIT=${WAIT:-$WAIT_DEFAULT}
# A basic explanation of the commandline parameters:
basic_usage() {
cat <<-EOT
*** $(basename $0) revision $REV ***
Usage:
$(basename $0) [ options ] [ kernel_filename ]
Options:
-a <"additional params"> Additional parameters to pass to mkinitrd.
-c | --conf Show a suitable mkinitrd configuration file.
-h | --help Show this help.
-i | --interactive Navigate through menus instead of using
commandline arguments.
--longhelp Show more detailed information/examples.
-k <kernelversion> Use specific kernel version. Or, support
more than one kernel version by passing a
list of versions separated by colons (:).
-m <"additional mods"> Additional modules to pass to mkinitrd,
separated by colons (:).
-l | --lilo Only show lilo.conf section
(requires a kernel_filename).
-r | --run Only show 'mkinitrd' command.
EOT
}
# More of a tutorial here:
extended_usage() {
cat <<-EOT
This script is useful in situations where you require an initrd image
to boot your computer.
For instance, when booting a kernel that does not have support for your
storage or root filesystem built in (such as the Slackware 'generic'
kernels').
* When you run the script without parameters, it will examine your
running system, your current kernel version and will output an example
of a 'mkinitrd' commandline that you can use to generate an initrd
image containing enough driver support to boot the computer.
* You can make it more specific: when you add the filename of a kernel
as parameter to the script, it will determine the kernel version from
that kernel, and also give an example of the lines that you should add
to your '/etc/lilo.conf' file.
* If you want your initrd image to have a custom name instead of the
default '/boot/initrd.gz' you can add it as another parameter to the
script, as follows:
$(basename $0) -a "-o /boot/custom.gz"
The arguments to the '-a' parameter will be used as additional arguments
to the 'mkinitrd' command.
* If you need additional modules in the initrd image, apart from what
the script determines, you can pass then to the script using the '-m'
parameter as follows:
$(basename $0) -m "uhci-hcd:usbhid:hid_generic"
The above example adds support for USB keyboards to the initrd - you
may need that if you have encrypted your root partition and need to
enter a passphrase using a USB keyboard.
* Instead of copying and pasting the script's output, you can create
an initrd by directly executing the output, like in this example:
EOT
echo " \$($(basename $0) --run /boot/vmlinuz-generic-smp-2.6.35.11-smp)"
cat <<-EOT
That used the '-r' or '--run' switch to make the script only write
the 'mkinitrd' commandline to the terminal.
* When you want to add a section for a specific kernel to
'/etc/lilo.conf' directly, use the '-l' or '--lilo' switch and use a
command like in this example:
EOT
echo " $(basename $0) --lilo /boot/vmlinuz-generic-smp-2.6.35.11-smp >>/etc/lilo.conf"
cat <<-EOT
That command will result in the following lines being added to your
'/etc/lilo.conf' file (example for my hardware):
# Linux bootable partition config begins
# initrd created with 'mkinitrd -c -k 2.6.35.11-smp -m ata_generic:pata_amd:mbcache:jbd:ext3 -f ext3 -r /dev/hda7'
image = /boot/vmlinuz-generic-smp-2.6.35.11-smp
initrd = /boot/initrd.gz
root = /dev/hda7
label = 2.6.35.11-smp
read-only
# Linux bootable partition config ends
The last two examples show how easy it is to configure your computer
for the use of an initrd if you need one. The only thing left to do
afterwards is running 'lilo'.
EOT
}
# Find the device that holds the root partition:
get_root_device() {
if [ -e $FSTAB ]; then
RD=$(cat $FSTAB |tr '\t' ' ' |grep -v '^ *#' |tr -s ' ' |grep ' / ' |cut -f1 -d' ')
if [ "$(echo $RD | cut -f1 -d=)" = "LABEL" -o "$(echo $RD | cut -f1 -d=)" = "UUID" -o "$(echo $RD | cut -f1 -d=)" = "PARTUUID" ]; then
DKEY=$(echo $RD | cut -f1 -d=)
# The value can be LABEL=foo or LABEL='foo' or LABEL="foo"
DVAL=$(echo $RD | cut -f2 -d= | tr -d "'\042")
RD=$(/sbin/blkid --match-token $DKEY=$DVAL --list-one --output device)
fi
else
RD=$(grep -m1 "^/dev/.*[[:blank:]]/[[:blank:]]" /proc/mounts | cut -f1 -d' ')
fi
echo $RD
}
# Get the root fs information:
get_rootfs_type() {
if $(type blkid 1>/dev/null 2>&1) ; then
blkid -s TYPE -o value $ROOTDEV
elif $(type vol_id 1>/dev/null 2>&1) ; then
vol_id $ROOTDEV | grep ID_FS_TYPE | cut -f2 -d=
else
# As a fallback, use:
cat $FSTAB |tr '\t' ' ' |grep -v '^ *#' |tr -s ' ' |grep ' / ' |cut -f3 -d' '
fi
}
# Add the module(s) needed for the root filesystem:
add_rootfs_module() {
local FSMOD
FSMOD=$(/sbin/modprobe --set-version $KVER --show-depends ${ROOTFS} 2>/dev/null | while read LINE; do
echo $(basename $(echo $LINE | cut -d' ' -f2) .ko )
done)
if [ -n "$FSMOD" ]; then
[ -n "$MLIST" ] && echo "$MLIST:$(echo $FSMOD | tr ' ' ':')" \
|| echo $FSMOD | tr ' ' ':'
fi
}
# Determine the list of kernel modules needed to support the root device:
determine_blockdev_drivers() {
# Walk the /sys tree to find kernel modules that are
# required for our storage devices.
# Thanks to PiterPUNK for help with this code.
local MLIST
MLIST=$(for i in $(find /sys/block/*/ -name "device" -print0 | xargs -0 -i'{}' readlink -f '{}' | sort -u); do
/sbin/udevadm info --query=all --path=$i --attribute-walk | \
sed -ne 's/^[[:blank:]]\+DRIVER[S]*=="\([^"]\+\)"$/\1/p' | \
sed -e 's/^mmcblk$/mmc_block/' | \
xargs -I@ /sbin/modprobe --set-version $KVER --show-depends @ \
2>/dev/null | grep -v "builtin " | \
while read LINE ; do
echo $(basename $(echo $LINE | cut -d' ' -f2) .ko )
done
done)
MLIST=$( echo $MLIST | tr ' ' ':' )
echo $MLIST
}
# Search for USB keyboards:
function add_usb_keyboard() {
local USBMOD
if cat /proc/bus/input/devices | sed -e 's/^$/\$/g' | \
tr "\n$" " \n" | grep -q " Phys=.*usb.* .*Handlers=.*kbd.*B:"; then
USBMOD="xhci-pci:ohci-pci:ehci-pci:xhci-hcd:uhci-hcd:ehci-hcd:hid:usbhid:i2c-hid:hid_generic:hid-asus:hid-cherry:hid-logitech:hid-logitech-dj:hid-logitech-hidpp:hid-lenovo:hid-microsoft:hid_multitouch"
[ -n "$MLIST" ] && MLIST="$MLIST:$USBMOD" \
|| MLIST="$USBMOD"
fi
echo $MLIST
}
# Determine what USB Host Controller is in use
function add_usb_hcd() {
local USBMOD
for i in $(ls -Ld /sys/module/*_hcd/drivers/* 2> /dev/null); do
if ls -L $i | grep -q "[0-9a-f]*:" ; then
USBMOD=$( echo $i | cut -f4 -d/ | tr "_" "-")
[ -n "$MLIST" ] && MLIST="$MLIST:$USBMOD" \
|| MLIST="$USBMOD"
fi
done
echo $MLIST
}
# Is the root partition on a (combination of) LVM/LUKS volume?
check_luks_lvm_raid() {
if $( lvdisplay -c $ROOTDEV 1>/dev/null 2>/dev/null ); then
# Our root partition is on a LV:
USING_LVM=1
# Search the Physical Volume of our Logical Volume:
MYVG=$( echo $(lvdisplay -c $ROOTDEV 2>/dev/null) | cut -d: -f2 )
for LINE in $(pvdisplay -c) ; do
VG=$(echo $LINE | cut -d: -f2)
[ "$VG" = "$MYVG" ] && break
done
PV=$(echo $LINE | cut -d: -f1)
# Check if there is a LUKS device underneath:
if $( cryptsetup status $PV 1>/dev/null 2>/dev/null ) ; then
# Our root partition's LV is on a LUKS volume:
USING_LUKS=1
REALDEV=$( cryptsetup status $PV | grep 'device: ' | tr -d ' ' | cut -d: -f2 )
BASEDEV=$REALDEV
else
BASEDEV=$PV
fi
elif $( cryptsetup status $ROOTDEV 1>/dev/null 2>/dev/null ) ; then
# Our root device is on a LUKS volume:
USING_LUKS=1
REALDEV=$( cryptsetup status $ROOTDEV | grep 'device: ' | tr -d ' ' | cut -d: -f2 )
ROOTDEV=$(basename $ROOTDEV)
# Check for LVM:
for LV in $(lvdisplay -c 2>/dev/null | tr -d ' ' | cut -f1 -d:) ; do
# Note: cryptsetup shows the real device, whereas
# lvdisplay requires the /dev/<myvg>/... symlink to the real device.
if [ "$(readlink $LV)" = "$REALDEV" ]; then
REALDEV=$LV
break
fi
done
if $( lvdisplay -c $REALDEV 1>/dev/null 2>/dev/null ); then
# Our root partition's LUKS device is on a LV:
USING_LVM=1
# Search the Physical Volume of our Logical Volume:
MYVG=$( echo $(lvdisplay -c $REALDEV 2>/dev/null) | cut -d: -f2 )
for LINE in $(pvdisplay -c) ; do
VG=$(echo $LINE | cut -d: -f2)
[ "$VG" = "$MYVG" ] && break
done
PV=$(echo $LINE | cut -d: -f1)
BASEDEV=$PV
else
BASEDEV=$REALDEV
fi
else
BASEDEV=$ROOTDEV
fi
# Finally, we should check if base device is
# a real block device or a RAID volume:
for MD in $(cat /proc/mdstat | grep -w active | cut -d' ' -f1) ; do
if [ "$BASEDEV" = "/dev/$MD" ]; then
USING_RAID=1
break
fi
done
}
# Before we start
[ -x /bin/id ] && CMD_ID="/bin/id" || CMD_ID="/usr/bin/id"
if [ "$($CMD_ID -u)" != "0" ]; then
echo "You need to be root to run $(basename $0)."
exit 1
fi
# Parse the commandline parameters:
while [ ! -z "$1" ]; do
case $1 in
--longhelp)
basic_usage
extended_usage
exit 0
;;
-a)
MKINIT_PARAMS="$2"
shift 2
;;
-c|--conf)
[ -n "$EMIT" ] && { echo "Do not mix incompatible parameters!"; exit 1; }
EMIT="conf"
shift
;;
-h|--help)
basic_usage
exit 0
;;
-i|--interactive)
INTERACTIVE=1
shift
;;
-k)
if [ "$2" = "" ]; then
echo "Error: -k requires a kernel version."
exit 1
fi
KVERLIST=$2
shift 2
;;
-m)
MKINIT_MODS=$2
shift 2
;;
-l|--lilo)
[ -n "$EMIT" ] && { echo "Do not mix incompatible parameters!"; exit 1; }
EMIT="lilo"
shift
;;
-L|--fromlilo)
FROMLILO=1
shift
;;
-r|--run)
[ -n "$EMIT" ] && { echo "Do not mix incompatible parameters!"; exit 1; }
EMIT="run"
shift
;;
-R|--rootdev)
ROOTDEV=$2
shift 2
;;
-*)
echo "Unsupported parameter '$1'!"
exit 1
;;
*) # Everything else but switches (which start with '-') follows:
if [ -f $1 ]; then
KFILE=$1
# Construction of KFILE's full filename:
KFILEPATH=$(cd $(dirname $KFILE) && pwd)
if [ -L $KFILE ]; then
KFILE=$(readlink $KFILE)
else
KFILE=$(basename $KFILE)
fi
KFILE=${KFILEPATH}/$KFILE
if [ -z "$(file $KFILE | grep -E 'Linux kernel x86 boot|x86 boot sector')" ]; then
echo "File '$KFILE' does not look like it is a kernel file!"
exit 1
fi
else
echo "File $1 not found!"
exit 1
fi
shift
;;
esac
done
# Determine what to show as output (other options may have set EMIT already)
EMIT=${EMIT:-"all"}
# An EMIT value of 'lilo' requires a kernel filename as script parameter:
if [ "$EMIT" = "lilo" ]; then
if [ -z "$KFILE" ]; then
echo "A kernel_filename is required with the '-l|--lilo' option!"
exit 1
fi
fi
# Determine kernel version to use,
# and check if modules for this kernel are actually present:
if [ ! -z $KVERLIST ]; then
for kernel_version in $(echo $KVERLIST | tr ":" "\n") ; do
KVER=$kernel_version
if [ ! -d /lib/modules/$KVER ]; then
echo "Modules for kernel $KVER aren't installed."
exit 1
fi
done
fi
if [ -z "$KVER" ]; then
if [ -n "$KFILE" ]; then
KVER="$(strings $KFILE | grep '([^ ]*@[^ ]*) #' | cut -f1 -d' ')"
else
KVER="$(uname -r)"
fi
fi
if [ ! -d /lib/modules/$KVER ]; then
echo "Modules for kernel $KVER aren't installed."
exit 1
fi
# Determine whether the user passed an alternate filename for the initrd:
if [ -n "$MKINIT_PARAMS" ]; then
SRCHLIST="$MKINIT_PARAMS"
for ELEM in $MKINIT_PARAMS ; do
SRCHLIST=$(echo $SRCHLIST | cut -d' ' -f2-) # cut ELEM from the list
if [ "$ELEM" = "-o" ]; then
IMGFILE=$(echo $SRCHLIST | cut -d' ' -f1)
break
fi
done
fi
IMGFILE=${IMGFILE:-"/boot/initrd.gz"}
# Get information about the root device / root filesystem:
ROOTDEV=${ROOTDEV:-$(get_root_device)}
ROOTFS=$(get_rootfs_type)
# Determine the list of kernel modules needed to support the root device:
MLIST=$(determine_blockdev_drivers)
# Check if we are running in a kvm guest with virtio block device driver
# (add all virtio modules, we sort out the doubles later):
if echo $MLIST | grep -q "virtio"; then
MLIST="$MLIST:virtio:virtio_balloon:virtio_blk:virtio_ring:virtio_pci:virtio_net"
fi
# Determine if a USB keyboard is in use and include usbhid and hid_generic
# to module list
MLIST=$(add_usb_keyboard)
# If we use any USB module, try to determine the Host Controller
if echo $MLIST | grep -q "usb"; then
MLIST=$(add_usb_hcd)
fi
# Check what combination of LUKS/LVM/RAID we have to support:
# This sets values for USING_LUKS, USING_LVM, USING_RAID, REALDEV and BASEDEV.
check_luks_lvm_raid
# This is the interactive part:
if [ "$INTERACTIVE" = "1" ]; then
if [ "$FROMLILO" != "1" ]; then
dialog --stdout --title "WELCOME TO MKINITRD COMMAND GENERATOR" --msgbox "\
The main goal of this utility is to create a good initrd to \
fit your needs. It can detect what kernel you are running, \
what is your root device, root filesystem, if you use encryption, \
LVM, RAID, etc. \
\n\n\
Usually the probed values are OK and they will be the \
defaults in all subsequent dialogs, but maybe you want \
to change something. \n\
If in doubt, leave the defaults." 0 0
KVER=$( ls -d1 --indicator-style=none /lib/modules/* | \
awk -F/ -vVER=$KVER '{
if ( VER == $NF ) {
ONOFF="on"
} else {
ONOFF="off"
} ; printf("%s \"\" %s\n",$NF,ONOFF) }' | \
xargs dialog --stdout --title "CHOOSE KERNEL VERSION" \
--default-item $KVER --radiolist "\
Please, select the kernel version you want to create this initrd for." 0 0 4 )
[ -z "$KVER" ] && exit 1
OLDROOTDEV=$ROOTDEV
ROOTDEV=$( dialog --stdout --title "SELECT ROOT DEVICE" --inputbox "\
Enter your root device. Root device is the one where your '/' filesystem \
is mounted." 0 0 "$ROOTDEV" )
[ -z "$ROOTDEV" ] && exit 1
# We need to re-check our defaults in case the user changed the default
# value for ROOTDEV:
[ "$OLDROOTDEV" != "$ROOTDEV" ] && check_luks_lvm_raid
ROOTFS=$(get_rootfs_type)
ROOTFS=$( dialog --stdout --title "SELECT ROOT FILESYSTEM" --inputbox "\
Enter the type of your root filesystem." 0 0 "$ROOTFS" )
[ -z "$ROOTFS" ] && exit 1
fi
MLIST=$(add_rootfs_module)
LLR=$( dialog --stdout --title "LVM/LUKS/RAID" --checklist "\
Do you use some of those in your root filesystem? \
If this is the case, please select one or more options." 12 45 3 \
"LVM" "Logical Volume Manager" $([ "$USING_LVM" = "1" ] && echo on || echo off) \
"LUKS" "Linux Unified Key Setup" $([ "$USING_LUKS" = "1" ] && echo on || echo off) \
"RAID" "Linux Software RAID" $([ "$USING_RAID" = "1" ] && echo on || echo off))
if [ "$?" != "0" ]; then
exit 1
fi
echo $LLR | grep -q LUKS && USING_LUKS="1"
echo $LLR | grep -q LVM && USING_LVM="1"
echo $LLR | grep -q RAID && USING_RAID="1"
if [ "$USING_LUKS" = "1" ]; then
REALDEV=$( dialog --stdout --title "LUKS ROOT DEVICE" --inputbox "\
Please, enter your LUKS root device:" 0 0 "$REALDEV" )
[ -z "$REALDEV" ] && exit 1
fi
fi
# Step out of the interactive loop for a moment. The next block needs to be
# executed in all cases.
# We need to 'undouble' the MLIST array. Some people report that walking the
# /sys tree produces duplicate modules in the list.
# The awk command elimitates doubles without changing the order:
MLIST=$( echo $MLIST | tr ':' '\n' | awk '!x[$0]++' | tr '\n' ' ' )
MLIST=$( echo $MLIST | tr ' ' ':' )
MLIST=$(echo ${MLIST%:}) # To weed out a trailing ':' which was reported once.
# Back to the interactive part:
if [ "$INTERACTIVE" = "1" ]; then
MLIST=$( dialog --stdout --title "INITRD'S MODULE LIST" --inputbox "\
The list here shows all modules needed to support your root filesystem \
and boot from it. But you can change the list to use some alternative \
or additional modules. If you don't know what to do, the default is safe." \
0 0 "$MLIST" )
if [ "$?" != "0" ]; then
exit 1
fi
EXTRA=$( dialog --stdout --title "EXTRA CONFIGURATION" --checklist "\
Now is your chance for some additional configuration. All of these \
configurations are optional and you can stick to the defaults." 11 72 3 \
"KEYMAP" "Select keyboard layout (default: US)" \
$([ $USING_LUKS = 1 ] && echo on || echo off) \
"RESUMEDEV" "Select device for 'suspend-to-disk' feature" off \
"UDEV" "Use UDEV in the initrd for device configuration" $(test $UDEV -eq 1 && echo on || echo off) \
"WAIT" "Add delay to allow detection of slow disks at boot" $(test $WAIT -gt $WAIT_DEFAULT && echo on || echo off) )
if [ "$?" != "0" ]; then
exit 1
fi
if echo $EXTRA | grep -q KEYMAP ; then
KEYMAP=$( dialog --stdout --title "KEYBOARD LAYOUT SELECTION" \
--cancel-label "Skip" \
--menu "You may select one of the following keyboard layouts. \
If you do not select a keyboard map, 'us.map' \
(the US keyboard layout) is the default. Use the UP/DOWN \
arrow keys and PageUp/PageDown to scroll \
through the whole list of choices." \
22 55 11 \
"qwerty/us.map" "" \
"azerty/azerty.map" "" \
"azerty/be-latin1.map" "" \
"azerty/fr-latin0.map" "" \
"azerty/fr-latin1.map" "" \
"azerty/fr-latin9.map" "" \
"azerty/fr-old.map" "" \
"azerty/fr-pc.map" "" \
"azerty/fr.map" "" \
"azerty/wangbe.map" "" \
"azerty/wangbe2.map" "" \
"dvorak/ANSI-dvorak.map" "" \
"dvorak/dvorak-l.map" "" \
"dvorak/dvorak-r.map" "" \
"dvorak/dvorak.map" "" \
"dvorak/no-dvorak.map" "" \
"fgGIod/tr_f-latin5.map" "" \
"fgGIod/trf-fgGIod.map" "" \
"olpc/es-olpc.map" "" \
"olpc/pt-olpc.map" "" \
"qwerty/bg-cp1251.map" "" \
"qwerty/bg-cp855.map" "" \
"qwerty/bg_bds-cp1251.map" "" \
"qwerty/bg_bds-utf8.map" "" \
"qwerty/bg_pho-cp1251.map" "" \
"qwerty/bg_pho-utf8.map" "" \
"qwerty/br-abnt.map" "" \
"qwerty/br-abnt2.map" "" \
"qwerty/br-latin1-abnt2.map" "" \
"qwerty/br-latin1-us.map" "" \
"qwerty/by-cp1251.map" "" \
"qwerty/by.map" "" \
"qwerty/bywin-cp1251.map" "" \
"qwerty/cf.map" "" \
"qwerty/cz-cp1250.map" "" \
"qwerty/cz-lat2-prog.map" "" \
"qwerty/cz-lat2.map" "" \
"qwerty/cz-qwerty.map" "" \
"qwerty/defkeymap.map" "" \
"qwerty/defkeymap_V1.0.map" "" \
"qwerty/dk-latin1.map" "" \
"qwerty/dk.map" "" \
"qwerty/emacs.map" "" \
"qwerty/emacs2.map" "" \
"qwerty/es-cp850.map" "" \
"qwerty/es.map" "" \
"qwerty/et-nodeadkeys.map" "" \
"qwerty/et.map" "" \
"qwerty/fi-latin1.map" "" \
"qwerty/fi-latin9.map" "" \
"qwerty/fi-old.map" "" \
"qwerty/fi.map" "" \
"qwerty/gr-pc.map" "" \
"qwerty/gr.map" "" \
"qwerty/hu101.map" "" \
"qwerty/il-heb.map" "" \
"qwerty/il-phonetic.map" "" \
"qwerty/il.map" "" \
"qwerty/is-latin1-us.map" "" \
"qwerty/is-latin1.map" "" \
"qwerty/it-ibm.map" "" \
"qwerty/it.map" "" \
"qwerty/it2.map" "" \
"qwerty/jp106.map" "" \
"qwerty/kazakh.map" "" \
"qwerty/kyrgyz.map" "" \
"qwerty/la-latin1.map" "" \
"qwerty/lt.baltic.map" "" \
"qwerty/lt.l4.map" "" \
"qwerty/lt.map" "" \
"qwerty/mk-cp1251.map" "" \
"qwerty/mk-utf.map" "" \
"qwerty/mk.map" "" \
"qwerty/mk0.map" "" \
"qwerty/nl.map" "" \
"qwerty/nl2.map" "" \
"qwerty/no-latin1.map" "" \
"qwerty/no.map" "" \
"qwerty/pc110.map" "" \
"qwerty/pl.map" "" \
"qwerty/pl1.map" "" \
"qwerty/pl2.map" "" \
"qwerty/pl3.map" "" \
"qwerty/pl4.map" "" \
"qwerty/pt-latin1.map" "" \
"qwerty/pt-latin9.map" "" \
"qwerty/pt.map" "" \
"qwerty/ro.map" "" \
"qwerty/ro_std.map" "" \
"qwerty/ru-cp1251.map" "" \
"qwerty/ru-ms.map" "" \
"qwerty/ru-yawerty.map" "" \
"qwerty/ru.map" "" \
"qwerty/ru1.map" "" \
"qwerty/ru2.map" "" \
"qwerty/ru3.map" "" \
"qwerty/ru4.map" "" \
"qwerty/ru_win.map" "" \
"qwerty/ruwin_alt-CP1251.map" "" \
"qwerty/ruwin_alt-KOI8-R.map" "" \
"qwerty/ruwin_alt-UTF-8.map" "" \
"qwerty/ruwin_cplk-CP1251.map" "" \
"qwerty/ruwin_cplk-KOI8-R.map" "" \
"qwerty/ruwin_cplk-UTF-8.map" "" \
"qwerty/ruwin_ct_sh-CP1251.map" "" \
"qwerty/ruwin_ct_sh-KOI8-R.map" "" \
"qwerty/ruwin_ct_sh-UTF-8.map" "" \
"qwerty/ruwin_ctrl-CP1251.map" "" \
"qwerty/ruwin_ctrl-KOI8-R.map" "" \
"qwerty/ruwin_ctrl-UTF-8.map" "" \
"qwerty/se-fi-ir209.map" "" \
"qwerty/se-fi-lat6.map" "" \
"qwerty/se-ir209.map" "" \
"qwerty/se-lat6.map" "" \
"qwerty/se-latin1.map" "" \
"qwerty/sk-prog-qwerty.map" "" \
"qwerty/sk-qwerty.map" "" \
"qwerty/speakup-jfw.map" "" \
"qwerty/speakupmap.map" "" \
"qwerty/sr-cy.map" "" \
"qwerty/sv-latin1.map" "" \
"qwerty/tr_q-latin5.map" "" \
"qwerty/tralt.map" "" \
"qwerty/trf.map" "" \
"qwerty/trq.map" "" \
"qwerty/ttwin_alt-UTF-8.map.gz" "" \
"qwerty/ttwin_cplk-UTF-8.map.gz" "" \
"qwerty/ttwin_ct_sh-UTF-8.map.gz" "" \
"qwerty/ttwin_ctrl-UTF-8.map.gz" "" \
"qwerty/ua-cp1251.map.gz" "" \
"qwerty/ua-utf-ws.map" "" \
"qwerty/ua-utf.map" "" \
"qwerty/ua-ws.map" "" \
"qwerty/ua.map" "" \
"qwerty/uk.map" "" \
"qwerty/us-acentos.map" "" \
"qwerty/us.map" "" \
"qwertz/croat.map" "" \
"qwertz/cz-us-qwertz.map" "" \
"qwertz/cz.map" "" \
"qwertz/de-latin1-nodeadkeys.map" "" \
"qwertz/de-latin1.map" "" \
"qwertz/de.map" "" \
"qwertz/de_CH-latin1.map" "" \
"qwertz/fr_CH-latin1.map" "" \
"qwertz/fr_CH.map" "" \
"qwertz/hu.map" "" \
"qwertz/sg-latin1-lk450.map" "" \
"qwertz/sg-latin1.map" "" \
"qwertz/sg.map" "" \
"qwertz/sk-prog-qwertz.map" "" \
"qwertz/sk-qwertz.map" "" \
"qwertz/slovene.map" "" )
[ -n "$KEYMAP" ] && KEYMAP=$(basename $KEYMAP .map)
fi
if echo $EXTRA | grep -q UDEV ; then
UDEV=1
fi
if echo $EXTRA | grep -q RESUMEDEV ; then
# Print information about swap partitions:
FREERAM=$(free -k | grep "^Mem:" | tr -s ' ' | cut -d' ' -f2)
SWPINFO=""
for SWPDEV in $(grep -w swap $FSTAB | cut -d' ' -f1) ; do
SWPINFO="$SWPINFO $SWPDEV Linux swap partition $(fdisk -s $SWPDEV) KB \\n"
[ $(fdisk -s $SWPDEV) -gt $FREERAM ] && RESUMEDEV=$SWPDEV
done
FREERAM=$(free -m | grep "^Mem:" | tr -s ' ' | cut -d' ' -f2)
RESUMEDEV=$( dialog --stdout --no-collapse --title "HIBERNATE RESUME DEVICE" --inputbox "\
When using suspend-to-disk feature (hibernate), your computer's RAM is copied \
to a swap device when it shuts down. The kernel will resume from that RAM \
image at boot. This means that the swap partition must not be smaller than \
the amount of RAM you have ($FREERAM MB). \n\
$SWPINFO \n\
Please specify a swap partition to be used for hibernation:" \
0 0 "$RESUMEDEV")
[ -z "$RESUMEDEV" ] && exit 1
fi
if echo $EXTRA | grep -q WAIT ; then
WAIT=$( dialog --stdout --title "WAIT FOR ROOT DEVICE" --inputbox "\
Some block devices are too slow to be detected properly at boot. USB storage \
devices and some disk arrays have this 'feature'. To make your machine \
boot properly, you can add some delay here, to wait until all your disks are \
probed and detected. The time is in seconds:" 0 0 "$WAIT")
[ -z "$WAIT" ] && exit 1
fi
IMGFILE=$( dialog --stdout --title "INITRD IMAGE NAME" --inputbox "\
Enter your initrd image filename." 0 0 "$IMGFILE" )
[ -z "$IMGFILE" ] && exit 1
else
MLIST=$(add_rootfs_module)
fi
# Add any modules passed along on the commandline:
if [ -n "$MKINIT_MODS" ]; then
[ -n "$MLIST" ] && MLIST="$MLIST:$(echo $MKINIT_MODS | tr ' ' ':')" \
|| MLIST="$(echo $MKINIT_MODS | tr ' ' ':')"
fi
# Constructing the mkinitrd command:
if [ -z $KVERLIST ]; then
MKINIT="mkinitrd -c -k $KVER -f $ROOTFS -r $ROOTDEV"
else
MKINIT="mkinitrd -c -k $KVERLIST -f $ROOTFS -r $ROOTDEV"
fi
# If we have a module list, add them:
if ! [ -z "$MLIST" -o "$MLIST" = ":" ]; then
MKINIT="$MKINIT -m $MLIST"
fi
# Deal with LUKS/LVM/RAID:
if [ "$USING_LUKS" = "1" ]; then
MKINIT="$MKINIT -C $REALDEV"
fi
if [ "$USING_LVM" = "1" ]; then
MKINIT="$MKINIT -L"
fi
if [ "$USING_RAID" = "1" ]; then
MKINIT="$MKINIT -R"
fi
if [ -n "$RESUMEDEV" ]; then
# Add hibernation partition:
MKINIT="$MKINIT -h $RESUMEDEV"
fi
if [ -n "$KEYMAP" -a "$KEYMAP" != "us" ]; then
# Add non-us keyboard mapping:
MKINIT="$MKINIT -l $KEYMAP"
fi
if [ $UDEV -eq 1 ]; then
# Add UDEV support:
MKINIT="$MKINIT -u"
fi
if [ -n "$WAIT" -a $WAIT -ne $WAIT_DEFAULT ]; then
# Add non-default wait time:
MKINIT="$MKINIT -w $WAIT"
fi
if ! echo "$MKINIT_PARAMS" | grep -q -- '-o ' ; then
# Add default output filename:
MKINIT="$MKINIT -o $IMGFILE"
fi
if [ -n "$MKINIT_PARAMS" ]; then
# Add user-supplied additional parameters:
MKINIT="$MKINIT $MKINIT_PARAMS"
fi
# Notify the user:
if [ "$EMIT" = "all" ]; then
cat <<-EOT
#
# $(basename $0) revision $REV
#
# This script will now make a recommendation about the command to use
# in case you require an initrd image to boot a kernel that does not
# have support for your storage or root filesystem built in
# (such as the Slackware 'generic' kernels').
# A suitable 'mkinitrd' command will be:
$MKINIT
EOT
elif [ "$EMIT" = "run" ]; then
echo "$MKINIT"
elif [ "$EMIT" = "conf" ]; then
cat <<-EOT
SOURCE_TREE="$SOURCE_TREE"
CLEAR_TREE="$CLEAR_TREE"
OUTPUT_IMAGE="$IMGFILE"
KERNEL_VERSION="$KVER"
KEYMAP="$KEYMAP"
MODULE_LIST="$(echo $MLIST | cut -f2 -d\ )"
LUKSDEV="$REALDEV"
ROOTDEV="$ROOTDEV"
ROOTFS="$ROOTFS"
RESUMEDEV="$RESUMEDEV"
RAID="$USING_RAID"
LVM="$USING_LVM"
UDEV="$UDEV"
WAIT="$WAIT"
EOT
fi
if [ -n "$KFILE" ]; then
if [ "$EMIT" = "all" ]; then
cat <<-EOT
# An entry in 'etc/lilo.conf' for kernel '$KFILE' would look like this:
EOT
fi
if [ "$EMIT" = "all" -o "$EMIT" = "lilo" ]; then
# Compensate for the syntax used for the LUKS-on-LVM case:
[ "$(basename $ROOTDEV)" = "$ROOTDEV" ] && BASE="/dev/mapper/" || BASE=""
cat <<-EOT
# Linux bootable partition config begins
# initrd created with '$MKINIT'
image = $KFILE
initrd = $IMGFILE
root = $BASE$ROOTDEV
label = $KVER
read-only
# Linux bootable partition config ends
EOT
fi
fi

View file

@ -1,51 +0,0 @@
#!/bin/sh
#BLURB="Generate /boot/initrd.gz for the generic kernel"
# Load defaults:
if [ -r etc/default/geninitrd ]; then
. etc/default/geninitrd
fi
if [ -z "$KERNEL_SYMLINK" ]; then
KERNEL_SYMLINK="boot/vmlinuz-generic"
elif [ "$(echo $KERNEL_SYMLINK | cut -b 1)" = "/" ]; then # trim to make a relative path
KERNEL_SYMLINK="$(echo $KERNEL_SYMLINK | cut -b 2-)"
fi
# Find the kernel version:
if [ -r $KERNEL_SYMLINK ]; then
KERNEL_VERSION=$(strings $KERNEL_SYMLINK | grep '([^ ]*@[^ ]*) #' | cut -f1 -d' ')
fi
# Assume the kernel "name" aka flavor is just the second part of the symlink name:
KERNEL_NAME="$(echo $KERNEL_SYMLINK | rev | cut -f 1 -d - | rev)"
# Sometimes mkinitrd_command_generator.sh does not detect LVM properly. Until I
# get to the bottom of that, it's safer to just always include LVM support.
LVM_OPTION="-L"
# Generate the initrd:
if [ ! -z $KERNEL_VERSION ]; then
dialog --title "GENERATING INITIAL RAMDISK" --infobox \
"Generating an initial ramdisk for use with the $KERNEL_VERSION kernel. \
The initial ramdisk contains kernel modules needed to mount the \
root partition, and must be regenerated whenever the kernel is updated. To \
regenerate the initrd, select this setup script from within pkgtool, or run \
'geninitrd' which will produce an initial ramdisk (/boot/initrd.gz) for the \
installed kernel." 8 70
chroot . /usr/share/mkinitrd/mkinitrd_command_generator.sh -k $KERNEL_VERSION -a "$LVM_OPTION -o /boot/initrd-${KERNEL_VERSION}-${KERNEL_NAME}.img" | chroot . bash 1> /dev/null 2> /dev/null
fi
if [ "$GENINITRD_NAMED_SYMLINK" = "true" ]; then
( cd boot
rm -f initrd-${KERNEL_NAME}.img
ln -sf initrd-${KERNEL_VERSION}-${KERNEL_NAME}.img initrd-${KERNEL_NAME}.img
)
fi
if [ "$GENINITRD_INITRD_GZ_SYMLINK" = "true" ]; then
( cd boot
rm -f initrd.gz
ln -sf initrd-${KERNEL_VERSION}-${KERNEL_NAME}.img initrd.gz
)
fi

View file

@ -1,19 +0,0 @@
# HOW TO EDIT THIS FILE:
# The "handy ruler" below makes it easier to edit a package description. Line
# up the first '|' above the ':' following the base package name, and the '|' on
# the right side marks the last column you can put a character in. You must make
# exactly 11 lines for the formatting to be correct. It's also customary to
# leave one space after the ':'.
|-----handy-ruler------------------------------------------------------|
mkinitrd: mkinitrd (make an initial ramdisk)
mkinitrd:
mkinitrd: mkinitrd is a script to create an initial ramdisk that is loaded at
mkinitrd: the same time as the kernel. The initial ramdisk may be responsible
mkinitrd: for loading kernel modules (such a filesystem or SCSI controller
mkinitrd: module) that are needed to mount the root filesystem.
mkinitrd:
mkinitrd: The "initrd" is implemented as an initramfs. See the kernel
mkinitrd: documentation for more information on this, if you are interested.
mkinitrd:
mkinitrd: