Changeset 3885 in MondoRescue for branches/3.3/mondo/src/common
- Timestamp:
- Mar 10, 2024, 7:23:12 PM (4 months ago)
- Location:
- branches/3.3/mondo/src/common
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3.3/mondo/src/common/libmondo-archive.c
r3883 r3885 854 854 if (bkpinfo->make_cd_use_lilo) { 855 855 log_msg(1, "make_cd_use_lilo = TRUE"); 856 #ifdef __IA64__857 log_msg(1, "IA64 --> elilo");858 mr_asprintf(full_isofs_cmd, "%s%s-o '_ISO_' .",isofs_cmd,MONDO_MKISOFS_REGULAR_ELILO);859 res = eval_call_to_make_ISO(full_isofs_cmd, destfile, g_current_media_number, message_to_screen);860 mr_free(full_isofs_cmd);861 #else862 log_msg(1, "Non-ia64 --> lilo");863 856 mr_asprintf(full_isofs_cmd, "%s%s-b images/mindi-bootroot.img -c images/boot.cat -o '_ISO_' .",isofs_cmd,MONDO_MKISOFS); 864 857 // FIXME: fixed boot size probably wrong. lilo to be removed 865 858 res = eval_call_to_make_ISO(full_isofs_cmd, destfile, g_current_media_number, message_to_screen); 866 859 mr_free(full_isofs_cmd); 867 #endif868 860 } else { 869 861 log_msg(1, "make_cd_use_lilo = FALSE"); … … 2589 2581 char *cd_recovery_sz = NULL; 2590 2582 char *tape_size_sz = NULL; 2591 char *use_lilo_sz = NULL; /* TODO: shared between LILO/ELILO */2583 char *use_lilo_sz = NULL; 2592 2584 char *value = NULL; 2593 2585 char *bootdev = NULL; … … 2701 2693 #else 2702 2694 /* Linux */ 2703 #ifdef __IA64__2704 bootdev = call_program_and_get_last_line_of_output("mount | grep ' /boot/efi ' | head -1 | cut -d' ' -f1 | sed 's/[0-9].*//'");2705 #else2706 2695 bootdev = call_program_and_get_last_line_of_output("mount | grep ' /boot ' | head -1 | cut -d' ' -f1 | sed 's/[0-9].*//'"); 2707 #endif2708 2696 if (strstr(bootdev, "/dev/cciss/")) { 2709 2697 mr_free(bootdev); 2710 #ifdef __IA64__2711 bootdev = call_program_and_get_last_line_of_output("mount | grep ' /boot/efi ' | head -1 | cut -d' ' -f1 | cut -dp -f1");2712 #else2713 2698 bootdev = call_program_and_get_last_line_of_output("mount | grep ' /boot ' | head -1 | cut -d' ' -f1 | cut -dp -f1"); 2714 #endif2715 2699 } 2716 2700 if (!bootdev[0]) { … … 2745 2729 bkpinfo->boot_loader != 'B' && bkpinfo->boot_loader != 'D' && 2746 2730 #endif 2747 #ifdef __IA64__2748 bkpinfo->boot_loader != 'E' &&2749 #endif2750 2731 bkpinfo->boot_loader != 'L' && bkpinfo->boot_loader != 'G' && bkpinfo->boot_loader != 'R') { 2751 2732 fatal_error("Please specify your boot loader and device, e.g. -l GRUB -f /dev/hda. Type 'man mondoarchive' to read the manual."); … … 2775 2756 mr_free(bootldr_ver); 2776 2757 bootldr_ver = call_program_and_get_last_line_of_output("grub2-install --version"); 2777 }2778 } else if (bkpinfo->boot_loader == 'E') {2779 mr_asprintf(bootldr_str, "ELILO");2780 /* TODO: fix it for Debian, Mageia, ... */2781 if (!does_file_exist("/etc/elilo.conf") && does_file_exist("/boot/efi/efi/redhat/elilo.conf")) {2782 run_program_and_log_output("ln -sf /boot/efi/efi/redhat/elilo.conf /etc/elilo.conf", 5);2783 }2784 if (!does_file_exist("/etc/elilo.conf") && does_file_exist("/boot/efi/efi/SuSE/elilo.conf")) {2785 run_program_and_log_output("ln -sf /boot/efi/efi/SuSE/elilo.conf /etc/elilo.conf", 5);2786 }2787 if (!does_file_exist("/etc/elilo.conf") && does_file_exist("/boot/efi/efi/debian/elilo.conf")) {2788 run_program_and_log_output ("ln -sf /boot/efi/efi/debian/elilo.conf /etc/elilo.conf", 5);2789 }2790 if (!does_file_exist("/etc/elilo.conf") && does_file_exist("/boot/efi/debian/elilo.conf")) {2791 run_program_and_log_output ("ln -sf /boot/efi/debian/elilo.conf /etc/elilo.conf", 5);2792 }2793 if (!does_file_exist("/etc/elilo.conf")) {2794 mr_free(bootldr_str);2795 fatal_error("The de facto mondo standard location for your boot loader's config file is /etc/elilo.conf but I cannot find it there. What is wrong with your Linux distribution? Try finding it under /boot/efi and do 'ln -s /boot/efi/..../elilo.conf /etc/elilo.conf'");2796 2758 } 2797 2759 } else if (bkpinfo->boot_loader == 'R') { -
branches/3.3/mondo/src/common/libmondo-cli.c
r3883 r3885 767 767 # define BOOT_LOADER_CHARS "GLBMR" 768 768 #else 769 # ifdef __IA64__ 770 # define BOOT_LOADER_CHARS "GER" 771 # else 772 # define BOOT_LOADER_CHARS "GLR" 773 # endif 769 # define BOOT_LOADER_CHARS "GLR" 774 770 #endif 775 771 if (!strchr(BOOT_LOADER_CHARS, (bkpinfo->boot_loader = flag_val['l'][0]))) { 776 log_msg(1, "%c? What is %c? I need G, L, Eor R.", bkpinfo->boot_loader, bkpinfo->boot_loader);777 fatal_error("Please specify GRUB, LILO , ELILOor RAW with the -l switch");772 log_msg(1, "%c? What is %c? I need G, L, or R.", bkpinfo->boot_loader, bkpinfo->boot_loader); 773 fatal_error("Please specify GRUB, LILO or RAW with the -l switch"); 778 774 } 779 775 #undef BOOT_LOADER_CHARS … … 842 838 if ((run_program_and_log_output("which mkfs.vfat", 2)) && (! bkpinfo->restore_data)) { 843 839 bkpinfo->make_cd_use_lilo = TRUE; 844 #ifdef __IA32__845 840 log_to_screen("Your filesystem is missing 'mkfs.vfat', so I cannot use SYSLINUX as"); 846 841 log_to_screen("your boot loader. I shall therefore use LILO instead."); 847 #endif 848 #ifdef __IA64__ 849 log_to_screen("Your filesystem is missing 'mkfs.vfat', so I cannot prepare the EFI"); 850 log_to_screen("environment correctly. Please install it."); 851 fatal_error("Aborting"); 852 #endif 853 } 854 #ifdef __IA64__ 855 /* We force ELILO usage on IA64 */ 856 bkpinfo->make_cd_use_lilo = TRUE; 857 #endif 842 } 858 843 #endif 859 844 -
branches/3.3/mondo/src/common/libmondo-devices.c
r3883 r3885 1771 1771 DIR *fd = NULL; 1772 1772 1773 #ifdef __IA64__1774 return(EFI);1775 #endif1776 1773 /* Try to detect whether we are in fact in UEFI mode */ 1777 1774 fd = opendir("/sys/firmware/efi"); … … 1788 1785 * Find out which boot loader is in use. 1789 1786 * @param which_device Device to look for the boot loader on. 1790 * @return 'L' for LILO, ' E'for ELILO, 'G' for GRUB, 'B' or 'D' for FreeBSD boot loaders, or 'U' for Unknown.1787 * @return 'L' for LILO, 'G' for GRUB, 'B' or 'D' for FreeBSD boot loaders, or 'U' for Unknown. 1791 1788 * @note Under Linux, all drives are examined, not just @p which_device. 1792 1789 */ … … 1813 1810 count_dangerouslydedicated++; 1814 1811 } 1815 log_it("%d grubs and %d lilos and %d elilosand %d boot0s and %d DD\n",1816 count_grubs, count_lilos, count_ elilos, count_boot0s,1812 log_it("%d grubs and %d lilos andand %d boot0s and %d DD\n", 1813 count_grubs, count_lilos, count_boot0s, 1817 1814 count_dangerouslydedicated); 1818 1815 … … 1851 1848 1852 1849 /*@ end vars *************************************************** */ 1853 1854 #ifdef __IA64__1855 /* No choice for it */1856 return ('E');1857 #endif1858 if (bkpinfo->boot_type == EFI) {1859 /* No choice for it */1860 return ('E');1861 }1862 1850 1863 1851 if (bkpinfo->boot_type == UEFI) { … … 2455 2443 mr_asprintf(bkpinfo->boot_device, "%s", tmp1); 2456 2444 2457 if (does_string_exist_in_boot_block(bkpinfo->boot_device, "ELILO")) { 2458 i = 'E'; 2459 } else 2460 if (does_string_exist_in_boot_block(bkpinfo->boot_device, "LILO")) { 2445 if (does_string_exist_in_boot_block(bkpinfo->boot_device, "LILO")) { 2461 2446 i = 'L'; 2462 2447 } else … … 2568 2553 } 2569 2554 // Interactive mode: 2570 #ifdef __IA64__2571 bkpinfo->make_cd_use_lilo = TRUE;2572 #else2573 2555 bkpinfo->make_cd_use_lilo = FALSE; 2574 #endif2575 2556 bkpinfo->backup_data = TRUE; 2576 2557 if (strcmp(compression_type,"lzo") == 0) { -
branches/3.3/mondo/src/common/libmondo-tools.c
r3883 r3885 191 191 # endif 192 192 #endif 193 #ifdef __IA64__194 return ("ia64");195 #endif196 193 return ("unknown"); 197 194 } … … 442 439 (bkpinfo->make_cd_use_lilo) 443 440 #endif 444 #ifdef __IA64__445 {446 mr_asprintf(mondo_mkisofs_sz, MONDO_GROWISOFS_REGULAR_ELILO);447 }448 #else449 441 { 450 442 mr_asprintf(mondo_mkisofs_sz, MONDO_GROWISOFS_REGULAR_LILO); 451 443 } 452 #endif453 444 else { 454 445 mondo_mkisofs_sz = mr_compute_uefi_string(cdr_exe); … … 509 500 (bkpinfo->make_cd_use_lilo) 510 501 #endif 511 #ifdef __IA64__512 {513 mr_asprintf(mondo_mkisofs_sz, "%s%s ", isofs_cmd, MONDO_MKISOFS_REGULAR_ELILO);514 }515 #else516 502 { 517 503 mr_asprintf(mondo_mkisofs_sz, "%s%s ", isofs_cmd, MONDO_MKISOFS_REGULAR_LILO); 518 504 } 519 #endif520 505 else { 521 506 mondo_mkisofs_sz = mr_compute_uefi_string(isofs_cmd); -
branches/3.3/mondo/src/common/mondostructures.h
r3883 r3885 351 351 * - 'G' for GRUB 352 352 * - 'L' for LILO 353 * - 'E' for ELILO354 353 * - (FreeBSD only) 'B' for boot0 355 354 * - (FreeBSD only) 'D' for dangerously dedicated … … 620 619 621 620 /** 622 * If TRUE, make the bootable CD use LILO /ELILO. If FALSE, use isolinux (the default).621 * If TRUE, make the bootable CD use LILO. If FALSE, use isolinux (the default). 623 622 */ 624 623 bool make_cd_use_lilo;
Note:
See TracChangeset
for help on using the changeset viewer.