cl-kernel: добавлена опция --mbr

master 0.3.2
parent db53880bbc
commit edb48e1b17

@ -14,7 +14,7 @@
# limitations under the License. # limitations under the License.
TEXTDOMAIN=cl_kernel TEXTDOMAIN=cl_kernel
CL_KERNEL_VERSION=0.2.6 CL_KERNEL_VERSION=0.2.7
DESCRIPTION=$"Kernel building tool" DESCRIPTION=$"Kernel building tool"
DEFAULT_KERNEL_DIRECTORY="$(readlink -f /usr/src/linux)" DEFAULT_KERNEL_DIRECTORY="$(readlink -f /usr/src/linux)"
SRC_DIRECTORY=/usr/src SRC_DIRECTORY=/usr/src
@ -32,6 +32,9 @@ CREATE_NEW=1
# собирать ядро после конфигурации # собирать ядро после конфигурации
# compile the kernel once configuration is complete # compile the kernel once configuration is complete
BUILD_KERNEL=1 BUILD_KERNEL=1
# обновить MBR запись диска во время установки ядра
# update the MBR record of the disk during the kernel installation
UPDATE_MBR=1
# очистить исходники ядра перед сборкой # очистить исходники ядра перед сборкой
# clean the kernel sources before the compilation # clean the kernel sources before the compilation
CLEAN_KERNEL=1 CLEAN_KERNEL=1
@ -96,6 +99,7 @@ ${DESCRIPTION}
--kver-old [VERSION] specify the kernel version for new options ('list' for displaying possible values) --kver-old [VERSION] specify the kernel version for new options ('list' for displaying possible values)
--convert migrate .config from the kernel directory to templates --convert migrate .config from the kernel directory to templates
-s, --skip-build do not build the kernel after configuration -s, --skip-build do not build the kernel after configuration
--mbr [ON/OFF] update MBR
--skip-config do not manual configure the kernel --skip-config do not manual configure the kernel
--noclean do not clean the kernel sources before the compilation --noclean do not clean the kernel sources before the compilation
--march [ARCH] kernel architecture (x86 or x86_64) --march [ARCH] kernel architecture (x86 or x86_64)
@ -117,6 +121,7 @@ rearrange_params() {
--long convert \ --long convert \
--long noclean \ --long noclean \
--long skip-build \ --long skip-build \
--long mbr: \
--long skip-config \ --long skip-config \
--long safemode \ --long safemode \
-- "$@" 2>&1) -- "$@" 2>&1)
@ -162,6 +167,19 @@ do_args() {
-s|--skip-build) -s|--skip-build)
BUILD_KERNEL= BUILD_KERNEL=
;; ;;
--mbr)
UPDATE_MBR="$2"
if [[ ${UPDATE_MBR} =~ ^[Oo][Nn]$ ]]
then
UPDATE_MBR='on'
elif [[ ${UPDATE_MBR} =~ ^[Oo][Ff][Ff]$ ]]
then
UPDATE_MBR='off'
else
eerror $"Error in parameter --mbr. The value may be 'on' or 'off'"
fi
shift
;;
--skip-config) --skip-config)
MANUAL_CONFIG= MANUAL_CONFIG=
;; ;;
@ -704,7 +722,12 @@ then
# applying the templates for boot configuration # applying the templates for boot configuration
if [[ -n $NOT_CHROOT ]] if [[ -n $NOT_CHROOT ]]
then then
cl-setup-boot mbr_set=
if [[ $UPDATE_MBR == 'off' ]]
then
mbr_set=' --mbr none'
fi
cl-setup-boot $mbr_set
fi fi
# вывод времени компиляции ядра # вывод времени компиляции ядра

@ -2,7 +2,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: cl-kernel 0.1.4\n" "Project-Id-Version: cl-kernel 0.1.4\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2015-02-24 13:43+0300\n" "POT-Creation-Date: 2023-02-07 17:46+0300\n"
"PO-Revision-Date: 2015-02-24 13:43+0300\n" "PO-Revision-Date: 2015-02-24 13:43+0300\n"
"Last-Translator: Mir Calculate <support@calculate.ru>, Elena Gavrilova <e.vl." "Last-Translator: Mir Calculate <support@calculate.ru>, Elena Gavrilova <e.vl."
"gavrilova@yandex.ru>\n" "gavrilova@yandex.ru>\n"
@ -16,11 +16,11 @@ msgstr ""
msgid "Kernel building tool" msgid "Kernel building tool"
msgstr "Утилита для сборки ядра" msgstr "Утилита для сборки ядра"
#: ../cl-kernel:64 #: ../cl-kernel:67
msgid "This program must be run as root" msgid "This program must be run as root"
msgstr "Это программа должна быть запущена от пользователя root" msgstr "Это программа должна быть запущена от пользователя root"
#: ../cl-kernel:77 #: ../cl-kernel:80
msgid "" msgid ""
"Usage: $0 [OPTION]\n" "Usage: $0 [OPTION]\n"
"\n" "\n"
@ -38,7 +38,7 @@ msgstr ""
"\n" "\n"
" -h, --help отобразить все параметры и выйти" " -h, --help отобразить все параметры и выйти"
#: ../cl-kernel:89 #: ../cl-kernel:92
msgid "" msgid ""
"Usage: $0 [OPTION]\n" "Usage: $0 [OPTION]\n"
"\n" "\n"
@ -53,6 +53,7 @@ msgid ""
" --convert migrate .config from the kernel directory to " " --convert migrate .config from the kernel directory to "
"templates\n" "templates\n"
" -s, --skip-build do not build the kernel after configuration\n" " -s, --skip-build do not build the kernel after configuration\n"
" --mbr [ON/OFF] update MBR\n"
" --skip-config do not manual configure the kernel\n" " --skip-config do not manual configure the kernel\n"
" --noclean do not clean the kernel sources before the " " --noclean do not clean the kernel sources before the "
"compilation\n" "compilation\n"
@ -74,6 +75,7 @@ msgstr ""
" --convert преобразовать .config из директории c исходным " " --convert преобразовать .config из директории c исходным "
"кодом ядра в шаблон\n" "кодом ядра в шаблон\n"
" -s, --skip-build не собирать ядро после конфигурации\n" " -s, --skip-build не собирать ядро после конфигурации\n"
" --mbr [ON/OFF] обновить MBR\n"
" --skip-config не выполнять редактирование настроек\n" " --skip-config не выполнять редактирование настроек\n"
" --noclean не выполнять make clean перед сборкой ядра\n" " --noclean не выполнять make clean перед сборкой ядра\n"
" --march [АРХИТЕКТУРА] архитектура ядра (x86 или x86_64)\n" " --march [АРХИТЕКТУРА] архитектура ядра (x86 или x86_64)\n"
@ -81,153 +83,159 @@ msgstr ""
"(только для calculate-sources)\n" "(только для calculate-sources)\n"
" --help вывод этой справки и выход\n" " --help вывод этой справки и выход\n"
#: ../cl-kernel:154 #: ../cl-kernel:159
msgid "Error in parameter --march. The value may be 'x86' or 'x86_64'" msgid "Error in parameter --march. The value may be 'x86' or 'x86_64'"
msgstr "Ошибка в параметре --march. Значение может быть 'x86' или 'x86_64'" msgstr "Ошибка в параметре --march. Значение может быть 'x86' или 'x86_64'"
#: ../cl-kernel:173 #: ../cl-kernel:179
msgid "Error in parameter --mbr. The value may be 'on' or 'off'"
msgstr "Ошибка в параметре --mbr. Значение может быть 'on' или 'off'"
#: ../cl-kernel:191
msgid "Unknown option: $1" msgid "Unknown option: $1"
msgstr "Неизвестный параметр: $1" msgstr "Неизвестный параметр: $1"
#: ../cl-kernel:181 #: ../cl-kernel:199
msgid "Unknown argument: $1" msgid "Unknown argument: $1"
msgstr "Неизвестный параметр: $1" msgstr "Неизвестный параметр: $1"
#: ../cl-kernel:292 #: ../cl-kernel:310
msgid "Failed to create the default kernel config" msgid "Failed to create the default kernel config"
msgstr "Не удалось создать конфигурацию ядра по умолчанию" msgstr "Не удалось создать конфигурацию ядра по умолчанию"
#: ../cl-kernel:303 #: ../cl-kernel:321
msgid "Failed to apply kernel templates" msgid "Failed to apply kernel templates"
msgstr "Не удалось применить шаблоны ядра" msgstr "Не удалось применить шаблоны ядра"
#: ../cl-kernel:306 #: ../cl-kernel:324
msgid "Kernel configuration file not found" msgid "Kernel configuration file not found"
msgstr "Файл конфигурации ядра не найден" msgstr "Файл конфигурации ядра не найден"
#: ../cl-kernel:373 #: ../cl-kernel:391
#, sh-format
msgid "Will be used $config kernel configuration" msgid "Will be used $config kernel configuration"
msgstr "Будет использован $config с конфигурацией ядра" msgstr "Будет использован $config с конфигурацией ядра"
#: ../cl-kernel:375 #: ../cl-kernel:393
msgid "Failed to get current kernel configuration" msgid "Failed to get current kernel configuration"
msgstr "Не удалось получить текущую конфигурацию ядра" msgstr "Не удалось получить текущую конфигурацию ядра"
#: ../cl-kernel:395 #: ../cl-kernel:413
#, sh-format
msgid "${fn} does not belong to any package" msgid "${fn} does not belong to any package"
msgstr "${fn} не принадлежит ни одному пакету" msgstr "${fn} не принадлежит ни одному пакету"
#: ../cl-kernel:398 #: ../cl-kernel:416
#, sh-format
msgid "${fn} belongs to multiple packages" msgid "${fn} belongs to multiple packages"
msgstr "${fn} принадлежит нескольким пакетам" msgstr "${fn} принадлежит нескольким пакетам"
#: ../cl-kernel:477 #: ../cl-kernel:495
#, sh-format
msgid "Kernel directory ${check_dir} not found" msgid "Kernel directory ${check_dir} not found"
msgstr "Директория ядра ${check_dir} не найдена" msgstr "Директория ядра ${check_dir} не найдена"
#: ../cl-kernel:478 #: ../cl-kernel:496
#, sh-format
msgid "Kernel directory ${check_dir} has no full sources" msgid "Kernel directory ${check_dir} has no full sources"
msgstr "Директория ядра ${check_dir} не содержит всего исходного кода" msgstr "Директория ядра ${check_dir} не содержит всего исходного кода"
#: ../cl-kernel:492 #: ../cl-kernel:510
msgid "--safemode unavailable for chroot" msgid "--safemode unavailable for chroot"
msgstr "--safemode недоступен для chroot" msgstr "--safemode недоступен для chroot"
#: ../cl-kernel:497 #: ../cl-kernel:515
msgid "--safemode available for calculate-sources only" msgid "--safemode available for calculate-sources only"
msgstr "--safemode доступен только для calculate-sources" msgstr "--safemode доступен только для calculate-sources"
#: ../cl-kernel:502 #: ../cl-kernel:520
msgid "--safemode unavailable without dracut" msgid "--safemode unavailable without dracut"
msgstr "--safemode недоступен без dracut" msgstr "--safemode недоступен без dracut"
#: ../cl-kernel:511 #: ../cl-kernel:529
msgid "Failed to create the kernel template directory" msgid "Failed to create the kernel template directory"
msgstr "Не удалось создать директорию для шаблонов ядра" msgstr "Не удалось создать директорию для шаблонов ядра"
#: ../cl-kernel:562 #: ../cl-kernel:580
msgid "Preparing the current kernel configuration" msgid "Preparing the current kernel configuration"
msgstr "Подготовка текущей конфигурации ядра" msgstr "Подготовка текущей конфигурации ядра"
#: ../cl-kernel:570 #: ../cl-kernel:588
msgid "--convert is uncompatible with --march" msgid "--convert is uncompatible with --march"
msgstr "--convert не совместим с --march" msgstr "--convert не совместим с --march"
#: ../cl-kernel:574 #: ../cl-kernel:592
msgid "--convert is uncompatible with --kver-old" msgid "--convert is uncompatible with --kver-old"
msgstr "--convert не совместим с --kver-old" msgstr "--convert не совместим с --kver-old"
#: ../cl-kernel:585 #: ../cl-kernel:603
msgid "Preparing the basic kernel configuration" msgid "Preparing the basic kernel configuration"
msgstr "Подготовка базовой конфигурации ядра" msgstr "Подготовка базовой конфигурации ядра"
#: ../cl-kernel:623 #: ../cl-kernel:641
msgid "The kernel configuration has not changed" msgid "The kernel configuration has not changed"
msgstr "Конфигурация ядра не изменилась" msgstr "Конфигурация ядра не изменилась"
#: ../cl-kernel:628 #: ../cl-kernel:646
msgid "Backing up the template" msgid "Backing up the template"
msgstr "Резервное копирование шаблона" msgstr "Резервное копирование шаблона"
#: ../cl-kernel:632 #: ../cl-kernel:650
msgid "Failed to create a backup directory" msgid "Failed to create a backup directory"
msgstr "Не удалось создать директорию для резервных копий" msgstr "Не удалось создать директорию для резервных копий"
#: ../cl-kernel:647 #: ../cl-kernel:665
msgid "Creating the template" msgid "Creating the template"
msgstr "Создание шаблона" msgstr "Создание шаблона"
#: ../cl-kernel:650 #: ../cl-kernel:668
msgid "Skipping the empty template" msgid "Skipping the empty template"
msgstr "Пропуск пустого шаблона" msgstr "Пропуск пустого шаблона"
#: ../cl-kernel:670 #: ../cl-kernel:688
msgid "Failed to clean the kernel sources" msgid "Failed to clean the kernel sources"
msgstr "Не удалось выполнить make clean для исходного кода ядра" msgstr "Не удалось выполнить make clean для исходного кода ядра"
#: ../cl-kernel:672 #: ../cl-kernel:690
msgid "Failed to compile the kernel" msgid "Failed to compile the kernel"
msgstr "Не удалось скомпилировать ядро" msgstr "Не удалось скомпилировать ядро"
#: ../cl-kernel:673 #: ../cl-kernel:691
msgid "Failed to compile the kernel modules" msgid "Failed to compile the kernel modules"
msgstr "Не удалось собрать модули ядра" msgstr "Не удалось собрать модули ядра"
#: ../cl-kernel:674 #: ../cl-kernel:692
msgid "Failed to install the kernel" msgid "Failed to install the kernel"
msgstr "Не удалось установить ядро" msgstr "Не удалось установить ядро"
#: ../cl-kernel:675 #: ../cl-kernel:693
msgid "Failed to build kernel" msgid "Failed to build kernel"
msgstr "Не удалось собрать ядро" msgstr "Не удалось собрать ядро"
#: ../cl-kernel:692 #: ../cl-kernel:710
msgid "Failed to create the host-only initramfs" msgid "Failed to create the host-only initramfs"
msgstr "Не удалось создать host-only initramfs" msgstr "Не удалось создать host-only initramfs"
#: ../cl-kernel:695 #: ../cl-kernel:713
msgid "Failed to create the safemode initramfs" msgid "Failed to create the safemode initramfs"
msgstr "Не удалось создать safemode initramfs" msgstr "Не удалось создать safemode initramfs"
#: ../cl-kernel:719 #: ../cl-kernel:742
msgid "Kernel build time: " msgid "Kernel build time: "
msgstr "Время сборки ядра: " msgstr "Время сборки ядра: "
#: ../cl-kernel:722 #: ../cl-kernel:745
msgid "%d hour %d min %d sec\\n" msgid "%d hour %d min %d sec\\n"
msgstr "%d час %d мин %d сек\\n" msgstr "%d час %d мин %d сек\\n"
#: ../cl-kernel:724 #: ../cl-kernel:747
msgid "%d min %d sec\\n" msgid "%d min %d sec\\n"
msgstr "%d мин %d сек\\n" msgstr "%d мин %d сек\\n"
#: ../cl-kernel:737 #: ../cl-kernel:760
msgid "To rebuild kernel modules packages, please run:" msgid "To rebuild kernel modules packages, please run:"
msgstr "Для пересборки пакетов модулей ядра необходимо запустить:" msgstr "Для пересборки пакетов модулей ядра необходимо запустить:"
#: ../cl-kernel:744 #: ../cl-kernel:767
msgid "All done!" msgid "All done!"
msgstr "Все готово!" msgstr "Все готово!"
#~ msgid "Failed to import make.conf"
#~ msgstr "Не удалось импортировать make.conf"

Loading…
Cancel
Save