Import Debian version 20170213
live-build (1:20170213) unstable; urgency=medium
* Drop the versatile kernel flavour on armel. It's no longer built since
Linux 4.9.
live-build (1:20161216) unstable; urgency=medium
* Cleanup binary_loopback_cfg and offer more freedom in overriding
the default grub-pc configuration.
* Update the manual page with the missiong --bootappend-live-failsafe
option.
* Keep supporting the former --bootloader (without s).
live-build (1:20161202) unstable; urgency=medium
[ Raphaël Hertzog ]
* Officially adopt the package. Closes: #808048
* Better handle empty package lists.
* Drop ixp4xx from available armel flavors, the image has been gone since
linux 3.17.
* Add symlinks for libgpl.c32 and libmenu.c32 which are required by
the "Hardware Detection Tool (HDT)" menu entry that live-build adds
in the advanced menu.
* Add EFI boot support with grub-efi, thanks to Adrian Gibanel Lopez.
Closes: #731709
* Fix usage of config/packages.chroot/*.deb that has been broken by the
switch to GnuPG2 by default by no longer using GnuPG but relying
on APT's trusted=yes attribute instead.
Thus we no longer have remaining key in /etc/apt/trusted.gpg
after building. Closes: #816204
* Try to reuse /isolinux/splash.png in default grub configuration.
* Drop debian/source/{local-options,options} as they are no longer needed.
* Pass components to debootstrap --second-stage. Closes: #806782
Thanks to Sjoerd Simons <[email protected]> for the patch.
* Fix behaviour of (undocumented) "#nif" conditional test. Closes: #801379
Thanks to Erik Cumps <[email protected]> for the patch.
* Export SOURCE_DATE_EPOCH when running chroot commands. Closes: #832998
Thanks to Chris Lamb <[email protected]> for the patch.
* Set xorriso's "modification time" to SOURCE_DATE_EPOCH. Closes: #831379
Thanks to Chris Lamb <[email protected]> for the patch.
* Support “lb config --debootstrap-script <script>” to use an alternate
bootstrap script when running debootstrap. Thanks to Sjoerd Simons
<[email protected]> for the initial patch. Closes: #790033
* Manual pages updates by jnqnfe. Closes: #774730
* Drop left-over translation files for removed lb_testroot command.
* Get rid of useless bootstrap_archive-keys script. Closes: #773775
* Drop an optimization in chroot_archives that has undesired side-effects.
Thanks to jnqnfe for the patch. Closes: #775989
* Drop gpgv and debian-keyring from Suggests.
* Fix Check_installed function when checking against host. Thanks to jnqnfe
for the report. Closes: #774807
* Bump debhelper compat level to 10.
* Bump Standards-Version to 3.9.8.
* Use a grub theme that integrates reasonably well with the current
background picture.
* Default for LB_UNION_FILESYSTEM is now "overlay" just like in live-boot.
* Update the way we generate the version of live-build that is displayed by
lb --version.
* Instead of renaming kernel for syslinux, create hardlinks.
* Simplify grub configuration code to use only long kernel names. Put
advanced options in a submenu. Use distro-agnostic labels.
[ Kristian Klausen ]
* Include ext{3,4} journal size when calculating image size. Closes: #801712
* Switch d-i.debian.org URIs from http to https. Closes: #809699
* Fix typo in binary_syslinux. Closes: #818916
* Correct syslinux/extlinux mbr.bin path. Closes: #773833
Raphaël Hertzog
7 years ago
39 | 39 | install: |
40 | 40 | # Installing shared data |
41 | 41 | mkdir -p $(DESTDIR)/usr/share/live/build |
42 | cp -r data functions VERSION $(DESTDIR)/usr/share/live/build | |
42 | cp -r data functions $(DESTDIR)/usr/share/live/build | |
43 | sed -e 's/.*(\(.*\)).*/\1/; q' debian/changelog >$(DESTDIR)/usr/share/live/build/VERSION | |
43 | 44 | cp -r share/* $(DESTDIR)/usr/share/live/build |
44 | 45 | |
45 | 46 | # Installing executables |
0 | live-build (1:20170213) unstable; urgency=medium | |
1 | ||
2 | * Drop the versatile kernel flavour on armel. It's no longer built since | |
3 | Linux 4.9. | |
4 | ||
5 | -- Raphaël Hertzog <[email protected]> Mon, 13 Feb 2017 16:58:00 +0100 | |
6 | ||
7 | live-build (1:20161216) unstable; urgency=medium | |
8 | ||
9 | * Cleanup binary_loopback_cfg and offer more freedom in overriding | |
10 | the default grub-pc configuration. | |
11 | * Update the manual page with the missiong --bootappend-live-failsafe | |
12 | option. | |
13 | * Keep supporting the former --bootloader (without s). | |
14 | ||
15 | -- Raphaël Hertzog <[email protected]> Fri, 16 Dec 2016 10:05:26 +0100 | |
16 | ||
17 | live-build (1:20161202) unstable; urgency=medium | |
18 | ||
19 | [ Raphaël Hertzog ] | |
20 | * Officially adopt the package. Closes: #808048 | |
21 | * Better handle empty package lists. | |
22 | * Drop ixp4xx from available armel flavors, the image has been gone since | |
23 | linux 3.17. | |
24 | * Add symlinks for libgpl.c32 and libmenu.c32 which are required by | |
25 | the "Hardware Detection Tool (HDT)" menu entry that live-build adds | |
26 | in the advanced menu. | |
27 | * Add EFI boot support with grub-efi, thanks to Adrian Gibanel Lopez. | |
28 | Closes: #731709 | |
29 | * Fix usage of config/packages.chroot/*.deb that has been broken by the | |
30 | switch to GnuPG2 by default by no longer using GnuPG but relying | |
31 | on APT's trusted=yes attribute instead. | |
32 | Thus we no longer have remaining key in /etc/apt/trusted.gpg | |
33 | after building. Closes: #816204 | |
34 | * Try to reuse /isolinux/splash.png in default grub configuration. | |
35 | * Drop debian/source/{local-options,options} as they are no longer needed. | |
36 | * Pass components to debootstrap --second-stage. Closes: #806782 | |
37 | Thanks to Sjoerd Simons <[email protected]> for the patch. | |
38 | * Fix behaviour of (undocumented) "#nif" conditional test. Closes: #801379 | |
39 | Thanks to Erik Cumps <[email protected]> for the patch. | |
40 | * Export SOURCE_DATE_EPOCH when running chroot commands. Closes: #832998 | |
41 | Thanks to Chris Lamb <[email protected]> for the patch. | |
42 | * Set xorriso's "modification time" to SOURCE_DATE_EPOCH. Closes: #831379 | |
43 | Thanks to Chris Lamb <[email protected]> for the patch. | |
44 | * Support “lb config --debootstrap-script <script>” to use an alternate | |
45 | bootstrap script when running debootstrap. Thanks to Sjoerd Simons | |
46 | <[email protected]> for the initial patch. Closes: #790033 | |
47 | * Manual pages updates by jnqnfe. Closes: #774730 | |
48 | * Drop left-over translation files for removed lb_testroot command. | |
49 | * Get rid of useless bootstrap_archive-keys script. Closes: #773775 | |
50 | * Drop an optimization in chroot_archives that has undesired side-effects. | |
51 | Thanks to jnqnfe for the patch. Closes: #775989 | |
52 | * Drop gpgv and debian-keyring from Suggests. | |
53 | * Fix Check_installed function when checking against host. Thanks to jnqnfe | |
54 | for the report. Closes: #774807 | |
55 | * Bump debhelper compat level to 10. | |
56 | * Bump Standards-Version to 3.9.8. | |
57 | * Use a grub theme that integrates reasonably well with the current | |
58 | background picture. | |
59 | * Default for LB_UNION_FILESYSTEM is now "overlay" just like in live-boot. | |
60 | * Update the way we generate the version of live-build that is displayed by | |
61 | lb --version. | |
62 | * Instead of renaming kernel for syslinux, create hardlinks. | |
63 | * Simplify grub configuration code to use only long kernel names. Put | |
64 | advanced options in a submenu. Use distro-agnostic labels. | |
65 | ||
66 | [ Kristian Klausen ] | |
67 | * Include ext{3,4} journal size when calculating image size. Closes: #801712 | |
68 | * Switch d-i.debian.org URIs from http to https. Closes: #809699 | |
69 | * Fix typo in binary_syslinux. Closes: #818916 | |
70 | * Correct syslinux/extlinux mbr.bin path. Closes: #773833 | |
71 | ||
72 | -- Raphaël Hertzog <[email protected]> Fri, 02 Dec 2016 23:33:45 +0100 | |
73 | ||
0 | 74 | live-build (1:20151215) unstable; urgency=medium |
1 | 75 | |
2 | 76 | * QA Upload. |
0 | 0 | Source: live-build |
1 | 1 | Section: misc |
2 | 2 | Priority: optional |
3 | Maintainer: Debian QA Group <[email protected]> | |
3 | Maintainer: Debian Live <[email protected]> | |
4 | Uploaders: Raphaël Hertzog <[email protected]> | |
4 | 5 | Build-Depends: |
5 | debhelper (>= 9), | |
6 | Standards-Version: 3.9.6 | |
6 | debhelper (>= 10), | |
7 | Standards-Version: 3.9.8 | |
7 | 8 | Homepage: https://debian-live.alioth.debian.org/live-build/ |
8 | 9 | Vcs-Browser: https://anonscm.debian.org/cgit/debian-live/live-build.git |
9 | 10 | Vcs-Git: https://anonscm.debian.org/git/debian-live/live-build.git |
20 | 21 | live-config-doc, |
21 | 22 | live-manual-html | live-manual, |
22 | 23 | wget, |
23 | Suggests: | |
24 | debian-keyring, | |
25 | gpgv, | |
26 | 24 | Description: Live System Build Components |
27 | 25 | The Live Systems project maintains the components to build Debian based Live |
28 | 26 | systems and the official Debian Live images themselves. |
0 | 0 | #!/usr/bin/make -f |
1 | 1 | |
2 | include /usr/share/dpkg/pkg-info.mk | |
3 | ||
2 | 4 | %: |
3 | dh ${@} --parallel | |
5 | dh $@ | |
4 | 6 | |
5 | 7 | override_dh_auto_install: |
6 | 8 | dh_auto_install -- DESTDIR=debian/live-build |
7 | 9 | |
10 | # Update VERSION file | |
11 | echo $(DEB_VERSION) >debian/live-build/usr/share/live/build/VERSION | |
12 | ||
8 | 13 | # Removing unused files |
9 | 14 | rm -f debian/live-build/usr/share/doc/live-build/COPYING |
10 | 15 | |
11 | override_dh_builddeb: | |
12 | dh_builddeb -- -Zxz | |
13 | ||
14 | 16 | override_dh_link: |
15 | dh_link | |
16 | ||
17 | # workaround dh_link convertion of absolute symlinks to relvative symlinks | |
18 | rm -rf debian/live-build/usr/share/live/build/bootloaders | |
19 | cp -a share/bootloaders debian/live-build/usr/share/live/build/bootloaders | |
17 | # workaround dh_link conversion of absolute symlinks to relative symlinks | |
18 | dh_link -X.c32 -Xisolinux.bin -Xpxelinux.0 |
0 | # Ignore those errors, it's not nice but works currently | |
1 | source-contains-unsafe-symlink share/bootloaders/* |
0 | #!/bin/sh | |
1 | ||
2 | ## live-build(7) - System Build Scripts | |
3 | ## Copyright (C) 2016 Adrian Gibanel Lopez <[email protected]> | |
4 | ## | |
5 | ## This program comes with ABSOLUTELY NO WARRANTY; for details see COPYING. | |
6 | ## This is free software, and you are welcome to redistribute it | |
7 | ## under certain conditions; see COPYING for details. | |
8 | ||
9 | Is_First_Bootloader () | |
10 | { | |
11 | EVAL_FIRST_BOOTLOADER="${1}" | |
12 | ||
13 | if [ "${LB_FIRST_BOOTLOADER}" = "${EVAL_FIRST_BOOTLOADER}" ] | |
14 | then | |
15 | return 0 | |
16 | else | |
17 | return 1 | |
18 | fi | |
19 | ||
20 | } | |
21 | ||
22 | Is_Bootloader () | |
23 | { | |
24 | EVAL_BOOTLOADER="${1}" | |
25 | OLDIFS="$IFS" | |
26 | IFS="," | |
27 | for BOOTLOADER in ${LB_BOOTLOADERS} | |
28 | do | |
29 | if [ "${BOOTLOADER}" = "${EVAL_BOOTLOADER}" ] | |
30 | then | |
31 | IFS="$OLDIFS" | |
32 | return 0 | |
33 | fi | |
34 | done | |
35 | IFS="$OLDIFS" | |
36 | return 1 | |
37 | } | |
38 | ||
39 | Is_Extra_Bootloader () | |
40 | { | |
41 | EVAL_EXTRA_BOOTLOADER="${1}" | |
42 | ||
43 | if Is_First_Bootloader "${EVAL_EXTRA_BOOTLOADER}" | |
44 | then | |
45 | return 1 | |
46 | else | |
47 | if Is_Bootloader "${EVAL_EXTRA_BOOTLOADER}" | |
48 | then | |
49 | return 0 | |
50 | fi | |
51 | fi | |
52 | return 1 | |
53 | ||
54 | } | |
55 | ||
56 | Check_Non_First_Bootloader () | |
57 | { | |
58 | NON_FIRST_BOOTLOADER="${1}" | |
59 | ||
60 | if Is_First_Bootloader "${NON_FIRST_BOOTLOADER}" | |
61 | then | |
62 | Echo_error "Bootloader: ${NON_FIRST_BOOTLOADER} not supported as a first bootloader." | |
63 | exit 1 | |
64 | else | |
65 | return 0 | |
66 | fi | |
67 | } | |
68 | ||
69 | ||
70 | Check_Non_Extra_Bootloader () | |
71 | { | |
72 | NON_EXTRA_BOOTLOADER="${1}" | |
73 | ||
74 | if Is_Extra_Bootloader "${NON_EXTRA_BOOTLOADER}" | |
75 | then | |
76 | Echo_error "Bootloader: ${NON_EXTRA_BOOTLOADER} not supported as a extra bootloader." | |
77 | exit 1 | |
78 | else | |
79 | return 0 | |
80 | fi | |
81 | } | |
82 | ||
83 | Check_First_Bootloader_Role () | |
84 | { | |
85 | FIRST_BOOTLOADER_ROLE="${1}" | |
86 | Check_Non_Extra_Bootloader "${FIRST_BOOTLOADER_ROLE}" | |
87 | ||
88 | if Is_First_Bootloader "${FIRST_BOOTLOADER_ROLE}" | |
89 | then | |
90 | return 0 | |
91 | else | |
92 | exit 0 | |
93 | fi | |
94 | ||
95 | } | |
96 | ||
97 | Check_Extra_Bootloader_Role () | |
98 | { | |
99 | EXTRA_BOOTLOADER_ROLE="${1}" | |
100 | Check_Non_First_Bootloader "${EXTRA_BOOTLOADER_ROLE}" | |
101 | ||
102 | if Is_Extra_Bootloader "${EXTRA_BOOTLOADER_ROLE}" | |
103 | then | |
104 | return 0 | |
105 | else | |
106 | exit 0 | |
107 | fi | |
108 | ||
109 | } | |
110 | ||
111 | Check_Any_Bootloader_Role () | |
112 | { | |
113 | ANY_BOOTLOADER_ROLE="${1}" | |
114 | ||
115 | if Is_First_Bootloader "${ANY_BOOTLOADER_ROLE}" | |
116 | then | |
117 | return 0 | |
118 | fi | |
119 | ||
120 | if Is_Extra_Bootloader "${ANY_BOOTLOADER_ROLE}" | |
121 | then | |
122 | return 0 | |
123 | fi | |
124 | ||
125 | exit 0 | |
126 | ||
127 | }⏎ |
25 | 25 | fi |
26 | 26 | done |
27 | 27 | |
28 | # Only pass SOURCE_DATE_EPOCH if its already set | |
29 | if [ "${SOURCE_DATE_EPOCH:-}" != "" ] | |
30 | then | |
31 | ENV="${ENV} SOURCE_DATE_EPOCH=${SOURCE_DATE_EPOCH}" | |
32 | fi | |
33 | ||
28 | 34 | ${_LINUX32} chroot "${CHROOT}" /usr/bin/env -i HOME="/root" PATH="/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin" TERM="${TERM}" DEBIAN_FRONTEND="${LB_DEBCONF_FRONTEND}" DEBIAN_PRIORITY="${LB_DEBCONF_PRIORITY}" DEBCONF_NONINTERACTIVE_SEEN="true" DEBCONF_NOWARNINGS="true" ${ENV} ${COMMANDS} |
29 | 35 | |
30 | 36 | return "${?}" |
395 | 395 | LB_CHROOT_FILESYSTEM="${LB_CHROOT_FILESYSTEM:-squashfs}" |
396 | 396 | |
397 | 397 | # Setting union filesystem |
398 | LB_UNION_FILESYSTEM="${LB_UNION_FILESYSTEM:-aufs}" | |
398 | LB_UNION_FILESYSTEM="${LB_UNION_FILESYSTEM:-overlay}" | |
399 | 399 | |
400 | 400 | # Setting interactive shell/X11/Xnest |
401 | 401 | LB_INTERACTIVE="${LB_INTERACTIVE:-false}" |
412 | 412 | armel) |
413 | 413 | # armel will have special images: one rootfs image and many additional kernel images. |
414 | 414 | # therefore we default to all available armel flavours |
415 | LB_LINUX_FLAVOURS="${LB_LINUX_FLAVOURS:-ixp4xx kirkwood orion5x versatile}" | |
415 | LB_LINUX_FLAVOURS="${LB_LINUX_FLAVOURS:-kirkwood orion5x}" | |
416 | 416 | ;; |
417 | 417 | |
418 | 418 | armhf) |
531 | 531 | then |
532 | 532 | case "${LB_ARCHITECTURES}" in |
533 | 533 | amd64|i386) |
534 | LB_BOOTLOADERS="syslinux" | |
534 | LB_BOOTLOADERS="syslinux,grub-efi" | |
535 | 535 | ;; |
536 | 536 | esac |
537 | 537 | fi |
538 | ||
539 | LB_FIRST_BOOTLOADER=$(echo "${LB_BOOTLOADERS}" | awk -F, '{ print $1 }') | |
538 | 540 | |
539 | 541 | # Setting checksums |
540 | 542 | case "${LB_MODE}" in |
778 | 780 | |
779 | 781 | Check_defaults () |
780 | 782 | { |
781 | if [ -n "${LIVE_BUILD_VERSION}" ] | |
782 | then | |
783 | # We're only checking when we're actually running the checks | |
784 | # that's why the check for emptyness of the version; | |
785 | # however, as live-build always declares LIVE_BUILD_VERSION | |
786 | # internally, this is safe assumption (no cases where it's unset, | |
787 | # except when bootstrapping the functions/defaults etc.). | |
788 | ||
789 | CURRENT_CONFIGURATION_VERSION="$(echo ${LIVE_CONFIGURATION_VERSION} | awk -F. ' { print $1 }')" | |
790 | ||
791 | if [ -n "${CURRENT_CONFIGURATION_VERSION}" ] | |
792 | then | |
793 | CORRECT_VERSION="$(echo ${LIVE_BUILD_VERSION} | awk -F. '{ print $1 }')" | |
794 | TOO_NEW_VERSION="$((${CORRECT_VERSION} + 1))" | |
795 | TOO_OLD_VERSION="$((${CORRECT_VERSION} - 1))" | |
796 | ||
797 | if [ ${CURRENT_CONFIGURATION_VERSION} -ne ${CORRECT_VERSION} ] | |
798 | then | |
799 | if [ ${CURRENT_CONFIGURATION_VERSION} -ge ${TOO_NEW_VERSION} ] | |
800 | then | |
801 | Echo_error "This config tree is too new for live-build (${VERSION})." | |
802 | Echo_error "Aborting build, please update live-build." | |
803 | ||
804 | exit 1 | |
805 | elif [ ${CURRENT_CONFIGURATION_VERSION} -le ${TOO_OLD_VERSION} ] | |
806 | then | |
807 | Echo_error "This config tree is too old for live-build (${VERSION})." | |
808 | Echo_error "Aborting build, please update the configuration." | |
809 | ||
810 | exit 1 | |
811 | else | |
812 | Echo_warning "This configuration does not specify a version or has a unknown version." | |
813 | Echo_warning "Continuing build, please correct the configuration." | |
814 | fi | |
815 | fi | |
816 | fi | |
817 | fi | |
818 | ||
819 | 783 | case "${LB_BINARY_FILESYSTEM}" in |
820 | 784 | ntfs) |
821 | 785 | if [ ! -x "$(which ntfs-3g 2>/dev/null)" ] |
844 | 808 | fi |
845 | 809 | fi |
846 | 810 | |
847 | ||
848 | LB_PRIMARY_BOOTLOADER=$(echo "${LB_BOOTLOADERS}" | awk -F, '{ print $1 }') | |
849 | ||
850 | if [ "${LB_PRIMARY_BOOTLOADER}" = "syslinux" ] | |
811 | if [ "${LB_FIRST_BOOTLOADER}" = "syslinux" ] | |
851 | 812 | then |
852 | 813 | # syslinux + fat or ntfs, or extlinux + ext[234] or btrfs |
853 | 814 | case "${LB_BINARY_FILESYSTEM}" in |
854 | 815 | fat*|ntfs|ext[234]|btrfs) |
855 | 816 | ;; |
856 | 817 | *) |
857 | Echo_warning "You have selected values of LB_BOOTLOADER and LB_BINARY_FILESYSTEM which are incompatible - the syslinux family only support FAT, NTFS, ext[234] or btrfs filesystems." | |
818 | Echo_warning "You have selected values of LB_BOOTLOADERS and LB_BINARY_FILESYSTEM which are incompatible - the syslinux family only support FAT, NTFS, ext[234] or btrfs filesystems." | |
858 | 819 | ;; |
859 | 820 | esac |
860 | 821 | fi |
861 | 822 | |
862 | 823 | case "${LIVE_IMAGE_TYPE}" in |
863 | 824 | hdd*) |
864 | case "${LB_PRIMARY_BOOTLOADER}" in | |
825 | case "${LB_FIRST_BOOTLOADER}" in | |
865 | 826 | grub) |
866 | 827 | Echo_error "You have selected a combination of bootloader and image type that is currently not supported by live-build. Please use either another bootloader or a different image type." |
867 | 828 | exit 1 |
60 | 60 | fi |
61 | 61 | } |
62 | 62 | |
63 | Calculate_partition_size () | |
63 | # adapted from lib/ext2fs/mkjournal.c, default block size is 4096 bytes (/etc/mke2fs.conf). | |
64 | ext2fs_default_journal_size() | |
64 | 65 | { |
65 | ORIGINAL_SIZE="${1}" | |
66 | FILESYSTEM="${2}" | |
66 | SIZE="$1" | |
67 | if [ "${SIZE}" -lt "8" ]; then # 2048*4096 | |
68 | echo 0 | |
69 | elif [ "${SIZE}" -lt "128" ]; then # 32768*4096 | |
70 | echo 4 | |
71 | elif [ "${SIZE}" -lt "1024" ]; then # 256*1024*4096 | |
72 | echo 16 | |
73 | elif [ "${SIZE}" -lt "2048" ]; then # 512*1024*4096 | |
74 | echo 32 | |
75 | elif [ "${SIZE}" -lt "4096" ]; then # 1024*1024*4096 | |
76 | echo 64 | |
77 | else | |
78 | echo 128 | |
79 | fi | |
80 | } | |
67 | 81 | |
68 | case "${FILESYSTEM}" in | |
82 | Calculate_partition_size_without_journal () | |
83 | { | |
84 | WITHOUT_JOURNAL_ORIGINAL_SIZE="${1}" | |
85 | WITHOUT_JOURNAL_FILESYSTEM="${2}" | |
86 | ||
87 | case "${WITHOUT_JOURNAL_FILESYSTEM}" in | |
69 | 88 | ext2|ext3|ext4) |
70 | 89 | PERCENT="6" |
71 | 90 | ;; |
74 | 93 | ;; |
75 | 94 | esac |
76 | 95 | |
77 | echo $(expr ${ORIGINAL_SIZE} + ${ORIGINAL_SIZE} \* ${PERCENT} / 100 + 1) | |
96 | echo $(expr ${WITHOUT_JOURNAL_ORIGINAL_SIZE} + ${WITHOUT_JOURNAL_ORIGINAL_SIZE} \* ${PERCENT} / 100 + 1) | |
78 | 97 | } |
98 | ||
99 | Calculate_partition_size () | |
100 | { | |
101 | ORIGINAL_SIZE="${1}" | |
102 | FILESYSTEM="${2}" | |
103 | ||
104 | case "${FILESYSTEM}" in | |
105 | ext3|ext4) | |
106 | NON_JOURNAL_SIZE=$(Calculate_partition_size_without_journal ${ORIGINAL_SIZE} ${FILESYSTEM}) | |
107 | PROJECTED_JOURNAL_SIZE=$(ext2fs_default_journal_size ${NON_JOURNAL_SIZE}) | |
108 | PROJECTED_PARTITION_SIZE=$(expr ${ORIGINAL_SIZE} + ${PROJECTED_JOURNAL_SIZE}) | |
109 | PRE_FINAL_PARTITION_SIZE=$(Calculate_partition_size_without_journal ${PROJECTED_PARTITION_SIZE} ${FILESYSTEM}) | |
110 | JOURNAL_SIZE=$(ext2fs_default_journal_size ${PRE_FINAL_PARTITION_SIZE}) | |
111 | ||
112 | expr $(Calculate_partition_size_without_journal ${ORIGINAL_SIZE} ${FILESYSTEM}) + ${JOURNAL_SIZE} | |
113 | ;; | |
114 | *) | |
115 | Calculate_partition_size_without_journal ${ORIGINAL_SIZE} ${FILESYSTEM} | |
116 | ;; | |
117 | esac | |
118 | } |
88 | 88 | _LB_NEEDLE="$(echo "${_LB_LINE}" | cut -d' ' -f3-)" |
89 | 89 | _LB_HAYSTACK="$(eval "echo \$LB_$(echo "${_LB_LINE}" | cut -d' ' -f2)")" |
90 | 90 | |
91 | _LB_ENABLED=0 | |
91 | _LB_ENABLED=1 | |
92 | 92 | for _LB_NEEDLE_PART in ${_LB_NEEDLE} |
93 | 93 | do |
94 | 94 | for _LB_HAYSTACK_PART in ${_LB_HAYSTACK} |
95 | 95 | do |
96 | if [ "${_LB_NEEDLE_PART}" != "${_LB_HAYSTACK_PART}" ] | |
96 | if [ "${_LB_NEEDLE_PART}" = "${_LB_HAYSTACK_PART}" ] | |
97 | 97 | then |
98 | _LB_ENABLED=1 | |
98 | _LB_ENABLED=0 | |
99 | 99 | fi |
100 | 100 | done |
101 | 101 | done |
81 | 81 | else |
82 | 82 | if which dpkg-query > /dev/null 2>&1 |
83 | 83 | then |
84 | if Chroot chroot "dpkg-query -s ${PACKAGE}" 2> /dev/null | grep -qs "Status: install" | |
84 | if dpkg-query -s "${PACKAGE}" 2> /dev/null | grep -qs "Status: install" | |
85 | 85 | then |
86 | 86 | INSTALL_STATUS=0 |
87 | 87 | else |
0 | 0 | .TH LIVE\-BUILD 1 2015\-10\-21 5.0~a11-1 "Live Systems Project" |
1 | 1 | |
2 | 2 | .SH NAME |
3 | \fBlb binary\fR \- Complete the binary stage | |
3 | \fBlb_binary\fR \- Complete the binary stage | |
4 | 4 | |
5 | 5 | .SH SYNOPSIS |
6 | 6 | \fBlb binary\fR [\fIlive\-build options\fR] |
0 | 0 | .TH LIVE\-BUILD 1 2015\-10\-21 5.0~a11-1 "Live Systems Project" |
1 | 1 | |
2 | 2 | .SH NAME |
3 | \fBlb bootstrap\fR \- Complete the bootstrap stage | |
3 | \fBlb_bootstrap\fR \- Complete the bootstrap stage | |
4 | 4 | |
5 | 5 | .SH SYNOPSIS |
6 | 6 | \fBlb bootstrap\fR [\fIlive\-build options\fR] |
0 | 0 | .TH LIVE\-BUILD 1 2015\-10\-21 5.0~a11-1 "Live Systems Project" |
1 | 1 | |
2 | 2 | .SH NAME |
3 | \fBlb build\fR \- Complete the bootstrap, chroot, binary, and source stages | |
3 | \fBlb_build\fR \- Complete the bootstrap, chroot, binary, and source stages | |
4 | 4 | |
5 | 5 | .SH SYNOPSIS |
6 | 6 | \fBlb build\fR [\fIlive\-build options\fR] |
0 | 0 | .TH LIVE\-BUILD 1 2015\-10\-21 5.0~a11-1 "Live Systems Project" |
1 | 1 | |
2 | 2 | .SH NAME |
3 | \fBlb chroot\fR \- Complete the chroot stage | |
3 | \fBlb_chroot\fR \- Complete the chroot stage | |
4 | 4 | |
5 | 5 | .SH SYNOPSIS |
6 | 6 | \fBlb chroot\fR [\fIlive\-build options\fR] |
0 | 0 | .TH LIVE\-BUILD 1 2015\-10\-21 5.0~a11-1 "Live Systems Project" |
1 | 1 | |
2 | 2 | .SH NAME |
3 | \fBlb clean\fR \- Clean build directory | |
3 | \fBlb_clean\fR \- Clean build directory | |
4 | 4 | |
5 | 5 | .SH SYNOPSIS |
6 | 6 | \fBlb clean\fR [\fIlive\-build options\fR] |
0 | 0 | .TH LIVE\-BUILD 1 2015\-10\-21 5.0~a11-1 "Live Systems Project" |
1 | 1 | |
2 | 2 | .SH NAME |
3 | \fBlb config\fR \- Create config directory | |
3 | \fBlb_config\fR \- Create config directory | |
4 | 4 | |
5 | 5 | .SH SYNOPSIS |
6 | 6 | \fBlb config\fR [\fIlive\-build options\fR] |
38 | 38 | .br |
39 | 39 | [\fB\-\-bootappend\-live\fR \fIPARAMETER\fR|\fI"PARAMETERS"\fR] |
40 | 40 | .br |
41 | [\fB\-\-bootloader\fR grub|grub2|syslinux] | |
41 | [\fB\-\-bootappend\-live\-failsafe\fR \fIPARAMETER\fR|\fI"PARAMETERS"\fR] | |
42 | .br | |
43 | [\fB\-\-bootloaders\fR grub-legacy|grub-pc|syslinux|grub-efi] | |
42 | 44 | .br |
43 | 45 | [\fB\-\-cache\fR true|false] |
44 | 46 | .br |
73 | 75 | [\fB\-\-debian\-installer\-preseedfile\fR \fIFILE\fR|\fIURL\fR] |
74 | 76 | .br |
75 | 77 | [\fB\-\-debian\-installer\-gui\fR true|false] |
78 | .br | |
79 | [\fB\-\-debootstrap\-options\fR \fIOPTIONS\fR] | |
80 | .br | |
81 | [\fB\-\-debootstrap\-script\fR \fISCRIPT\fR] | |
76 | 82 | .br |
77 | 83 | [\fB\-\-debug\fR] |
78 | 84 | .br |
257 | 263 | .IP "\-b|\fB\-\-binary\-images\fR iso|iso\-hybrid|netboot|tar|hdd" 4 |
258 | 264 | defines the image type to build. By default, for images using syslinux this is set to iso\-hybrid to build CD/DVD images that may also be used like hdd images, for non\-syslinux images, it defaults to iso. |
259 | 265 | .IP "\fB\-\-binary\-filesystem\fR fat16|fat32|ext2|ext3|ext4" 4 |
260 | defines the filesystem to be used in the image type. This only has an effect if the selected binary image type does allow to choose a filesystem. For example, when selection iso the resulting CD/DVD has always the filesystem ISO9660. When building hdd images for usb sticks, this is active. Note that it defaults to fat16 on all architectures except sparc where it defaults to ext4. Also note that if you choose fat16 and your resulting binary image gets bigger than 2GB, the binary filesystem automatically gets switched to fat32. | |
266 | defines the filesystem to be used in the image type. This only has an effect if the selected binary image type lets you choose a filesystem. For example, when selection iso the resulting CD/DVD has always the filesystem ISO9660. When building hdd images for usb sticks, this is active. Note that it defaults to fat16 on all architectures except sparc where it defaults to ext4. Also note that if you choose fat16 and your resulting binary image gets bigger than 2GB, the binary filesystem automatically gets switched to fat32. | |
261 | 267 | .IP "\fB\-\-bootappend\-install\fR \fIPARAMETER\fR|""\fIPARAMETERS\fR""" 4 |
262 | 268 | sets boot parameters specific to debian\-installer, if included. |
263 | 269 | .IP "\fB\-\-bootappend\-live\fR \fIPARAMETER\fR|""\fIPARAMETERS\fR""" 4 |
264 | 270 | sets boot parameters specific to debian\-live. A complete list of boot parameters can be found in the \fIlive\-boot\fR(7) and \fIlive\-config\fR(7) manual pages. |
265 | .IP "\fB\-\-bootloader\fR grub|grub2|syslinux" 4 | |
266 | defines which bootloader is being used in the generated image. This has only an effect if the selected binary image type does allow to choose the bootloader. For example, if you build a iso, always syslinux (or more precise, isolinux) is being used. Also note that some combinations of binary images types and bootloaders may be possible but live\-build does not support them yet. \fBlb config\fR will fail to create such a not yet supported configuration and give a explanation about it. For hdd images on amd64 and i386, the default is syslinux. | |
271 | .IP "\fB\-\-bootappend\-live\-failsafe\fR \fIPARAMETER\fR|""\fIPARAMETERS\fR""" 4 | |
272 | sets boot parameters specific to debian\-live failsafe boot entries. A complete list of boot parameters can be found in the \fIlive\-boot\fR(7) and \fIlive\-config\fR(7) manual pages. | |
273 | .IP "\fB\-\-bootloaders\fR grub-legacy|grub-pc|syslinux|grub-efi" 4 | |
274 | defines which bootloader is being used in the generated image. This has only an effect if the selected binary image type lets you choose the bootloader. For example, if you build a iso, always syslinux (or more precise, isolinux) is being used. Also note that some combinations of binary images types and bootloaders may be possible but live\-build does not support them yet. \fBlb config\fR will fail to create such a not yet supported configuration and give a explanation about it. For hdd images on amd64 and i386, the default is syslinux. | |
267 | 275 | .IP "\fB\-\-cache\fR true|false" 4 |
268 | 276 | defines globally if any cache should be used at all. Different caches can be controlled through the their own options. |
269 | 277 | .IP "\fB\-\-cache\-indices\fR true|false" 4 |
270 | defines if downloaded package indices and lists should be cached which is false by default. Enabling it would allow to rebuild an image completely offline, however, you would not get updates anymore then. | |
278 | defines if downloaded package indices and lists should be cached which is false by default. Enabling it lets you rebuild an image completely offline, however, you would not get updates anymore then. | |
271 | 279 | .IP "\fB\-\-cache\-packages\fR true|false" 4 |
272 | 280 | defines if downloaded packages files should be cached which is true by default. Disabling it does save space consumption in your build directory, but remember that you will cause much unnecessary traffic if you do a couple of rebuilds. In general you should always leave it true, however, in some particular rare build setups, it can be faster to refetch packages from the local network mirror rather than to utilize the local disk. |
273 | 281 | .IP "\fB\-\-cache\-stages\fR true|false|\fISTAGE\fR|""\fISTAGES\fR""" 4 |
277 | 285 | .IP "\fB\-\-compression\fR bzip2|gzip|lzip|none" 4 |
278 | 286 | defines the compression program to be used to compress tarballs. Defaults to gzip. |
279 | 287 | .IP "\fB\-\-config\fR \fIGIT_URL\fR::\fIGIT_ID\fR" 4 |
280 | allows to bootstrap a config tree from a git repositories, optionally appended by a Git Id (branch, commit, tag, etc.). | |
288 | bootstrap the config tree from a git repository, optionally appended by a Git Id (branch, commit, tag, etc.). | |
281 | 289 | .IP "\fB\-\-build\-with\-chroot\fR true|false" 4 |
282 | 290 | defines whether live\-build should use the tools from within the chroot to build the binary image or not by using and including the host system's tools. This is a very dangerous option, using the tools of the host system can lead to tainted and even non-bootable images if the host systems version of the required tools (mainly these are the bootloaders such as syslinux and grub, and the auxiliary tools such as dosfstools, xorriso, squashfs-tools and others) do not \fBexactly\fR match what is present at build-time in the target distribution. Never do disable this option unless you are \fBexactly\fR sure what you are doing and have \fBcompletely\fI understood its consequences. |
283 | 291 | .IP "\fB\-\-chroot\-filesystem\fR ext2|ext3|ext4|squashfs|jffs2|none" 4 |
298 | 306 | sets the filename or URL for an optionally used and included preseeding file for debian\-installer. If config/binary_debian\-installer/preseed.cfg exists, it will be used by default. |
299 | 307 | .IP "\fB\-\-debian\-installer\-gui\fR true|false" 4 |
300 | 308 | defines if the debian\-installer graphical GTK interface should be true or not. In Debian mode and for most versions of Ubuntu, this option is true, whereas otherwise false, by default. |
309 | .IP "\fB\-\-debootstrap\-options\fR \fIOPTIONS\fR" 4 | |
310 | passes the given options to debootstrap when setting up the base system. | |
311 | .IP "\fB\-\-debootstrap\-script\fR \fISCRIPT\fR" 4 | |
312 | tells debootstrap to use an alternate bootstrap script (last parameter to debootstrap). | |
301 | 313 | .IP "\fB\-\-debug\fR" 4 |
302 | 314 | turn on debugging informational messages. |
303 | 315 | .IP "\-d|\fB\-\-distribution\fR \fICODENAME\fR" 4 |
307 | 319 | .IP "\-d|\fB\-\-parent\-debian\-installer\-distribution\fR \fICODENAME\fR" 4 |
308 | 320 | defines the parent debian\-installer distribution for derivatives of the resulting live system. |
309 | 321 | .IP "\fB\-\-dump\fR" 4 |
310 | prepares a report of the currently present live system configuration and the version of live\-build used. This is useful to provide if you submit bug reports, we do get all informations required for us to locate and replicate an error. | |
322 | prepares a report of the currently present live system configuration and the version of live\-build used. This is useful to provide if you submit bug reports, we do get all information required for us to locate and replicate an error. | |
311 | 323 | .IP "\fB\-\-fdisk\fR fdisk|fdisk.dist" 4 |
312 | 324 | sets the filename of the fdisk binary from the host system that should be used. This is autodetected and does generally not need any customization. |
313 | 325 | .IP "\fB\-\-force\fR" 4 |
0 | .TH LIVE\-BUILD 1 2015\-01\-04 5.0~a1-1 "Live Systems Project" | |
1 | ||
2 | .SH NAME | |
3 | \fBlb_installer\fR \- Complete the installer stage | |
4 | ||
5 | .SH SYNOPSIS | |
6 | \fBlb installer\fR [\fIlive\-build options\fR] | |
7 | ||
8 | .SH DESCRIPTION | |
9 | \fBlb installer\fR is a high\-level command (porcelain) of \fIlive\-build\fR(7), the live systems tool suite. | |
10 | .PP | |
11 | \fBlb installer\fR calls all necessary live\-build programs in the correct order to complete the installer stage. | |
12 | ||
13 | .SH OPTIONS | |
14 | \fBlb installer\fR has no specific options but understands all generic live\-build options. See \fIlive\-build\fR(7) for a complete list of all generic live\-build options. | |
15 | ||
16 | .SH FILES | |
17 | .IP "\fBnone\fR" 4 | |
18 | ||
19 | .SH SEE ALSO | |
20 | \fIlive\-build\fR(7) | |
21 | .PP | |
22 | This program is a part of live\-build. | |
23 | ||
24 | .SH HOMEPAGE | |
25 | More information about live\-build and the Live Systems project can be found on the homepage at <\fIhttp://live-systems.org/\fR> and in the manual at <\fIhttp://live-systems.org/manual/\fR>. | |
26 | ||
27 | .SH BUGS | |
28 | Bugs can be reported by submitting a bugreport for the live\-build package in the Bug Tracking System at <\fIhttp://bugs.debian.org/\fR> or by writing a mail to the Live Systems mailing list at <\[email protected]\fR>. | |
29 | ||
30 | .SH AUTHOR | |
31 | live\-build was written by Daniel Baumann <\[email protected]\fR>. |
0 | 0 | .TH LIVE\-BUILD 1 2015\-10\-21 5.0~a11-1 "Live Systems Project" |
1 | 1 | |
2 | 2 | .SH NAME |
3 | \fBlb source\fR \- Complete the source stage | |
3 | \fBlb_source\fR \- Complete the source stage | |
4 | 4 | |
5 | 5 | .SH SYNOPSIS |
6 | 6 | \fBlb source\fR [\fIlive\-build options\fR] |
54 | 54 | .\" FIXME |
55 | 55 | We separate the porcelain commands into the main commands and some ancillary user utilities. |
56 | 56 | .SS Main porcelain commands |
57 | .IP "\fBlb_config\fR(1)" 4 | |
58 | create configuration for live\-build | |
59 | .IP "\fBlb_bootstrap\fR(1)" 4 | |
60 | create the first stage by bootstrapping a basic debian system | |
61 | .IP "\fBlb_chroot\fR(1)" 4 | |
62 | create the second stage by customizing the chroot | |
63 | .IP "\fBlb_binary\fR(1)" 4 | |
64 | create the third stage by generating a binary image | |
65 | .IP "\fBlb_source\fR(1)" 4 | |
66 | create the optional fourth stage by generating a source image | |
67 | .IP "\fBlb_clean\fR(1)" 4 | |
68 | clean up system build directories | |
57 | .IP "\fBlb config\fR(1)" 4 | |
58 | creates configuration for live\-build | |
59 | .IP "\fBlb bootstrap\fR(1)" 4 | |
60 | executes the first build stage, creating (bootstraping) a basic Debian root filesystem | |
61 | .IP "\fBlb chroot\fR(1)" 4 | |
62 | executes the second build stage, building the live OS filesystem | |
63 | .IP "\fBlb installer\fR(1)" 4 | |
64 | executes the third build stage, obtaining installer components (optional) | |
65 | .IP "\fBlb binary\fR(1)" 4 | |
66 | executes the fourth build stage, generating a binary image | |
67 | .IP "\fBlb source\fR(1)" 4 | |
68 | executes the fifth build stage, generating a source image (optional) | |
69 | .IP "\fBlb clean\fR(1)" 4 | |
70 | cleans up system build directories | |
69 | 71 | .SS Ancillary Commands |
70 | 72 | .IP "\fBlb\fR(1)" 4 |
71 | generic live\-build wrapper | |
72 | .IP "\fBlb_build\fR(1)" 4 | |
73 | alias for all stages | |
74 | .IP "\fBlb_local\fR(1)" 4 | |
75 | helper for using a local live\-build | |
76 | .IP "\fBlb_testroot\fR(1)" 4 | |
77 | ensure that a system is built as root | |
78 | .\" FIXME | |
79 | ||
80 | .SH LOW\-LEVEL COMMANDS (PLUMBING) | |
73 | generic live\-build script execution wrapper | |
74 | .IP "\fBlb build\fR(1)" 4 | |
75 | alias for all build stages | |
76 | .\" FIXME | |
77 | ||
78 | .SH LOW\-LEVEL COMMANDS (PLUMBING) - BUILD STAGE COMPONENTS | |
81 | 79 | .\" FIXME |
82 | 80 | The actual work of live\-build is implemented in the low-level commands, called plumbing. They are not supposed to be used by end users, they should stick with porcelains as they ensure that all the different plumbing commands are executed in the right order. However, if you intend to reuse live\-build commands in your own scripts, then the plumbings might be of interest for you. |
83 | 81 | .PP |
84 | 82 | Note that the interface (set of options and the semantics) to these low\-level commands are meant to be a lot more stable than Porcelain level commands. The interface to Porcelain commands on the other hand are subject to change in order to improve the end user experience. |
85 | .SS Bootstrap commands | |
86 | .IP "\fBlb_bootstrap_cache\fR(1)" 4 | |
87 | cache bootstrap stage | |
88 | .IP "\fBlb_bootstrap_debootstrap\fR(1)" 4 | |
89 | bootstrap a Debian system with debootstrap(8) | |
90 | .SS Chroot commands | |
91 | .IP "\fBlb_chroot_apt\fR(1)" 4 | |
92 | manage /etc/apt/apt.conf | |
93 | .IP "\fBlb_chroot_cache\fR(1)" 4 | |
94 | cache chroot stage | |
95 | .IP "\fBlb_chroot_debianchroot\fR(1)" 4 | |
96 | manage /etc/debian_chroot | |
97 | .IP "\fBlb_chroot_devpts\fR(1)" 4 | |
98 | mount /dev/pts | |
99 | .IP "\fBlb_chroot_dpkg\fR(1)" 4 | |
100 | manage /sbin/dpkg | |
101 | .IP "\fBlb_chroot_hacks\fR(1)" 4 | |
102 | execute hacks in chroot | |
103 | .IP "\fBlb_chroot_hostname\fR(1)" 4 | |
104 | manage /bin/hostname | |
105 | .IP "\fBlb_chroot_hosts\fR(1)" 4 | |
106 | manage /etc/hosts | |
107 | .IP "\fBlb_chroot_install\-packages\fR(1)" 4 | |
108 | install queued packages into chroot | |
109 | .IP "\fBlb_chroot_interactive\fR(1)" 4 | |
110 | make build interactive | |
111 | .IP "\fBlb_chroot_linux\-image\fR(1)" 4 | |
112 | manage /etc/kernel\-img.conf | |
113 | .IP "\fBlb_chroot_hooks\fR(1)" 4 | |
114 | execute local hooks in chroot | |
115 | .IP "\fBlb_chroot_local\-includes\fR(1)" 4 | |
116 | copy local files into chroot | |
117 | .IP "\fBlb_chroot_packages\fR(1)" 4 | |
118 | queue install of packages into chroot | |
119 | .IP "\fBlb_chroot_local\-patches\fR(1)" 4 | |
120 | apply local patches against chroot | |
121 | .IP "\fBlb_chroot_local\-preseed\fR(1)" 4 | |
122 | use debconf local preseeding file | |
123 | .IP "\fBlb_chroot_packagelists\fR(1)" 4 | |
124 | queue install of package lists into chroot | |
125 | .IP "\fBlb_chroot_proc\fR(1)" 4 | |
126 | mount /proc | |
127 | .IP "\fBlb_chroot_resolv\fR(1)" 4 | |
128 | manage /etc/resolv.conf | |
129 | .IP "\fBlb_chroot_selinuxfs\fR(1)" 4 | |
130 | mount /selinux | |
131 | .IP "\fBlb_chroot_archives\fR(1)" 4 | |
132 | manage /etc/apt/sources.list | |
133 | .IP "\fBlb_chroot_sysfs\fR(1)" 4 | |
134 | mount /sys | |
135 | .IP "\fBlb_chroot_sysv\-rc\fR(1)" 4 | |
136 | manage /usr/sbin/policy\-rc.d | |
137 | .IP "\fBlb_chroot_task\-lists\fR(1)" 4 | |
138 | install task lists into chroot | |
139 | .SS Binary commands | |
140 | .IP "\fBlb_binary_chroot\fR(1)" 4 | |
141 | copy chroot into chroot | |
142 | .IP "\fBlb_binary_debian\-installer\fR(1)" 4 | |
143 | install debian\-installer into binary | |
144 | .IP "\fBlb_binary_disk\fR(1)" 4 | |
145 | install disk information into binary | |
146 | .IP "\fBlb_binary_grub\fR(1)" 4 | |
147 | installs grub into binary | |
148 | .IP "\fBlb_binary_grub2\fR(1)" 4 | |
149 | installs grub2 into binary | |
150 | .IP "\fBlb_binary_includes\fR(1)" 4 | |
151 | copy files into binary | |
152 | .IP "\fBlb_binary_iso\fR(1)" 4 | |
153 | build iso binary image | |
154 | .IP "\fBlb_binary_linux\-image\fR(1)" 4 | |
155 | install linux\-image into binary | |
156 | .IP "\fBlb_binary_local\-hooks\fR(1)" 4 | |
157 | execute local hooks in binary | |
158 | .IP "\fBlb_binary_local\-includes\fR(1)" 4 | |
159 | copy files into binary | |
160 | .IP "\fBlb_binary_local\-packagelists\fR(1)" 4 | |
161 | install local package lists into binary | |
162 | .IP "\fBlb_binary_manifest\fR(1)" 4 | |
163 | create manifest | |
164 | .IP "\fBlb_binary_checksums\fR(1)" 4 | |
165 | create binary checksums (md5, sha1, and/or sha256) | |
166 | .IP "\fBlb_binary_memtest\fR(1)" 4 | |
167 | installs a memtest into binary | |
168 | .IP "\fBlb_binary_net\fR(1)" 4 | |
169 | build netboot binary image | |
170 | .IP "\fBlb_binary_rootfs\fR(1)" 4 | |
171 | build rootfs image | |
172 | .IP "\fBlb_binary_syslinux\fR(1)" 4 | |
173 | installs syslinux into binary | |
174 | .IP "\fBlb_binary_tar\fR(1)" 4 | |
175 | build harddisk binary image | |
176 | .IP "\fBlb_binary_hdd\fR(1)" 4 | |
177 | build binary hdd image | |
178 | .IP "\fBlb_binary_win32\-loader\fR(1)" 4 | |
179 | installs win32\-loader into binary | |
180 | .SS Source commands | |
181 | .IP "\fBlb_source_debian\fR(1)" 4 | |
182 | download sources | |
183 | .IP "\fBlb_source_debian\-live\fR(1)" 4 | |
184 | copy debian\-live config into source | |
185 | .IP "\fBlb_source_disk\fR(1)" 4 | |
186 | install disk information into source | |
187 | .IP "\fBlb_source_iso\fR(1)" 4 | |
188 | build iso source image | |
189 | .IP "\fBlb_source_checksums\fR(1)" 4 | |
190 | create source checksums (md5, sha1, and/or sha256) | |
191 | .IP "\fBlb_source_net\fR(1)" 4 | |
192 | build source net image | |
193 | .IP "\fBlb_source_tar\fR(1)" 4 | |
194 | build source tarball | |
195 | .IP "\fBlb_source_hdd\fR(1)" 4 | |
196 | build source hdd image | |
83 | .SS Bootstrap stage specific commands | |
84 | .IP "\fBlb bootstrap_archives\fR(1)" 4 | |
85 | applies apt archive configuration | |
86 | .IP "\fBlb bootstrap_cache\fR(1)" 4 | |
87 | in save mode, saves to cache a copy of the generated bootstrap directory, and in restore mode, restores from cache a previously generated copy | |
88 | .IP "\fBlb bootstrap_debootstrap\fR(1)" 4 | |
89 | creates (bootstrap) a basic Debian root filesystem using debootstrap(8) | |
90 | .SS Chroot stage specific commands | |
91 | .PP | |
92 | Note: The following chroot_ prefixed commands are used in building the live OS filesystem. Another set of similarly prefixed files are listed separately (see further down). | |
93 | .IP "\fBlb chroot_cache\fR(1)" 4 | |
94 | in save mode, saves to cache a copy of the chroot directory, and in restore mode, restores from cache a previously generated copy | |
95 | .IP "\fBlb chroot_firmware\fR(1)" 4 | |
96 | compiles a list of firmware packages to be installed in the live OS root filesystem | |
97 | .IP "\fBlb chroot_hacks\fR(1)" 4 | |
98 | executes local hacks against the live OS root filesystem, if any are provided | |
99 | .IP "\fBlb chroot_hooks\fR(1)" 4 | |
100 | executes local hooks against the live OS root filesystem, if any are provided | |
101 | .IP "\fBlb chroot_includes\fR(1)" 4 | |
102 | copies a set of local files from the config directory into the live OS root filesystem, if any are provided | |
103 | .IP "\fBlb chroot_install\-packages\fR(1)" 4 | |
104 | installs into the live OS root filesystem any packages listed in local package lists | |
105 | .IP "\fBlb chroot_interactive\fR(1)" 4 | |
106 | pauses the build process and starts an interactive shell from the live OS root filesystem, providing an oportunity for manual modifications or testing; note that this is (currently) usually executed with several chroot prep modifications applied (see description of these further down) | |
107 | .IP "\fBlb chroot_linux\-image\fR(1)" 4 | |
108 | compiles a list of kernel images to be installed in the live OS root filesystem | |
109 | .IP "\fBlb chroot_live\-packages\fR(1)" 4 | |
110 | installs a set of live system specific packages to the live OS root filesystem | |
111 | .IP "\fBlb chroot_package\-lists\fR(1)" 4 | |
112 | compiles a list of packages provided in the user\' local config to be installed in the live OS root filesystem | |
113 | .IP "\fBlb chroot_preseed\fR(1)" 4 | |
114 | installs pre-configured answers to certain install prompts into the live OS root filesystem | |
115 | .SS Installer stage specific commands | |
116 | .IP "\fBlb installer_debian\-installer\fR(1)" 4 | |
117 | obtains and sets up Debian installer(d-i) components | |
118 | .IP "\fBlb installer_preseed\fR(1)" 4 | |
119 | installs pre-configured answers to certain install prompts | |
120 | .SS Binary stage specific commands | |
121 | .IP "\fBlb binary_checksums\fR(1)" 4 | |
122 | creates checksums (md5, sha1, and/or sha256) for live image content | |
123 | .IP "\fBlb binary_chroot\fR(1)" 4 | |
124 | duplicates the chroot directory, to place a copy of what whould be the completed live OS root filesystem to one side, allowing the original to continue to be used in executing certain parts of the remainder of the build process | |
125 | .IP "\fBlb binary_disk\fR(1)" 4 | |
126 | creates disk information files to be added to live image | |
127 | .IP "\fBlb binary_grub\fR(1)" 4 | |
128 | installs grub into live image to provide image boot capability | |
129 | .IP "\fBlb binary_grub2\fR(1)" 4 | |
130 | installs grub2 into live image to provide image boot capability | |
131 | .IP "\fBlb binary_hdd\fR(1)" 4 | |
132 | compiles the final live image into an hdd image file | |
133 | .IP "\fBlb binary_hooks\fR(1)" 4 | |
134 | executes local hooks against the live image, if any are provided | |
135 | .IP "\fBlb binary_includes\fR(1)" 4 | |
136 | copies a set of local files from the config directory into the live image, if any are provided | |
137 | .IP "\fBlb binary_iso\fR(1)" 4 | |
138 | compiles the final live image into an iso file | |
139 | .IP "\fBlb binary_linux\-image\fR(1)" 4 | |
140 | copies the linux\-image into the live image | |
141 | .IP "\fBlb binary_loadlin\fR(1)" 4 | |
142 | bundles a copy of loadlin into the live image | |
143 | .IP "\fBlb binary_manifest\fR(1)" 4 | |
144 | creates manifest of packages installed into live OS filesystem, and list of packages to be excluded by a persistence mechanism installing the live OS to disk | |
145 | .IP "\fBlb binary_memtest\fR(1)" 4 | |
146 | bundles a copy of memtest into the live image | |
147 | .IP "\fBlb binary_netboot\fR(1)" 4 | |
148 | compiles the final live image into a netboot tar archive | |
149 | .IP "\fBlb binary_package\-lists\fR(1)" 4 | |
150 | processes local lists of packages to obtain and bundle into image (from which they could later be installed if not already) | |
151 | .IP "\fBlb binary_rootfs\fR(1)" 4 | |
152 | wraps up the completed live OS root filesystem into a virtual file system image | |
153 | .IP "\fBlb binary_syslinux\fR(1)" 4 | |
154 | installs syslinux into live image to provide image boot capability | |
155 | .IP "\fBlb binary_tar\fR(1)" 4 | |
156 | compiles the final live image into a tar archive | |
157 | .IP "\fBlb binary_win32\-loader\fR(1)" 4 | |
158 | bundles a copy of win32\-loader into the live image and creates an autorun.inf file | |
159 | .IP "\fBlb binary_zsync\fR(1)" 4 | |
160 | builds zsync control files | |
161 | .SS Source stage specific commands | |
162 | .IP "\fBlb source_checksums\fR(1)" 4 | |
163 | creates checksums (md5, sha1, and/or sha256) for source image content | |
164 | .IP "\fBlb source_debian\fR(1)" 4 | |
165 | downloads source packages for bundling into source image | |
166 | .IP "\fBlb source_disk\fR(1)" 4 | |
167 | creates disk information files to be added to source image | |
168 | .IP "\fBlb source_hdd\fR(1)" 4 | |
169 | compiles the final source image into an hdd image file | |
170 | .IP "\fBlb source_hooks\fR(1)" 4 | |
171 | executes local hooks against the source image, if any are provided | |
172 | .IP "\fBlb source_iso\fR(1)" 4 | |
173 | compiles the final source image into an iso file | |
174 | .IP "\fBlb source_live\fR(1)" 4 | |
175 | copies live-build config into source | |
176 | .IP "\fBlb source_tar\fR(1)" 4 | |
177 | compiles the final source image into a tar archive | |
178 | .\" FIXME | |
179 | ||
180 | .SH LOW\-LEVEL COMMANDS (PLUMBING) - CHROOT PREP COMPONENTS | |
181 | .\" FIXME | |
182 | The notes above under the section regarding build-stage specific low-level plumbing commands also apply here. | |
183 | .PP | |
184 | The following chroot_ prefixed commands are used throughout the various primary stages of the build process to apply and remove modifications to a chroot root filesystem. Generally these are used to apply modification that setup the chroot for use (execution of programs within it) during the build process, and later to remove those modification, unmounting things that were mounted, and making the chroot suitable for use as the root filesystem of the live OS to be bundled into the live image. | |
185 | .IP "\fBlb chroot_apt\fR(1)" 4 | |
186 | manages apt configuration; in apply mode it applies configuration for use during build process, and in remove mode removes that configuration | |
187 | .IP "\fBlb chroot_archives\fR(1)" 4 | |
188 | manages apt archive source lists; in apply mode it applies source list configurations suitable for use of the chroot in the build process, and in remove mode replaces that with a configuration suitable for the final live OS | |
189 | .IP "\fBlb chroot_debianchroot\fR(1)" 4 | |
190 | manages a /etc/debian_chroot file | |
191 | .IP "\fBlb chroot_devpts\fR(1)" 4 | |
192 | manages mounting of /dev/pts | |
193 | .IP "\fBlb chroot_dpkg\fR(1)" 4 | |
194 | manages dpkg; in apply mode disabling things like the start-stop-daemon, and in remove mode enabling them again | |
195 | .IP "\fBlb chroot_hostname\fR(1)" 4 | |
196 | manages the hostname configuration | |
197 | .IP "\fBlb chroot_hosts\fR(1)" 4 | |
198 | manages the /etc/hosts file | |
199 | .IP "\fBlb chroot_proc\fR(1)" 4 | |
200 | manages mounting of /proc | |
201 | .IP "\fBlb chroot_resolv\fR(1)" 4 | |
202 | manages configuration of the /etc/resolv.conf file | |
203 | .IP "\fBlb chroot_selinuxfs\fR(1)" 4 | |
204 | manages mounting of /sys/fs/selinux | |
205 | .IP "\fBlb chroot_sysfs\fR(1)" 4 | |
206 | manages mounting of /sys | |
207 | .IP "\fBlb chroot_sysv\-rc\fR(1)" 4 | |
208 | manages the /usr/sbin/policy\-rc.d file | |
209 | .IP "\fBlb chroot_tmpfs\fR(1)" 4 | |
210 | manages configuration of dpkg to use a tmpfs filesystem | |
211 | .IP "\fBlb chroot_upstart\fR(1)" 4 | |
212 | manages use of upstart /sbin/initctl program; in apply mode blocking execution through a dpkg diversion, and in remove mode enabling execution again | |
197 | 213 | .\" FIXME |
198 | 214 | |
199 | 215 | .SH CONFIG FILES |
200 | 216 | .\" FIXME |
201 | 217 | Many live\-build commands make use of files in the \fIconfig/\fR directory to control what they do. Besides the common \fIconfig/common\fR, which is used by all live\-build commands, some additional files can be used to configure the behavior of specific live\-build commands. These files are typically named config/stage or config/stage_helper (where "stage" of course, is replaced with the name of the stage that they belong to, and "helper" with the name of the helper). |
202 | 218 | .PP |
203 | For example, lb_bootstrap_debootstrap uses files named config/bootstrap and config/bootstrap_debootstrap to read the options it will use. See the man pages of individual commands for details about the names and formats of the files they use. Generally, these files contain variables with values assigned, one variable per line. Some programs in live\-build use pairs of values or slightly more complicated variable assignments. | |
219 | For example, lb bootstrap_debootstrap uses files named config/bootstrap and config/bootstrap_debootstrap to read the options it will use. See the man pages of individual commands for details about the names and formats of the files they use. Generally, these files contain variables with values assigned, one variable per line. Some programs in live\-build use pairs of values or slightly more complicated variable assignments. | |
204 | 220 | .PP |
205 | 221 | Note that live\-build will respect environment variables which are present in the context of the shell it is running. If variables can be read from config files, then they override environment variables, and if command line options are used, they override values from config files. If no value for a given variable can be found and thus is unset, live\-build will automatically set it to the default value. |
206 | 222 | .PP |
0 | # French translation of the live-build manpage | |
1 | # Copyright (C) 2015 Olivier Humbert <[email protected]>. | |
2 | # This file is distributed under the same license as the live-images package. | |
3 | # | |
4 | msgid "" | |
5 | msgstr "" | |
6 | "Project-Id-Version: live-build 4.0~alpha39-1\n" | |
7 | "POT-Creation-Date: 2014-08-27 23:56+0200\n" | |
8 | "PO-Revision-Date: 2015-09-20 14:53+0200\n" | |
9 | "Last-Translator: Olivier Humbert <[email protected]>\n" | |
10 | "Language-Team: none\n" | |
11 | "Language: fr\n" | |
12 | "MIME-Version: 1.0\n" | |
13 | "Content-Type: text/plain; charset=UTF-8\n" | |
14 | "Content-Transfer-Encoding: 8bit\n" | |
15 | ||
16 | #. type: TH | |
17 | #: en/lb.1:1 en/lb_binary.1:1 en/lb_bootstrap.1:1 en/lb_build.1:1 | |
18 | #: en/lb_chroot.1:1 en/lb_clean.1:1 en/lb_config.1:1 en/lb_source.1:1 | |
19 | #: en/lb_testroot.1:1 en/live-build.7:1 | |
20 | #, no-wrap | |
21 | msgid "LIVE-BUILD" | |
22 | msgstr "LIVE-BUILD" | |
23 | ||
24 | #. type: TH | |
25 | #: en/lb.1:1 en/lb_binary.1:1 en/lb_bootstrap.1:1 en/lb_build.1:1 | |
26 | #: en/lb_chroot.1:1 en/lb_clean.1:1 en/lb_config.1:1 en/lb_source.1:1 | |
27 | #: en/lb_testroot.1:1 en/live-build.7:1 | |
28 | #, no-wrap | |
29 | msgid "2014-08-27" | |
30 | msgstr "2014-08-27" | |
31 | ||
32 | #. type: TH | |
33 | #: en/lb.1:1 en/lb_binary.1:1 en/lb_bootstrap.1:1 en/lb_build.1:1 | |
34 | #: en/lb_chroot.1:1 en/lb_clean.1:1 en/lb_config.1:1 en/lb_source.1:1 | |
35 | #: en/lb_testroot.1:1 en/live-build.7:1 | |
36 | #, no-wrap | |
37 | msgid "4.0~alpha39-1" | |
38 | msgstr "4.0~alpha39-1" | |
39 | ||
40 | #. type: TH | |
41 | #: en/lb.1:1 en/lb_binary.1:1 en/lb_bootstrap.1:1 en/lb_build.1:1 | |
42 | #: en/lb_chroot.1:1 en/lb_clean.1:1 en/lb_config.1:1 en/lb_source.1:1 | |
43 | #: en/lb_testroot.1:1 en/live-build.7:1 | |
44 | #, no-wrap | |
45 | msgid "Live Systems Project" | |
46 | msgstr "Projet Systems Live" | |
47 | ||
48 | #. type: SH | |
49 | #: en/lb.1:3 en/lb_binary.1:3 en/lb_bootstrap.1:3 en/lb_build.1:3 | |
50 | #: en/lb_chroot.1:3 en/lb_clean.1:3 en/lb_config.1:3 en/lb_source.1:3 | |
51 | #: en/lb_testroot.1:3 en/live-build.7:3 | |
52 | #, no-wrap | |
53 | msgid "NAME" | |
54 | msgstr "NOM" | |
55 | ||
56 | #. type: SH | |
57 | #: en/lb.1:6 en/lb_binary.1:6 en/lb_bootstrap.1:6 en/lb_build.1:6 | |
58 | #: en/lb_chroot.1:6 en/lb_clean.1:6 en/lb_config.1:6 en/lb_source.1:6 | |
59 | #: en/lb_testroot.1:6 en/live-build.7:6 | |
60 | #, no-wrap | |
61 | msgid "SYNOPSIS" | |
62 | msgstr "SYNOPSIS" | |
63 | ||
64 | #. type: SH | |
65 | #: en/lb.1:11 en/lb_binary.1:9 en/lb_bootstrap.1:9 en/lb_build.1:9 | |
66 | #: en/lb_chroot.1:9 en/lb_clean.1:9 en/lb_config.1:225 en/lb_source.1:9 | |
67 | #: en/lb_testroot.1:9 en/live-build.7:11 | |
68 | #, no-wrap | |
69 | msgid "DESCRIPTION" | |
70 | msgstr "DESCRIPTION" | |
71 | ||
72 | #. type: SH | |
73 | #: en/lb.1:16 en/lb_binary.1:14 en/lb_bootstrap.1:14 en/lb_build.1:14 | |
74 | #: en/lb_chroot.1:14 en/lb_clean.1:16 en/lb_config.1:234 en/lb_source.1:14 | |
75 | #: en/lb_testroot.1:16 en/live-build.7:20 | |
76 | #, no-wrap | |
77 | msgid "OPTIONS" | |
78 | msgstr "OPTIONS" | |
79 | ||
80 | #. type: SH | |
81 | #: en/lb.1:19 en/lb_binary.1:17 en/lb_bootstrap.1:17 en/lb_build.1:17 | |
82 | #: en/lb_chroot.1:17 en/lb_clean.1:38 en/lb_config.1:466 en/lb_source.1:17 | |
83 | #: en/lb_testroot.1:19 en/live-build.7:215 | |
84 | #, no-wrap | |
85 | msgid "FILES" | |
86 | msgstr "FILES" | |
87 | ||
88 | #. type: IP | |
89 | #: en/lb.1:20 en/lb_binary.1:18 en/lb_bootstrap.1:18 en/lb_chroot.1:18 | |
90 | #: en/lb_source.1:18 en/lb_testroot.1:20 | |
91 | #, no-wrap | |
92 | msgid "B<none>" | |
93 | msgstr "B<aucun>" | |
94 | ||
95 | #. type: SH | |
96 | #: en/lb.1:22 en/lb_binary.1:20 en/lb_bootstrap.1:20 en/lb_build.1:22 | |
97 | #: en/lb_chroot.1:20 en/lb_clean.1:43 en/lb_config.1:473 en/lb_source.1:20 | |
98 | #: en/lb_testroot.1:22 en/live-build.7:219 | |
99 | #, no-wrap | |
100 | msgid "SEE ALSO" | |
101 | msgstr "VOIR AUSSI" | |
102 | ||
103 | #. type: Plain text | |
104 | #: en/lb.1:24 en/lb_binary.1:22 en/lb_bootstrap.1:22 en/lb_build.1:24 | |
105 | #: en/lb_chroot.1:22 en/lb_clean.1:45 en/lb_config.1:475 en/lb_source.1:22 | |
106 | #: en/lb_testroot.1:24 | |
107 | msgid "I<live-build>(7)" | |
108 | msgstr "I<live-build>(7)" | |
109 | ||
110 | #. type: Plain text | |
111 | #: en/lb.1:26 en/lb_binary.1:24 en/lb_bootstrap.1:24 en/lb_build.1:26 | |
112 | #: en/lb_chroot.1:24 en/lb_clean.1:47 en/lb_config.1:481 en/lb_source.1:24 | |
113 | #: en/lb_testroot.1:26 en/live-build.7:225 | |
114 | msgid "This program is a part of live-build." | |
115 | msgstr "Ce programme est une partie de live-build." | |
116 | ||
117 | #. type: SH | |
118 | #: en/lb.1:27 en/lb_binary.1:25 en/lb_bootstrap.1:25 en/lb_build.1:27 | |
119 | #: en/lb_chroot.1:25 en/lb_clean.1:48 en/lb_config.1:482 en/lb_source.1:25 | |
120 | #: en/lb_testroot.1:27 en/live-build.7:226 | |
121 | #, no-wrap | |
122 | msgid "HOMEPAGE" | |
123 | msgstr "PAGE D'ACCUEIL" | |
124 | ||
125 | #. type: Plain text | |
126 | #: en/lb.1:29 en/lb_binary.1:27 en/lb_bootstrap.1:27 en/lb_build.1:29 | |
127 | #: en/lb_chroot.1:27 en/lb_clean.1:50 en/lb_config.1:484 en/lb_source.1:27 | |
128 | #: en/lb_testroot.1:29 en/live-build.7:228 | |
129 | msgid "" | |
130 | "More information about live-build and the Live Systems project can be found " | |
131 | "on the homepage at E<lt>I<http://live-systems.org/>E<gt> and in the manual " | |
132 | "at E<lt>I<http://live-systems.org/manual/>E<gt>." | |
133 | msgstr "" | |
134 | "Davantage d'informations à propos de live-build et du projet Live Systems " | |
135 | "peuvent être trouvées sur la page d'accueil à E<lt>I<http://live-systems.org/" | |
136 | ">E<gt> et dans le manuel à E<lt>I<http://live-systems.org/manual/>E<gt>." | |
137 | ||
138 | #. type: SH | |
139 | #: en/lb.1:30 en/lb_binary.1:28 en/lb_bootstrap.1:28 en/lb_build.1:30 | |
140 | #: en/lb_chroot.1:28 en/lb_clean.1:51 en/lb_config.1:485 en/lb_source.1:28 | |
141 | #: en/lb_testroot.1:30 en/live-build.7:229 | |
142 | #, no-wrap | |
143 | msgid "BUGS" | |
144 | msgstr "BOGUES" | |
145 | ||
146 | #. type: Plain text | |
147 | #: en/lb.1:32 en/lb_binary.1:30 en/lb_bootstrap.1:30 en/lb_build.1:32 | |
148 | #: en/lb_chroot.1:30 en/lb_clean.1:53 en/lb_config.1:487 en/lb_source.1:30 | |
149 | #: en/lb_testroot.1:32 en/live-build.7:231 | |
150 | msgid "" | |
151 | "Bugs can be reported by submitting a bugreport for the live-build package in " | |
152 | "the Bug Tracking System at E<lt>I<http://bugs.debian.org/>E<gt> or by " | |
153 | "writing a mail to the Live Systems mailing list at E<lt>I<debian-live@lists." | |
154 | "debian.org>E<gt>." | |
155 | msgstr "" | |
156 | "Les bogues peuvent être signalés en soumettant un rapport de bogue pour le " | |
157 | "paquet live-build dans le BTS à E<lt>I<http://bugs.debian.org/>E<gt> ou par " | |
158 | "l'écriture d'un courriel à la liste de diffusion Live Systems à " | |
159 | "E<lt>I<[email protected]>E<gt>." | |
160 | ||
161 | #. type: SH | |
162 | #: en/lb.1:33 en/lb_binary.1:31 en/lb_bootstrap.1:31 en/lb_build.1:33 | |
163 | #: en/lb_chroot.1:31 en/lb_clean.1:54 en/lb_config.1:488 en/lb_source.1:31 | |
164 | #: en/lb_testroot.1:33 en/live-build.7:232 | |
165 | #, no-wrap | |
166 | msgid "AUTHOR" | |
167 | msgstr "AUTEUR" | |
168 | ||
169 | #. type: Plain text | |
170 | #: en/lb.1:34 en/lb_binary.1:32 en/lb_bootstrap.1:32 en/lb_build.1:34 | |
171 | #: en/lb_chroot.1:32 en/lb_clean.1:55 en/lb_config.1:489 en/lb_source.1:32 | |
172 | #: en/lb_testroot.1:34 en/live-build.7:233 | |
173 | msgid "" | |
174 | "live-build was written by Daniel Baumann E<lt>I<[email protected]>E<gt>." | |
175 | msgstr "" | |
176 | "live-images a été écrit par Daniel Baumann E<lt>I<mail@daniel-baumann." | |
177 | "ch>E<gt>." | |
178 | ||
179 | #. type: Plain text | |
180 | #: en/lb_testroot.1:5 | |
181 | msgid "B<lb testroot> - Ensure that a system is built as root" | |
182 | msgstr "" | |
183 | "B<lb testroot> - s'assure que le système est construit en tant que root" | |
184 | ||
185 | #. type: Plain text | |
186 | #: en/lb_testroot.1:8 | |
187 | msgid "B<lb testroot> [I<live-build options>]" | |
188 | msgstr "B<lb testroot> [I<live-build options>]" | |
189 | ||
190 | #. type: Plain text | |
191 | #: en/lb_testroot.1:11 | |
192 | msgid "" | |
193 | "B<lb testroot> is a high-level command (porcelain) of I<live-build>(7), the " | |
194 | "live systems tool suite." | |
195 | msgstr "" | |
196 | "B<lb testroot> est une commande de haut-niveau (porcelaine) de I<live-" | |
197 | "build>(7), la suite d'outils de live-systems." | |
198 | ||
199 | #. FIXME | |
200 | #. FIXME | |
201 | #. type: Plain text | |
202 | #: en/lb_testroot.1:15 | |
203 | msgid "" | |
204 | "B<lb testroot> simply checks to see if you are root. If not, it exits with " | |
205 | "an error. live system images must currently be built as real root (using " | |
206 | "sudo is fine too)." | |
207 | msgstr "" | |
208 | "B<lb testroot> vérifie simplement si vous êtes administrateur (root). Si vous " | |
209 | "ne l'êtes pas, il s'arrête avec une erreur. Les images live system doivent " | |
210 | "actuellement être construites en qu'administrateur réel (utiliser sudo " | |
211 | "fonctionne également)." | |
212 | ||
213 | #. type: Plain text | |
214 | #: en/lb_testroot.1:18 | |
215 | msgid "" | |
216 | "B<lb testroot> has no specific options but understands all generic live-" | |
217 | "build options. See I<live-build>(7) for a complete list of all generic live-" | |
218 | "build options." | |
219 | msgstr "" | |
220 | "B<lb chroot> n'a pas d'options spécifiques mais fonctionne avec toutes les " | |
221 | "options génériques de live-build. Voir I<live-build>(7) pour une liste " | |
222 | "complète de toutes les options génériques de live-build options." |
0 | # Japanese translations for live-build package | |
1 | # Copyright (C) 2014 victory <[email protected]> | |
2 | # This file is distributed under the same license as the live-build package. | |
3 | # | |
4 | msgid "" | |
5 | msgstr "" | |
6 | "Project-Id-Version: live-build\n" | |
7 | "POT-Creation-Date: 2014-08-27 23:56+0200\n" | |
8 | "PO-Revision-Date: 2014-08-28 02:52+0900\n" | |
9 | "Last-Translator: victory <[email protected]>\n" | |
10 | "Language-Team: none\n" | |
11 | "Language: ja\n" | |
12 | "MIME-Version: 1.0\n" | |
13 | "Content-Type: text/plain; charset=UTF-8\n" | |
14 | "Content-Transfer-Encoding: 8bit\n" | |
15 | ||
16 | #. type: TH | |
17 | #: en/lb.1:1 en/lb_binary.1:1 en/lb_bootstrap.1:1 en/lb_build.1:1 | |
18 | #: en/lb_chroot.1:1 en/lb_clean.1:1 en/lb_config.1:1 en/lb_source.1:1 | |
19 | #: en/lb_testroot.1:1 en/live-build.7:1 | |
20 | #, no-wrap | |
21 | msgid "LIVE-BUILD" | |
22 | msgstr "LIVE-BUILD" | |
23 | ||
24 | #. type: TH | |
25 | #: en/lb.1:1 en/lb_binary.1:1 en/lb_bootstrap.1:1 en/lb_build.1:1 | |
26 | #: en/lb_chroot.1:1 en/lb_clean.1:1 en/lb_config.1:1 en/lb_source.1:1 | |
27 | #: en/lb_testroot.1:1 en/live-build.7:1 | |
28 | #, no-wrap | |
29 | msgid "2014-09-12" | |
30 | msgstr "" | |
31 | ||
32 | #. type: TH | |
33 | #: en/lb.1:1 en/lb_binary.1:1 en/lb_bootstrap.1:1 en/lb_build.1:1 | |
34 | #: en/lb_chroot.1:1 en/lb_clean.1:1 en/lb_config.1:1 en/lb_source.1:1 | |
35 | #: en/lb_testroot.1:1 en/live-build.7:1 | |
36 | #, no-wrap | |
37 | msgid "4.0~alpha39-1" | |
38 | msgstr "4.0~alpha39-1" | |
39 | ||
40 | #. type: TH | |
41 | #: en/lb.1:1 en/lb_binary.1:1 en/lb_bootstrap.1:1 en/lb_build.1:1 | |
42 | #: en/lb_chroot.1:1 en/lb_clean.1:1 en/lb_config.1:1 en/lb_source.1:1 | |
43 | #: en/lb_testroot.1:1 en/live-build.7:1 | |
44 | #, no-wrap | |
45 | msgid "Live Systems Project" | |
46 | msgstr "Live システムプロジェクト" | |
47 | ||
48 | #. type: SH | |
49 | #: en/lb.1:3 en/lb_binary.1:3 en/lb_bootstrap.1:3 en/lb_build.1:3 | |
50 | #: en/lb_chroot.1:3 en/lb_clean.1:3 en/lb_config.1:3 en/lb_source.1:3 | |
51 | #: en/lb_testroot.1:3 en/live-build.7:3 | |
52 | #, no-wrap | |
53 | msgid "NAME" | |
54 | msgstr "名前" | |
55 | ||
56 | #. type: SH | |
57 | #: en/lb.1:6 en/lb_binary.1:6 en/lb_bootstrap.1:6 en/lb_build.1:6 | |
58 | #: en/lb_chroot.1:6 en/lb_clean.1:6 en/lb_config.1:6 en/lb_source.1:6 | |
59 | #: en/lb_testroot.1:6 en/live-build.7:6 | |
60 | #, no-wrap | |
61 | msgid "SYNOPSIS" | |
62 | msgstr "概要" | |
63 | ||
64 | #. type: SH | |
65 | #: en/lb.1:11 en/lb_binary.1:9 en/lb_bootstrap.1:9 en/lb_build.1:9 | |
66 | #: en/lb_chroot.1:9 en/lb_clean.1:9 en/lb_config.1:225 en/lb_source.1:9 | |
67 | #: en/lb_testroot.1:9 en/live-build.7:11 | |
68 | #, no-wrap | |
69 | msgid "DESCRIPTION" | |
70 | msgstr "説明" | |
71 | ||
72 | #. type: SH | |
73 | #: en/lb.1:16 en/lb_binary.1:14 en/lb_bootstrap.1:14 en/lb_build.1:14 | |
74 | #: en/lb_chroot.1:14 en/lb_clean.1:16 en/lb_config.1:234 en/lb_source.1:14 | |
75 | #: en/lb_testroot.1:16 en/live-build.7:20 | |
76 | #, no-wrap | |
77 | msgid "OPTIONS" | |
78 | msgstr "オプション" | |
79 | ||
80 | #. type: SH | |
81 | #: en/lb.1:19 en/lb_binary.1:17 en/lb_bootstrap.1:17 en/lb_build.1:17 | |
82 | #: en/lb_chroot.1:17 en/lb_clean.1:38 en/lb_config.1:466 en/lb_source.1:17 | |
83 | #: en/lb_testroot.1:19 en/live-build.7:215 | |
84 | #, no-wrap | |
85 | msgid "FILES" | |
86 | msgstr "ファイル" | |
87 | ||
88 | #. type: IP | |
89 | #: en/lb.1:20 en/lb_binary.1:18 en/lb_bootstrap.1:18 en/lb_chroot.1:18 | |
90 | #: en/lb_source.1:18 en/lb_testroot.1:20 | |
91 | #, no-wrap | |
92 | msgid "B<none>" | |
93 | msgstr "B<無し>" | |
94 | ||
95 | #. type: SH | |
96 | #: en/lb.1:22 en/lb_binary.1:20 en/lb_bootstrap.1:20 en/lb_build.1:22 | |
97 | #: en/lb_chroot.1:20 en/lb_clean.1:43 en/lb_config.1:473 en/lb_source.1:20 | |
98 | #: en/lb_testroot.1:22 en/live-build.7:219 | |
99 | #, no-wrap | |
100 | msgid "SEE ALSO" | |
101 | msgstr "関連項目" | |
102 | ||
103 | #. type: Plain text | |
104 | #: en/lb.1:24 en/lb_binary.1:22 en/lb_bootstrap.1:22 en/lb_build.1:24 | |
105 | #: en/lb_chroot.1:22 en/lb_clean.1:45 en/lb_config.1:475 en/lb_source.1:22 | |
106 | #: en/lb_testroot.1:24 | |
107 | msgid "I<live-build>(7)" | |
108 | msgstr "I<live-build>(7)" | |
109 | ||
110 | #. type: Plain text | |
111 | #: en/lb.1:26 en/lb_binary.1:24 en/lb_bootstrap.1:24 en/lb_build.1:26 | |
112 | #: en/lb_chroot.1:24 en/lb_clean.1:47 en/lb_config.1:481 en/lb_source.1:24 | |
113 | #: en/lb_testroot.1:26 en/live-build.7:225 | |
114 | msgid "This program is a part of live-build." | |
115 | msgstr "このプログラムは live-build の一部です。" | |
116 | ||
117 | #. type: SH | |
118 | #: en/lb.1:27 en/lb_binary.1:25 en/lb_bootstrap.1:25 en/lb_build.1:27 | |
119 | #: en/lb_chroot.1:25 en/lb_clean.1:48 en/lb_config.1:482 en/lb_source.1:25 | |
120 | #: en/lb_testroot.1:27 en/live-build.7:226 | |
121 | #, no-wrap | |
122 | msgid "HOMEPAGE" | |
123 | msgstr "ホームページ" | |
124 | ||
125 | #. type: Plain text | |
126 | #: en/lb.1:29 en/lb_binary.1:27 en/lb_bootstrap.1:27 en/lb_build.1:29 | |
127 | #: en/lb_chroot.1:27 en/lb_clean.1:50 en/lb_config.1:484 en/lb_source.1:27 | |
128 | #: en/lb_testroot.1:29 en/live-build.7:228 | |
129 | msgid "" | |
130 | "More information about live-build and the Live Systems project can be found " | |
131 | "on the homepage at E<lt>I<http://live-systems.org/>E<gt> and in the manual " | |
132 | "at E<lt>I<http://live-systems.org/manual/>E<gt>." | |
133 | msgstr "" | |
134 | "live-build 及び Live システムプロジェクトについてのさらなる情報は、" | |
135 | "E<lt>I<http://live-systems.org/>E<gt> のホームページや E<lt>I<http://live-" | |
136 | "systems.org/manual/>E<gt> のマニュアルにあります。" | |
137 | ||
138 | #. type: SH | |
139 | #: en/lb.1:30 en/lb_binary.1:28 en/lb_bootstrap.1:28 en/lb_build.1:30 | |
140 | #: en/lb_chroot.1:28 en/lb_clean.1:51 en/lb_config.1:485 en/lb_source.1:28 | |
141 | #: en/lb_testroot.1:30 en/live-build.7:229 | |
142 | #, no-wrap | |
143 | msgid "BUGS" | |
144 | msgstr "バグ" | |
145 | ||
146 | #. type: Plain text | |
147 | #: en/lb.1:32 en/lb_binary.1:30 en/lb_bootstrap.1:30 en/lb_build.1:32 | |
148 | #: en/lb_chroot.1:30 en/lb_clean.1:53 en/lb_config.1:487 en/lb_source.1:30 | |
149 | #: en/lb_testroot.1:32 en/live-build.7:231 | |
150 | msgid "" | |
151 | "Bugs can be reported by submitting a bugreport for the live-build package in " | |
152 | "the Bug Tracking System at E<lt>I<http://bugs.debian.org/>E<gt> or by " | |
153 | "writing a mail to the Live Systems mailing list at E<lt>I<debian-live@lists." | |
154 | "debian.org>E<gt>." | |
155 | msgstr "" | |
156 | "バグは E<lt>I<http://bugs.debian.org/>E<gt> にあるバグ追跡システムに live-" | |
157 | "build パッケージのバグ報告として提出するか、E<lt>I<[email protected]." | |
158 | "org>E<gt> にある Live システムのメーリングリスト宛てにメールを書くことにより" | |
159 | "報告できます。" | |
160 | ||
161 | #. type: SH | |
162 | #: en/lb.1:33 en/lb_binary.1:31 en/lb_bootstrap.1:31 en/lb_build.1:33 | |
163 | #: en/lb_chroot.1:31 en/lb_clean.1:54 en/lb_config.1:488 en/lb_source.1:31 | |
164 | #: en/lb_testroot.1:33 en/live-build.7:232 | |
165 | #, no-wrap | |
166 | msgid "AUTHOR" | |
167 | msgstr "作者" | |
168 | ||
169 | #. type: Plain text | |
170 | #: en/lb.1:34 en/lb_binary.1:32 en/lb_bootstrap.1:32 en/lb_build.1:34 | |
171 | #: en/lb_chroot.1:32 en/lb_clean.1:55 en/lb_config.1:489 en/lb_source.1:32 | |
172 | #: en/lb_testroot.1:34 en/live-build.7:233 | |
173 | msgid "" | |
174 | "live-build was written by Daniel Baumann E<lt>I<[email protected]>E<gt>." | |
175 | msgstr "" | |
176 | "live-build は Daniel Baumann さん E<lt>I<[email protected]>E<gt> により" | |
177 | "書かれました。" | |
178 | ||
179 | #. type: Plain text | |
180 | #: en/lb_testroot.1:5 | |
181 | msgid "B<lb testroot> - Ensure that a system is built as root" | |
182 | msgstr "B<lb testroot> - システムが root により構成されていることを確認します" | |
183 | ||
184 | #. type: Plain text | |
185 | #: en/lb_testroot.1:8 | |
186 | msgid "B<lb testroot> [I<live-build options>]" | |
187 | msgstr "B<lb testroot> [I<live-build オプション>]" | |
188 | ||
189 | #. type: Plain text | |
190 | #: en/lb_testroot.1:11 | |
191 | msgid "" | |
192 | "B<lb testroot> is a high-level command (porcelain) of I<live-build>(7), the " | |
193 | "live systems tool suite." | |
194 | msgstr "" | |
195 | "B<lb testroot> は Live システムツール集 I<live-build>(7) の高レベルコマンド " | |
196 | "(porcelain) です。" | |
197 | ||
198 | #. FIXME | |
199 | #. FIXME | |
200 | #. type: Plain text | |
201 | #: en/lb_testroot.1:15 | |
202 | msgid "" | |
203 | "B<lb testroot> simply checks to see if you are root. If not, it exits with " | |
204 | "an error. live system images must currently be built as real root (using " | |
205 | "sudo is fine too)." | |
206 | msgstr "" | |
207 | "B<lb testroot> は単に root で実行しているのか確認します。root でない場合はエ" | |
208 | "ラーを返して終了します。Live システムのイメージは現在実際の root (sudo を使っ" | |
209 | "ても可) でビルドる必要があります。" | |
210 | ||
211 | #. type: Plain text | |
212 | #: en/lb_testroot.1:18 | |
213 | msgid "" | |
214 | "B<lb testroot> has no specific options but understands all generic live-" | |
215 | "build options. See I<live-build>(7) for a complete list of all generic live-" | |
216 | "build options." | |
217 | msgstr "" | |
218 | "B<lb testroot> には特定のオプションはありませんが、live-build 全般のオプ" | |
219 | "ションを全て理解します。live-build 全般のオプションの全容については I<live-" | |
220 | "build>(7) を見てください。" |
0 | # SOME DESCRIPTIVE TITLE | |
1 | # Copyright (C) YEAR Free Software Foundation, Inc. | |
2 | # This file is distributed under the same license as the live-build package. | |
3 | # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. | |
4 | # | |
5 | #, fuzzy | |
6 | msgid "" | |
7 | msgstr "" | |
8 | "Project-Id-Version: live-build 4.0~alpha39-1\n" | |
9 | "POT-Creation-Date: 2014-08-27 23:56+0200\n" | |
10 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" | |
11 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" | |
12 | "Language-Team: LANGUAGE <[email protected]>\n" | |
13 | "Language: \n" | |
14 | "MIME-Version: 1.0\n" | |
15 | "Content-Type: text/plain; charset=CHARSET\n" | |
16 | "Content-Transfer-Encoding: 8bit\n" | |
17 | ||
18 | #. type: TH | |
19 | #: en/lb.1:1 en/lb_binary.1:1 en/lb_bootstrap.1:1 en/lb_build.1:1 | |
20 | #: en/lb_chroot.1:1 en/lb_clean.1:1 en/lb_config.1:1 en/lb_source.1:1 | |
21 | #: en/lb_testroot.1:1 en/live-build.7:1 | |
22 | #, no-wrap | |
23 | msgid "LIVE-BUILD" | |
24 | msgstr "" | |
25 | ||
26 | #. type: TH | |
27 | #: en/lb.1:1 en/lb_binary.1:1 en/lb_bootstrap.1:1 en/lb_build.1:1 | |
28 | #: en/lb_chroot.1:1 en/lb_clean.1:1 en/lb_config.1:1 en/lb_source.1:1 | |
29 | #: en/lb_testroot.1:1 en/live-build.7:1 | |
30 | #, no-wrap | |
31 | msgid "2014-08-27" | |
32 | msgstr "" | |
33 | ||
34 | #. type: TH | |
35 | #: en/lb.1:1 en/lb_binary.1:1 en/lb_bootstrap.1:1 en/lb_build.1:1 | |
36 | #: en/lb_chroot.1:1 en/lb_clean.1:1 en/lb_config.1:1 en/lb_source.1:1 | |
37 | #: en/lb_testroot.1:1 en/live-build.7:1 | |
38 | #, no-wrap | |
39 | msgid "4.0~alpha39-1" | |
40 | msgstr "" | |
41 | ||
42 | #. type: TH | |
43 | #: en/lb.1:1 en/lb_binary.1:1 en/lb_bootstrap.1:1 en/lb_build.1:1 | |
44 | #: en/lb_chroot.1:1 en/lb_clean.1:1 en/lb_config.1:1 en/lb_source.1:1 | |
45 | #: en/lb_testroot.1:1 en/live-build.7:1 | |
46 | #, no-wrap | |
47 | msgid "Live Systems Project" | |
48 | msgstr "" | |
49 | ||
50 | #. type: SH | |
51 | #: en/lb.1:3 en/lb_binary.1:3 en/lb_bootstrap.1:3 en/lb_build.1:3 | |
52 | #: en/lb_chroot.1:3 en/lb_clean.1:3 en/lb_config.1:3 en/lb_source.1:3 | |
53 | #: en/lb_testroot.1:3 en/live-build.7:3 | |
54 | #, no-wrap | |
55 | msgid "NAME" | |
56 | msgstr "" | |
57 | ||
58 | #. type: SH | |
59 | #: en/lb.1:6 en/lb_binary.1:6 en/lb_bootstrap.1:6 en/lb_build.1:6 | |
60 | #: en/lb_chroot.1:6 en/lb_clean.1:6 en/lb_config.1:6 en/lb_source.1:6 | |
61 | #: en/lb_testroot.1:6 en/live-build.7:6 | |
62 | #, no-wrap | |
63 | msgid "SYNOPSIS" | |
64 | msgstr "" | |
65 | ||
66 | #. type: SH | |
67 | #: en/lb.1:11 en/lb_binary.1:9 en/lb_bootstrap.1:9 en/lb_build.1:9 | |
68 | #: en/lb_chroot.1:9 en/lb_clean.1:9 en/lb_config.1:225 en/lb_source.1:9 | |
69 | #: en/lb_testroot.1:9 en/live-build.7:11 | |
70 | #, no-wrap | |
71 | msgid "DESCRIPTION" | |
72 | msgstr "" | |
73 | ||
74 | #. type: SH | |
75 | #: en/lb.1:16 en/lb_binary.1:14 en/lb_bootstrap.1:14 en/lb_build.1:14 | |
76 | #: en/lb_chroot.1:14 en/lb_clean.1:16 en/lb_config.1:234 en/lb_source.1:14 | |
77 | #: en/lb_testroot.1:16 en/live-build.7:20 | |
78 | #, no-wrap | |
79 | msgid "OPTIONS" | |
80 | msgstr "" | |
81 | ||
82 | #. type: SH | |
83 | #: en/lb.1:19 en/lb_binary.1:17 en/lb_bootstrap.1:17 en/lb_build.1:17 | |
84 | #: en/lb_chroot.1:17 en/lb_clean.1:38 en/lb_config.1:466 en/lb_source.1:17 | |
85 | #: en/lb_testroot.1:19 en/live-build.7:215 | |
86 | #, no-wrap | |
87 | msgid "FILES" | |
88 | msgstr "" | |
89 | ||
90 | #. type: IP | |
91 | #: en/lb.1:20 en/lb_binary.1:18 en/lb_bootstrap.1:18 en/lb_chroot.1:18 | |
92 | #: en/lb_source.1:18 en/lb_testroot.1:20 | |
93 | #, no-wrap | |
94 | msgid "B<none>" | |
95 | msgstr "" | |
96 | ||
97 | #. type: SH | |
98 | #: en/lb.1:22 en/lb_binary.1:20 en/lb_bootstrap.1:20 en/lb_build.1:22 | |
99 | #: en/lb_chroot.1:20 en/lb_clean.1:43 en/lb_config.1:473 en/lb_source.1:20 | |
100 | #: en/lb_testroot.1:22 en/live-build.7:219 | |
101 | #, no-wrap | |
102 | msgid "SEE ALSO" | |
103 | msgstr "" | |
104 | ||
105 | #. type: Plain text | |
106 | #: en/lb.1:24 en/lb_binary.1:22 en/lb_bootstrap.1:22 en/lb_build.1:24 | |
107 | #: en/lb_chroot.1:22 en/lb_clean.1:45 en/lb_config.1:475 en/lb_source.1:22 | |
108 | #: en/lb_testroot.1:24 | |
109 | msgid "I<live-build>(7)" | |
110 | msgstr "" | |
111 | ||
112 | #. type: Plain text | |
113 | #: en/lb.1:26 en/lb_binary.1:24 en/lb_bootstrap.1:24 en/lb_build.1:26 | |
114 | #: en/lb_chroot.1:24 en/lb_clean.1:47 en/lb_config.1:481 en/lb_source.1:24 | |
115 | #: en/lb_testroot.1:26 en/live-build.7:225 | |
116 | msgid "This program is a part of live-build." | |
117 | msgstr "" | |
118 | ||
119 | #. type: SH | |
120 | #: en/lb.1:27 en/lb_binary.1:25 en/lb_bootstrap.1:25 en/lb_build.1:27 | |
121 | #: en/lb_chroot.1:25 en/lb_clean.1:48 en/lb_config.1:482 en/lb_source.1:25 | |
122 | #: en/lb_testroot.1:27 en/live-build.7:226 | |
123 | #, no-wrap | |
124 | msgid "HOMEPAGE" | |
125 | msgstr "" | |
126 | ||
127 | #. type: Plain text | |
128 | #: en/lb.1:29 en/lb_binary.1:27 en/lb_bootstrap.1:27 en/lb_build.1:29 | |
129 | #: en/lb_chroot.1:27 en/lb_clean.1:50 en/lb_config.1:484 en/lb_source.1:27 | |
130 | #: en/lb_testroot.1:29 en/live-build.7:228 | |
131 | msgid "" | |
132 | "More information about live-build and the Live Systems project can be found " | |
133 | "on the homepage at E<lt>I<http://live-systems.org/>E<gt> and in the manual " | |
134 | "at E<lt>I<http://live-systems.org/manual/>E<gt>." | |
135 | msgstr "" | |
136 | ||
137 | #. type: SH | |
138 | #: en/lb.1:30 en/lb_binary.1:28 en/lb_bootstrap.1:28 en/lb_build.1:30 | |
139 | #: en/lb_chroot.1:28 en/lb_clean.1:51 en/lb_config.1:485 en/lb_source.1:28 | |
140 | #: en/lb_testroot.1:30 en/live-build.7:229 | |
141 | #, no-wrap | |
142 | msgid "BUGS" | |
143 | msgstr "" | |
144 | ||
145 | #. type: Plain text | |
146 | #: en/lb.1:32 en/lb_binary.1:30 en/lb_bootstrap.1:30 en/lb_build.1:32 | |
147 | #: en/lb_chroot.1:30 en/lb_clean.1:53 en/lb_config.1:487 en/lb_source.1:30 | |
148 | #: en/lb_testroot.1:32 en/live-build.7:231 | |
149 | msgid "" | |
150 | "Bugs can be reported by submitting a bugreport for the live-build package in " | |
151 | "the Bug Tracking System at E<lt>I<http://bugs.debian.org/>E<gt> or by " | |
152 | "writing a mail to the Live Systems mailing list at E<lt>I<debian-live@lists." | |
153 | "debian.org>E<gt>." | |
154 | msgstr "" | |
155 | ||
156 | #. type: SH | |
157 | #: en/lb.1:33 en/lb_binary.1:31 en/lb_bootstrap.1:31 en/lb_build.1:33 | |
158 | #: en/lb_chroot.1:31 en/lb_clean.1:54 en/lb_config.1:488 en/lb_source.1:31 | |
159 | #: en/lb_testroot.1:33 en/live-build.7:232 | |
160 | #, no-wrap | |
161 | msgid "AUTHOR" | |
162 | msgstr "" | |
163 | ||
164 | #. type: Plain text | |
165 | #: en/lb.1:34 en/lb_binary.1:32 en/lb_bootstrap.1:32 en/lb_build.1:34 | |
166 | #: en/lb_chroot.1:32 en/lb_clean.1:55 en/lb_config.1:489 en/lb_source.1:32 | |
167 | #: en/lb_testroot.1:34 en/live-build.7:233 | |
168 | msgid "" | |
169 | "live-build was written by Daniel Baumann E<lt>I<[email protected]>E<gt>." | |
170 | msgstr "" | |
171 | ||
172 | #. type: Plain text | |
173 | #: en/lb_testroot.1:5 | |
174 | msgid "B<lb testroot> - Ensure that a system is built as root" | |
175 | msgstr "" | |
176 | ||
177 | #. type: Plain text | |
178 | #: en/lb_testroot.1:8 | |
179 | msgid "B<lb testroot> [I<live-build options>]" | |
180 | msgstr "" | |
181 | ||
182 | #. type: Plain text | |
183 | #: en/lb_testroot.1:11 | |
184 | msgid "" | |
185 | "B<lb testroot> is a high-level command (porcelain) of I<live-build>(7), the " | |
186 | "live systems tool suite." | |
187 | msgstr "" | |
188 | ||
189 | #. FIXME | |
190 | #. FIXME | |
191 | #. type: Plain text | |
192 | #: en/lb_testroot.1:15 | |
193 | msgid "" | |
194 | "B<lb testroot> simply checks to see if you are root. If not, it exits with " | |
195 | "an error. live system images must currently be built as real root (using " | |
196 | "sudo is fine too)." | |
197 | msgstr "" | |
198 | ||
199 | #. type: Plain text | |
200 | #: en/lb_testroot.1:18 | |
201 | msgid "" | |
202 | "B<lb testroot> has no specific options but understands all generic live-" | |
203 | "build options. See I<live-build>(7) for a complete list of all generic live-" | |
204 | "build options." | |
205 | msgstr "" |
68 | 68 | lb binary_win32-loader ${@} |
69 | 69 | lb binary_includes ${@} |
70 | 70 | lb binary_hooks ${@} |
71 | lb binary_grub-efi ${@} | |
71 | 72 | lb binary_checksums ${@} |
72 | 73 | |
73 | 74 | if [ "${LB_BUILD_WITH_CHROOT}" != "true" ] |
0 | #!/bin/sh | |
1 | ||
2 | ## live-build(7) - System Build Scripts | |
3 | ## Copyright (C) 2016 Adrian Gibanel Lopez <[email protected]> | |
4 | ## | |
5 | ## This program comes with ABSOLUTELY NO WARRANTY; for details see COPYING. | |
6 | ## This is free software, and you are welcome to redistribute it | |
7 | ## under certain conditions; see COPYING for details. | |
8 | ||
9 | ||
10 | set -e | |
11 | ||
12 | # Including common functions | |
13 | [ -e "${LIVE_BUILD}/scripts/build.sh" ] && . "${LIVE_BUILD}/scripts/build.sh" || . /usr/lib/live/build.sh | |
14 | ||
15 | # Setting static variables | |
16 | DESCRIPTION="$(Echo 'prepares and installs Grub based EFI support into binary')" | |
17 | HELP="" | |
18 | USAGE="${PROGRAM} [--force]" | |
19 | ||
20 | Arguments "${@}" | |
21 | ||
22 | # Reading configuration files | |
23 | Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source | |
24 | Set_defaults | |
25 | ||
26 | Check_Any_Bootloader_Role "grub-efi" | |
27 | ||
28 | Echo_message "Begin preparing Grub based EFI support..." | |
29 | ||
30 | # Requiring stage file | |
31 | Require_stagefile .build/config .build/bootstrap | |
32 | ||
33 | # Checking stage file | |
34 | Check_stagefile .build/binary_grub-efi | |
35 | ||
36 | # Checking lock file | |
37 | Check_lockfile .lock | |
38 | ||
39 | # Creating lock file | |
40 | Create_lockfile .lock | |
41 | ||
42 | # Check architecture | |
43 | Check_architectures amd64 i386 | |
44 | Check_crossarchitectures | |
45 | ||
46 | # Checking depends | |
47 | case "${LB_BUILD_WITH_CHROOT}" in | |
48 | true) | |
49 | _CHROOT_DIR="" | |
50 | ||
51 | Check_package chroot /usr/lib/grub/x86_64-efi/configfile.mod grub-efi-amd64-bin | |
52 | Check_package chroot /usr/lib/grub/i386-efi/configfile.mod grub-efi-ia32-bin | |
53 | Check_package chroot /usr/bin/grub-mkimage grub-common | |
54 | Check_package chroot /usr/bin/mcopy mtools | |
55 | Check_package chroot /sbin/mkfs.msdos dosfstools | |
56 | ;; | |
57 | ||
58 | false) | |
59 | _CHROOT_DIR="chroot" | |
60 | ||
61 | if [ ! -e /usr/lib/grub/x86_64-efi ] | |
62 | then | |
63 | # grub-efi-amd64-bin | |
64 | Echo_error "/usr/lib/grub/x86_64-efi - no such directory" | |
65 | exit 1 | |
66 | fi | |
67 | ||
68 | if [ ! -e /usr/lib/grub/i386-efi ] | |
69 | then | |
70 | # grub-efi-ia32-bin | |
71 | Echo_error "/usr/lib/grub/i386-efi - no such directory" | |
72 | exit 1 | |
73 | fi | |
74 | ||
75 | if [ ! -e /usr/bin/grub-mkimage ] | |
76 | then | |
77 | # grub-common | |
78 | Echo_error "/usr/bin/grub-mkimage - no such file." | |
79 | exit 1 | |
80 | fi | |
81 | ||
82 | if [ ! -e /usr/bin/mcopy ] | |
83 | then | |
84 | # mtools | |
85 | Echo_error "/usr/bin/mcopy - no such file." | |
86 | exit 1 | |
87 | fi | |
88 | ||
89 | if [ ! -e /sbin/mkfs.msdos ] | |
90 | then | |
91 | # dosfstools | |
92 | Echo_error "/sbin/mkfs.msdos - no such file." | |
93 | exit 1 | |
94 | fi | |
95 | ;; | |
96 | esac | |
97 | ||
98 | # Setting destination directory | |
99 | case "${LIVE_IMAGE_TYPE}" in | |
100 | hdd*|netboot) | |
101 | Echo_warning "Bootloader in this image type not yet supported by live-build." | |
102 | Echo_warning "This would produce a not bootable image, aborting (FIXME)." | |
103 | exit 1 | |
104 | ;; | |
105 | esac | |
106 | ||
107 | # Restoring cache | |
108 | Restore_cache cache/packages.binary | |
109 | ||
110 | # Installing depends | |
111 | Install_package | |
112 | ||
113 | # Cleanup files that we generate | |
114 | rm -rf binary/boot/efi.img binary/boot/grub/i386-efi/ binary/boot/grub/x86_64-efi | |
115 | ||
116 | # This is workaround till both efi-image and grub-cpmodules are put into a binary package | |
117 | case "${LB_BUILD_WITH_CHROOT}" in | |
118 | true) | |
119 | if [ ! -e "${LIVE_BUILD}" ] ; then | |
120 | LIVE_BUILD_PATH="/usr/lib/live/build" | |
121 | else | |
122 | LIVE_BUILD_PATH="${LIVE_BUILD}/scripts/build" | |
123 | fi | |
124 | mkdir -p chroot/${LIVE_BUILD_PATH} | |
125 | cp "${LIVE_BUILD_PATH}/efi-image" "chroot/${LIVE_BUILD_PATH}" | |
126 | cp "${LIVE_BUILD_PATH}/grub-cpmodules" "chroot/${LIVE_BUILD_PATH}" | |
127 | ;; | |
128 | esac | |
129 | ##### | |
130 | cat >binary.sh <<END | |
131 | #!/bin/sh | |
132 | ||
133 | set -e | |
134 | ||
135 | PRE_EFI_IMAGE_PATH="${PATH}" | |
136 | if [ ! -e "${LIVE_BUILD}" ] ; then | |
137 | LIVE_BUILD_PATH="/usr/lib/live/build" | |
138 | else | |
139 | LIVE_BUILD_PATH="${LIVE_BUILD}/scripts/build" | |
140 | fi | |
141 | ||
142 | PATH="${PATH}:\${LIVE_BUILD_PATH}" # Make sure grub-cpmodules is used as if it was installed in the system | |
143 | ||
144 | "\${LIVE_BUILD_PATH}/efi-image" "${_CHROOT_DIR}/grub-efi-temp-x86_64-efi/" "x86_64-efi" "x64" "debian-live/amd64" | |
145 | mkdir -p ${_CHROOT_DIR}/grub-efi-temp/efi/boot | |
146 | mcopy -n -i ${_CHROOT_DIR}/grub-efi-temp-x86_64-efi/efi.img '::efi/boot/boot*.efi' ${_CHROOT_DIR}/grub-efi-temp/efi/boot | |
147 | cp -r "${_CHROOT_DIR}"/grub-efi-temp-x86_64-efi/* "${_CHROOT_DIR}/grub-efi-temp/" | |
148 | ||
149 | "\${LIVE_BUILD_PATH}/efi-image" "${_CHROOT_DIR}/grub-efi-temp-i386-efi/" "i386-efi" "ia32" "debian-live/i386" | |
150 | PATH="\${PRE_EFI_IMAGE_PATH}" | |
151 | mkdir -p ${_CHROOT_DIR}/grub-efi-temp/efi/boot | |
152 | mcopy -n -i ${_CHROOT_DIR}/grub-efi-temp-i386-efi/efi.img '::efi/boot/boot*.efi' ${_CHROOT_DIR}/grub-efi-temp/efi/boot | |
153 | cp -r "${_CHROOT_DIR}"/grub-efi-temp-i386-efi/* "${_CHROOT_DIR}/grub-efi-temp/" | |
154 | ||
155 | # The code below is adapted from tools/boot/jessie/boot-x86 | |
156 | # in debian-cd | |
157 | ||
158 | # Stuff the EFI boot files into a FAT filesystem, making it as | |
159 | # small as possible. 24KiB headroom seems to be enough; | |
160 | # (x+31)/32*32 rounds up to multiple of 32. | |
161 | # This is the same as in efi-image, but we need to redo it here in | |
162 | # the case of a multi-arch amd64/i386 image | |
163 | ||
164 | size=0 | |
165 | for file in ${_CHROOT_DIR}/grub-efi-temp/efi/boot/boot*.efi; do | |
166 | size=\$((\$size + \$(stat -c %s "\$file"))) | |
167 | done | |
168 | ||
169 | blocks=\$(((\$size / 1024 + 55) / 32 * 32 )) | |
170 | ||
171 | rm -f ${_CHROOT_DIR}/grub-efi-temp/boot/grub/efi.img | |
172 | mkfs.msdos -C "${_CHROOT_DIR}/grub-efi-temp/boot/grub/efi.img" \$blocks >/dev/null | |
173 | mmd -i "${_CHROOT_DIR}/grub-efi-temp/boot/grub/efi.img" ::efi | |
174 | mmd -i "${_CHROOT_DIR}/grub-efi-temp/boot/grub/efi.img" ::efi/boot | |
175 | mcopy -o -i "${_CHROOT_DIR}/grub-efi-temp/boot/grub/efi.img" ${_CHROOT_DIR}/grub-efi-temp/efi/boot/boot*.efi \ | |
176 | "::efi/boot" | |
177 | END | |
178 | ||
179 | case "${LB_BUILD_WITH_CHROOT}" in | |
180 | true) | |
181 | mv binary.sh chroot/ | |
182 | Chroot chroot "sh binary.sh" | |
183 | rm -f chroot/binary.sh | |
184 | ||
185 | # Saving cache | |
186 | Save_cache cache/packages.binary | |
187 | ||
188 | # Removing depends | |
189 | Remove_package | |
190 | ;; | |
191 | ||
192 | false) | |
193 | sh binary.sh | |
194 | rm -f binary.sh | |
195 | ;; | |
196 | esac | |
197 | ||
198 | # Remove unnecessary files | |
199 | rm -f chroot/grub-efi-temp/bootnetia32.efi | |
200 | rm -f chroot/grub-efi-temp/bootnetx64.efi | |
201 | ||
202 | mkdir -p binary | |
203 | cp -r chroot/grub-efi-temp/* binary/ | |
204 | rm -rf chroot/grub-efi-temp-x86_64-efi | |
205 | rm -rf chroot/grub-efi-temp-i386-efi | |
206 | rm -rf chroot/grub-efi-temp | |
207 | ||
208 | # We rely on: binary_loopback_cfg to generate grub.cfg and other configuration files | |
209 | ||
210 | # Creating stage file | |
211 | Create_stagefile .build/binary_grub-efi |
23 | 23 | Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source |
24 | 24 | Set_defaults |
25 | 25 | |
26 | FOUND_MYSELF="" | |
27 | IFS="," | |
28 | for BOOTLOADER in ${LB_BOOTLOADERS} | |
29 | do | |
30 | ||
31 | case ${BOOTLOADER} in | |
32 | "grub-legacy" ) | |
33 | FOUND_MYSELF="True" | |
34 | break ;; | |
35 | esac | |
36 | ||
37 | done | |
38 | ||
39 | if [ -z ${FOUND_MYSELF} ] ; then | |
40 | exit 0 | |
41 | fi | |
26 | Check_First_Bootloader_Role "grub-legacy" | |
42 | 27 | |
43 | 28 | Echo_message "Begin installing grub-legacy..." |
44 | 29 | |
178 | 163 | mkdir -p "${DESTDIR_LIVE}" |
179 | 164 | |
180 | 165 | # Setting boot parameters |
181 | if [ "${LB_UNION_FILESYSTEM}" != "aufs" ] | |
166 | if [ "${LB_UNION_FILESYSTEM}" != "overlay" ] | |
182 | 167 | then |
183 | 168 | LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} union=${LB_UNION_FILESYSTEM}" |
184 | 169 | fi |
23 | 23 | Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source |
24 | 24 | Set_defaults |
25 | 25 | |
26 | FOUND_MYSELF="" | |
27 | OLDIFS="$IFS" | |
28 | IFS="," | |
29 | for BOOTLOADER in ${LB_BOOTLOADERS} | |
30 | do | |
31 | ||
32 | case ${BOOTLOADER} in | |
33 | "grub-pc" ) | |
34 | FOUND_MYSELF="True" | |
35 | break ;; | |
36 | esac | |
37 | ||
38 | done | |
39 | IFS="$OLDIFS" | |
40 | ||
41 | if [ -z ${FOUND_MYSELF} ] ; then | |
42 | exit 0 | |
43 | fi | |
26 | Check_Any_Bootloader_Role "grub-pc" | |
44 | 27 | |
45 | 28 | Echo_message "Begin installing grub-pc..." |
46 | 29 | |
69 | 52 | # Installing depends |
70 | 53 | Install_package |
71 | 54 | |
72 | # Local functions | |
73 | Grub_live_entry () | |
74 | { | |
75 | LABEL="${1}" | |
76 | KERNEL="${2}" | |
77 | INITRD="${3}" | |
78 | APPEND="${4}" | |
79 | ||
80 | LINUX_LIVE="${LINUX_LIVE}\nmenuentry \"Debian GNU/Linux - ${LABEL}\" {" | |
81 | LINUX_LIVE="${LINUX_LIVE}\nlinux\t\t/${KERNEL} ${INITFS:+boot=${INITFS} }config LB_BOOTAPPEND_LIVE ${APPEND}" | |
82 | LINUX_LIVE="${LINUX_LIVE}\ninitrd\t\t/${INITRD}" | |
83 | LINUX_LIVE="${LINUX_LIVE}\n}" | |
84 | } | |
85 | ||
86 | Grub_install_entry () | |
87 | { | |
88 | LABEL="${1}" | |
89 | KERNEL="${2}" | |
90 | INITRD="${3}" | |
91 | APPEND="${4}" | |
92 | ||
93 | if [ "${LABEL}" != "rescue" ] && [ "${LABEL}" != "rescuegui" ] | |
94 | then | |
95 | APPEND="${APPEND} quiet" | |
96 | fi | |
97 | ||
98 | LINUX_INSTALL="${LINUX_INSTALL}\nmenuentry \"Debian GNU/Linux - ${LABEL}\" {" | |
99 | LINUX_INSTALL="${LINUX_INSTALL}\nlinux\t\t/${KERNEL} ${APPEND} LB_BOOTAPPEND_INSTALL" | |
100 | LINUX_INSTALL="${LINUX_INSTALL}\ninitrd\t\t/${INITRD}" | |
101 | LINUX_INSTALL="${LINUX_INSTALL}\n}" | |
102 | } | |
103 | ||
104 | if [ -e "config/bootloaders/grub-pc" ] | |
105 | then | |
106 | # Internal local copy | |
107 | _SOURCE="config/bootloaders/grub-pc" | |
108 | else | |
109 | # Internal system copy | |
110 | if [ -n "${LIVE_BUILD}" ] | |
111 | then | |
112 | _SOURCE="${LIVE_BUILD}/share/bootloaders/grub-pc" | |
113 | else | |
114 | _SOURCE="/usr/share/live/build/bootloaders/grub-pc" | |
115 | fi | |
116 | fi | |
117 | ||
118 | case "${LB_INITRAMFS}" in | |
119 | live-boot) | |
120 | INITFS="live" | |
121 | ;; | |
122 | ||
123 | *) | |
124 | INITFS="" | |
125 | ;; | |
126 | esac | |
127 | ||
128 | 55 | # Setting destination directory |
129 | 56 | case "${LIVE_IMAGE_TYPE}" in |
130 | iso*|tar) | |
131 | case "${LB_INITRAMFS}" in | |
132 | live-boot) | |
133 | DESTDIR_LIVE="binary/live" | |
134 | ;; | |
135 | ||
136 | *) | |
137 | DESTDIR_LIVE="binary/live" | |
138 | ;; | |
139 | esac | |
140 | ||
141 | DESTDIR_INSTALL="binary/install" | |
142 | ;; | |
143 | ||
144 | 57 | hdd*|netboot) |
145 | 58 | Echo_warning "Bootloader in this image type not yet supported by live-build." |
146 | 59 | Echo_warning "This would produce a not bootable image, aborting (FIXME)." |
150 | 63 | |
151 | 64 | Check_multiarchitectures |
152 | 65 | |
153 | # Creating directory | |
154 | mkdir -p "${DESTDIR_LIVE}" | |
155 | ||
156 | # Setting boot parameters | |
157 | if [ "${LB_UNION_FILESYSTEM}" != "aufs" ] | |
158 | then | |
159 | LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} union=${LB_UNION_FILESYSTEM}" | |
160 | fi | |
161 | ||
162 | if [ -n "${LB_NET_COW_PATH}" ] | |
163 | then | |
164 | Echo_error "Net cow not yet supported on grub" | |
165 | exit 1 | |
166 | fi | |
167 | ||
168 | LB_BOOTAPPEND_LIVE="$(echo ${LB_BOOTAPPEND_LIVE} | sed -e 's| ||')" | |
169 | ||
170 | # Assembling kernel configuration | |
171 | ||
172 | # Default entries | |
173 | DEFAULT_FLAVOUR="$(echo ${LB_LINUX_FLAVOURS} | awk '{ print $1 }')" | |
174 | DEFAULT_KERNEL="$(basename chroot/boot/vmlinuz-*${DEFAULT_FLAVOUR})" | |
175 | DEFAULT_INITRD="initrd.img-$(echo ${DEFAULT_KERNEL} | sed -e 's|vmlinuz-||')" | |
176 | ||
177 | Grub_live_entry "live" "$(basename ${DESTDIR_LIVE})/${DEFAULT_KERNEL}" "$(basename ${DESTDIR_LIVE})/${DEFAULT_INITRD}" | |
178 | ||
179 | if [ "${LB_BOOTAPPEND_FAILSAFE}" != "none" ] | |
180 | then | |
181 | Grub_live_entry "live (fail-safe mode)" "$(basename ${DESTDIR_LIVE})/${DEFAULT_KERNEL}" "$(basename ${DESTDIR_LIVE})/${DEFAULT_INITRD}" "${LB_BOOTAPPEND_FAILSAFE}" | |
182 | fi | |
183 | ||
184 | for KERNEL in chroot/boot/vmlinuz-* | |
185 | do | |
186 | VERSION="$(basename ${KERNEL} | sed -e 's|vmlinuz-||')" | |
187 | ||
188 | Grub_live_entry "live, kernel ${VERSION}" "$(basename ${DESTDIR_LIVE})/$(basename ${KERNEL})" "$(basename ${DESTDIR_LIVE})/initrd.img-${VERSION}" | |
189 | Grub_live_entry "live, kernel ${VERSION} (fail-safe mode)" "$(basename ${DESTDIR_LIVE})/$(basename ${KERNEL})" "$(basename ${DESTDIR_LIVE})/initrd.img-${VERSION}" "${LB_BOOTAPPEND_FAILSAFE}" | |
190 | done | |
191 | ||
192 | LINUX_LIVE="$(/bin/echo ${LINUX_LIVE} | sed -e 's|binary||g' -e 's|//|/|g')" | |
193 | ||
194 | # Assembling debian-installer configuration | |
195 | if [ "${LB_DEBIAN_INSTALLER}" != "false" ] | |
196 | then | |
197 | LINUX_LIVE="#\t \"Live\"\n${LINUX_LIVE}" | |
198 | LINUX_INSTALL="#\t \"Installer\"\n" | |
199 | ||
200 | VMLINUZ_DI="install/vmlinuz" | |
201 | INITRD_DI="install/initrd.gz" | |
202 | APPEND_DI="vga=normal" | |
203 | ||
204 | VMLINUZ_GI="install/gtk/vmlinuz" | |
205 | INITRD_GI="install/gtk/initrd.gz" | |
206 | APPEND_GI="video=vesa:ywrap,mtrr vga=788" | |
207 | ||
208 | Grub_install_entry "install" "${VMLINUZ_DI}" "${INITRD_DI}" "${APPEND_DI}" | |
209 | Grub_install_entry "installgui" "${VMLINUZ_GI}" "${INITRD_GI}" "${APPEND_GI}" | |
210 | Grub_install_entry "expert" "${VMLINUZ_DI}" "${INITRD_DI}" "priority=low ${APPEND_DI}" | |
211 | Grub_install_entry "expertgui" "${VMLINUZ_GI}" "${INITRD_GI}" "priority=low ${APPEND_GI}" | |
212 | Grub_install_entry "rescue" "${VMLINUZ_DI}" "${INITRD_DI}" "rescue/enable=true ${APPEND_DI}" | |
213 | Grub_install_entry "rescuegui" "${VMLINUZ_GI}" "${INITRD_GI}" "rescue/enable=true ${APPEND_GI}" | |
214 | Grub_install_entry "auto" "${VMLINUZ_DI}" "${INITRD_DI}" "auto=true priority=critical ${APPEND_DI}" | |
215 | Grub_install_entry "autogui" "${VMLINUZ_GI}" "${INITRD_GI}" "auto=true priority=critical ${APPEND_GI}" | |
216 | fi | |
217 | ||
218 | LINUX_INSTALL="$(/bin/echo ${LINUX_INSTALL} | sed -e 's|binary||g' -e 's|//|/|g')" | |
219 | ||
220 | # Assembling memtest configuration | |
221 | if [ -f "${DESTDIR_LIVE}"/memtest ] | |
222 | then | |
223 | MEMTEST="#\t \"Other\"\n" | |
224 | MEMTEST="${MEMTEST}\nmenuentry\t\"${LB_MEMTEST}\" {\nlinux16\t$(basename ${DESTDIR_LIVE})/memtest\n}" | |
225 | MEMTEST="$(/bin/echo ${MEMTEST} | sed -e 's|//|/|g')" | |
226 | fi | |
227 | ||
228 | 66 | # Copying templates |
229 | 67 | mkdir -p binary/boot/grub/i386-pc |
230 | cp -r "${_SOURCE}"/* binary/boot/grub | |
231 | 68 | |
232 | 69 | case ${LIVE_IMAGE_TYPE} in |
233 | 70 | iso*) |
244 | 81 | FILES="$(echo ${FILES} | sed -e 's|chroot||g')" |
245 | 82 | fi |
246 | 83 | |
84 | # We rely on: binary_loopback_cfg to generate grub.cfg and other configuration files | |
85 | ||
247 | 86 | # Copying grub |
248 | 87 | cp ${FILES} binary/boot/grub/i386-pc |
249 | ||
250 | sed -i -e "s|LINUX_LIVE|${LINUX_LIVE}|" -e "s|LINUX_INSTALL|${LINUX_INSTALL}|" -e "s|MEMTEST|${MEMTEST}|" binary/boot/grub/grub.cfg | |
251 | sed -i -e "s#LB_BOOTAPPEND_INSTALL#${LB_BOOTAPPEND_INSTALL}#" -e "s#LB_BOOTAPPEND_LIVE#${LB_BOOTAPPEND_LIVE}#" binary/boot/grub/grub.cfg | |
252 | ||
253 | sed -i -e 's|\ $||g' binary/boot/grub/grub.cfg | |
254 | 88 | |
255 | 89 | # Saving cache |
256 | 90 | Save_cache cache/packages.binary |
66 | 66 | esac |
67 | 67 | done |
68 | 68 | |
69 | LB_PRIMARY_BOOTLOADER=$(echo "${LB_BOOTLOADERS}" | awk -F, '{ print $1 }') | |
70 | ||
71 | case ${LB_PRIMARY_BOOTLOADER} in | |
69 | case ${LB_FIRST_BOOTLOADER} in | |
72 | 70 | syslinux) |
73 | 71 | case ${LB_BINARY_FILESYSTEM} in |
74 | 72 | fat*|ntfs) |
183 | 181 | Chroot chroot "parted -s ${FREELO} set 1 boot on" || true |
184 | 182 | Chroot chroot "parted -s ${FREELO} set 1 lba off" || true |
185 | 183 | |
186 | if [ "${LB_PRIMARY_BOOTLOADER}" = "syslinux" ] | |
184 | if [ "${LB_FIRST_BOOTLOADER}" = "syslinux" ] | |
187 | 185 | then |
188 | dd if=chroot/usr/lib/SYSLINUX/mbr.bin of=${FREELO} bs=440 count=1 | |
186 | dd if=chroot/usr/lib/$(echo ${_BOOTLOADER} | tr [a-z] [A-Z])/mbr.bin of=${FREELO} bs=440 count=1 | |
189 | 187 | fi |
190 | 188 | ;; |
191 | 189 | |
203 | 201 | parted -s "${FREELO}" set 1 boot on || true |
204 | 202 | parted -s "${FREELO}" set 1 lba off || true |
205 | 203 | |
206 | if [ "${LB_PRIMARY_BOOTLOADER}" = "syslinux" ] | |
204 | if [ "${LB_FIRST_BOOTLOADER}" = "syslinux" ] | |
207 | 205 | then |
208 | dd if=/usr/lib/SYSLINUX/mbr.bin of=${FREELO} bs=440 count=1 | |
206 | dd if=/usr/lib/$(echo ${_BOOTLOADER} | tr [a-z] [A-Z])/mbr.bin of=${FREELO} bs=440 count=1 | |
209 | 207 | fi |
210 | 208 | ;; |
211 | 209 | esac |
218 | 216 | case "${LB_BINARY_FILESYSTEM}" in |
219 | 217 | ext2|ext3|ext4) |
220 | 218 | MKFS="${LB_BINARY_FILESYSTEM}" |
221 | MKFS_OPTIONS="-L ${LB_HDD_LABEL} -m 0" | |
219 | MKFS_OPTIONS="-L ${LB_HDD_LABEL} -m 0 -O ^64bit" | |
222 | 220 | MOUNT_OPTIONS="" |
223 | 221 | ;; |
224 | 222 | |
269 | 267 | |
270 | 268 | FIXME() |
271 | 269 | { |
272 | if [ "${LB_PRIMARY_BOOTLOADER}" = "grub" ] | |
270 | if [ "${LB_FIRST_BOOTLOADER}" = "grub" ] | |
273 | 271 | then |
274 | 272 | |
275 | 273 | cat > chroot/grub.sh << EOF |
106 | 106 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -V \"${LB_ISO_VOLUME}\"" |
107 | 107 | fi |
108 | 108 | |
109 | LB_PRIMARY_BOOTLOADER=$(echo "${LB_BOOTLOADERS}" | awk -F, '{ print $1 }') | |
110 | ||
111 | # Handle xorriso architecture specific options | |
112 | case "${LB_PRIMARY_BOOTLOADER}" in | |
113 | grub) | |
114 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -no-emul-boot -boot-load-size 4 -boot-info-table" | |
115 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -b boot/grub/stage2_eltorito" | |
116 | XORRISO_EXCLUDE="boot/grub/stage2_eltorito" | |
117 | ;; | |
118 | ||
119 | grub-pc) | |
120 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -no-emul-boot -boot-load-size 4 -boot-info-table" | |
121 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -b boot/grub/grub_eltorito -J" | |
122 | XORRISO_EXCLUDE="boot/grub/grub_eltorito" | |
123 | ;; | |
124 | ||
125 | syslinux) | |
126 | case "${LB_MODE}" in | |
127 | progress-linux) | |
128 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -b boot/boot.bin -c boot/boot.cat" | |
129 | XORRISO_EXCLUDE="boot/boot.bin" | |
130 | ;; | |
131 | ||
132 | *) | |
133 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -b isolinux/isolinux.bin -c isolinux/boot.cat" | |
134 | XORRISO_EXCLUDE="isolinux/isolinux.bin" | |
135 | ;; | |
136 | esac | |
137 | ||
138 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -no-emul-boot -boot-load-size 4 -boot-info-table" | |
139 | ;; | |
140 | ||
141 | *) | |
142 | Echo_warning "Bootloader on your architecture not yet supported by live-build." | |
143 | Echo_warning "This will produce a most likely not bootable image (Continuing in 5 seconds)." | |
144 | sleep 5 | |
145 | ;; | |
146 | esac | |
109 | # Set an explicit modification date | |
110 | XORRISO_OPTIONS="${XORRISO_OPTIONS} --modification-date=$(date --utc --date="@${SOURCE_DATE_EPOCH:-$(date +%s)}" +%Y%m%d%H%m%S00)" | |
111 | ||
112 | OLDIFS="$IFS" | |
113 | IFS="," | |
114 | BOOTLOADER_NUMBER=0 | |
115 | for BOOTLOADER in ${LB_BOOTLOADERS} | |
116 | do | |
117 | BOOTLOADER_NUMBER=$(expr ${BOOTLOADER_NUMBER} + 1) | |
118 | # Handle xorriso architecture specific options | |
119 | ||
120 | # If the bootloader number is greater or equal than 2 it means | |
121 | # we are not the first bootloader and thus we need to tell | |
122 | # mkisosfs to add an additional eltorito entry | |
123 | if [ ${BOOTLOADER_NUMBER} -ge 2 ] | |
124 | then | |
125 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -eltorito-alt-boot " | |
126 | fi | |
127 | case "${BOOTLOADER}" in | |
128 | grub) | |
129 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -no-emul-boot -boot-load-size 4 -boot-info-table" | |
130 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -b boot/grub/stage2_eltorito" | |
131 | XORRISO_EXCLUDE="boot/grub/stage2_eltorito" | |
132 | ;; | |
133 | ||
134 | grub-pc) | |
135 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -no-emul-boot -boot-load-size 4 -boot-info-table" | |
136 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -b boot/grub/grub_eltorito -J" | |
137 | XORRISO_EXCLUDE="boot/grub/grub_eltorito" | |
138 | ;; | |
139 | ||
140 | syslinux) | |
141 | case "${LB_MODE}" in | |
142 | progress-linux) | |
143 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -b boot/boot.bin -c boot/boot.cat" | |
144 | XORRISO_EXCLUDE="boot/boot.bin" | |
145 | ;; | |
146 | ||
147 | *) | |
148 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -b isolinux/isolinux.bin -c isolinux/boot.cat" | |
149 | XORRISO_EXCLUDE="isolinux/isolinux.bin" | |
150 | ;; | |
151 | esac | |
152 | ||
153 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -no-emul-boot -boot-load-size 4 -boot-info-table --hardlinks" | |
154 | ;; | |
155 | ||
156 | grub-efi) | |
157 | if [ -e binary/boot/grub/efi.img ] | |
158 | then | |
159 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -e boot/grub/efi.img -no-emul-boot" | |
160 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -isohybrid-gpt-basdat -isohybrid-apm-hfsplus" | |
161 | else | |
162 | Echo "No EFI boot code to include in the ISO" | |
163 | fi | |
164 | ;; | |
165 | ||
166 | *) | |
167 | Echo_warning "Bootloader on your architecture not yet supported by live-build." | |
168 | Echo_warning "This will produce a most likely not bootable image (Continuing in 5 seconds)." | |
169 | sleep 5 | |
170 | ;; | |
171 | esac | |
172 | ||
173 | done | |
174 | IFS="$OLDIFS" | |
147 | 175 | |
148 | 176 | #if [ "${LB_DEBIAN_INSTALLER}" != "live" ] |
149 | 177 | #then |
150 | 178 | # XORRISO_OPTIONS="${XORRISO_OPTIONS} -m ${XORRISO_EXCLUDE}" |
151 | 179 | #fi |
152 | 180 | |
153 | if [ "${LB_PRIMARY_BOOTLOADER}" = "grub-pc" ] | |
181 | if [ "${LB_FIRST_BOOTLOADER}" = "grub-pc" ] | |
154 | 182 | then |
155 | 183 | |
156 | 184 | cat > binary.sh << EOF |
45 | 45 | Check_architectures amd64 i386 |
46 | 46 | Check_crossarchitectures |
47 | 47 | |
48 | # Variable used to embed newlines | |
49 | NL=" | |
50 | " | |
51 | ||
48 | 52 | # Local functions |
49 | Grub_live_entry_commands () | |
50 | { | |
51 | local KERNEL="${1}" | |
52 | local INITRD="${2}" | |
53 | local APPEND="${3}" | |
54 | ||
55 | LINUX_LIVE="${LINUX_LIVE}\nlinux\t\t/${KERNEL} ${INITFS:+boot=${INITFS} }config LB_BOOTAPPEND_LIVE ${APPEND}" | |
56 | LINUX_LIVE="${LINUX_LIVE}\ninitrd\t\t/${INITRD}" | |
53 | Grub_menu_entry() { | |
54 | local LABEL="$1" | |
55 | local KERNEL="$2" | |
56 | local INITRD="$3" | |
57 | local APPEND="$4" | |
58 | ||
59 | cat <<END | |
60 | menuentry "$LABEL" { | |
61 | linux $KERNEL $APPEND | |
62 | initrd $INITRD | |
63 | } | |
64 | END | |
57 | 65 | } |
58 | 66 | |
59 | 67 | Grub_live_entry () |
60 | 68 | { |
61 | local LABEL="${1}" | |
62 | local KERNEL="${2}" | |
63 | local INITRD="${3}" | |
64 | local APPEND="${4}" | |
65 | ||
66 | LINUX_LIVE="${LINUX_LIVE}\nmenuentry \"Debian GNU/Linux - ${LABEL}\" {" | |
67 | Grub_live_entry_commands "${KERNEL}" "${INITRD}" "${APPEND} findiso=\${iso_path}" | |
68 | LINUX_LIVE="${LINUX_LIVE}\n}" | |
69 | } | |
70 | ||
71 | Grub_live_autodetect_entry () | |
69 | LINUX_LIVE="${LINUX_LIVE}$(Grub_menu_entry "$@")$NL" | |
70 | } | |
71 | ||
72 | Grub_install_entry () | |
73 | { | |
74 | LABEL="${1}" | |
75 | TYPE="${2}" | |
76 | KERNEL="${3}" | |
77 | INITRD="${4}" | |
78 | APPEND="${5}" | |
79 | ||
80 | # Drop "quiet" kernel parameter for rescue entries | |
81 | case $TYPE in | |
82 | rescue|rescuegui) | |
83 | APPEND=$(echo "$APPEND" | sed -e 's/ quiet//') | |
84 | ;; | |
85 | esac | |
86 | ||
87 | if [ -z "$LINUX_INSTALL" ]; then | |
88 | # First entry recorded in LINUX_INSTALL | |
89 | LINUX_INSTALL="$(Grub_menu_entry "$LABEL" "$KERNEL" "$INITRD" "$APPEND")$NL" | |
90 | else | |
91 | # Remaining entries recorded in LINUX_ADVANCED_INSTALL | |
92 | LINUX_ADVANCED_INSTALL="$LINUX_ADVANCED_INSTALL$(Grub_menu_entry "$LABEL" "$KERNEL" "$INITRD" "$APPEND")$NL" | |
93 | fi | |
94 | } | |
95 | ||
96 | Grub_live_autodetect_menu_entry () | |
72 | 97 | { |
73 | 98 | local LABEL="${1}" |
74 | 99 | local AMD64_KERNEL="${2}" |
76 | 101 | local _486_KERNEL="${4}" |
77 | 102 | local _486_INITRD="${5}" |
78 | 103 | local APPEND="${6}" |
79 | ||
80 | LINUX_LIVE="${LINUX_LIVE}\nmenuentry \"Debian GNU/Linux - ${LABEL}\" {" | |
81 | LINUX_LIVE="${LINUX_LIVE}\nif cpuid -l ; then" | |
82 | Grub_live_entry_commands "${AMD64_KERNEL}" "${AMD64_INITRD}" "${APPEND} findiso=\${iso_path}" | |
83 | LINUX_LIVE="${LINUX_LIVE}\nelse" | |
84 | Grub_live_entry_commands "${_486_KERNEL}" "${_486_INITRD}" "${APPEND} findiso=\${iso_path}" | |
85 | LINUX_LIVE="${LINUX_LIVE}\nfi" | |
86 | LINUX_LIVE="${LINUX_LIVE}\n}" | |
104 | cat <<END | |
105 | # Autodetect if amd64 is supported | |
106 | menuentry "$LABEL" { | |
107 | if cpuid -l; then | |
108 | linux ${AMD64_KERNEL} ${APPEND} | |
109 | initrd ${AMD64_INITRD} | |
110 | else | |
111 | linux ${_486_KERNEL} ${APPEND} | |
112 | initrd ${_486_INITRD} | |
113 | fi | |
114 | } | |
115 | END | |
116 | } | |
117 | ||
118 | Grub_live_autodetect_entry () | |
119 | { | |
120 | LINUX_LIVE="${LINUX_LIVE}$(Grub_live_autodetect_menu_entry "$@")$NL" | |
121 | } | |
122 | ||
123 | Grub_memtest_menu_entry () | |
124 | { | |
125 | cat <<END | |
126 | menuentry "$LB_MEMTEST" { | |
127 | linux16 /${INITFS}/memtest | |
128 | } | |
129 | END | |
87 | 130 | } |
88 | 131 | |
89 | 132 | if [ -e "config/bootloaders/grub-pc" ] |
110 | 153 | ;; |
111 | 154 | esac |
112 | 155 | |
113 | # Assembling image specifics | |
114 | case "${LIVE_IMAGE_TYPE}" in | |
115 | iso*) | |
116 | _BOOTLOADER="isolinux" | |
117 | ||
118 | case "${LB_MODE}" in | |
119 | progress-linux) | |
120 | _TARGET="binary/boot" | |
121 | ;; | |
122 | ||
123 | *) | |
124 | _TARGET="binary/isolinux" | |
125 | ;; | |
126 | esac | |
127 | ;; | |
128 | ||
129 | netboot) | |
130 | _BOOTLOADER="pxelinux" | |
131 | _TARGET="tftpboot" | |
132 | ;; | |
133 | ||
134 | hdd*|*) | |
135 | case ${LB_BINARY_FILESYSTEM} in | |
136 | fat*|ntfs) | |
137 | _BOOTLOADER=syslinux | |
138 | ||
139 | case "${LB_MODE}" in | |
140 | progress-linux) | |
141 | _TARGET="binary/boot" | |
142 | ;; | |
143 | ||
144 | *) | |
145 | _TARGET="binary/syslinux" | |
146 | ;; | |
147 | esac | |
148 | ;; | |
149 | ||
150 | ext[234]|btrfs) | |
151 | _BOOTLOADER=extlinux | |
152 | _TARGET="binary/boot/extlinux" | |
153 | ;; | |
154 | *) | |
155 | Echo_error "syslinux/extlinux doesn't support ${LB_BINARY_FILESYSTEM}" | |
156 | exit 1 | |
157 | ;; | |
158 | esac | |
159 | ;; | |
160 | esac | |
161 | ||
162 | DESTDIR_LIVE="${_TARGET}" | |
163 | ||
164 | 156 | Check_multiarchitectures |
165 | 157 | |
166 | # Creating directory | |
167 | mkdir -p "${DESTDIR_LIVE}" | |
168 | ||
169 | 158 | # Setting boot parameters |
170 | if [ "${LB_UNION_FILESYSTEM}" != "aufs" ] | |
159 | if [ "${LB_UNION_FILESYSTEM}" != "overlay" ] | |
171 | 160 | then |
172 | 161 | LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} union=${LB_UNION_FILESYSTEM}" |
173 | 162 | fi |
178 | 167 | exit 1 |
179 | 168 | fi |
180 | 169 | |
181 | LB_BOOTAPPEND_LIVE="$(echo ${LB_BOOTAPPEND_LIVE} | sed -e 's| ||')" | |
170 | # Default entries | |
171 | DEFAULT_FLAVOUR="$(echo ${LB_LINUX_FLAVOURS} | awk '{ print $1 }')" | |
172 | DEFAULT_KERNEL="$(basename chroot/boot/vmlinuz-*${DEFAULT_FLAVOUR})" | |
173 | DEFAULT_INITRD="initrd.img-$(echo ${DEFAULT_KERNEL} | sed -e 's|vmlinuz-||')" | |
174 | ||
175 | KERNEL_LIVE="/${INITFS}/${DEFAULT_KERNEL}" | |
176 | INITRD_LIVE="/${INITFS}/${DEFAULT_INITRD}" | |
177 | APPEND_LIVE="${LB_BOOTAPPEND_LIVE}" | |
182 | 178 | |
183 | 179 | # Assembling kernel configuration |
184 | # If Bootloader is not syslinux that means | |
185 | # binary_syslinux it's not going to rename kernel filenames in a later stage. | |
186 | # We will use binary_grub2 algorithm which does not rename kernel filenames. | |
187 | ||
188 | FOUND_SYSLINUX="" | |
189 | OLDIFS="$IFS" | |
190 | IFS="," | |
191 | for BOOTLOADER in ${LB_BOOTLOADERS} | |
180 | _AMD64_486_NUMBER="0" | |
181 | ||
182 | for _FLAVOUR in ${LB_LINUX_FLAVOURS} | |
192 | 183 | do |
193 | ||
194 | case ${BOOTLOADER} in | |
195 | "syslinux" ) | |
196 | FOUND_SYSLINUX="True" | |
197 | break ;; | |
198 | esac | |
199 | ||
184 | if [ "${_FLAVOUR}" = "amd64" -o "${_FLAVOUR}" = "486" ] ; then | |
185 | _AMD64_486_NUMBER="$((${_AMD64_486_NUMBER} + 1))" | |
186 | fi | |
200 | 187 | done |
201 | IFS="$OLDIFS" | |
202 | ||
203 | if [ -z ${FOUND_SYSLINUX} ] | |
204 | then | |
205 | ||
206 | _AMD64_486_NUMBER="0" | |
207 | ||
208 | for _FLAVOUR in ${LB_LINUX_FLAVOURS} | |
209 | do | |
210 | if [ "${_FLAVOUR}" = "amd64" -o "${_FLAVOUR}" = "486" ] ; then | |
211 | _AMD64_486_NUMBER="$((${_AMD64_486_NUMBER} + 1))" | |
212 | fi | |
213 | done | |
214 | ||
215 | if [ "${_AMD64_486_NUMBER}" -ge 2 ] ; then | |
216 | # Default entries | |
217 | AMD64_KERNEL="$(basename chroot/boot/vmlinuz-*amd64)" | |
218 | AMD64_INITRD="initrd.img-$(echo ${AMD64_KERNEL} | sed -e 's|vmlinuz-||')" | |
219 | _486_KERNEL="$(basename chroot/boot/vmlinuz-*486)" | |
220 | _486_INITRD="initrd.img-$(echo ${_486_KERNEL} | sed -e 's|vmlinuz-||')" | |
221 | ||
222 | Grub_live_autodetect_entry "live (autodetect)" \ | |
223 | "${INITFS}/${AMD64_KERNEL}" \ | |
224 | "${INITFS}/${AMD64_INITRD}" \ | |
225 | "${INITFS}/${_486_KERNEL}" \ | |
226 | "${INITFS}/${_486_INITRD}" | |
227 | fi | |
228 | ||
188 | ||
189 | if [ "${_AMD64_486_NUMBER}" -ge 2 ] ; then | |
229 | 190 | # Default entries |
230 | DEFAULT_FLAVOUR="$(echo ${LB_LINUX_FLAVOURS} | awk '{ print $1 }')" | |
231 | DEFAULT_KERNEL="$(basename chroot/boot/vmlinuz-*${DEFAULT_FLAVOUR})" | |
232 | DEFAULT_INITRD="initrd.img-$(echo ${DEFAULT_KERNEL} | sed -e 's|vmlinuz-||')" | |
233 | ||
234 | Grub_live_entry "live" "${INITFS}/${DEFAULT_KERNEL}" "${INITFS}/${DEFAULT_INITRD}" | |
235 | ||
236 | if [ "${LB_BOOTAPPEND_FAILSAFE}" != "none" ] | |
237 | then | |
238 | Grub_live_entry "live (fail-safe mode)" "${INITFS}/${DEFAULT_KERNEL}" "${INITFS}/${DEFAULT_INITRD}" "${LB_BOOTAPPEND_FAILSAFE}" | |
239 | fi | |
240 | ||
191 | AMD64_KERNEL="$(basename chroot/boot/vmlinuz-*amd64)" | |
192 | AMD64_INITRD="initrd.img-$(echo ${AMD64_KERNEL} | sed -e 's|vmlinuz-||')" | |
193 | _486_KERNEL="$(basename chroot/boot/vmlinuz-*486)" | |
194 | _486_INITRD="initrd.img-$(echo ${_486_KERNEL} | sed -e 's|vmlinuz-||')" | |
195 | ||
196 | Grub_live_autodetect_entry "Live system (autodetect)" \ | |
197 | "/${INITFS}/${AMD64_KERNEL}" \ | |
198 | "/${INITFS}/${AMD64_INITRD}" \ | |
199 | "/${INITFS}/${_486_KERNEL}" \ | |
200 | "/${INITFS}/${_486_INITRD}" \ | |
201 | "$APPEND_LIVE" | |
202 | else | |
203 | Grub_live_entry "Live system" "/${INITFS}/${DEFAULT_KERNEL}" "/${INITFS}/${DEFAULT_INITRD}" "${APPEND_LIVE}" | |
204 | fi | |
205 | ||
206 | if [ "${LB_BOOTAPPEND_LIVE_FAILSAFE}" != "none" ] | |
207 | then | |
208 | Grub_live_entry "Live system (fail-safe mode)" "/${INITFS}/${DEFAULT_KERNEL}" "/${INITFS}/${DEFAULT_INITRD}" "${LB_BOOTAPPEND_LIVE_FAILSAFE}" | |
209 | fi | |
210 | ||
211 | _COUNT=0 | |
212 | for KERNEL in chroot/boot/vmlinuz-*; do | |
213 | _COUNT=$(( $COUNT + 1 )) | |
214 | done | |
215 | ||
216 | if [ $_COUNT -gt 1 ]; then | |
241 | 217 | for KERNEL in chroot/boot/vmlinuz-* |
242 | 218 | do |
243 | 219 | VERSION="$(basename ${KERNEL} | sed -e 's|vmlinuz-||')" |
244 | 220 | |
245 | Grub_live_entry "live, kernel ${VERSION}" "${INITFS}/$(basename ${KERNEL})" "${INITFS}/initrd.img-${VERSION}" | |
246 | Grub_live_entry "live, kernel ${VERSION} (fail-safe mode)" "${INITFS}/$(basename ${KERNEL})" "${INITFS}/initrd.img-${VERSION}" "${LB_BOOTAPPEND_FAILSAFE}" | |
221 | Grub_live_entry "Live system, kernel ${VERSION}" "/${INITFS}/$(basename ${KERNEL})" "/${INITFS}/initrd.img-${VERSION}" "${APPEND_LIVE}" | |
222 | ||
223 | if [ "${LB_BOOTAPPEND_LIVE_FAILSAFE}" != "none" ]; then | |
224 | Grub_live_entry "Live system, kernel ${VERSION} (fail-safe mode)" "/${INITFS}/$(basename ${KERNEL})" "/${INITFS}/initrd.img-${VERSION}" "${LB_BOOTAPPEND_LIVE_FAILSAFE}" | |
225 | fi | |
247 | 226 | done |
248 | else # LB_BOOTLOADERS does not contain syslinux | |
249 | # If one of the bootloader is syslinux that means | |
250 | # binary_syslinux it's going to rename kernel filenames. | |
251 | # We will use binary_syslinux algorithm but without renaming kernel filenames. | |
252 | # That will ensure binary_syslinux will find the original kernel filenames. | |
253 | #if [ -e "${_TARGET}/live.cfg.in" ] | |
254 | #then | |
255 | # This is all rather suboptimal.. needs prettifying at some point | |
256 | _FLAVOURS="$(echo ${LB_LINUX_FLAVOURS} | wc -w)" | |
257 | ||
258 | case "${_FLAVOURS}" in | |
259 | 1) | |
260 | Grub_live_entry "live (${LB_LINUX_FLAVOURS})" "${INITFS}/vmlinuz" "${INITFS}/initrd.img" "${LB_BOOTAPPEND_LIVE}" | |
261 | Grub_live_entry "live (${LB_LINUX_FLAVOURS}) (failsafe mode)" "${INITFS}/vmlinuz" "${INITFS}/initrd.img" "${LB_BOOTAPPEND_LIVE_FAILSAFE}" | |
262 | ;; | |
263 | ||
264 | *) | |
265 | _AMD64_486_NUMBER="0" | |
266 | ||
267 | for _FLAVOUR in ${LB_LINUX_FLAVOURS} | |
268 | do | |
269 | if [ "${_FLAVOUR}" = "amd64" -o "${_FLAVOUR}" = "486" ] ; then | |
270 | _AMD64_486_NUMBER="$((${_AMD64_486_NUMBER} + 1))" | |
271 | fi | |
272 | done | |
273 | ||
274 | _NUMBER="0" | |
275 | for _FLAVOUR in ${LB_LINUX_FLAVOURS} | |
276 | do | |
277 | _NUMBER="$((${_NUMBER} + 1))" | |
278 | if [ "${_FLAVOUR}" = "amd64" ] ; then | |
279 | AMD64_KERNEL="vmlinuz${_NUMBER}" | |
280 | AMD64_INITRD="initrd${_NUMBER}.img" | |
281 | fi | |
282 | ||
283 | if [ "${_FLAVOUR}" = "486" ] ; then | |
284 | _486_KERNEL="vmlinuz${_NUMBER}" | |
285 | _486_INITRD="initrd${_NUMBER}.img" | |
286 | fi | |
287 | done | |
288 | ||
289 | _NUMBER="0" | |
290 | ||
291 | for _FLAVOUR in ${LB_LINUX_FLAVOURS} | |
292 | do | |
293 | _NUMBER="$((${_NUMBER} + 1))" | |
294 | ||
295 | if [ "${_NUMBER}" -gt 1 ] | |
296 | then | |
297 | Grub_live_entry "live (${_FLAVOUR})" "${INITFS}/vmlinuz${_NUMBER}" "${INITFS}/initrd${_NUMBER}.img" "${LB_BOOTAPPEND_LIVE}" | |
298 | Grub_live_entry "live (${_FLAVOUR}) (failsafe mode)" "${INITFS}/vmlinuz${_NUMBER}" "${INITFS}/initrd${_NUMBER}.img" "${LB_BOOTAPPEND_LIVE_FAILSAFE}" | |
299 | ||
300 | else | |
301 | if [ "${_AMD64_486_NUMBER}" -ge 2 ] ; then | |
302 | ||
303 | Grub_live_autodetect_entry "live (autodetect)" \ | |
304 | "${INITFS}/${AMD64_KERNEL}" \ | |
305 | "${INITFS}/${AMD64_INITRD}" \ | |
306 | "${INITFS}/${_486_KERNEL}" \ | |
307 | "${INITFS}/${_486_INITRD}" | |
308 | fi | |
309 | ||
310 | Grub_live_entry "live (${_FLAVOUR})" "${INITFS}/vmlinuz${_NUMBER}" "${INITFS}/initrd${_NUMBER}.img" "${LB_BOOTAPPEND_LIVE}" | |
311 | Grub_live_entry "live (${_FLAVOUR}) (failsafe mode)" "${INITFS}/vmlinuz${_NUMBER}" "${INITFS}/initrd${_NUMBER}.img" "${LB_BOOTAPPEND_LIVE_FAILSAFE}" | |
312 | fi | |
313 | ||
314 | done | |
315 | ||
316 | ;; | |
317 | esac | |
318 | #fi | |
319 | fi | |
320 | LINUX_LIVE="$(/bin/echo ${LINUX_LIVE} | sed -e 's|binary||g' -e 's|//|/|g')" | |
227 | fi | |
228 | ||
229 | # Assembling debian-installer configuration | |
230 | if [ "${LB_DEBIAN_INSTALLER}" != "false" ] | |
231 | then | |
232 | KERNEL_DI="/install/vmlinuz" | |
233 | INITRD_DI="/install/initrd.gz" | |
234 | APPEND_DI="vga=normal quiet ${LB_BOOTAPPEND_INSTALL}" | |
235 | ||
236 | KERNEL_GI="/install/gtk/vmlinuz" | |
237 | INITRD_GI="/install/gtk/initrd.gz" | |
238 | APPEND_GI="video=vesa:ywrap,mtrr vga=788 quiet ${LB_BOOTAPPEND_INSTALL}" | |
239 | ||
240 | Grub_install_entry "Start installer" "installgui" "${KERNEL_GI}" "${INITRD_GI}" "${APPEND_GI}" | |
241 | ||
242 | Grub_install_entry "Install in graphical mode" "installgui" "${KERNEL_GI}" "${INITRD_GI}" "${APPEND_GI}" | |
243 | Grub_install_entry "Install in text mode" "install" "${KERNEL_DI}" "${INITRD_DI}" "${APPEND_DI}" | |
244 | Grub_install_entry "Expert install in graphical mode" "expertgui" "${KERNEL_GI}" "${INITRD_GI}" "priority=low ${APPEND_GI}" | |
245 | Grub_install_entry "Expert install in text mode" "expert" "${KERNEL_DI}" "${INITRD_DI}" "priority=low ${APPEND_DI}" | |
246 | Grub_install_entry "Automatic install in graphical mode" "autogui" "${KERNEL_GI}" "${INITRD_GI}" "auto=true priority=critical ${APPEND_GI}" | |
247 | Grub_install_entry "Automatic install in text mode" "auto" "${KERNEL_DI}" "${INITRD_DI}" "auto=true priority=critical ${APPEND_DI}" | |
248 | Grub_install_entry "Rescue system in graphical mode" "rescuegui" "${KERNEL_GI}" "${INITRD_GI}" "rescue/enable=true ${APPEND_GI}" | |
249 | Grub_install_entry "Rescue system in text mode" "rescue" "${KERNEL_DI}" "${INITRD_DI}" "rescue/enable=true ${APPEND_DI}" | |
250 | fi | |
321 | 251 | |
322 | 252 | # Assembling memtest configuration |
323 | if [ -f "${DESTDIR_LIVE}"/memtest ] | |
324 | then | |
325 | MEMTEST="#\t \"Other\"\n" | |
326 | MEMTEST="${MEMTEST}\nmenuentry\t\"${LB_MEMTEST}\" {\nlinux16\t${INITFS}/memtest\n}" | |
327 | MEMTEST="$(/bin/echo ${MEMTEST} | sed -e 's|//|/|g')" | |
253 | if [ -f "binary/${INITFS}/memtest" ] | |
254 | then | |
255 | MEMTEST="$(Grub_memtest_menu_entry)$NL" | |
328 | 256 | fi |
329 | 257 | |
330 | 258 | # Copying templates |
331 | 259 | mkdir -p binary/boot/grub |
332 | cp "${_SOURCE}"/grub.cfg binary/boot/grub/loopback.cfg | |
333 | ||
334 | sed -i -e "s|LINUX_LIVE|${LINUX_LIVE}|" -e "s|LINUX_INSTALL||" -e "s|MEMTEST|${MEMTEST}|" binary/boot/grub/loopback.cfg | |
335 | sed -i -e "s#LB_BOOTAPPEND_INSTALL##" -e "s#LB_BOOTAPPEND_LIVE#${LB_BOOTAPPEND_LIVE}#" binary/boot/grub/loopback.cfg | |
336 | ||
337 | sed -i -e 's|\ $||g' binary/boot/grub/loopback.cfg | |
260 | cp -a "${_SOURCE}"/* binary/boot/grub/ | |
261 | ||
262 | escape_for_sed() { | |
263 | echo -n "$1" | perl -npe 's/\n/\\n/gm' | |
264 | } | |
265 | ||
266 | sed -i \ | |
267 | -e "s|LINUX_LIVE|$(escape_for_sed "${LINUX_LIVE}")|" \ | |
268 | -e "s|LINUX_ADVANCED_INSTALL|$(escape_for_sed "${LINUX_ADVANCED_INSTALL}")|" \ | |
269 | -e "s|LINUX_INSTALL|$(escape_for_sed "${LINUX_INSTALL}")|" \ | |
270 | -e "s|MEMTEST|$(escape_for_sed "${MEMTEST}")|" \ | |
271 | -e "s|KERNEL_GI|$(escape_for_sed "${KERNEL_GI}")|" \ | |
272 | -e "s|INITRD_GI|$(escape_for_sed "${INITRD_GI}")|" \ | |
273 | -e "s|APPEND_GI|$(escape_for_sed "${APPEND_GI}")|" \ | |
274 | -e "s|KERNEL_DI|$(escape_for_sed "${KERNEL_DI}")|" \ | |
275 | -e "s|INITRD_DI|$(escape_for_sed "${INITRD_DI}")|" \ | |
276 | -e "s|APPEND_DI|$(escape_for_sed "${APPEND_DI}")|" \ | |
277 | -e "s|KERNEL_LIVE|$(escape_for_sed "${KERNEL_LIVE}")|" \ | |
278 | -e "s|INITRD_LIVE|$(escape_for_sed "${INITRD_LIVE}")|" \ | |
279 | -e "s|APPEND_LIVE|$(escape_for_sed "${APPEND_LIVE}")|" \ | |
280 | -e "s|LB_BOOTAPPEND_INSTALL|$(escape_for_sed "${LB_BOOTAPPEND_INSTALL}")|" \ | |
281 | -e "s|LB_BOOTAPPEND_LIVE_FAILSAFE|$(escape_for_sed "${LB_BOOTAPPEND_LIVE_FAILSAFE}")|" \ | |
282 | -e "s|LB_BOOTAPPEND_LIVE|$(escape_for_sed "${LB_BOOTAPPEND_LIVE}")|" \ | |
283 | binary/boot/grub/*.cfg | |
284 | ||
285 | sed -i -e 's|//|/|g' binary/boot/grub/*.cfg | |
286 | sed -i -e 's|\ $||g' binary/boot/grub/*.cfg | |
287 | ||
288 | echo "source /boot/grub/grub.cfg" > binary/boot/grub/loopback.cfg | |
338 | 289 | |
339 | 290 | # Creating stage file |
340 | 291 | Create_stagefile .build/binary_loopback_cfg |
144 | 144 | |
145 | 145 | for SECTION in ${POOL}/* |
146 | 146 | do |
147 | if [ ! -d "${SECTION}" ]; then | |
148 | break # Do nothing if the package lists were empty... | |
149 | fi | |
150 | ||
147 | 151 | SECTION="$(basename ${SECTION})" |
148 | 152 | |
149 | 153 | mkdir -p ${DISTS}/${LB_PARENT_DISTRIBUTION}/${SECTION}/binary-${LB_ARCHITECTURES} |
23 | 23 | Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source |
24 | 24 | Set_defaults |
25 | 25 | |
26 | FOUND_MYSELF="" | |
27 | OLDIFS="$IFS" | |
28 | IFS="," | |
29 | for BOOTLOADER in ${LB_BOOTLOADERS} | |
30 | do | |
31 | ||
32 | case ${BOOTLOADER} in | |
33 | "syslinux" ) | |
34 | FOUND_MYSELF="True" | |
35 | break ;; | |
36 | esac | |
37 | ||
38 | done | |
39 | IFS="$OLDIFS" | |
40 | ||
41 | if [ -z ${FOUND_MYSELF} ] ; then | |
42 | exit 0 | |
43 | fi | |
26 | Check_Any_Bootloader_Role "syslinux" | |
44 | 27 | |
45 | 28 | Echo_message "Begin installing syslinux..." |
46 | 29 | |
202 | 185 | 1) |
203 | 186 | # If multiple initrd images are being generated (by DKMS packages, etc), |
204 | 187 | # we likely only want the latest version. |
205 | mv $(ls -r1 --sort=version binary/${_INITRAMFS}/vmlinuz-* | head -n 1) binary/${_INITRAMFS}/vmlinuz | |
206 | mv $(ls -r1 --sort=version binary/${_INITRAMFS}/initrd.img-* | head -n 1) binary/${_INITRAMFS}/initrd.img | |
188 | ln $(ls -r1 --sort=version binary/${_INITRAMFS}/vmlinuz-* | head -n 1) binary/${_INITRAMFS}/vmlinuz | |
189 | ln $(ls -r1 --sort=version binary/${_INITRAMFS}/initrd.img-* | head -n 1) binary/${_INITRAMFS}/initrd.img | |
207 | 190 | |
208 | 191 | sed -e "s|@FLAVOUR@|${LB_LINUX_FLAVOURS}|g" \ |
209 | 192 | -e "s|@LINUX@|/${_INITRAMFS}/vmlinuz|g" \ |
220 | 203 | do |
221 | 204 | _NUMBER="$((${_NUMBER} + 1))" |
222 | 205 | |
223 | mv binary/${_INITRAMFS}/vmlinuz-*-${_FLAVOUR} binary/${_INITRAMFS}/vmlinuz${_NUMBER} | |
224 | mv binary/${_INITRAMFS}/initrd.img-*-${_FLAVOUR} binary/${_INITRAMFS}/initrd${_NUMBER}.img | |
206 | ln binary/${_INITRAMFS}/vmlinuz-*-${_FLAVOUR} binary/${_INITRAMFS}/vmlinuz${_NUMBER} | |
207 | ln binary/${_INITRAMFS}/initrd.img-*-${_FLAVOUR} binary/${_INITRAMFS}/initrd${_NUMBER}.img | |
225 | 208 | |
226 | 209 | if [ "${_NUMBER}" -gt 1 ] |
227 | 210 | then |
247 | 230 | _VERSION="$(. chroot/etc/os-release && echo ${VERSION_ID})" |
248 | 231 | fi |
249 | 232 | |
250 | _VERSION="${VERSION:-none}" | |
233 | _VERSION="${_VERSION:-none}" | |
251 | 234 | |
252 | 235 | _DISTRIBUTION="${LB_DISTRIBUTION}" |
253 | 236 | _ARCHITECTURE="${LB_ARCHITECTURES}" |
324 | 307 | rm -f "${_TARGET}/splash.svg" |
325 | 308 | fi |
326 | 309 | |
310 | # Tweak the grub theme to reuse the syslinux background image | |
311 | if [ -e binary/boot/grub/live-theme/theme.txt ]; then | |
312 | sed -i -e 's|^desktop-image:.*|desktop-image: "/isolinux/splash.png"|' \ | |
313 | -e 's|^title-text:.*|title-text: ""|' \ | |
314 | binary/boot/grub/live-theme/theme.txt | |
315 | fi | |
316 | ||
327 | 317 | case "${LB_MODE}" in |
328 | 318 | progress-linux) |
329 | 319 | for _FILE in "${_TARGET}/isolinux.bin" "${_TARGET}/isolinux.cfg" "${_TARGET}/syslinux.cfg" |
36 | 36 | # Bootstrapping system |
37 | 37 | lb bootstrap_cache restore ${@} |
38 | 38 | lb bootstrap_debootstrap ${@} |
39 | lb bootstrap_archive-keys ${@} | |
40 | 39 | lb bootstrap_cache save ${@} |
41 | 40 | |
42 | 41 | # Configuring chroot |
0 | #!/bin/sh | |
1 | ||
2 | ## live-build(7) - System Build Scripts | |
3 | ## Copyright (C) 2006-2015 Daniel Baumann <[email protected]> | |
4 | ## | |
5 | ## This program comes with ABSOLUTELY NO WARRANTY; for details see COPYING. | |
6 | ## This is free software, and you are welcome to redistribute it | |
7 | ## under certain conditions; see COPYING for details. | |
8 | ||
9 | ||
10 | set -e | |
11 | ||
12 | # Including common functions | |
13 | [ -e "${LIVE_BUILD}/scripts/build.sh" ] && . "${LIVE_BUILD}/scripts/build.sh" || . /usr/lib/live/build.sh | |
14 | ||
15 | # Setting static variables | |
16 | DESCRIPTION="$(Echo 'bootstrap non-Debian archive-signing-keys')" | |
17 | HELP="" | |
18 | USAGE="${PROGRAM} [--force]" | |
19 | ||
20 | Arguments "${@}" | |
21 | ||
22 | # Reading configuration files | |
23 | Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source | |
24 | Set_defaults | |
25 | ||
26 | # TODO: allow verification against user-specified keyring | |
27 | # For now, we'll only validate against debian-keyring | |
28 | ||
29 | # TODO2: use chrooted validation rather than host system based one | |
30 | ||
31 | case "${LB_MODE}" in | |
32 | progress-linux) | |
33 | case "${LB_DISTRIBUTION}" in | |
34 | artax*) | |
35 | _KEYS="artax artax-backports" | |
36 | ;; | |
37 | ||
38 | baureo*) | |
39 | _KEYS="baureo baureo-backports" | |
40 | ;; | |
41 | ||
42 | cairon*) | |
43 | _KEYS="cairon cairon-backports" | |
44 | ;; | |
45 | esac | |
46 | ||
47 | _URL="${LB_MIRROR_CHROOT}/project/pgp" | |
48 | ;; | |
49 | esac | |
50 | ||
51 | for _KEY in ${_KEYS} | |
52 | do | |
53 | Echo_message "Fetching archive-key ${_KEY}..." | |
54 | ||
55 | wget -q "${_URL}/archive-key-${_KEY}.asc" -O chroot/key.asc | |
56 | wget -q "${_URL}/archive-key-${_KEY}.asc.sig" -O chroot/key.asc.sig | |
57 | ||
58 | if [ -e /usr/bin/gpgv ] && [ -e /usr/share/keyrings/debian-keyring.gpg ] | |
59 | then | |
60 | Echo_message "Verifying archive-key ${_KEY} against debian-keyring..." | |
61 | ||
62 | /usr/bin/gpgv --quiet --keyring /usr/share/keyrings/debian-keyring.gpg chroot/key.asc.sig chroot/key.asc > /dev/null 2>&1 || { Echo_error "archive-key ${_KEY} has invalid signature."; return 1;} | |
63 | else | |
64 | Echo_warning "Skipping archive-key ${_KEY} verification, either gpgv or debian-keyring not available on host system..." | |
65 | fi | |
66 | ||
67 | Echo_message "Importing archive-key ${_KEY}..." | |
68 | ||
69 | Chroot chroot "apt-key add key.asc" | |
70 | rm -f chroot/key.asc chroot/key.asc.sig | |
71 | done | |
72 | ||
73 | Chroot chroot "apt-get update" | |
74 | ||
75 | # Creating stage file | |
76 | Create_stagefile .build/bootstrap_archive-keys |
61 | 61 | then |
62 | 62 | # Modify archive areas to remove leading/trailing whitespaces and replace other whitepspace with commas |
63 | 63 | DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --components=$(echo ${LB_ARCHIVE_AREAS} | sed -e 's| |,|g')" |
64 | FOREIGN_DEBOOTSTRAP_OPTIONS="--components=$(echo ${LB_ARCHIVE_AREAS} | sed -e 's| |,|g')" | |
64 | 65 | fi |
65 | 66 | |
66 | 67 | if [ "${_VERBOSE}" = "true" ] |
86 | 87 | fi |
87 | 88 | |
88 | 89 | Echo_breakage "Running debootstrap (download-only)... " |
89 | debootstrap ${DEBOOTSTRAP_OPTIONS} --download-only "${LB_PARENT_DISTRIBUTION}" chroot "${LB_PARENT_MIRROR_BOOTSTRAP}" | |
90 | debootstrap ${DEBOOTSTRAP_OPTIONS} --download-only "${LB_PARENT_DISTRIBUTION}" chroot "${LB_PARENT_MIRROR_BOOTSTRAP}" ${DEBOOTSTRAP_SCRIPT} | |
90 | 91 | |
91 | 92 | # Removing old cache |
92 | 93 | rm -f cache/packages.bootstrap/*.deb |
107 | 108 | fi |
108 | 109 | |
109 | 110 | Echo_message "Bootstrap will be foreign" |
110 | debootstrap ${DEBOOTSTRAP_OPTIONS} --foreign "${LB_PARENT_DISTRIBUTION}" chroot "${LB_PARENT_MIRROR_BOOTSTRAP}" | |
111 | debootstrap ${DEBOOTSTRAP_OPTIONS} --foreign "${LB_PARENT_DISTRIBUTION}" chroot "${LB_PARENT_MIRROR_BOOTSTRAP}" ${DEBOOTSTRAP_SCRIPT} | |
111 | 112 | |
112 | 113 | Echo_message "Running debootstrap second stage under QEMU" |
113 | 114 | cp ${LB_BOOTSTRAP_QEMU_STATIC} chroot/usr/bin |
114 | Chroot chroot /bin/sh /debootstrap/debootstrap --second-stage | |
115 | Chroot chroot /bin/sh /debootstrap/debootstrap --second-stage ${FOREIGN_DEBOOTSTRAP_OPTIONS} | |
115 | 116 | else |
116 | debootstrap ${DEBOOTSTRAP_OPTIONS} "${LB_PARENT_DISTRIBUTION}" chroot "${LB_PARENT_MIRROR_BOOTSTRAP}" | |
117 | debootstrap ${DEBOOTSTRAP_OPTIONS} "${LB_PARENT_DISTRIBUTION}" chroot "${LB_PARENT_MIRROR_BOOTSTRAP}" ${DEBOOTSTRAP_SCRIPT} | |
117 | 118 | fi |
118 | 119 | |
119 | 120 | # Deconfiguring debootstrap configurations |
28 | 28 | |
29 | 29 | # Requiring stage file |
30 | 30 | Require_stagefile .build/config .build/bootstrap |
31 | ||
32 | _LB_LOCAL_KEY_EMAIL="live-build-local-key@invalid" | |
33 | 31 | |
34 | 32 | case "${LB_DERIVATIVE}" in |
35 | 33 | true) |
279 | 277 | -o APT::FTPArchive::Release::Origin=config/packages.chroot \ |
280 | 278 | release . > Release" | Chroot chroot sh |
281 | 279 | |
282 | if [ "${LB_APT_SECURE}" = "true" ] | |
283 | then | |
284 | if [ -e chroot/root/.gnupg ] | |
285 | then | |
286 | mv chroot/root/.gnupg chroot/root/.gnupg.orig | |
287 | fi | |
288 | ||
289 | # Ensure ~/.gnupg exists | |
290 | mkdir -p chroot/root/.gnupg | |
291 | ||
292 | # Temporarily replace /dev/random with /dev/urandom so as not | |
293 | # to block automated image builds; we don't care about the | |
294 | # security of this key anyway. | |
295 | if [ -e chroot/dev/random ] | |
296 | then | |
297 | mv chroot/dev/random chroot/dev/random.orig | |
298 | cp -a chroot/dev/urandom chroot/dev/random | |
299 | fi | |
300 | ||
301 | if Find_files cache/local-package-keyring.* | |
302 | then | |
303 | cp cache/local-package-keyring.* chroot/root | |
304 | else | |
305 | # Generate temporary key | |
306 | echo "Key-Type: RSA | |
307 | Key-Length: 1024 | |
308 | Subkey-Type: ELG-E | |
309 | Subkey-Length: 1024 | |
310 | Name-Real: live-build local packages key | |
311 | Name-Email: ${_LB_LOCAL_KEY_EMAIL} | |
312 | Expire-Date: 0 | |
313 | %secring /root/local-package-keyring.sec | |
314 | %pubring /root/local-package-keyring.pub | |
315 | %commit" | Chroot chroot "gpg --batch --gen-key" || _LB_RET=${?} | |
316 | ||
317 | case "${_LB_RET}" in | |
318 | ""|2) | |
319 | # Gnupg sometimes seems to return with a status of 2 when there was not | |
320 | # enough entropy (and key creation blocks temporarily) even if the | |
321 | # operation was ultimately successful. | |
322 | ;; | |
323 | *) | |
324 | Echo_error "GPG exited with error status %s" "${_LB_RET}" | |
325 | exit ${_LB_RET} | |
326 | ;; | |
327 | esac | |
328 | ||
329 | # Save keyrings to avoid regeneration | |
330 | cp chroot/root/local-package-keyring.* cache/ | |
331 | fi | |
332 | ||
333 | # Sign release | |
334 | Chroot chroot "gpg --no-default-keyring --secret-keyring /root/local-package-keyring.sec \ | |
335 | --keyring /root/local-package-keyring.pub -abs -o \ | |
336 | /root/packages/Release.gpg /root/packages/Release" | |
337 | ||
338 | # Import key | |
339 | Chroot chroot "gpg --no-default-keyring --secret-keyring /root/local-package-keyring.sec \ | |
340 | --keyring /root/local-package-keyring.pub --armor \ | |
341 | --export ${_LB_LOCAL_KEY_EMAIL}" | Chroot chroot "apt-key add -" | |
342 | ||
343 | # Remove temporary keyrings | |
344 | rm chroot/root/local-package-keyring.pub | |
345 | rm chroot/root/local-package-keyring.sec | |
346 | ||
347 | # Revert /dev/random | |
348 | if [ -e chroot/dev/random.orig ] | |
349 | then | |
350 | mv chroot/dev/random.orig chroot/dev/random | |
351 | fi | |
352 | ||
353 | rm -rf chroot/root/.gnupg | |
354 | ||
355 | if [ -e chroot/root/.gnupg.orig ] | |
356 | then | |
357 | mv chroot/root/.gnupg.orig chroot/root/.gnupg | |
358 | fi | |
359 | fi | |
360 | ||
361 | 280 | # Add to sources.list.d |
362 | echo "deb file:/root/packages ./" > chroot/etc/apt/sources.list.d/packages.list | |
281 | echo "deb [ trusted=yes ] file:/root/packages ./" > chroot/etc/apt/sources.list.d/packages.list | |
363 | 282 | |
364 | 283 | # Move top-level sources away, otherwise apt always preferes it (#644148) |
365 | 284 | if [ -e chroot/etc/apt/sources.list ] |
536 | 455 | fi |
537 | 456 | |
538 | 457 | # Configure generic indices |
539 | # Don't do anything if it's not required | |
540 | if [ "${LB_PARENT_MIRROR_CHROOT}" = "${LB_PARENT_MIRROR_BINARY}" ] && \ | |
541 | [ "${LB_PARENT_MIRROR_CHROOT_SECURITY}" = "${LB_PARENT_MIRROR_BINARY_SECURITY}" ] && \ | |
542 | [ ! -d chroot/root/packages ] | |
543 | then | |
544 | # Removing stage file | |
545 | rm -f .build/chroot_archives | |
546 | ||
547 | exit 0 | |
548 | fi | |
549 | ||
550 | 458 | # Cleaning apt list cache |
551 | 459 | rm -rf chroot/var/lib/apt/lists |
552 | 460 | mkdir -p chroot/var/lib/apt/lists/partial |
758 | 666 | rm -f chroot/etc/apt/sources.list.d/packages.list |
759 | 667 | rm -rf chroot/root/packages |
760 | 668 | |
761 | # Remove local packages key if it exists | |
762 | if Chroot chroot apt-key list | grep -q ${_LB_LOCAL_KEY_EMAIL} | |
763 | then | |
764 | Chroot chroot apt-key del ${_LB_LOCAL_KEY_EMAIL} | |
765 | fi | |
766 | ||
767 | 669 | # Removing stage file |
768 | 670 | rm -f .build/chroot_archives |
769 | 671 | ;; |
31 | 31 | \t [--bootappend-install PARAMETER|\"PARAMETERS\"]\n\ |
32 | 32 | \t [--bootappend-live PARAMETER|\"PARAMETERS\"]\n\ |
33 | 33 | \t [--bootappend-live-failsafe PARAMETER|\"PARAMETERS\"]\n\ |
34 | \t [--bootloaders grub-legacy|grub-pc|syslinux]\n\ | |
34 | \t [--bootloaders grub-legacy|grub-pc|syslinux|grub-efi]\n\ | |
35 | 35 | \t [--cache true|false]\n\ |
36 | 36 | \t [--cache-indices true|false]\n\ |
37 | 37 | \t [--cache-packages true|false]\n\ |
50 | 50 | \t [--debian-installer-distribution daily|CODENAME]\n\ |
51 | 51 | \t [--debian-installer-preseedfile FILE|URL]\n\ |
52 | 52 | \t [--debian-installer-gui true|false]\n\ |
53 | \t [--debootstrap-options OPTIONS]\n\ | |
54 | \t [--debootstrap-script SCRIPT]\n\ | |
53 | 55 | \t [--debug]\n\ |
54 | 56 | \t [-d|--distribution CODENAME]\n\ |
55 | 57 | \t [--parent-distribution CODENAME]\n\ |
125 | 127 | |
126 | 128 | Local_arguments () |
127 | 129 | { |
128 | LONG_OPTIONS="apt:,apt-ftp-proxy:,apt-http-proxy:,apt-options:,aptitude-options:,debootstrap-options:, | |
130 | LONG_OPTIONS="apt:,apt-ftp-proxy:,apt-http-proxy:,apt-options:,aptitude-options:,debootstrap-options:,debootstrap-script:, | |
129 | 131 | apt-pipeline:,apt-recommends:,apt-secure:,apt-source-archives:,bootstrap:,cache:,cache-indices:,cache-packages:, |
130 | 132 | cache-stages:,debconf-frontend:,debconf-priority:,dump, |
131 | 133 | initramfs:,initramfs-compression:,initsystem:,fdisk:,losetup:,mode:,system:,tasksel:, |
137 | 139 | archive-areas:,parent-archive-areas:,chroot-filesystem:, |
138 | 140 | gzip-options:,image-name:,interactive:,keyring-packages:,linux-flavours:,linux-packages:, |
139 | 141 | security:,updates:,backports:,binary-filesystem:,binary-images:, |
140 | apt-indices:,bootappend-install:,bootappend-live:,bootappend-live-failsafe:,bootloaders:,checksums:,compression:,config:,zsync:,build-with-chroot:, | |
142 | apt-indices:,bootappend-install:,bootappend-live:,bootappend-live-failsafe:,bootloader:,bootloaders:,checksums:,compression:,config:,zsync:,build-with-chroot:, | |
141 | 143 | debian-installer:,debian-installer-distribution:,debian-installer-preseedfile:,debian-installer-gui:, |
142 | 144 | grub-splash:,isohybrid-options:,hdd-label:,hdd-size:,hdd-partition-start:,iso-application:,iso-preparer:,iso-publisher:, |
143 | 145 | iso-volume:,jffs2-eraseblock:,memtest:,net-root-filesystem:,net-root-mountoptions:, |
258 | 260 | shift 2 |
259 | 261 | ;; |
260 | 262 | |
263 | --debootstrap-script) | |
264 | DEBOOTSTRAP_SCRIPT="${2}" | |
265 | shift 2 | |
266 | ;; | |
267 | ||
261 | 268 | --cache) |
262 | 269 | LB_CACHE="${2}" |
263 | 270 | shift 2 |
491 | 498 | shift 2 |
492 | 499 | ;; |
493 | 500 | |
494 | --bootloaders) | |
501 | --bootloaders|--bootloader) | |
495 | 502 | LB_BOOTLOADERS="${2}" |
496 | 503 | shift 2 |
497 | 504 | ;; |
995 | 1002 | APT_OPTIONS="${APT_OPTIONS}" |
996 | 1003 | APTITUDE_OPTIONS="${APTITUDE_OPTIONS}" |
997 | 1004 | DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS}" |
1005 | DEBOOTSTRAP_SCRIPT="${DEBOOTSTRAP_SCRIPT}" | |
998 | 1006 | GZIP_OPTIONS="${GZIP_OPTIONS}" |
999 | 1007 | ISOHYBRID_OPTIONS="${ISOHYBRID_OPTIONS}" |
1000 | 1008 | EOF |
0 | #! /bin/sh | |
1 | set -e | |
2 | ||
3 | # Copyright (C) 2010, 2011 Canonical Ltd. | |
4 | # Author: Colin Watson <[email protected]> | |
5 | # | |
6 | # This program is free software; you can redistribute it and/or modify it | |
7 | # under the terms of the GNU General Public License as published by the Free | |
8 | # Software Foundation; either version 2, or (at your option) any later | |
9 | # version. | |
10 | # | |
11 | # This program is distributed in the hope that it will be useful, but | |
12 | # WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY | |
13 | # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License | |
14 | # for more details. | |
15 | # | |
16 | # You should have received a copy of the GNU General Public License along | |
17 | # with this program; if not, write to the Free Software Foundation, Inc., | |
18 | # 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. | |
19 | ||
20 | # Make an EFI boot image. | |
21 | ||
22 | if [ -z "$1" ] || [ -z "$2" ]; then | |
23 | echo "usage: $0 OUTPUT-DIRECTORY GRUB-PLATFORM EFI-NAME NETBOOT-PREFIX" | |
24 | exit 1 | |
25 | fi | |
26 | ||
27 | outdir="$1" | |
28 | platform="$2" | |
29 | efi_name="$3" | |
30 | netboot_prefix="$4" | |
31 | ||
32 | memdisk_img= | |
33 | workdir= | |
34 | ||
35 | cleanup () { | |
36 | [ -z "$memdisk_img" ] || rm -f "$memdisk_img" | |
37 | [ -z "$workdir" ] || rm -rf "$workdir" | |
38 | } | |
39 | trap cleanup EXIT HUP INT QUIT TERM | |
40 | ||
41 | rm -rf "$outdir" | |
42 | mkdir -p "$outdir" | |
43 | ||
44 | memdisk_img="$(mktemp efi-image.XXXXXX)" | |
45 | workdir="$(mktemp -d efi-image.XXXXXX)" | |
46 | ||
47 | # Skeleton configuration file which finds the real boot disk. | |
48 | mkdir -p "$workdir/boot/grub" | |
49 | cat >"$workdir/boot/grub/grub.cfg" <<EOF | |
50 | search --file --set=root /.disk/info | |
51 | set prefix=(\$root)/boot/grub | |
52 | source \$prefix/$platform/grub.cfg | |
53 | EOF | |
54 | ||
55 | mkdir -p "$outdir/boot/grub/$platform" | |
56 | (for i in /usr/lib/grub/$platform/part_*.mod; do | |
57 | i=`echo $i | sed 's?^.*/??g;s?\.mod$??g;'` | |
58 | echo "insmod $i" | |
59 | done; \ | |
60 | echo "source /boot/grub/grub.cfg") >"$outdir/boot/grub/$platform/grub.cfg" | |
61 | ||
62 | # Build the core image. | |
63 | (cd "$workdir"; tar -cf - boot) >"$memdisk_img" | |
64 | grub-mkimage -O "$platform" -m "$memdisk_img" \ | |
65 | -o "$workdir/boot$efi_name.efi" -p '(memdisk)/boot/grub' \ | |
66 | search iso9660 configfile normal memdisk tar part_msdos part_gpt fat | |
67 | ||
68 | grub-mkimage -O "$platform" \ | |
69 | -o "$outdir/bootnet$efi_name.efi" -p "$netboot_prefix/grub" \ | |
70 | search configfile normal efinet tftp net | |
71 | ||
72 | # Stuff it into a FAT filesystem, making it as small as possible. 24KiB | |
73 | # headroom seems to be enough; (x+31)/32*32 rounds up to multiple of 32. | |
74 | mkfs.msdos -C "$outdir/efi.img" \ | |
75 | $(( ($(stat -c %s "$workdir/boot$efi_name.efi") / 1024 + 55) \ | |
76 | / 32 * 32 )) | |
77 | mmd -i "$outdir/efi.img" ::efi | |
78 | mmd -i "$outdir/efi.img" ::efi/boot | |
79 | mcopy -i "$outdir/efi.img" "$workdir/boot$efi_name.efi" \ | |
80 | "::efi/boot/boot$efi_name.efi" | |
81 | ||
82 | grub-cpmodules "$outdir" "$platform" | |
83 | cp /usr/share/grub/unicode.pf2 "$outdir/boot/grub/" | |
84 | ||
85 | exit 0 |
0 | #! /bin/sh | |
1 | set -e | |
2 | ||
3 | # Copyright (C) 2010, 2011 Canonical Ltd. | |
4 | # Author: Colin Watson <[email protected]> | |
5 | # | |
6 | # This program is free software; you can redistribute it and/or modify it | |
7 | # under the terms of the GNU General Public License as published by the Free | |
8 | # Software Foundation; either version 2, or (at your option) any later | |
9 | # version. | |
10 | # | |
11 | # This program is distributed in the hope that it will be useful, but | |
12 | # WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY | |
13 | # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License | |
14 | # for more details. | |
15 | # | |
16 | # You should have received a copy of the GNU General Public License along | |
17 | # with this program; if not, write to the Free Software Foundation, Inc., | |
18 | # 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. | |
19 | ||
20 | # Copy GRUB modules. | |
21 | ||
22 | # TODO: take the modules list as parameter, and only include the needed modules, using moddeps.lst to get dependencies | |
23 | ||
24 | if [ -z "$1" ] || [ -z "$2" ]; then | |
25 | echo "usage: $0 OUTPUT-DIRECTORY GRUB-PLATFORM" | |
26 | exit 1 | |
27 | fi | |
28 | ||
29 | outdir="$1" | |
30 | platform="$2" | |
31 | ||
32 | # Copy over GRUB modules, except for those already built in. | |
33 | cp -a "/usr/lib/grub/$platform"/*.lst "$outdir/boot/grub/$platform/" | |
34 | for x in "/usr/lib/grub/$platform"/*.mod; do | |
35 | # TODO: Some of these exclusions are based on knowledge of module | |
36 | # dependencies. It would be nice to have a way to read the module | |
37 | # list directly out of the image. | |
38 | case $(basename "$x" .mod) in | |
39 | configfile|fshelp|iso9660|memdisk|search|search_fs_file|search_fs_uuid|search_label|tar) | |
40 | # included in boot image | |
41 | ;; | |
42 | affs|afs|afs_be|befs|befs_be|minix|nilfs2|sfs|zfs|zfsinfo) | |
43 | # unnecessary filesystem modules | |
44 | ;; | |
45 | example_functional_test|functional_test|hello) | |
46 | # other cruft | |
47 | ;; | |
48 | *) | |
49 | cp -a "$x" "$outdir/boot/grub/$platform/" | |
50 | ;; | |
51 | esac | |
52 | done | |
53 | ||
54 | exit 0 |
247 | 247 | LB_PARENT_DEBIAN_INSTALLER_DISTRIBUTION="sid" |
248 | 248 | |
249 | 249 | # Debian Installer daily builds |
250 | URL="http://d-i.debian.org/daily-images/${LB_ARCHITECTURES}/daily/" | |
250 | URL="https://d-i.debian.org/daily-images/${LB_ARCHITECTURES}/daily/" | |
251 | 251 | else |
252 | 252 | URL="${LB_MIRROR_DEBIAN_INSTALLER}/dists/${LB_DEBIAN_INSTALLER_DISTRIBUTION}/main/installer-${LB_ARCHITECTURES}/current/images/" |
253 | 253 | fi |
259 | 259 | LB_PARENT_DEBIAN_INSTALLER_DISTRIBUTION="sid" |
260 | 260 | |
261 | 261 | # Debian Installer daily builds |
262 | URL="http://d-i.debian.org/daily-images/${LB_ARCHITECTURES}/daily/" | |
262 | URL="https://d-i.debian.org/daily-images/${LB_ARCHITECTURES}/daily/" | |
263 | 263 | else |
264 | 264 | URL="${LB_PARENT_MIRROR_DEBIAN_INSTALLER}/dists/${LB_PARENT_DEBIAN_INSTALLER_DISTRIBUTION}/main/installer-${LB_ARCHITECTURES}/current/images/" |
265 | 265 | fi |
103 | 103 | case "${LB_BINARY_FILESYSTEM}" in |
104 | 104 | ext2|ext3|ext4) |
105 | 105 | MKFS="${LB_BINARY_FILESYSTEM}" |
106 | MKFS_OPTIONS="-L ${LB_HDD_LABEL} -m 0" | |
106 | MKFS_OPTIONS="-L ${LB_HDD_LABEL} -m 0 -O ^64bit" | |
107 | 107 | MOUNT_OPTIONS="" |
108 | 108 | ;; |
109 | 109 |
97 | 97 | XORRISO_OPTIONS="${XORRISO_OPTIONS} -V \"${LB_ISO_VOLUME}\"" |
98 | 98 | fi |
99 | 99 | |
100 | # Set an explicit modification date | |
101 | XORRISO_OPTIONS="${XORRISO_OPTIONS} --modification-date=$(date --utc --date="@${SOURCE_DATE_EPOCH:-$(date +%s)}" +%Y%m%d%H%m%S00)" | |
102 | ||
100 | 103 | # Moving image |
101 | 104 | mv source chroot |
102 | 105 |
0 | /usr/lib/syslinux/modules/bios/libgpl.c32⏎ |
0 | /usr/lib/syslinux/modules/bios/libmenu.c32⏎ |
Binary diff not shown
Binary diff not shown
0 | 0 | set default=0 |
1 | 1 | |
2 | insmod tga | |
3 | background_image ($root)/boot/grub/splash.tga | |
4 | set color_normal=cyan/blue | |
5 | set color_highlight=white/blue | |
2 | loadfont $prefix/dejavu-bold-16.pf2 | |
3 | loadfont $prefix/dejavu-bold-14.pf2 | |
4 | loadfont $prefix/unicode.pf2 | |
5 | set gfxmode=auto | |
6 | insmod all_video | |
7 | insmod gfxterm | |
8 | insmod png | |
6 | 9 | |
10 | set color_normal=light-gray/black | |
11 | set color_highlight=white/black | |
12 | ||
13 | if [ -e /isolinux/splash.png ]; then | |
14 | # binary_syslinux modifies the theme file to point to the correct | |
15 | # background picture | |
16 | set theme=/boot/grub/live-theme/theme.txt | |
17 | elif [ -e /boot/grub/splash.png ]; then | |
18 | set theme=/boot/grub/live-theme/theme.txt | |
19 | else | |
20 | set menu_color_normal=cyan/blue | |
21 | set menu_color_highlight=white/blue | |
22 | fi | |
23 | ||
24 | terminal_output gfxterm | |
25 | ||
26 | insmod play | |
27 | play 960 440 1 0 4 440 1 | |
28 | ||
29 | # Live boot | |
7 | 30 | LINUX_LIVE |
8 | 31 | |
32 | # You can add more entries like this | |
33 | # menuentry "Alternate live boot" { | |
34 | # linux KERNEL_LIVE APPEND_LIVE custom options here | |
35 | # initrd INITRD_LIVE | |
36 | # } | |
37 | # menuentry "Alternate graphical installer" { | |
38 | # linux KERNEL_GI APPEND_GI custom options here | |
39 | # initrd INITRD_GI | |
40 | # } | |
41 | # menuentry "Alternate textual installer" { | |
42 | # linux KERNEL_DI APPEND_DI custom options here | |
43 | # initrd INITRD_DI | |
44 | # } | |
45 | ||
46 | # Installer (if any) | |
9 | 47 | LINUX_INSTALL |
10 | 48 | |
49 | submenu 'Advanced options...' { | |
50 | ||
51 | # More installer entries (if any) | |
52 | LINUX_ADVANCED_INSTALL | |
53 | ||
54 | # Memtest (if any) | |
11 | 55 | MEMTEST |
56 | ||
57 | } |
0 | desktop-image: "../splash.png" | |
1 | title-color: "#ffffff" | |
2 | title-font: "DejaVu Sans Bold 16" | |
3 | title-text: "Live Boot Menu with GRUB" | |
4 | message-font: "Unifont Regular 16" | |
5 | terminal-font: "Unifont Regular 16" | |
6 | ||
7 | #help bar at the bottom | |
8 | + label { | |
9 | top = 100%-50 | |
10 | left = 0 | |
11 | width = 100% | |
12 | height = 20 | |
13 | text = "@KEYMAP_SHORT@" | |
14 | align = "center" | |
15 | color = "#ffffff" | |
16 | font = "DejaVu Sans Bold 14" | |
17 | } | |
18 | ||
19 | #boot menu | |
20 | + boot_menu { | |
21 | left = 10% | |
22 | width = 80% | |
23 | top = 52% | |
24 | height = 48%-80 | |
25 | item_color = "#a8a8a8" | |
26 | item_font = "DejaVu Sans Bold 14" | |
27 | selected_item_color= "#ffffff" | |
28 | selected_item_font = "DejaVu Sans Bold 14" | |
29 | item_height = 16 | |
30 | item_padding = 0 | |
31 | item_spacing = 4 | |
32 | icon_width = 0 | |
33 | icon_heigh = 0 | |
34 | item_icon_space = 0 | |
35 | } | |
36 | ||
37 | #progress bar | |
38 | + progress_bar { | |
39 | id = "__timeout__" | |
40 | left = 15% | |
41 | top = 100%-80 | |
42 | height = 16 | |
43 | width = 70% | |
44 | font = "DejaVu Sans Regular 14" | |
45 | text_color = "#000000" | |
46 | fg_color = "#ffffff" | |
47 | bg_color = "#a8a8a8" | |
48 | border_color = "#ffffff" | |
49 | text = "@TIMEOUT_NOTIFICATION_LONG@" | |
50 | } |
Binary diff not shown
0 | /usr/lib/syslinux/modules/bios/libgpl.c32⏎ |
0 | /usr/lib/syslinux/modules/bios/libmenu.c32⏎ |
0 | /usr/lib/syslinux/modules/bios/libgpl.c32⏎ |
0 | /usr/lib/syslinux/modules/bios/libmenu.c32⏎ |
0 | /usr/lib/syslinux/modules/bios/libgpl.c32⏎ |
0 | /usr/lib/syslinux/modules/bios/libmenu.c32⏎ |