Changeset 497 in MondoRescue


Ignore:
Timestamp:
Apr 28, 2006, 12:34:03 AM (18 years ago)
Author:
bcornec
Message:

Integration of a big patch from rene-marc dolhen <rmd_at_mecreant.org> to support internationalization with gettext.

Location:
branches/stable/mondo
Files:
3 added
20 edited

Legend:

Unmodified
Added
Removed
  • branches/stable/mondo/ChangeLog

    r427 r497  
    33MONDO CHANGES
    44
    5 v2.07 (2006-02-23)
     5v2.2.0 (2006-05-01)
     6
     7- Internationalization (A huge thank to rene-marc dolhen
     8<rmd_at_mecreant.org> who achieved that big task)
     9- Fixed verify for NFS (Andree Leidenfrost)
     10- Fix for Bug #6975 (Bruno Cornec)
     11- Fix a bug when restoring interactively and having file names with blank
     12  (Bruno Cornec)
     13- Fix options -I and -E of mondoarchive which were not working
     14  (Bruno Cornec)
     15- Removed 'ax' options from ps call in busybox (Andree Leidenfrost)
     16
     17v2.0.7 (2006-02-23)
    618- useless cat, sort|uniq commands removed
    719  (Bruno Cornec/Sébastien Aperghis-Tramoni)
  • branches/stable/mondo/bootstrap

    r35 r497  
    2727
    2828make maintainer-clean >/dev/null 2>&1
     29gettextize -c --no-changelog
    2930libtoolize -f -c --automake
    30 aclocal
     31aclocal -I m4
    3132autoheader
    3233automake
  • branches/stable/mondo/configure.in

    r487 r497  
    3030AC_PROG_MAKE_SET
    3131
     32AM_GNU_GETTEXT([external])
     33ALL_LINGUAS="fr"
    3234
    3335dnl --with/--enable stuff
     
    121123AC_CHECK_FUNCS([bzero getcwd memmove memset mkdir mkfifo setenv strcasecmp strchr strerror strrchr strstr])
    122124
    123 AC_OUTPUT([Makefile mondo/Makefile mondo/common/Makefile mondo/mondoarchive/Makefile mondo/mondorestore/Makefile mondo/restore-scripts/Makefile mondo/restore-scripts/mondo/Makefile mondo/restore-scripts/usr/Makefile mondo/restore-scripts/usr/bin/Makefile mondo/post-nuke.sample/Makefile mondo/post-nuke.sample/usr/Makefile mondo/post-nuke.sample/usr/bin/Makefile])
     125AC_OUTPUT([Makefile mondo/Makefile mondo/common/Makefile mondo/mondoarchive/Makefile mondo/mondorestore/Makefile mondo/restore-scripts/Makefile mondo/restore-scripts/mondo/Makefile mondo/restore-scripts/usr/Makefile mondo/restore-scripts/usr/bin/Makefile mondo/post-nuke.sample/Makefile mondo/post-nuke.sample/usr/Makefile mondo/post-nuke.sample/usr/bin/Makefile m4/Makefile.in po/Makefile])
  • branches/stable/mondo/mondo/common/libmondo-devices.c

    r305 r497  
    352352            && !does_file_exist("/tmp/mountlist.txt.sample")) {
    353353            log_to_screen
    354                 ("Using /dev/root is stupid of you but I'll forgive you.");
     354                (_("Using /dev/root is stupid of you but I'll forgive you."));
    355355            is_this_a_ramdisk = FALSE;
    356356        }
     
    380380    switch (bt) {
    381381    case none:
    382         strcpy(output, "none");
     382        strcpy(output, _("none"));
    383383        break;
    384384    case iso:
    385         strcpy(output, "iso");
     385        strcpy(output, _("iso"));
    386386        break;
    387387    case cdr:
    388         strcpy(output, "cdr");
     388        strcpy(output, _("cdr"));
    389389        break;
    390390    case cdrw:
    391         strcpy(output, "cdrw");
     391        strcpy(output, _("cdrw"));
    392392        break;
    393393    case cdstream:
    394         strcpy(output, "cdstream");
     394        strcpy(output, _("cdstream"));
    395395        break;
    396396    case nfs:
    397         strcpy(output, "nfs");
     397        strcpy(output, _("nfs"));
    398398        break;
    399399    case tape:
    400         strcpy(output, "tape");
     400        strcpy(output, _("tape"));
    401401        break;
    402402    case udev:
    403         strcpy(output, "udev");
     403        strcpy(output, _("udev"));
    404404        break;
    405405    default:
    406         strcpy(output, "default");
     406        strcpy(output, _("default"));
    407407    }
    408408    return (output);
     
    695695    if (!dev[0] || (res = mount_CDROM_here(dev, mountpoint))) {
    696696        if (!popup_and_get_string
    697             ("CD-ROM device", "Please enter your CD-ROM's /dev device",
     697            (_("CD-ROM device"), _("Please enter your CD-ROM's /dev device"),
    698698             dev, MAX_STR_LEN / 4)) {
    699699            res = 1;
     
    703703    }
    704704    if (res) {
    705         log_msg(1, "mount failed");
     705        log_msg(1, _("mount failed"));
    706706    } else {
    707         log_msg(1, "mount succeeded with %s", dev);
     707        log_msg(1, _("mount succeeded with %s"), dev);
    708708    }
    709709    paranoid_free(dev);
     
    17721772            }
    17731773            if (res) {
    1774                 log_to_screen("WARNING - failed to unmount CD-ROM drive");
     1774                log_to_screen(_("WARNING - failed to unmount CD-ROM drive"));
    17751775            }
    17761776            if (!bkpinfo->please_dont_eject) {
     
    17801780            }
    17811781            if (res) {
    1782                 log_to_screen("WARNING - failed to eject CD-ROM disk");
     1782                log_to_screen(_("WARNING - failed to eject CD-ROM disk"));
    17831783            }
    17841784            popup_and_OK(request);
     
    18411841        which_backup_media_type(bkpinfo->restore_data);
    18421842    if (bkpinfo->backup_media_type == none) {
    1843         log_to_screen("User has chosen not to backup the PC");
     1843        log_to_screen(_("User has chosen not to backup the PC"));
    18441844        finish(1);
    18451845    }
    18461846    if (bkpinfo->backup_media_type == tape && bkpinfo->restore_data) {
    1847         popup_and_OK("Please remove CD/floppy from drive(s)");
     1847        popup_and_OK(_("Please remove CD/floppy from drive(s)"));
    18481848    }
    18491849    log_msg(3, "media type = %s",
     
    18801880        if (archiving_to_media) {
    18811881            if (ask_me_yes_or_no
    1882                 ("Is your computer a laptop, or does the CD writer incorporate BurnProof technology?"))
     1882                (_("Is your computer a laptop, or does the CD writer incorporate BurnProof technology?")))
    18831883            {
    18841884                bkpinfo->manual_cd_tray = TRUE;
     
    18861886            if ((bkpinfo->compression_level =
    18871887                 which_compression_level()) == -1) {
    1888                 log_to_screen("User has chosen not to backup the PC");
     1888                log_to_screen(_("User has chosen not to backup the PC"));
    18891889                finish(1);
    18901890            }
    1891             sprintf(comment, "What speed is your %s (re)writer?",
     1891            sprintf(comment, _("What speed is your %s (re)writer?"),
    18921892                    media_descriptor_string(bkpinfo->backup_media_type));
    18931893            if (bkpinfo->backup_media_type == dvd) {
     
    19031903            }
    19041904            if (bkpinfo->backup_media_type != dvd) {
    1905                 if (!popup_and_get_string("Speed", comment, tmp, 4)) {
    1906                     log_to_screen("User has chosen not to backup the PC");
     1905                if (!popup_and_get_string(_("Speed"), comment, tmp, 4)) {
     1906                    log_to_screen(_("User has chosen not to backup the PC"));
    19071907                    finish(1);
    19081908                }
     
    19101910            bkpinfo->cdrw_speed = atoi(tmp);    // if DVD then this shouldn't ever be used anyway :)
    19111911            sprintf(comment,
    1912                     "How much data (in Megabytes) will each %s store?",
     1912                    _("How much data (in Megabytes) will each %s store?"),
    19131913                    media_descriptor_string(bkpinfo->backup_media_type));
    19141914            if (!popup_and_get_string("Size", comment, sz_size, 5)) {
    1915                 log_to_screen("User has chosen not to backup the PC");
     1915                log_to_screen(_("User has chosen not to backup the PC"));
    19161916                finish(1);
    19171917            }
     
    19201920            }
    19211921            if (bkpinfo->media_size[0] <= 0) {
    1922                 log_to_screen("User has chosen not to backup the PC");
     1922                log_to_screen(_("User has chosen not to backup the PC"));
    19231923                finish(1);
    19241924            }
     
    19411941                        bkpinfo->media_device);
    19421942                sprintf(comment,
    1943                         "Please specify your %s drive's /dev entry",
     1943                        _("Please specify your %s drive's /dev entry"),
    19441944                        media_descriptor_string(bkpinfo->
    19451945                                                backup_media_type));
    19461946                if (!popup_and_get_string
    1947                     ("Device?", comment, bkpinfo->media_device,
     1947                    (_("Device?"), comment, bkpinfo->media_device,
    19481948                     MAX_STR_LEN / 4)) {
    1949                     log_to_screen("User has chosen not to backup the PC");
     1949                    log_to_screen(_("User has chosen not to backup the PC"));
    19501950                    finish(1);
    19511951                }
     
    19601960            if (bkpinfo->media_device[0]) {
    19611961                sprintf(tmp,
    1962                         "I think I've found your %s burner at SCSI node %s; am I right on the money?",
     1962                        _("I think I've found your %s burner at SCSI node %s; am I right on the money?"),
    19631963                        media_descriptor_string(bkpinfo->
    19641964                                                backup_media_type),
     
    19701970            if (!bkpinfo->media_device[0]) {
    19711971                if (g_kernel_version < 2.6) {
    1972                     i = popup_and_get_string("Device node?",
    1973                                              "What is the SCSI node of your CD (re)writer, please?",
     1972                    i = popup_and_get_string(_("Device node?"),
     1973                                             _("What is the SCSI node of your CD (re)writer, please?"),
    19741974                                             bkpinfo->media_device,
    19751975                                             MAX_STR_LEN / 4);
    19761976                } else {
    1977                     i = popup_and_get_string("/dev entry?",
    1978                                              "What is the /dev entry of your CD (re)writer, please?",
     1977                    i = popup_and_get_string(_("/dev entry?"),
     1978                                             _("What is the /dev entry of your CD (re)writer, please?"),
    19791979                                             bkpinfo->media_device,
    19801980                                             MAX_STR_LEN / 4);
    19811981                }
    19821982                if (!i) {
    1983                     log_to_screen("User has chosen not to backup the PC");
     1983                    log_to_screen(_("User has chosen not to backup the PC"));
    19841984                    finish(1);
    19851985                }
     
    19941994    case udev:
    19951995        if (!ask_me_yes_or_no
    1996             ("This option is for advanced users only. Are you sure?")) {
    1997             log_to_screen("User has chosen not to backup the PC");
     1996            (_("This option is for advanced users only. Are you sure?"))) {
     1997            log_to_screen(_("User has chosen not to backup the PC"));
    19981998            finish(1);
    19991999        }
     
    20012001
    20022002        if (find_tape_device_and_size(bkpinfo->media_device, sz_size)) {
    2003             log_msg(3, "Ok, using vanilla scsi tape.");
     2003            log_msg(3, _("Ok, using vanilla scsi tape."));
    20042004            strcpy(bkpinfo->media_device, VANILLA_SCSI_TAPE);
    20052005            if ((fin = fopen(bkpinfo->media_device, "r"))) {
     
    20192019            }
    20202020            sprintf(tmp,
    2021                     "I think I've found your tape streamer at %s; am I right on the money?",
     2021                    _("I think I've found your tape streamer at %s; am I right on the money?"),
    20222022                    bkpinfo->media_device);
    20232023        }
    20242024        if (bkpinfo->media_device[0]) {
    20252025            sprintf(tmp,
    2026                     "I think I've found your tape streamer at %s; am I right on the money?",
     2026                    _("I think I've found your tape streamer at %s; am I right on the money?"),
    20272027                    bkpinfo->media_device);
    20282028            if (!ask_me_yes_or_no(tmp)) {
     
    20322032        if (!bkpinfo->media_device[0]) {
    20332033            if (!popup_and_get_string
    2034                 ("Device name?",
    2035                  "What is the /dev entry of your tape streamer?",
     2034                (_("Device name?"),
     2035                 _("What is the /dev entry of your tape streamer?"),
    20362036                 bkpinfo->media_device, MAX_STR_LEN / 4)) {
    2037                 log_to_screen("User has chosen not to backup the PC");
     2037                log_to_screen(_("User has chosen not to backup the PC"));
    20382038                finish(1);
    20392039            }
     
    20412041        sprintf(tmp, "ls -l %s", bkpinfo->media_device);
    20422042        if (run_program_and_log_output(tmp, FALSE)) {
    2043             log_to_screen("User has not specified a valid /dev entry");
     2043            log_to_screen(_("User has not specified a valid /dev entry"));
    20442044            finish(1);
    20452045        }
     
    20692069            if ((bkpinfo->compression_level =
    20702070                 which_compression_level()) == -1) {
    2071                 log_to_screen("User has chosen not to backup the PC");
     2071                log_to_screen(_("User has chosen not to backup the PC"));
    20722072                finish(1);
    20732073            }
     
    20902090        {
    20912091            if (!popup_and_get_string
    2092                 ("NFS dir.",
    2093                  "Please enter path and directory where archives are stored remotely. (Mondo has taken a guess at the correct value. If it is incorrect, delete it and type the correct one.)",
     2092                (_("NFS dir."),
     2093                 _("Please enter path and directory where archives are stored remotely. (Mondo has taken a guess at the correct value. If it is incorrect, delete it and type the correct one.)"),
    20942094                 bkpinfo->nfs_mount, MAX_STR_LEN / 4)) {
    2095                 log_to_screen("User has chosen not to backup the PC");
     2095                log_to_screen(_("User has chosen not to backup the PC"));
    20962096                finish(1);
    20972097            }
     
    20992099                if ((bkpinfo->compression_level =
    21002100                     which_compression_level()) == -1) {
    2101                     log_to_screen("User has chosen not to backup the PC");
     2101                    log_to_screen(_("User has chosen not to backup the PC"));
    21022102                    finish(1);
    21032103                }
     
    21142114
    21152115            sprintf(comment,
    2116                     "How much data (in Megabytes) will each media store?");
    2117             if (!popup_and_get_string("Size", comment, sz_size, 5)) {
    2118                 log_to_screen("User has chosen not to backup the PC");
     2116                    _("How much data (in Megabytes) will each media store?"));
     2117            if (!popup_and_get_string(_("Size"), comment, sz_size, 5)) {
     2118                log_to_screen(_("User has chosen not to backup the PC"));
    21192119                finish(1);
    21202120            }
     
    21232123            }
    21242124            if (bkpinfo->media_size[0] <= 0) {
    2125                 log_to_screen("User has chosen not to backup the PC");
     2125                log_to_screen(_("User has chosen not to backup the PC"));
    21262126                finish(1);
    21272127            }
     
    21302130            system("umount /tmp/isodir 2> /dev/null");
    21312131            if (!popup_and_get_string
    2132                 ("NFS share", "Which remote NFS share should I mount?",
     2132                (_("NFS share"), _("Which remote NFS share should I mount?"),
    21332133                 bkpinfo->nfs_mount, MAX_STR_LEN)) {
    2134                 log_to_screen("User has chosen not to backup the PC");
     2134                log_to_screen(_("User has chosen not to backup the PC"));
    21352135                finish(1);
    21362136            }
     
    21492149        if (!is_this_device_mounted(bkpinfo->nfs_mount)) {
    21502150            popup_and_OK
    2151                 ("Please mount that partition before you try to backup to or restore from it.");
     2151                (_("Please mount that partition before you try to backup to or restore from it."));
    21522152            finish(1);
    21532153        }
    21542154        strcpy(tmp, bkpinfo->nfs_remote_dir);
    21552155        if (!popup_and_get_string
    2156             ("Directory", "Which directory within that mountpoint?", tmp,
     2156            (_("Directory"), _("Which directory within that mountpoint?"), tmp,
    21572157             MAX_STR_LEN)) {
    2158             log_to_screen("User has chosen not to backup the PC");
     2158            log_to_screen(_("User has chosen not to backup the PC"));
    21592159            finish(1);
    21602160        }
     
    21672167            strcpy(tmp, bkpinfo->nfs_remote_dir);
    21682168            sprintf(prompt,
    2169                     "Directory '%s' under mountpoint '%s' does not exist or is not writable. You can fix this or change the directory and retry or cancel the backup.",
     2169                    _("Directory '%s' under mountpoint '%s' does not exist or is not writable. You can fix this or change the directory and retry or cancel the backup."),
    21702170                    bkpinfo->nfs_remote_dir, bkpinfo->isodir);
    21712171            if (!popup_and_get_string
    2172                 ("Directory", prompt, tmp, MAX_STR_LEN)) {
    2173                 log_to_screen("User has chosen not to backup the PC");
     2172                (_("Directory"), prompt, tmp, MAX_STR_LEN)) {
     2173                log_to_screen(_("User has chosen not to backup the PC"));
    21742174                finish(1);
    21752175            }
     
    21812181        }
    21822182        if (!popup_and_get_string
    2183             ("Prefix.",
    2184              "Please enter the prefix that will be prepended to your ISO filename.  Example: machine1 to obtain machine1-[1-9]*.iso files",
     2183            (_("Prefix."),
     2184             _("Please enter the prefix that will be prepended to your ISO filename.  Example: machine1 to obtain machine1-[1-9]*.iso files"),
    21852185            bkpinfo->prefix, MAX_STR_LEN / 4)) {
    2186             log_to_screen("User has chosen not to backup the PC");
     2186            log_to_screen(_("User has chosen not to backup the PC"));
    21872187            finish(1);
    21882188        }
     
    22002200        if (!bkpinfo->disaster_recovery) {
    22012201            if (!popup_and_get_string
    2202                 ("Storage dir.",
    2203                  "Please enter the full path that contains your ISO images.  Example: /mnt/raid0_0",
     2202                (_("Storage dir."),
     2203                 _("Please enter the full path that contains your ISO images.  Example: /mnt/raid0_0"),
    22042204                 bkpinfo->isodir, MAX_STR_LEN / 4)) {
    2205                 log_to_screen("User has chosen not to backup the PC");
     2205                log_to_screen(_("User has chosen not to backup the PC"));
    22062206                finish(1);
    22072207            }
     
    22092209                if ((bkpinfo->compression_level =
    22102210                     which_compression_level()) == -1) {
    2211                     log_to_screen("User has chosen not to backup the PC");
     2211                    log_to_screen(_("User has chosen not to backup the PC"));
    22122212                    finish(1);
    22132213                }
    22142214                if (!popup_and_get_string
    2215                     ("ISO size.",
    2216                      "Please enter how big you want each ISO image to be (in megabytes). This should be less than or equal to the size of the CD-R[W]'s or DVD's you plan to backup to.",
     2215                    (_("ISO size."),
     2216                     _("Please enter how big you want each ISO image to be (in megabytes). This should be less than or equal to the size of the CD-R[W]'s or DVD's you plan to backup to."),
    22172217                     sz_size, 16)) {
    2218                     log_to_screen("User has chosen not to backup the PC");
     2218                    log_to_screen(_("User has chosen not to backup the PC"));
    22192219                    finish(1);
    22202220                }
     
    22232223                }
    22242224                if (!popup_and_get_string
    2225                     ("Prefix.",
    2226                      "Please enter the prefix that will be prepended to your ISO filename.  Example: machine1 to obtain machine1-[1-9]*.iso files",
     2225                    (_("Prefix."),
     2226                     _("Please enter the prefix that will be prepended to your ISO filename.  Example: machine1 to obtain machine1-[1-9]*.iso files"),
    22272227                     bkpinfo->prefix, MAX_STR_LEN / 4)) {
    22282228                    log_to_screen("User has chosen not to backup the PC");
     
    22592259#ifdef __FreeBSD__
    22602260            if (!popup_and_get_string
    2261                 ("Boot device",
    2262                  "What is your boot device? (e.g. /dev/ad0)",
     2261                (_("Boot device"),
     2262                 _("What is your boot device? (e.g. /dev/ad0)"),
    22632263                 bkpinfo->boot_device, MAX_STR_LEN / 4)) {
    2264                 log_to_screen("User has chosen not to backup the PC");
     2264                log_to_screen(_("User has chosen not to backup the PC"));
    22652265                finish(1);
    22662266            }
     
    22682268#else
    22692269            if (!popup_and_get_string
    2270                 ("Boot device",
    2271                  "What is your boot device? (e.g. /dev/hda)",
     2270                (_("Boot device"),
     2271                 _("What is your boot device? (e.g. /dev/hda)"),
    22722272                 bkpinfo->boot_device, MAX_STR_LEN / 4)) {
    2273                 log_to_screen("User has chosen not to backup the PC");
     2273                log_to_screen(_("User has chosen not to backup the PC"));
    22742274                finish(1);
    22752275            }
     
    22912291            if (i == 'U') {
    22922292                if (ask_me_yes_or_no
    2293                     ("Unidentified boot loader. Shall I restore it byte-for-byte at restore time and hope for the best?"))
     2293                    (_("Unidentified boot loader. Shall I restore it byte-for-byte at restore time and hope for the best?")))
    22942294                {
    22952295                    i = 'R';    // raw
    22962296                } else {
    22972297                    log_to_screen
    2298                         ("I cannot find your boot loader. Please run mondoarchive with parameters.");
     2298                        (_("I cannot find your boot loader. Please run mondoarchive with parameters."));
    22992299                    finish(1);
    23002300                }
     
    23042304        strcpy(bkpinfo->include_paths, "/");
    23052305        if (!popup_and_get_string
    2306             ("Backup paths",
    2307              "Please enter paths which you want me to backup. The default is '/' (i.e. everything).",
     2306            (_("Backup paths"),
     2307             _("Please enter paths which you want me to backup. The default is '/' (i.e. everything)."),
    23082308             bkpinfo->include_paths, MAX_STR_LEN)) {
    2309             log_to_screen("User has chosen not to backup the PC");
     2309            log_to_screen(_("User has chosen not to backup the PC"));
    23102310            finish(1);
    23112311        }
     
    23232323        if (strlen(tmp) > 2) {
    23242324            if (!popup_and_get_string
    2325                 ("NTFS partitions",
    2326                  "Please enter/confirm the NTFS partitions you wish to backup as well.",
     2325                (_("NTFS partitions"),
     2326                 _("Please enter/confirm the NTFS partitions you wish to backup as well."),
    23272327                 tmp, MAX_STR_LEN / 4)) {
    2328                 log_to_screen("User has chosen not to backup the PC");
     2328                log_to_screen(_("User has chosen not to backup the PC"));
    23292329                finish(1);
    23302330            }
     
    23342334
    23352335        if (!popup_and_get_string
    2336             ("Exclude paths",
    2337              "Please enter paths which you do NOT want to backup. Separate them with spaces. NB: /tmp and /proc are always excluded. :-) Just hit 'Enter' if you want to do a full system backup.",
     2336            (_("Exclude paths"),
     2337             _("Please enter paths which you do NOT want to backup. Separate them with spaces. NB: /tmp and /proc are always excluded. :-) Just hit 'Enter' if you want to do a full system backup."),
    23382338             bkpinfo->exclude_paths, MAX_STR_LEN)) {
    2339             log_to_screen("User has chosen not to backup the PC");
     2339            log_to_screen(_("User has chosen not to backup the PC"));
    23402340            finish(1);
    23412341        }
     
    23442344        bkpinfo->verify_data =
    23452345            ask_me_yes_or_no
    2346             ("Will you want to verify your backups after Mondo has created them?");
     2346            (_("Will you want to verify your backups after Mondo has created them?"));
    23472347
    23482348#ifndef __FreeBSD__
    23492349        if (!ask_me_yes_or_no
    2350             ("Are you confident that your kernel is a sane, sensible, standard Linux kernel? Say 'no' if you are using a Gentoo <1.4 or Debian <3.0, please."))
     2350            (_("Are you confident that your kernel is a sane, sensible, standard Linux kernel? Say 'no' if you are using a Gentoo <1.4 or Debian <3.0, please.")))
    23512351#endif
    23522352        {
     
    23552355
    23562356        if (!ask_me_yes_or_no
    2357             ("Are you sure you want to proceed? Hit 'no' to abort.")) {
    2358             log_to_screen("User has chosen not to backup the PC");
     2357            (_("Are you sure you want to proceed? Hit 'no' to abort."))) {
     2358            log_to_screen(_("User has chosen not to backup the PC"));
    23592359            finish(1);
    23602360        }
  • branches/stable/mondo/mondo/common/libmondo-filelist.c

    r336 r497  
    203203    malloc_string(cksumlist);
    204204    malloc_string(tmp);
    205     mvaddstr_and_log_it(g_currentY, 0, "Dividing filelist into sets");
    206 
    207     log_to_screen("Dividing filelist into sets. Please wait.");
     205    mvaddstr_and_log_it(g_currentY, 0, _("Dividing filelist into sets"));
     206
     207    log_to_screen(_("Dividing filelist into sets. Please wait."));
    208208    i = 0;
    209209/*
     
    503503    if (depth == 0) {
    504504        open_evalcall_form("Freeing memory");
    505         log_to_screen("Freeing memory formerly occupied by filelist");
     505        log_to_screen(_("Freeing memory formerly occupied by filelist"));
    506506    }
    507507    depth++;
     
    941941/* add here */
    942942    if (!(newnode = (struct s_node *) malloc(sizeof(struct s_node)))) {
    943         log_to_screen("failed to malloc");
     943        log_to_screen(_("failed to malloc"));
    944944        depth--;
    945945        return (1);
     
    973973            (node->down =
    974974             (struct s_node *) malloc(sizeof(struct s_node)))) {
    975             log_to_screen("%s - failed to malloc", string_to_add);
     975            log_to_screen(_("%s - failed to malloc"), string_to_add);
    976976            return (1);
    977977        }
     
    10261026        fatal_error("filelist does not exist -- cannot load it");
    10271027    }
    1028     log_to_screen("Loading filelist");
     1028    log_to_screen(_("Loading filelist"));
    10291029    sprintf(command_to_open_fname, "gzip -dc %s", filelist_fname);
    10301030    sprintf(tmp, "zcat %s | wc -l", filelist_fname);
     
    10331033        atol(call_program_and_get_last_line_of_output(tmp));
    10341034    if (lines_in_filelist < 3) {
    1035         log_to_screen("Warning - surprisingly short filelist.");
     1035        log_to_screen(_("Warning - surprisingly short filelist."));
    10361036    }
    10371037    g_original_noof_lines_in_filelist = lines_in_filelist;
     
    10501050        return (NULL);
    10511051    }
    1052     open_evalcall_form("Loading filelist from disk");
     1052    open_evalcall_form(_("Loading filelist from disk"));
    10531053    for (fgets(fname, MAX_STR_LEN, pin); !feof(pin);
    10541054         fgets(fname, MAX_STR_LEN, pin)) {
     
    11671167    assert(outfname != NULL);   // will be zerolength if save_filelist() is called by itself
    11681168    if (depth == 0) {
    1169         log_to_screen("Saving filelist");
     1169        log_to_screen(_("Saving filelist"));
    11701170        if (!(fout = fopen(outfname, "w"))) {
    11711171            fatal_error("Cannot openout/save filelist");
    11721172        }
    11731173        lines_in_filelist = g_original_noof_lines_in_filelist;  /* set by load_filelist() */
    1174         open_evalcall_form("Saving selection to disk");
     1174        open_evalcall_form(_("Saving selection to disk"));
    11751175    }
    11761176    for (node = filelist; node != NULL; node = node->right) {
     
    14521452    if (bkpinfo->make_filelist) {
    14531453        mvaddstr_and_log_it(g_currentY, 0,
    1454                             "Making catalog of files to be backed up");
     1454                            _("Making catalog of files to be backed up"));
    14551455    } else {
    14561456        mvaddstr_and_log_it(g_currentY, 0,
    1457                             "Using supplied catalog of files to be backed up");
     1457                            _("Using supplied catalog of files to be backed up"));
    14581458    }
    14591459
     
    14761476        log_OS_error("Call to mondo-makefilelist failed");
    14771477        *p_res++;
    1478         mvaddstr_and_log_it(g_currentY++, 74, "Failed.");
     1478        mvaddstr_and_log_it(g_currentY++, 74, _("Failed."));
    14791479    } else {
    1480         mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     1480        mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    14811481    }
    14821482    return (res);
     
    15721572#ifndef _XWIN
    15731573                if (!g_text_mode) {
    1574                     sprintf(tmp, "Reading %-68s", dir);
     1574                    sprintf(tmp, _("Reading %-68s"), dir);
    15751575                    newtDrawRootText(0, g_noof_rows - 3, tmp);
    15761576                }
  • branches/stable/mondo/mondo/common/libmondo-files.c

    r415 r497  
    362362    while (!kernel[0]) {
    363363        if (!ask_me_yes_or_no
    364             ("Kernel not found or invalid. Choose another?")) {
     364            (_("Kernel not found or invalid. Choose another?"))) {
    365365            return (1);
    366366        }
    367367        if (!popup_and_get_string
    368             ("Kernel path",
    369              "What is the full path and filename of your kernel, please?",
     368            (_("Kernel path"),
     369             _("What is the full path and filename of your kernel, please?"),
    370370             kernel, MAX_STR_LEN / 4)) {
    371371            fatal_error
     
    575575
    576576    if (!does_file_exist(filename)) {
    577         sprintf(tmp, "Tring to get last line of nonexistent file (%s)",
     577        sprintf(tmp, "Trying to get last line of nonexistent file (%s)",
    578578                filename);
    579579        log_it(tmp);
     
    664664        log_OS_error("Unable to openout cksumlist");
    665665        paranoid_fclose(fin);
    666         log_to_screen("Can't open checksum list");
     666        log_to_screen(_("Can't open checksum list"));
    667667        return (1);
    668668    }
     
    689689                    time_taken * 100 / (long) (percentage) - time_taken;
    690690                sprintf(tmp,
    691                         "%02d%% done   %02d:%02d taken   %02d:%02d remaining  %-37s\r",
     691                        _("%02d%% done   %02d:%02d taken   %02d:%02d remaining  %-37s"),
    692692                        percentage, (int) (time_taken / 60),
    693693                        (int) (time_taken % 60),
     
    10291029    sprintf(command, "which %s > /dev/null 2> /dev/null", fname);
    10301030    sprintf(errorstr,
    1031             "Please install '%s'. I cannot find it on your system.",
     1031            _("Please install '%s'. I cannot find it on your system."),
    10321032            fname);
    10331033    if (system(command)) {
    10341034        log_to_screen(errorstr);
    10351035        log_to_screen
    1036             ("There may be hyperlink at http://www.mondorescue.com which");
    1037         log_to_screen("will take you to the relevant (missing) package.");
     1036            (_("There may be hyperlink at http://www.mondorescue.com which"));
     1037        log_to_screen(_("will take you to the relevant (missing) package."));
    10381038        return (1);
    10391039    } else {
     
    11501150        fatal_error("Failed to copy Mondo's stuff to scratchdir");
    11511151    }
     1152
     1153    /* i18n */
     1154    sprintf(command, CP_BIN " --parents /usr/share/locale/*/LC_MESSAGES/mondo.mo %s",bkpinfo->scratchdir);
     1155    log_msg(4, "command = %s", command);
     1156    run_program_and_log_output(command, 1);
    11521157
    11531158    sprintf(tmp, "%s/payload.tgz", g_mondo_home);
     
    13841389    if (scratchLL <= 1) {
    13851390        sprintf(tmp,
    1386                 "Your backup will probably occupy a single %s. Maybe two.",
     1391                _("Your backup will probably occupy a single %s. Maybe two."),
    13871392                media_descriptor_string(bkpinfo->backup_media_type));
    13881393    } else if (scratchLL > 4) {
    13891394        sprintf(tmp,
    1390                 "Your backup will occupy one meeeeellion media! (maybe %s)",
     1395                _("Your backup will occupy one meeeeellion media! (maybe %s)"),
    13911396                number_to_text((int) (scratchLL + 1)));
    13921397    } else {
    1393         sprintf(tmp, "Your backup will occupy approximately %s media.",
     1398        sprintf(tmp, _("Your backup will occupy approximately %s media."),
    13941399                number_to_text((int) (scratchLL + 1)));
    13951400    }
  • branches/stable/mondo/mondo/common/libmondo-fork.c

    r411 r497  
    163163
    164164
    165 #define MONDO_POPMSG  "Your PC will not retract the CD tray automatically. Please call mondoarchive with the -m (manual CD tray) flag."
     165#define MONDO_POPMSG  _("Your PC will not retract the CD tray automatically. Please call mondoarchive with the -m (manual CD tray) flag.")
    166166
    167167/**
     
    234234
    235235    log_to_screen
    236         ("Please be patient. Do not be alarmed by on-screen inactivity.");
     236        (_("Please be patient. Do not be alarmed by on-screen inactivity."));
    237237    log_msg(4, "Calling open_evalcall_form() with what_i_am_doing='%s'",
    238238            what_i_am_doing);
     
    262262        if (retval) {
    263263            log_msg(2, "Basic call '%s' returned an error.", basic_call);
    264             popup_and_OK("Press ENTER to continue.");
     264            popup_and_OK(_("Press ENTER to continue."));
    265265            popup_and_OK
    266                 ("mkisofs and/or cdrecord returned an error. CD was not created");
     266                (_("mkisofs and/or cdrecord returned an error. CD was not created"));
    267267        }
    268268    }
     
    448448    if (!(fin = popen(command, "r"))) {
    449449        log_OS_error("Unable to popen-in command");
    450         sprintf(tmp, "Failed utterly to call '%s'", command);
     450        sprintf(tmp, _("Failed utterly to call '%s'"), command);
    451451        log_to_screen(tmp);
    452452        return (1);
    453453    }
    454454    if (!does_file_exist(lockfile)) {
    455         log_to_screen("Waiting for external binary to start");
     455        log_to_screen(_("Waiting for external binary to start"));
    456456        for (i = 0; i < 60 && !does_file_exist(lockfile); sleep(1), i++) {
    457457            log_msg(3, "Waiting for lockfile %s to exist", lockfile);
     
    712712        if (pcno <= 5 && last_pcno > 40) {
    713713            close_evalcall_form();
    714             strcpy(title, "Verifying...");
     714            strcpy(title, _("Verifying..."));
    715715            open_evalcall_form(title);
    716716        }
     
    800800        if (pcno <= 5 && last_pcno >= 40) {
    801801            close_evalcall_form();
    802             strcpy(title, "Verifying...");
     802            strcpy(title, _("Verifying..."));
    803803            open_evalcall_form(title);
    804804        }
  • branches/stable/mondo/mondo/common/libmondo-mountlist.c

    r279 r497  
    951951    if (!(fin = fopen(fname, "r"))) {
    952952        log_it("Unable to open mountlist - '%s'", fname);
    953         log_to_screen("Cannot open mountlist");
     953        log_to_screen(_("Cannot open mountlist"));
    954954        paranoid_free(incoming);
    955955        paranoid_free(siz);
     
    994994            && mountlist->el[items].device[0] != '#') {
    995995            if (items >= ARBITRARY_MAXIMUM) {
    996                 log_to_screen("Too many lines in mountlist.. ABORTING");
     996                log_to_screen(_("Too many lines in mountlist.. ABORTING"));
    997997                finish(1);
    998998            }
  • branches/stable/mondo/mondo/common/libmondo-raid.c

    r273 r497  
    958958                    ("Oh my gosh. You actually think a YOTTABYTE will get you anywhere? What're you going to do with 1,208,925,819,614,629,174,706,176 bytes?!?!");
    959959                popup_and_OK
    960                     ("That sizespec is more than 1,208,925,819,614,629,174,706,176 bytes. You have a shocking amount of data. Please send a screenshot to the list :-)");
     960                    (_("That sizespec is more than 1,208,925,819,614,629,174,706,176 bytes. You have a shocking amount of data. Please send a screenshot to the list :-)"));
    961961                return size * sign * 1024 * 1024 * 1024 * 1024 * 1024 *
    962962                    1024 * 1024 * 1024;
     
    11131113        // FIXME --- the above line does not allow for spare disks
    11141114        log_to_screen
    1115             ("FIXME - create_raidtab_from_mdstat does not allow for spare disks");
     1115            (_("FIXME - create_raidtab_from_mdstat does not allow for spare disks"));
    11161116    }
    11171117    raidlist->entries = i;
  • branches/stable/mondo/mondo/common/libmondo-stream.c

    r128 r497  
    519519        //      log_it("g_current_media_number = %d", g_current_media_number);
    520520        sprintf(tmp,
    521                 "When the tape drive goes quiet, please insert volume %d in this series.",
     521                _("When the tape drive goes quiet, please insert volume %d in this series."),
    522522                tapeno);
    523523        popup_and_OK(tmp);
    524         open_evalcall_form("Waiting while the tape drive settles");
    525     } else {
    526         open_evalcall_form("Waiting while the tape drive rewinds");
     524        open_evalcall_form(_("Waiting while the tape drive settles"));
     525    } else {
     526        open_evalcall_form(_("Waiting while the tape drive rewinds"));
    527527    }
    528528
     
    731731                                bkpinfo->internal_tape_block_size))) {
    732732        log_OS_error(g_tape_fifo);
    733         log_to_screen("Cannot openin stream device");
     733        log_to_screen(_("Cannot openin stream device"));
    734734        return (1);
    735735    }
    736     log_to_screen("Reading stream");
     736    log_to_screen(_("Reading stream"));
    737737    log_it("stream device = '%s'", bkpinfo->media_device);
    738738/* skip data disks */
    739739    open_evalcall_form("Skipping data disks on stream");
    740     log_to_screen("Skipping data disks on stream");
     740    log_to_screen(_("Skipping data disks on stream"));
    741741    if (!(fout = fopen(outfname, "w"))) {
    742742        log_OS_error(outfname);
    743         log_to_screen("Cannot openout datadisk all.tar.gz file");
     743        log_to_screen(_("Cannot openout datadisk all.tar.gz file"));
    744744        return (-1);
    745745    }
    746746    if (!(datablock = (char *) malloc(256 * 1024))) {
    747         log_to_screen("Unable to malloc 256*1024");
     747        log_to_screen(_("Unable to malloc 256*1024"));
    748748        exit(1);
    749749    }
     
    822822        return (0);
    823823    } else {
    824         log_to_screen("Failed to openout to cdstream (fifo)");
     824        log_to_screen(_("Failed to openout to cdstream (fifo)"));
    825825        return (1);
    826826    }
     
    855855         open_device_via_buffer(tapedev, 'w', internal_tape_block_size))) {
    856856        log_OS_error(g_tape_fifo);
    857         log_to_screen("Cannot openin stream device");
     857        log_to_screen(_("Cannot openin stream device"));
    858858        return (1);
    859859    }
     
    998998    if (!fout) {
    999999        log_OS_error(outfname);
    1000         log_to_screen("Cannot openout file");
     1000        log_to_screen(_("Cannot openout file"));
    10011001        return (1);
    10021002    }
     
    10561056    }
    10571057    if (strcmp(temp_cksum, actual_cksum)) {
    1058         sprintf(tmp, "actual cksum=%s; recorded cksum=%s", actual_cksum,
     1058        sprintf(tmp, _("actual cksum=%s; recorded cksum=%s"), actual_cksum,
    10591059                temp_cksum);
    10601060        log_to_screen(tmp);
    1061         sprintf(tmp, "%s (%ld K) is corrupt on tape", temp_fname,
     1061        sprintf(tmp, _("%s (%ld K) is corrupt on tape"), temp_fname,
    10621062                (long) orig_size >> 10);
    10631063        log_to_screen(tmp);
     
    12111211        log_it("mediasize = %ld", mediasize);
    12121212        we_need_a_new_tape = TRUE;
    1213         log_to_screen("Should have started a new tape/CD already");
     1213        log_to_screen(_("Should have started a new tape/CD already"));
    12141214    }
    12151215    if ((g_tape_posK + length_of_incoming_file / 1024) >> 10 >=
     
    13681368                                bkpinfo->internal_tape_block_size))) {
    13691369        log_OS_error(g_tape_fifo);
    1370         log_to_screen("Cannot openin stream device");
     1370        log_to_screen(_("Cannot openin stream device"));
    13711371        return (1);
    13721372    }
     
    14061406    if (g_current_media_number > MAX_NOOF_MEDIA) {
    14071407        res++;
    1408         log_to_screen("Too many tapes. Man, you need to use nfs!");
     1408        log_to_screen(_("Too many tapes. Man, you need to use nfs!"));
    14091409    }
    14101410    if (bkpinfo->backup_media_type == cdstream) {
     
    14181418        g_tape_stream = popen(command, "w");
    14191419        if (!g_tape_stream) {
    1420             log_to_screen("Failed to openout to cdstream (fifo)");
     1420            log_to_screen(_("Failed to openout to cdstream (fifo)"));
    14211421            return (1);
    14221422        }
     
    14281428                                    bkpinfo->internal_tape_block_size))) {
    14291429            log_OS_error(g_tape_fifo);
    1430             log_to_screen("Cannot openin stream device");
     1430            log_to_screen(_("Cannot openin stream device"));
    14311431            return (1);
    14321432        }
     
    15131513    /*@ end vars *************************************************** */
    15141514
    1515     open_evalcall_form("Writing data disks to tape");
    1516     log_to_screen("Writing data disks to tape");
     1515    open_evalcall_form(_("Writing data disks to tape"));
     1516    log_to_screen(_("Writing data disks to tape"));
    15171517    log_it("Data disks = %s", fname);
    15181518    if (!does_file_exist(fname)) {
    1519         sprintf(tmp, "Cannot find %s", fname);
     1519        sprintf(tmp, _("Cannot find %s"), fname);
    15201520        log_to_screen(tmp);
    15211521        return (1);
     
    17061706    if (!g_tape_stream) {
    17071707        log_to_screen
    1708             ("You're not backing up to tape. Why write a tape header?");
     1708            (_("You're not backing up to tape. Why write a tape header?"));
    17091709        return (1);
    17101710    }
     
    17511751
    17521752    /*@ end vars *************************************************** */
    1753     sprintf(tmp, "Wrong marker! (Should be %s, ",
     1753    sprintf(tmp, _("Wrong marker! (Should be %s, "),
    17541754            marker_to_string(should_be));
    1755     sprintf(tmp + strlen(tmp), "is actually %s)", marker_to_string(it_is));
     1755    sprintf(tmp + strlen(tmp), _("is actually %s)"), marker_to_string(it_is));
    17561756    log_to_screen(tmp);
    17571757}
  • branches/stable/mondo/mondo/common/libmondo-string.c

    r128 r497  
    297297            ("Oh my gosh. You actually think a YOTTABYTE will get you anywhere? What're you going to do with 1,208,925,819,614,629,174,706,176 bytes of data?!?!");
    298298        popup_and_OK
    299             ("That sizespec is more than 1,208,925,819,614,629,174,706,176 bytes. You have a shocking amount of data. Please send a screenshot to the list :-)");
     299            (_("That sizespec is more than 1,208,925,819,614,629,174,706,176 bytes. You have a shocking amount of data. Please send a screenshot to the list :-)"));
    300300        fatal_error("Integer overflow.");
    301301    } else if (ch != 'm' && ch != 'M') {
     
    984984    sev = 3;
    985985    sprintf(reason,
    986             "Changed since backup. Consider running a differential backup in a day or two.");
     986            _("Changed since backup. Consider running a differential backup in a day or two."));
    987987    if (!strncmp(filename, "/var/", 5)) {
    988988        sev = 2;
    989989        sprintf(reason,
    990                 "/var's contents will change regularly, inevitably.");
     990                _("/var's contents will change regularly, inevitably."));
    991991    }
    992992    if (!strncmp(filename, "/home", 5)) {
    993993        sev = 2;
    994994        sprintf(reason,
    995                 "It's in your /home partiton. Therefore, it is important.");
     995                _("It's in your /home partiton. Therefore, it is important."));
    996996    }
    997997    if (!strncmp(filename, "/usr/", 5)) {
    998998        sev = 3;
    999999        sprintf(reason,
    1000                 "You may have installed/removed software during the backup.");
     1000                _("You may have installed/removed software during the backup."));
    10011001    }
    10021002    if (!strncmp(filename, "/etc/", 5)) {
    10031003        sev = 3;
    10041004        sprintf(reason,
    1005                 "Do not edit config files while backing up your PC.");
     1005                _("Do not edit config files while backing up your PC."));
    10061006    }
    10071007    if (!strcmp(filename, "/etc/adjtime")
    10081008        || !strcmp(filename, "/etc/mtab")) {
    10091009        sev = 1;
    1010         sprintf(reason, "This file changes all the time. It's OK.");
     1010        sprintf(reason, _("This file changes all the time. It's OK."));
    10111011    }
    10121012    if (!strncmp(filename, "/root/", 6)) {
    10131013        sev = 3;
    1014         sprintf(reason, "Were you compiling/editing something in /root?");
     1014        sprintf(reason, _("Were you compiling/editing something in /root?"));
    10151015    }
    10161016    if (!strncmp(filename, "/root/.", 7)) {
    10171017        sev = 2;
    1018         sprintf(reason, "Temp or 'dot' files changed in /root.");
     1018        sprintf(reason, _("Temp or 'dot' files changed in /root."));
    10191019    }
    10201020    if (!strncmp(filename, "/var/lib/", 9)) {
    10211021        sev = 2;
    1022         sprintf(reason, "Did you add/remove software during backing?");
     1022        sprintf(reason, _("Did you add/remove software during backing?"));
    10231023    }
    10241024    if (!strncmp(filename, "/var/lib/rpm", 12)) {
    10251025        sev = 3;
    1026         sprintf(reason, "Did you add/remove software during backing?");
     1026        sprintf(reason, _("Did you add/remove software during backing?"));
    10271027    }
    10281028    if (!strncmp(filename, "/var/lib/slocate", 16)) {
    10291029        sev = 1;
    10301030        sprintf(reason,
    1031                 "The 'update' daemon ran during backup. This does not affect the integrity of your backup.");
     1031                _("The 'update' daemon ran during backup. This does not affect the integrity of your backup."));
    10321032    }
    10331033    if (!strncmp(filename, "/var/log/", 9)
     
    10361036        sev = 1;
    10371037        sprintf(reason,
    1038                 "Log files change frequently as the computer runs. Fret not.");
     1038                _("Log files change frequently as the computer runs. Fret not."));
    10391039    }
    10401040    if (!strncmp(filename, "/var/spool", 10)) {
    10411041        sev = 1;
    10421042        sprintf(reason,
    1043                 "Background processes or printers were active. This does not affect the integrity of your backup.");
     1043                _("Background processes or printers were active. This does not affect the integrity of your backup."));
    10441044    }
    10451045    if (!strncmp(filename, "/var/spool/mail", 10)) {
    10461046        sev = 2;
    1047         sprintf(reason, "Mail was sent/received during backup.");
     1047        sprintf(reason, _("Mail was sent/received during backup."));
    10481048    }
    10491049    if (filename[strlen(filename) - 1] == '~') {
    10501050        sev = 1;
    10511051        sprintf(reason,
    1052                 "Backup copy of another file which was modified recently.");
     1052                _("Backup copy of another file which was modified recently."));
    10531053    }
    10541054    if (strstr(filename, "cache")) {
    10551055        sev = 1;
    10561056        sprintf(reason,
    1057                 "Part of a cache of data. Caches change from time to time. Don't worry.");
     1057                _("Part of a cache of data. Caches change from time to time. Don't worry."));
    10581058    }
    10591059    if (!strncmp(filename, "/var/run/", 9)
     
    11321132//    { fatal_error( "percentage_media_full_comment() - unknown media size"); }
    11331133    {
    1134         sprintf(outstr, "Volume %d: %s kilobytes archived so far",
     1134        sprintf(outstr, _("Volume %d: %s kilobytes archived so far"),
    11351135                g_current_media_number, pos_w_commas);
    11361136        return (outstr);
     
    11451145            percentage = 100;
    11461146        }
    1147         sprintf(outstr, "Volume %d: [", g_current_media_number);
     1147        sprintf(outstr, _("Volume %d: ["), g_current_media_number);
    11481148    } else {
    11491149        percentage =
     
    11611161    }
    11621162    j = (int) strlen(outstr);
    1163     sprintf(outstr + j, "] %d%% used", percentage);
     1163    sprintf(outstr + j, _("] %d%% used"), percentage);
    11641164    paranoid_free(pos_w_commas);
    11651165    paranoid_free(tmp);
  • branches/stable/mondo/mondo/common/libmondo-tools.c

    r424 r497  
    271271        newtSuspend();
    272272#endif
    273     printf("ASSERTION FAILED: `%s'\n", exp);
    274     printf("\tat %s:%d in %s\n\n", file, line, function);
    275     printf("(I)gnore, ignore (A)ll, (D)ebug, a(B)ort, or (E)xit? ");
     273    printf(_("ASSERTION FAILED: `%s'\n"), exp);
     274    printf(_("\tat %s:%d in %s\n\n"), file, line, function);
     275    printf(_("(I)gnore, ignore (A)ll, (D)ebug, a(B)ort, or (E)xit? "));
    276276    do {
    277277        is_valid = TRUE;
     
    300300        case '\n':
    301301            printf
    302                 ("(I)gnore, ignore (A)ll, (D)ebug, a(B)ort, or (E)xit? ");
     302                (_("(I)gnore, ignore (A)ll, (D)ebug, a(B)ort, or (E)xit? "));
    303303            break;
    304304        default:
    305305            is_valid = FALSE;
    306             printf("Invalid choice.\n");
     306            printf(_("Invalid choice.\n"));
    307307            break;
    308308        }
     
    10691069    if (atol(tmp) < 35000) {
    10701070        retval++;
    1071         log_to_screen("You must have at least 32MB of RAM to use Mondo.");
     1071        log_to_screen(_("You must have at least 32MB of RAM to use Mondo."));
    10721072    }
    10731073    if (atol(tmp) < 66000) {
    10741074        log_to_screen
    1075             ("WARNING! You have very little RAM. Please upgrade to 64MB or more.");
     1075            (_("WARNING! You have very little RAM. Please upgrade to 64MB or more."));
    10761076    }
    10771077#endif
     
    11001100        ("grep ramdisk /proc/devices", FALSE)) {
    11011101        if (!ask_me_yes_or_no
    1102             ("Your kernel has no ramdisk support. That's mind-numbingly stupid but I'll allow it if you're planning to use a failsafe kernel. Are you?"))
     1102            (_("Your kernel has no ramdisk support. That's mind-numbingly stupid but I'll allow it if you're planning to use a failsafe kernel. Are you?")))
    11031103        {
    11041104            //          retval++;
    11051105            log_to_screen
    1106                 ("It looks as if your kernel lacks ramdisk and initrd support.");
     1106                (_("It looks as if your kernel lacks ramdisk and initrd support."));
    11071107            log_to_screen
    1108                 ("I'll allow you to proceed but FYI, if I'm right, your kernel is broken.");
     1108                (_("I'll allow you to proceed but FYI, if I'm right, your kernel is broken."));
    11091109        }
    11101110    }
     
    11281128        !run_program_and_log_output
    11291129        ("mount | grep -w dos | grep -v /dev/fd | grep -v nexdisk", 0)) {
    1130         log_to_screen("I think you have a Windows 9x partition.");
     1130        log_to_screen(_("I think you have a Windows 9x partition."));
    11311131        retval += whine_if_not_found("parted");
    11321132#ifndef __IA64__
     
    11341134        // retval +=
    11351135        if (!find_home_of_exe("ms-sys")) {
    1136             log_to_screen("Please install ms-sys just in case.");
     1136            log_to_screen(_("Please install ms-sys just in case."));
    11371137        }
    11381138#endif
     
    11441144        } else {
    11451145            log_to_screen
    1146                 ("Your system lacks the 'cmp' binary. I'll create a dummy cmp for you.");
     1146                (_("Your system lacks the 'cmp' binary. I'll create a dummy cmp for you."));
    11471147            if (run_program_and_log_output
    11481148                ("cp -f `which true` /usr/bin/cmp", 0)) {
     
    11591159        if (strstr(tmp, "autofs")) {
    11601160            log_to_screen
    1161                 ("Your CD-ROM is mounted via autofs. I therefore cannot tell");
     1161                (_("Your CD-ROM is mounted via autofs. I therefore cannot tell"));
    11621162            log_to_screen
    1163                 ("if a CD actually is inserted. If a CD is inserted, please");
    1164             log_to_screen("eject it. Thank you.");
     1163                (_("if a CD actually is inserted. If a CD is inserted, please"));
     1164            log_to_screen(_("eject it. Thank you."));
    11651165            log_it
    11661166                ("Ignoring autofs CD-ROM 'mount' since we hope nothing's in it.");
     
    11881188            retval++;
    11891189            log_to_screen
    1190                 ("Please find out what happened to /etc/modules.conf");
     1190                (_("Please find out what happened to /etc/modules.conf"));
    11911191        }
    11921192    }
     
    12011201
    12021202    if (run_program_and_log_output("mindi -V", 1)) {
    1203         log_to_screen("Could not ascertain mindi's version number.");
     1203        log_to_screen(_("Could not ascertain mindi's version number."));
    12041204        log_to_screen
    1205             ("You have not installed Mondo and/or Mindi properly.");
    1206         log_to_screen("Please uninstall and reinstall them both.");
     1205            (_("You have not installed Mondo and/or Mindi properly."));
     1206        log_to_screen(_("Please uninstall and reinstall them both."));
    12071207        fatal_error("Please reinstall Mondo and Mindi.");
    12081208    }
     
    12101210        ("mindi --makemountlist /tmp/mountlist.txt.test", 5)) {
    12111211        log_to_screen
    1212             ("Mindi --makemountlist /tmp/mountlist.txt.test failed for some reason.");
     1212            (_("Mindi --makemountlist /tmp/mountlist.txt.test failed for some reason."));
    12131213        log_to_screen
    1214             ("Please run that command by hand and examine /var/log/mindi.log");
     1214            (_("Please run that command by hand and examine /var/log/mindi.log"));
    12151215        log_to_screen
    1216             ("for more information. Perhaps your /etc/fstab file is insane.");
     1216            (_("for more information. Perhaps your /etc/fstab file is insane."));
    12171217        log_to_screen
    1218             ("Perhaps Mindi's MakeMountlist() subroutine has a bug. We'll see.");
     1218            (_("Perhaps Mindi's MakeMountlist() subroutine has a bug. We'll see."));
    12191219        retval++;
    12201220    }
     
    12231223        && !does_file_exist("/etc/raidtab")) {
    12241224        log_to_screen
    1225             ("You have RAID partitions but no /etc/raidtab - creating one from /proc/mdstat");
     1225            (_("You have RAID partitions but no /etc/raidtab - creating one from /proc/mdstat"));
    12261226        create_raidtab_from_mdstat("/etc/raidtab", "/proc/mdstat");
    12271227    }
    12281228
    12291229    if (retval) {
    1230         mvaddstr_and_log_it(g_currentY++, 74, "Failed.");
     1230        mvaddstr_and_log_it(g_currentY++, 74, _("Failed."));
    12311231    } else {
    1232         mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     1232        mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    12331233    }
    12341234    return (retval);
  • branches/stable/mondo/mondo/common/libmondo-verify.c

    r484 r497  
    758758                    orig_cksum);
    759759            log_msg(2, tmp);
    760             sprintf(tmp, "%s has changed on live filesystem",
     760            sprintf(tmp, _("%s has changed on live filesystem"),
    761761                    biggie_fname);
    762762            log_to_screen(tmp);
     
    811811    sprintf(curr_acl_list_fname, ACL_BIGGLST_FNAME_RAW_SZ,
    812812            bkpinfo->tmpdir);
    813     log_to_screen("Verifying regular archives on tape");
     813    log_to_screen(_("Verifying regular archives on tape"));
    814814    total_afioballs = get_last_filelist_number(bkpinfo) + 1;
    815     open_progress_form("Verifying filesystem",
    816                        "I am verifying archives against your live filesystem now.",
    817                        "Please wait. This may take a couple of hours.", "",
     815    open_progress_form(_("Verifying filesystem"),
     816                       _("I am verifying archives against your live filesystem now."),
     817                       _("Please wait. This may take a couple of hours."), "",
    818818                       total_afioballs);
    819819    res = read_header_block_from_stream(&size, fname, &ctrl_chr);
     
    854854        res = verify_an_afioball_from_stream(bkpinfo, fname, size);
    855855        if (res) {
    856             sprintf(tmp, "Afioball %ld differs from live filesystem",
     856            sprintf(tmp, _("Afioball %ld differs from live filesystem"),
    857857                    current_afioball_number);
    858858            log_to_screen(tmp);
     
    938938    noof_biggiefiles = (long) size;
    939939    log_msg(1, "noof_biggiefiles = %ld", noof_biggiefiles);
    940     open_progress_form("Verifying big files", comment,
    941                        "Please wait. This may take some time.", "",
     940    open_progress_form(_("Verifying big files"), comment,
     941                       _("Please wait. This may take some time."), "",
    942942                       noof_biggiefiles);
    943943    for (res = read_header_block_from_stream(&size, orig_fname, &ctrl_chr);
     
    955955            p++;
    956956        }
    957         sprintf(comment, "Verifying bigfile #%ld (%ld K)",
     957        sprintf(comment, _("Verifying bigfile #%ld (%ld K)"),
    958958                current_biggiefile_number, (long) size >> 10);
    959959        update_progress_form(comment);
     
    10311031        log_msg(2, tmp);
    10321032        if (bkpinfo->manual_cd_tray) {
    1033             popup_and_OK("Please push CD tray closed.");
     1033            popup_and_OK(_("Please push CD tray closed."));
    10341034        }
    10351035        if (find_and_mount_actual_cd(bkpinfo, mountpoint)) {
    1036             log_to_screen("failed to mount actual CD");
     1036            log_to_screen(_("failed to mount actual CD"));
    10371037            return (1);
    10381038        }
     
    10441044        mddevice = make_vn(fname);
    10451045        if (ret) {
    1046             sprintf(tmp, "make_vn of %s failed; unable to verify ISO\n",
     1046            sprintf(tmp, _("make_vn of %s failed; unable to verify ISO\n"),
    10471047                    fname);
    10481048            log_to_screen(tmp);
     
    10551055#endif
    10561056        if (run_program_and_log_output(command, FALSE)) {
    1057             sprintf(tmp, "%s failed; unable to mount ISO image\n",
     1057            sprintf(tmp, _("%s failed; unable to mount ISO image\n"),
    10581058                    command);
    10591059            log_to_screen(tmp);
     
    11331133
    11341134    log_msg(3, "verify_tape_backups --- starting");
    1135     log_to_screen("Verifying backups");
     1135    log_to_screen(_("Verifying backups"));
    11361136    openin_tape(bkpinfo);
    11371137/* verify archives themselves */
     
    11581158            && length_of_file(changed_files_fname) > 2) {
    11591159            log_to_screen
    1160                 ("Warning - unable to check logfile to derive list of changed files");
     1160                (_("Warning - unable to check logfile to derive list of changed files"));
    11611161        } else {
    11621162            log_to_screen
    1163                 ("No differences found. Therefore, no 'changed.files' text file.");
     1163                (_("No differences found. Therefore, no 'changed.files' text file."));
    11641164        }
    11651165    }
     
    11771177        log_msg(0, tmp);
    11781178        log_to_screen
    1179             ("See /tmp/changed.files for a list of nonmatching files.");
     1179            (_("See /tmp/changed.files for a list of nonmatching files."));
    11801180        log_to_screen
    1181             ("The files probably changed on filesystem, not on backup media.");
     1181            (_("The files probably changed on filesystem, not on backup media."));
    11821182        //      retval++;
    11831183    }
  • branches/stable/mondo/mondo/common/my-stuff.h

    r425 r497  
    202202#include <pthread.h>
    203203#include <assert.h>
     204
     205#include "../../config.h"
    204206
    205207#if defined(DEBUG) && !__cplusplus
     
    365367 * Welcome string displayed at the top of the newt interface.
    366368 */
    367 #define WELCOME_STRING "W E L C O M E   T O   M O N D O   R E S C U E"
     369#define WELCOME_STRING _("W E L C O M E   T O   M O N D O   R E S C U E")
    368370
    369371/**
     
    526528#define DEFAULT_MR_LOGLEVEL 4
    527529
     530#ifdef ENABLE_NLS 
     531# include <libintl.h> 
     532# undef _ 
     533# define _(String) dgettext (PACKAGE, String)
     534# ifdef gettext_noop 
     535#  define N_(String) gettext_noop (String) 
     536# else 
     537#  define N_(String) (String) 
     538# endif 
     539#else 
     540# define textdomain(String) (String) 
     541# define gettext(String) (String) 
     542# define dgettext(Domain,Message) (Message) 
     543# define dcgettext(Domain,Message,Type) (Message) 
     544# define bindtextdomain(Domain,Directory) (Domain) 
     545# define _(String) (String) 
     546# define N_(String) (String) 
     547
     548#endif
     549
     550
     551
    528552#endif                          /* _MY_STUFF_H_ */
  • branches/stable/mondo/mondo/common/newt-specific.c

    r296 r497  
    227227                    tmp[i - 1] = '\0';
    228228                }
    229                 if (strstr("yesYES", tmp)) {
     229                if (strstr(_("yesYES"), tmp)) {
    230230                    paranoid_free(tmp);
    231231                    return (TRUE);
    232                 } else if (strstr("NOno", tmp)) {
     232                } else if (strstr(_("NOno"), tmp)) {
    233233                    paranoid_free(tmp);
    234234                    return (FALSE);
     
    236236                    system("sync");
    237237                    printf
    238                         ("Please enter either YES or NO (or yes or no, or y or n, or...)\n");
     238                        (_("Please enter either YES or NO (or yes or no, or y or n, or...)\n"));
    239239                }
    240240            }
    241241        } else {
    242242            paranoid_free(tmp);
    243             return (popup_with_buttons(prompt, "Yes", "No"));
     243            return (popup_with_buttons(prompt, _("Yes"), _("No")));
    244244        }
    245245    }
     
    273273                tmp[i - 1] = '\0';
    274274            }
    275             if (strstr("okOKOkYESyes", tmp)) {
     275            if (strstr(_("okOKOkYESyes"), tmp)) {
    276276                paranoid_free(tmp);
    277277                return (TRUE);
     
    282282        } else {
    283283            paranoid_free(tmp);
    284             return (popup_with_buttons(prompt, " Okay ", "Cancel"));
     284            return (popup_with_buttons(prompt, _(" Okay "), _("Cancel")));
    285285        }
    286286    }
     
    426426            ("gzip -9c /var/log/mondo-archive.log > /tmp/MA.log.gz 2> /dev/null");
    427427        printf
    428                 ("If you require technical support, please contact the mailing list.\n");
    429         printf("See http://www.mondorescue.org for details.\n");
     428                (_("If you require technical support, please contact the mailing list.\n"));
     429        printf(_("See http://www.mondorescue.org for details.\n"));
    430430        printf
    431                 ("The list's members can help you, if you attach that file to your e-mail.\n");
    432         printf("Log file: %s\n", MONDO_LOGFILE);
     431                (_("The list's members can help you, if you attach that file to your e-mail.\n"));
     432        printf(_("Log file: %s\n"), MONDO_LOGFILE);
    433433        if (does_file_exist("/tmp/MA.log.gz")) {
    434434            printf
    435                 ("FYI, I have gzipped the log and saved it to /tmp/MA.log.gz\n");
    436         }
    437         printf("Mondo has aborted.\n");
     435                (_("FYI, I have gzipped the log and saved it to /tmp/MA.log.gz\n"));
     436        }
     437        printf(_("Mondo has aborted.\n"));
    438438        register_pid(0, "mondo");   // finish() does this too, FYI
    439439        if (!g_main_pid) {
     
    490490//  system("clear");
    491491//  iamhere("Finished calling newtFinished");
    492         printf("Execution run ended; result=%d\n", signal);
    493         printf("Type 'less %s' to see the output log\n", MONDO_LOGFILE);
     492        printf(_("Execution run ended; result=%d\n"), signal);
     493        printf(_("Type 'less %s' to see the output log\n"), MONDO_LOGFILE);
    494494        free_libmondo_global_strings();
    495495        exit(signal);
     
    783783            while (((ch = getchar()) != '\n') && (ch != EOF));
    784784        } else {
    785             (void) popup_with_buttons(prompt, " OK ", "");
     785            (void) popup_with_buttons(prompt, _(" OK "), "");
    786786        }
    787787    }
     
    843843#endif
    844844            );
    845         b_1 = newtButton(6, newtTextboxGetNumLines(text) + 4, "  OK  ");
    846         b_2 = newtButton(18, newtTextboxGetNumLines(text) + 4, "Cancel");
     845        b_1 = newtButton(6, newtTextboxGetNumLines(text) + 4, _("  OK  "));
     846        b_2 = newtButton(18, newtTextboxGetNumLines(text) + 4, _("Cancel"));
    847847        //  newtOpenWindow (8, 5, 54, newtTextboxGetNumLines (text) + 9, title);
    848848        newtCenteredWindow(54, newtTextboxGetNumLines(text) + 9, title);
     
    931931        }
    932932        //  newtOpenWindow (25, 5, 46, newtTextboxGetNumLines (text) + 7, "Alert");
    933         newtCenteredWindow(46, newtTextboxGetNumLines(text) + 7, "Alert");
     933        newtCenteredWindow(46, newtTextboxGetNumLines(text) + 7, _("Alert"));
    934934        myForm = newtForm(NULL, NULL, 0);
    935935        newtFormAddComponents(myForm, text, b_1, b_2, NULL);
     
    997997            newtCls();
    998998            newtPushHelpLine
    999                 ("Welcome to Mondo Rescue, by Hugo Rabson and the Internet. All rights reversed.");
     999                (_("Welcome to Mondo Rescue, by Hugo Rabson and the Internet. All rights reversed."));
    10001000            /*  newtDrawRootText(28,0,"Welcome to Mondo Rescue"); */
    10011001            newtDrawRootText(18, 0, WELCOME_STRING);
     
    10751075            g_isoform_old_progress = percentage;
    10761076            sprintf(timeline_str,
    1077                     "%2ld:%02ld taken            %2ld:%02ld remaining",
     1077                    _("%2ld:%02ld taken            %2ld:%02ld remaining"),
    10781078                    time_taken / 60, time_taken % 60, time_remaining / 60,
    10791079                    time_remaining % 60);
    10801080            if (percentage < 3) {
    1081                 sprintf(pcline_str, " Working");
     1081                sprintf(pcline_str, _(" Working"));
    10821082                for (j = 0; j < g_mysterious_dot_counter; j++) {
    10831083                    strcat(pcline_str, ".");
     
    10891089                        special_dot_char(g_mysterious_dot_counter));
    10901090            } else {
    1091                 sprintf(pcline_str, " %3d%% done              %3d%% to go",
     1091                sprintf(pcline_str, _(" %3d%% done              %3d%% to go"),
    10921092                        percentage, 100 - percentage);
    10931093            }
     
    12351235
    12361236        if (g_text_mode) {
    1237             printf("---progress-form---1--- %s\r\n", blurb1);
    1238             printf("---progress-form---2--- %s\r\n", blurb2);
    1239             printf("---progress-form---3--- %s\r\n", blurb3);
    1240             printf("---progress-form---E---\n");
     1237            printf(_("---progress-form---1--- %s%s"), blurb1, "\r\n");
     1238            printf(_("---progress-form---2--- %s%s"), blurb2, "\r\n");
     1239            printf(_("---progress-form---3--- %s%s"), blurb3, "\r\n");
     1240            printf(_("---progress-form---E---\n"));
    12411241            sprintf(taskprogress, "TASK:  [");
    12421242            for (i = 0; i < percentage; i += 5) {
     
    12471247            }
    12481248            if (percentage > 100) {
    1249                 log_msg(2, "percentage = %d", percentage);
     1249                log_msg(2, _("percentage = %d"), percentage);
    12501250            }
    12511251            sprintf(taskprogress + strlen(taskprogress),
    12521252                    "] %3d%c", percentage, '%');
    12531253            sprintf(taskprogress + strlen(taskprogress),
    1254                     " done; %2ld:%02ld to go",
     1254                    _(" done; %2ld:%02ld to go"),
    12551255                    time_remaining / 60, time_remaining % 60);
    1256             printf("---progress-form---4--- %s\r\n", taskprogress);
     1256            printf(_("---progress-form---4--- %s"), taskprogress, "\r\n");
    12571257        } else {
    12581258            center_string(blurb1, 54);
     
    13301330        if (g_text_mode) {
    13311331            for (backup_type = none; backup_type == none;) {
    1332                 printf("Backup type (");
     1332                printf(_("Backup type ("));
    13331333                for (i = 0; possible_responses[i]; i++) {
    13341334                    printf("%c%s", (i == 0) ? '\0' : ' ',
     
    13521352        if (restoring) {
    13531353            strcpy(title_sz,
    1354                    "Please choose the backup media from which you want to read data.");
    1355             strcpy(minimsg_sz, "Read from:");
     1354                   _("Please choose the backup media from which you want to read data."));
     1355            strcpy(minimsg_sz, _("Read from:"));
    13561356        } else {
    13571357            strcpy(title_sz,
    1358                    "Please choose the backup media to which you want to archive data.");
    1359             strcpy(minimsg_sz, "Backup to:");
     1358                   _("Please choose the backup media to which you want to archive data."));
     1359            strcpy(minimsg_sz, _("Backup to:"));
    13601360        }
    13611361        newtPushHelpLine(title_sz);
    13621362        //  newtOpenWindow (23, 3, 34, 17, minimsg_sz);
    13631363        newtCenteredWindow(34, 17, minimsg_sz);
    1364         b1 = newtButton(1, 1, "CD-R disks ");
    1365         b2 = newtButton(17, 1, "CD-RW disks");
    1366         b3 = newtButton(1, 9, "Tape drive ");
    1367         b4 = newtButton(17, 5, "CD streamer");
    1368         b5 = newtButton(1, 5, " DVD disks ");
    1369         b6 = newtButton(17, 9, " NFS mount ");
    1370         b7 = newtButton(1, 13, " Hard disk ");
    1371         b8 = newtButton(17, 13, "    Exit   ");
     1364        b1 = newtButton(1, 1, _("CD-R disks "));
     1365        b2 = newtButton(17, 1, _("CD-RW disks"));
     1366        b3 = newtButton(1, 9, _("Tape drive "));
     1367        b4 = newtButton(17, 5, _("CD streamer"));
     1368        b5 = newtButton(1, 5, _(" DVD disks "));
     1369        b6 = newtButton(17, 9, _(" NFS mount "));
     1370        b7 = newtButton(1, 13, _(" Hard disk "));
     1371        b8 = newtButton(17, 13, _("    Exit   "));
    13721372        myForm = newtForm(NULL, NULL, 0);
    13731373        newtFormAddComponents(myForm, b1, b5, b3, b7, b2, b4, b6, b8,
     
    14271427        newtDrawRootText(18, 0, WELCOME_STRING);
    14281428        newtPushHelpLine
    1429             ("   Please specify the level of compression that you want.");
     1429            (_("   Please specify the level of compression that you want."));
    14301430        //  newtOpenWindow (23, 3, 34, 13, "How much compression?");
    1431         newtCenteredWindow(34, 13, "How much compression?");
    1432         b1 = newtButton(4, 1, "Maximum");
    1433         b2 = newtButton(18, 1, "Average");
    1434         b3 = newtButton(4, 5, "Minumum");
    1435         b4 = newtButton(18, 5, " None  ");
    1436         b5 = newtButton(4, 9, "         Exit        ");
     1431        newtCenteredWindow(34, 13, _("How much compression?"));
     1432        b1 = newtButton(4, 1, _("Maximum"));
     1433        b2 = newtButton(18, 1, _("Average"));
     1434        b3 = newtButton(4, 5, _("Minimum"));
     1435        b4 = newtButton(18, 5, _(" None  "));
     1436        b5 = newtButton(4, 9, _("         Exit        "));
    14371437        myForm = newtForm(NULL, NULL, 0);
    14381438        newtFormAddComponents(myForm, b1, b3, b2, b4, b5, NULL);
     
    15151515        paranoid_fclose(fin);
    15161516        if (filelist->entries >= ARBITRARY_MAXIMUM) {
    1517             log_to_screen("Arbitrary limits suck, man!");
     1517            log_to_screen(_("Arbitrary limits suck, man!"));
    15181518            paranoid_free(tmp);
    15191519            return (1);
     
    16571657        }
    16581658        sprintf(differ_sz,
    1659                 "  %d files differ. Hit 'Select' to pick a file. Hit 'Close' to quit the list.",
     1659                _("  %d files differ. Hit 'Select' to pick a file. Hit 'Close' to quit the list."),
    16601660                i);
    16611661        newtPushHelpLine(differ_sz);
    1662         bClose = newtCompactButton(10, 15, " Close  ");
    1663         bSelect = newtCompactButton(30, 15, " Select ");
    1664         sprintf(tmp, "%-10s               %-20s", "Priority", "Filename");
     1662        bClose = newtCompactButton(10, 15, _(" Close  "));
     1663        bSelect = newtCompactButton(30, 15, _(" Select "));
     1664        sprintf(tmp, "%-10s               %-20s", _("Priority"), _("Filename"));
    16651665        headerMsg = newtLabel(2, 1, tmp);
    1666         newtOpenWindow(5, 4, 70, 16, "Non-matching files");
     1666        newtOpenWindow(5, 4, 70, 16, _("Non-matching files"));
    16671667        myForm = newtForm(NULL, NULL, 0);
    16681668        newtFormAddComponents(myForm, headerMsg, fileListbox, bClose,
     
    16781678                     i++);
    16791679                if (i == filelist->entries && filelist->entries > 0) {
    1680                     log_to_screen("I don't know what that button does!");
     1680                    log_to_screen(_("I don't know what that button does!"));
    16811681                } else {
    16821682                    currline = i;
  • branches/stable/mondo/mondo/mondoarchive/main.c

    r424 r497  
    251251    char *say_at_end;
    252252
     253#ifdef ENABLE_NLS
     254    setlocale(LC_ALL, "");
     255    (void) textdomain("mondo");
     256#endif
    253257/* Make sure I'm root; abort if not */
    254258    if (getuid() != 0) {
    255         fprintf(stderr, "Please run as root.\r\n");
     259        fprintf(stderr, _("Please run as root.\n"));
    256260        exit(127);
    257261    }
     
    261265        && (!strcmp(argv[argc - 1], "-v") || !strcmp(argv[argc - 1], "-V")
    262266            || !strcmp(argv[argc - 1], "--version"))) {
    263         printf("mondoarchive v%s\nSee man page for help\n", PACKAGE_VERSION);
     267        printf(_("mondoarchive v%s\nSee man page for help\n"), PACKAGE_VERSION);
    264268        exit(0);
    265269    }
     
    275279    diffs = 0;
    276280    say_at_end[0] = '\0';
    277     printf("Initializing...\n");
     281    printf(_("Initializing...\n"));
    278282    if (!(bkpinfo = malloc(sizeof(struct s_bkpinfo)))) {
    279283        fatal_error("Cannot malloc bkpinfo");
     
    321325        setup_newt_stuff();
    322326        if (!strstr(argv[2], "filelist")) {
    323             printf("Sorry - filelist goes first\n");
     327            printf(_("Sorry - filelist goes first\n"));
    324328            finish(1);
    325329        } else {
     
    350354        setup_newt_stuff();
    351355        if (!strstr(argv[2], "filelist")) {
    352             printf("Sorry - filelist goes first\n");
     356            printf(_("Sorry - filelist goes first\n"));
    353357            finish(1);
    354358        } else {
     
    370374        setup_newt_stuff();
    371375        if (find_cdrw_device(tmp)) {
    372             printf("Failed to find CDR-RW drive\n");
    373         } else {
    374             printf("CD-RW is at %s\n", tmp);
     376            printf(_("Failed to find CDR-RW drive\n"));
     377        } else {
     378            printf(_("CD-RW is at %s\n"), tmp);
    375379        }
    376380        tmp[0] = '\0';
    377381        if (find_cdrom_device(tmp, atoi(argv[2]))) {
    378             printf("Failed to find CD-ROM drive\n");
    379         } else {
    380             printf("CD-ROM is at %s\n", tmp);
     382            printf(_("Failed to find CD-ROM drive\n"));
     383        } else {
     384            printf(_("CD-ROM is at %s\n"), tmp);
    381385        }
    382386        finish(0);
     
    388392        setup_newt_stuff();
    389393        if (find_dvd_device(tmp, atoi(argv[2]))) {
    390             printf("Failed to find DVD drive\n");
    391         } else {
    392             printf("DVD is at %s\n", tmp);
     394            printf(_("Failed to find DVD drive\n"));
     395        } else {
     396            printf(_("DVD is at %s\n"), tmp);
    393397        }
    394398        finish(0);
     
    401405    if (argc > 2 && !strcmp(argv[1], "test-dev")) {
    402406        if (is_dev_an_NTFS_dev(argv[2])) {
    403             printf("%s is indeed an NTFS dev\n", argv[2]);
    404         } else {
    405             printf("%s is _not_ an NTFS dev\n", argv[2]);
     407            printf(_("%s is indeed an NTFS dev\n"), argv[2]);
     408        } else {
     409            printf(_("%s is _not_ an NTFS dev\n"), argv[2]);
    406410        }
    407411        finish(0);
     
    426430        if (res) {
    427431            printf
    428                 ("Errors were detected in the command line you supplied.\n");
    429             printf("Please review the log file - " MONDO_LOGFILE "\n");
     432                (_("Errors were detected in the command line you supplied.\n"));
     433            printf(_("Please review the log file - %s \n"),MONDO_LOGFILE);
    430434            log_msg(1, "Mondoarchive will now exit.");
    431435            finish(1);
     
    441445
    442446    log_to_screen
    443         ("BusyBox's sources are available from http://www.busybox.net");
     447        (_("BusyBox's sources are available from http://www.busybox.net"));
    444448    sprintf(g_erase_tmpdir_and_scratchdir, "rm -Rf %s %s", bkpinfo->tmpdir,
    445449            bkpinfo->scratchdir);
     
    457461        if (res) {
    458462            strcat(say_at_end,
    459                    "Data archived. Please check the logs, just as a precaution. ");
    460         } else {
    461             strcat(say_at_end, "Data archived OK. ");
     463                   _("Data archived. Please check the logs, just as a precaution. "));
     464        } else {
     465            strcat(say_at_end, _("Data archived OK. "));
    462466        }
    463467    }
     
    467471        res = verify_data(bkpinfo);
    468472        if (res < 0) {
    469             sprintf(tmp, "%d difference%c found.", -res,
     473            sprintf(tmp, _("%d difference%c found."), -res,
    470474                    (-res != 1) ? 's' : ' ');
    471475            strcat(say_at_end, tmp);
     
    487491    if (!retval) {
    488492        mvaddstr_and_log_it(g_currentY++, 0,
    489                             "Backup and/or verify ran to completion. Everything appears to be fine.");
     493                            _("Backup and/or verify ran to completion. Everything appears to be fine."));
    490494    } else {
    491495        mvaddstr_and_log_it(g_currentY++, 0,
    492                             "Backup and/or verify ran to completion. However, errors did occur.");
     496                            _("Backup and/or verify ran to completion. However, errors did occur."));
    493497    }
    494498
    495499    if (does_file_exist("/root/images/mindi/mondorescue.iso")) {
    496500        log_to_screen
    497             ("/root/images/mindi/mondorescue.iso, a boot/utility CD, is available if you want it.");
     501            (_("/root/images/mindi/mondorescue.iso, a boot/utility CD, is available if you want it."));
    498502    }
    499503
     
    502506        if (g_text_mode) {
    503507            log_to_screen
    504                 ("Type 'less /tmp/changed.files' to see which files don't match the archives");
     508                (_("Type 'less /tmp/changed.files' to see which files don't match the archives"));
    505509        } else {
    506510            log_msg(1,
    507                     "Type 'less /tmp/changed.files' to see which files don't match the archives");
     511                    _("Type 'less /tmp/changed.files' to see which files don't match the archives"));
    508512            log_msg(2, "Calling popup_changelist_from_file()");
    509513            popup_changelist_from_file("/tmp/changed.files");
     
    523527    system("rm -Rf /tmp.mondo.* /mondo.scratch.*");
    524528    if (!retval) {
    525         printf("Mondoarchive ran OK.\n");
     529        printf(_("Mondoarchive ran OK.\n"));
    526530    } else {
    527         printf("Errors occurred during backup. Please check logfile.\n");
     531        printf(_("Errors occurred during backup. Please check logfile.\n"));
    528532    }
    529533    distro_specific_kludges_at_end_of_mondoarchive();
     
    549553    if (!g_text_mode) {
    550554        popup_and_OK
    551             ("Mondo Archive has finished its run. Please press ENTER to return to the shell prompt.");
    552         log_to_screen("See %s for details of backup run.", MONDO_LOGFILE);
     555            (_("Mondo Archive has finished its run. Please press ENTER to return to the shell prompt."));
     556        log_to_screen(_("See %s for details of backup run."), MONDO_LOGFILE);
    553557        finish(retval);
    554558    } else {
    555         printf("See %s for details of backup run.\n", MONDO_LOGFILE);
     559        printf(_("See %s for details of backup run.\n"), MONDO_LOGFILE);
    556560        exit(retval);
    557561    }
  • branches/stable/mondo/mondo/mondorestore/mondo-prep.c

    r196 r497  
    239239// zero & reboot
    240240            log_to_screen
    241                 ("I am sorry for the inconvenience but I must ask you to reboot.");
     241                (_("I am sorry for the inconvenience but I must ask you to reboot."));
    242242            log_to_screen
    243                 ("I need to reset the Master Boot Record; in order to be");
     243                (_("I need to reset the Master Boot Record; in order to be"));
    244244            log_to_screen
    245                 ("sure the kernel notices, I must reboot after doing it.");
     245                (_("sure the kernel notices, I must reboot after doing it."));
    246246            log_to_screen("Please hit 'Enter' to reboot.");
    247247            for (lino = 0; lino < drivelist->entries; lino++) {
     
    269269            system("sync");
    270270            popup_and_OK
    271                 ("I must now reboot. Please leave the boot media in the drive and repeat your actions - e.g. type 'nuke' - and it should work fine.");
     271                (_("I must now reboot. Please leave the boot media in the drive and repeat your actions - e.g. type 'nuke' - and it should work fine."));
    272272            system("reboot");
    273273        }
     
    615615#ifdef __FreeBSD__
    616616    log_to_screen
    617         ("I don't know how to extrapolate the mountlist on FreeBSD. Sorry.");
     617        (_("I don't know how to extrapolate the mountlist on FreeBSD. Sorry."));
    618618    return (1);
    619619#endif
     
    624624            if (!does_file_exist("/etc/raidtab")) {
    625625                log_to_screen
    626                     ("Cannot find /etc/raidtab - cannot extrapolate the fdisk entries");
     626                    (_("Cannot find /etc/raidtab - cannot extrapolate the fdisk entries"));
    627627                finish(1);
    628628            }
     
    749749    }
    750750    if (is_this_device_mounted(device)) {
    751         sprintf(tmp, "%s is mounted - cannot format it       ", device);
     751        sprintf(tmp, _("%s is mounted - cannot format it       "), device);
    752752        log_to_screen(tmp);
    753753        paranoid_free(program);
     
    761761            if (!does_file_exist("/tmp/raidconf.txt")) {
    762762                log_to_screen
    763                     ("/tmp/raidconf.txt does not exist. I therefore cannot start Vinum.");
     763                    (_("/tmp/raidconf.txt does not exist. I therefore cannot start Vinum."));
    764764            } else {
    765765                int res;
     
    769769                if (res) {
    770770                    log_to_screen
    771                         ("`vinum create /tmp/raidconf.txt' returned errors. Please fix them and re-run mondorestore.");
     771                        (_("`vinum create /tmp/raidconf.txt' returned errors. Please fix them and re-run mondorestore."));
    772772                    finish(1);
    773773                }
     
    780780            char line[MAX_STR_LEN];
    781781            sprintf(tmp,
    782                     "Initializing Vinum device %s (this may take a *long* time)",
     782                    _("Initializing Vinum device %s (this may take a *long* time)"),
    783783                    device);
    784784            log_to_screen(tmp);
     
    823823        }
    824824#else
    825         sprintf(tmp, "Initializing RAID device %s", device);
     825        sprintf(tmp, _("Initializing RAID device %s"), device);
    826826        log_to_screen(tmp);
    827827
    828828// Shouldn't be necessary.
    829         log_to_screen("Stopping %s", device);
     829        log_to_screen(_("Stopping %s"), device);
    830830        stop_raid_device(device);
    831831        system("sync");
     
    900900    retval += res;
    901901    if (retval) {
    902         strcat(tmp, "...failed");
     902        strcat(tmp, _("...failed"));
    903903    } else {
    904         strcat(tmp, "...OK");
     904        strcat(tmp, _("...OK"));
    905905    }
    906906
     
    951951            (interactively) ? "true" : "false");
    952952    log_it(tmp);
    953     mvaddstr_and_log_it(g_currentY, 0, "Formatting partitions     ");
    954     open_progress_form("Formatting partitions",
    955                        "I am now formatting your hard disk partitions.",
    956                        "This may take up to five minutes.", "",
     953    mvaddstr_and_log_it(g_currentY, 0, _("Formatting partitions     "));
     954    open_progress_form(_("Formatting partitions"),
     955                       _("I am now formatting your hard disk partitions."),
     956                       _("This may take up to five minutes."), "",
    957957                       mountlist->entries + 1);
    958958
     
    10011001    if (does_file_exist("/tmp/i-want-my-lvm")) {
    10021002        wait_until_software_raids_are_prepped("/proc/mdstat", 10);
    1003         log_to_screen("Configuring LVM");
     1003        log_to_screen(_("Configuring LVM"));
    10041004        if (!g_text_mode) {
    10051005            newtSuspend();
     
    10921092
    10931093    if (retval) {
    1094         mvaddstr_and_log_it(g_currentY++, 74, "Failed.");
     1094        mvaddstr_and_log_it(g_currentY++, 74, _("Failed."));
    10951095        log_to_screen
    1096             ("Errors occurred during the formatting of your hard drives.");
     1096            (_("Errors occurred during the formatting of your hard drives."));
    10971097    } else {
    1098         mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     1098        mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    10991099    }
    11001100
     
    11071107//123456789 123456789 123456789 123456789 123456789 123456789 123456789 123456789
    11081108            log_to_screen
    1109                 ("Partition table locked up %d times. At least one 'mkfs' (format) command",
     1109                (_("Partition table locked up %d times. At least one 'mkfs' (format) command"),
    11101110                 g_partition_table_locked_up);
    11111111            log_to_screen
    1112                 ("failed. I think these two events are related. Sometimes, fdisk's ioctl() call");
     1112                (_("failed. I think these two events are related. Sometimes, fdisk's ioctl() call"));
    11131113            log_to_screen
    1114                 ("to refresh its copy of the partition table causes the kernel to lock the ");
     1114                (_("to refresh its copy of the partition table causes the kernel to lock the "));
    11151115            log_to_screen
    1116                 ("partition table. I believe this has just happened.");
     1116                (_("partition table. I believe this has just happened."));
    11171117            if (ask_me_yes_or_no
    1118                 ("Please choose 'yes' to reboot and try again; or 'no' to ignore this warning and continue."))
     1118                (_("Please choose 'yes' to reboot and try again; or 'no' to ignore this warning and continue.")))
    11191119            {
    11201120                system("sync");
     
    11251125        } else {
    11261126            log_to_screen
    1127                 ("Partition table locked up %d time%c. However, disk formatting succeeded.",
     1127                (_("Partition table locked up %d time%c. However, disk formatting succeeded."),
    11281128                 g_partition_table_locked_up,
    11291129                 (g_partition_table_locked_up == 1) ? '.' : 's');
     
    15281528    pout_to_fdisk = popen(tmp, "w");
    15291529    if (!pout_to_fdisk) {
    1530         log_to_screen("Cannot call parted2fdisk to configure %s", drivename);
     1530        log_to_screen(_("Cannot call parted2fdisk to configure %s"), drivename);
    15311531        paranoid_free(device_str);
    15321532        paranoid_free(format);
     
    15641564                    if (system(command)) {
    15651565                        log_to_screen
    1566                             ("Warning! Unable to make the drive bootable.");
     1566                            (_("Warning! Unable to make the drive bootable."));
    15671567                    }
    15681568                    paranoid_free(device_str);
     
    16141614            if (!file) {
    16151615                sprintf(tmp,
    1616                         "Warning - unable to open %s for wiping it's partition table",
     1616                        _("Warning - unable to open %s for wiping it's partition table"),
    16171617                        drivename);
    16181618                log_to_screen(tmp);
     
    16211621            for (i = 0; i < 512; i++) {
    16221622                if (!write(file, "\0", 1)) {
    1623                     sprintf(tmp, "Warning - unable to write to %s",
     1623                    sprintf(tmp, _("Warning - unable to write to %s"),
    16241624                            drivename);
    16251625                    log_to_screen(tmp);
     
    16561656        if (current_devno == 5 && previous_devno == 4) {
    16571657            log_to_screen
    1658                 ("You must leave at least one partition spare as the Extended partition.");
     1658                (_("You must leave at least one partition spare as the Extended partition."));
    16591659            paranoid_free(device_str);
    16601660            paranoid_free(format);
     
    16741674            if (system(tmp)) {
    16751675                log_to_screen
    1676                     ("Warning! Unable to make the slice bootable.");
     1676                    (_("Warning! Unable to make the slice bootable."));
    16771677            }
    16781678        }
     
    17021702            g_partition_table_locked_up++;
    17031703            log_to_screen
    1704                 ("A flaw in the Linux kernel has locked the partition table.");
     1704                (_("A flaw in the Linux kernel has locked the partition table."));
    17051705        }
    17061706    }
     
    17751775
    17761776    if (is_this_device_mounted(partition_name)) {
    1777         sprintf(tmp, "%s is mounted, and should not be partitioned",
     1777        sprintf(tmp, _("%s is mounted, and should not be partitioned"),
    17781778                partition_name);
    17791779        log_to_screen(tmp);
     
    18121812                if (prev_partno >= 4) {
    18131813                    log_to_screen
    1814                         ("You need to leave at least one partition free, for 'extended/logical'");
     1814                        (_("You need to leave at least one partition free, for 'extended/logical'"));
    18151815                    paranoid_free(program);
    18161816                    paranoid_free(partition_name);
     
    20022002*/
    20032003
    2004     open_progress_form("Partitioning devices",
    2005                        "I am now going to partition all your drives.",
    2006                        "This should not take more than five minutes.", "",
     2004    open_progress_form(_("Partitioning devices"),
     2005                       _("I am now going to partition all your drives."),
     2006                       _("This should not take more than five minutes."), "",
    20072007                       mountlist->entries);
    20082008
     
    20162016    close_progress_form();
    20172017    if (retval) {
    2018         mvaddstr_and_log_it(g_currentY++, 74, "Failed.");
     2018        mvaddstr_and_log_it(g_currentY++, 74, _("Failed."));
    20192019        log_to_screen
    2020             ("Errors occurred during the partitioning of your hard drives.");
     2020            (_("Errors occurred during the partitioning of your hard drives."));
    20212021    } else {
    2022         mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     2022        mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    20232023        paranoid_system("rm -f /tmp/fdisk*.log 2> /dev/null");
    20242024    }
     
    25322532        return;
    25332533    }
    2534     sprintf(tmp, "Expanding entries to suit drive %s (%ld MB)", drive_name,
     2534    sprintf(tmp, _("Expanding entries to suit drive %s (%ld MB)"), drive_name,
    25352535            current_size_of_drive);
    25362536    log_to_screen(tmp);
     
    25512551
    25522552    if (original_size_of_drive <= 0) {
    2553         sprintf(tmp, "Cannot resize %s's entries. Drive not found.",
     2553        sprintf(tmp, _("Cannot resize %s's entries. Drive not found."),
    25542554                drive_name);
    25552555        log_to_screen(tmp);
     
    25812581            newsizL = (long) new_size;
    25822582        }
    2583         sprintf(tmp, "Changing %s from %lld KB to %ld KB",
     2583        sprintf(tmp, _("Changing %s from %lld KB to %ld KB"),
    25842584                drivemntlist->el[partno]->device,
    25852585                drivemntlist->el[partno]->size, newsizL);
     
    25882588    }
    25892589    final_size = get_phys_size_of_drive(drive_name);
    2590     sprintf(tmp, "final_size = %ld MB", final_size);
     2590    sprintf(tmp, _("final_size = %ld MB"), final_size);
    25912591    paranoid_free(tmp);
    25922592    log_to_screen(tmp);
     
    26292629                                                        device);
    26302630    }
    2631     log_to_screen("Mountlist adjusted to suit current hard drive(s)");
     2631    log_to_screen(_("Mountlist adjusted to suit current hard drive(s)"));
    26322632    paranoid_free(drivelist);
    26332633}
  • branches/stable/mondo/mondo/mondorestore/mondo-restore.c

    r478 r497  
    505505 * The message to display if we detect that the user is using a Compaq Proliant.
    506506 */
    507 #define COMPAQ_PROLIANTS_SUCK "Partition and format your disk using Compaq's disaster recovery CD. After you've done that, please reboot with your Mondo CD/floppy in Interactive Mode."
     507#define COMPAQ_PROLIANTS_SUCK _("Partition and format your disk using Compaq's disaster recovery CD. After you've done that, please reboot with your Mondo CD/floppy in Interactive Mode.")
    508508
    509509
     
    535535    if (!does_file_exist(g_mountlist_fname)) {
    536536        log_to_screen(g_mountlist_fname);
    537         log_to_screen("does not exist");
     537        log_to_screen(_("does not exist"));
    538538        return (1);
    539539    }
     
    543543    if (retval) {
    544544        log_to_screen
    545             ("Warning - load_raidtab_into_raidlist returned an error");
     545            (_("Warning - load_raidtab_into_raidlist returned an error"));
    546546    }
    547547    res = edit_mountlist(g_mountlist_fname, mountlist, raidlist);
     
    553553    save_raidlist_to_raidtab(raidlist, RAIDTAB_FNAME);
    554554
    555     log_to_screen("I have finished editing the mountlist for you.");
     555    log_to_screen(_("I have finished editing the mountlist for you."));
    556556
    557557    return (retval);
     
    602602    popup_and_OK(COMPAQ_PROLIANTS_SUCK);
    603603    if (ask_me_yes_or_no
    604         ("Would you like to reboot and use your Compaq CD to prep your hard drive?"))
     604        (_("Would you like to reboot and use your Compaq CD to prep your hard drive?")))
    605605    {
    606606        fatal_error
    607             ("Aborting. Please reboot and prep your hard drive with your Compaq CD.");
     607            (_("Aborting. Please reboot and prep your hard drive with your Compaq CD."));
    608608    }
    609609}
     
    642642        interactively_obtain_media_parameters_from_user(bkpinfo, FALSE);
    643643    } else {
    644         popup_and_OK("No restoring or comparing will take place today.");
     644        popup_and_OK(_("No restoring or comparing will take place today."));
    645645        if (is_this_device_mounted("/mnt/cdrom")) {
    646646            run_program_and_log_output("umount /mnt/cdrom", FALSE);
     
    774774    if (g_text_mode) {
    775775        if (!ask_me_yes_or_no
    776             ("Interactive Mode + textonly = experimental! Proceed anyway?"))
     776            (_("Interactive Mode + textonly = experimental! Proceed anyway?")))
    777777        {
    778778            fatal_error("Wise move.");
     
    815815        save_mountlist_to_disk(mountlist, g_mountlist_fname);
    816816        save_raidlist_to_raidtab(raidlist, RAIDTAB_FNAME);
    817         mvaddstr_and_log_it(1, 30, "Restoring Interactively");
     817        mvaddstr_and_log_it(1, 30, _("Restoring Interactively"));
    818818        if (bkpinfo->differential) {
    819             log_to_screen("Because this is a differential backup, disk");
     819            log_to_screen(_("Because this is a differential backup, disk"));
    820820            log_to_screen
    821                 (" partitioning and formatting will not take place.");
     821                (_(" partitioning and formatting will not take place."));
    822822            done = TRUE;
    823823        } else {
    824824            if (ask_me_yes_or_no
    825                 ("Do you want to erase and partition your hard drives?")) {
     825                (_("Do you want to erase and partition your hard drives?"))) {
    826826                if (partition_table_contains_Compaq_diagnostic_partition
    827827                    (mountlist)) {
     
    834834                    if (ptn_errs) {
    835835                        log_to_screen
    836                             ("Warning. Errors occurred during disk partitioning.");
     836                            (_("Warning. Errors occurred during disk partitioning."));
    837837                    }
    838838
     
    840840                    if (!fmt_errs) {
    841841                        log_to_screen
    842                             ("Errors during disk partitioning were handled OK.");
     842                            (_("Errors during disk partitioning were handled OK."));
    843843                        log_to_screen
    844                             ("Partitions were formatted OK despite those errors.");
     844                            (_("Partitions were formatted OK despite those errors."));
    845845                        ptn_errs = 0;
    846846                    }
     
    852852            } else {
    853853                mvaddstr_and_log_it(g_currentY++, 0,
    854                                     "User opted not to partition the devices");
     854                                    _("User opted not to partition the devices"));
    855855                if (ask_me_yes_or_no
    856                     ("Do you want to format your hard drives?")) {
     856                    (_("Do you want to format your hard drives?"))) {
    857857                    fmt_errs = format_everything(mountlist, TRUE);
    858858                    if (!fmt_errs) {
     
    867867                mvaddstr_and_log_it(g_currentY++,
    868868                                    0,
    869                                     "Errors occurred. Please repartition and format drives manually.");
     869                                    _("Errors occurred. Please repartition and format drives manually."));
    870870                done = FALSE;
    871871            }
     
    873873                mvaddstr_and_log_it(g_currentY++,
    874874                                    0,
    875                                     "Errors occurred during partitioning. Formatting, however, went OK.");
     875                                    _("Errors occurred during partitioning. Formatting, however, went OK."));
    876876                done = TRUE;
    877877            }
    878878            if (!done) {
    879                 if (!ask_me_yes_or_no("Re-edit the mountlist?")) {
     879                if (!ask_me_yes_or_no(_("Re-edit the mountlist?"))) {
    880880                    retval++;
    881881                    goto end_of_func;
     
    893893    /* restore */
    894894    if ((restore_all =
    895          ask_me_yes_or_no("Do you want me to restore all of your data?")))
     895         ask_me_yes_or_no(_("Do you want me to restore all of your data?"))))
    896896    {
    897897        log_msg(1, "Restoring all data");
     
    900900        if ((restore_all =
    901901             ask_me_yes_or_no
    902              ("Do you want me to restore _some_ of your data?"))) {
     902             (_("Do you want me to restore _some_ of your data?")))) {
    903903        strcpy(old_restpath, bkpinfo->restore_path);
    904904        for (done = FALSE; !done;) {
     
    913913// (NB: %s is where your filesystem is mounted now, by default)", MNT_RESTORING);
    914914                if (popup_and_get_string
    915                     ("Restore path", "Restore files to where?", tmp,
     915                    (_("Restore path"), _("Restore files to where?"), tmp,
    916916                     MAX_STR_LEN / 4)) {
    917917                    if (!strcmp(tmp, "/")) {
    918                         if (!ask_me_yes_or_no("Are you sure?")) {
     918                        if (!ask_me_yes_or_no(_("Are you sure?"))) {
    919919                            goto gotos_suck;
    920920                        }
     
    930930                }
    931931                if (!ask_me_yes_or_no
    932                     ("Restore another subset of your backup?")) {
     932                    (_("Restore another subset of your backup?"))) {
    933933                    done = TRUE;
    934934                }
     
    941941        mvaddstr_and_log_it(g_currentY++,
    942942                            0,
    943                             "User opted not to restore any data.                                  ");
     943                            _("User opted not to restore any data.                                  "));
    944944    }
    945945    if (retval) {
    946946        mvaddstr_and_log_it(g_currentY++,
    947947                            0,
    948                             "Errors occurred during the restore phase.            ");
    949     }
    950 
    951     if (ask_me_yes_or_no("Initialize the boot loader?")) {
     948                            _("Errors occurred during the restore phase.            "));
     949    }
     950
     951    if (ask_me_yes_or_no(_("Initialize the boot loader?"))) {
    952952        run_boot_loader(TRUE);
    953953    } else {
    954954        mvaddstr_and_log_it(g_currentY++,
    955955                            0,
    956                             "User opted not to initialize the boot loader.");
     956                            _("User opted not to initialize the boot loader."));
    957957    }
    958958
     
    963963    /*  if (restore_some || restore_all || */
    964964    if (ask_me_yes_or_no
    965         ("Label your ext2 and ext3 partitions if necessary?")) {
     965        (_("Label your ext2 and ext3 partitions if necessary?"))) {
    966966        mvaddstr_and_log_it(g_currentY, 0,
    967                             "Using e2label to label your ext2,3 partitions");
     967                            _("Using e2label to label your ext2,3 partitions"));
    968968        if (does_file_exist("/tmp/fstab.new")) {
    969969            strcpy(fstab_fname, "/tmp/fstab.new");
     
    978978        if (res) {
    979979            log_to_screen
    980                 ("label-partitions-as-necessary returned an error");
    981             mvaddstr_and_log_it(g_currentY++, 74, "Failed.");
     980                (_("label-partitions-as-necessary returned an error"));
     981            mvaddstr_and_log_it(g_currentY++, 74, _("Failed."));
    982982        } else {
    983983            mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     
    990990        mvaddstr_and_log_it(g_currentY++,
    991991                            0,
    992                             "Warning - errors occurred during the restore phase.");
     992                            _("Warning - errors occurred during the restore phase."));
    993993    }
    994994  end_of_func:
     
    10421042            retval += compare_mode(bkpinfo, mountlist, raidlist);
    10431043        } else {
    1044             log_to_screen("OK, I shan't restore/compare any files.");
     1044            log_to_screen(_("OK, I shan't restore/compare any files."));
    10451045        }
    10461046    }
     
    10521052    if (system("umount /tmp/isodir 2> /dev/null")) {
    10531053        log_to_screen
    1054             ("WARNING - unable to unmount device where the ISO files are stored.");
     1054            (_("WARNING - unable to unmount device where the ISO files are stored."));
    10551055    }
    10561056//    }
     
    11131113    if (!evaluate_mountlist(mountlist, tmpA, tmpB, tmpC)) {
    11141114        sprintf(tmp,
    1115                 "Mountlist analyzed. Result: \"%s %s %s\" Switch to Interactive Mode?",
     1115                _("Mountlist analyzed. Result: \"%s %s %s\" Switch to Interactive Mode?"),
    11161116                tmpA, tmpB, tmpC);
    11171117        if (ask_me_yes_or_no(tmp)) {
     
    11231123    }
    11241124    save_mountlist_to_disk(mountlist, g_mountlist_fname);
    1125     mvaddstr_and_log_it(1, 30, "Restoring Automatically");
     1125    mvaddstr_and_log_it(1, 30, _("Restoring Automatically"));
    11261126    if (bkpinfo->differential) {
    1127         log_to_screen("Because this is a differential backup, disk");
    1128         log_to_screen("partitioning and formatting will not take place.");
     1127        log_to_screen(_("Because this is a differential backup, disk"));
     1128        log_to_screen(_("partitioning and formatting will not take place."));
    11291129        res = 0;
    11301130    } else {
     
    11521152                if (res) {
    11531153                    log_to_screen
    1154                         ("Warning. Errors occurred during partitioning.");
     1154                        (_("Warning. Errors occurred during partitioning."));
    11551155                    res = 0;
    11561156                }
     
    11581158            retval += res;
    11591159            if (!res) {
    1160                 log_to_screen("Preparing to format your disk(s)");
     1160                log_to_screen(_("Preparing to format your disk(s)"));
    11611161                sleep(1);
    11621162                system("sync");
    1163                 log_to_screen("Please wait. This may take a few minutes.");
     1163                log_to_screen(_("Please wait. This may take a few minutes."));
    11641164                res += format_everything(mountlist, FALSE);
    11651165            }
     
    11711171        mvaddstr_and_log_it(g_currentY++,
    11721172                            0,
    1173                             "Failed to partition and/or format your hard drives.");
    1174 
    1175         if (ask_me_yes_or_no("Try in interactive mode instead?")) {
     1173                            _("Failed to partition and/or format your hard drives."));
     1174
     1175        if (ask_me_yes_or_no(_("Try in interactive mode instead?"))) {
    11761176            retval = interactive_mode(bkpinfo, mountlist, raidlist);
    11771177            goto after_the_nuke;
    11781178        } else
    11791179            if (!ask_me_yes_or_no
    1180                 ("Would you like to try to proceed anyway?")) {
     1180                (_("Would you like to try to proceed anyway?"))) {
    11811181            return (retval);
    11821182        }
     
    11861186        unmount_all_devices(mountlist);
    11871187        log_to_screen
    1188             ("Unable to mount all partitions. Sorry, I cannot proceed.");
     1188            (_("Unable to mount all partitions. Sorry, I cannot proceed."));
    11891189        return (retval);
    11901190    }
     
    12021202    mvaddstr_and_log_it(g_currentY,
    12031203                        0,
    1204                         "Using e2label to label your ext2,3 partitions");
     1204                        _("Using e2label to label your ext2,3 partitions"));
    12051205
    12061206    sprintf(tmp, "label-partitions-as-necessary %s < /tmp/fstab",
     
    12081208    res = run_program_and_log_output(tmp, TRUE);
    12091209    if (res) {
    1210         log_to_screen("label-partitions-as-necessary returned an error");
    1211         mvaddstr_and_log_it(g_currentY++, 74, "Failed.");
     1210        log_to_screen(_("label-partitions-as-necessary returned an error"));
     1211        mvaddstr_and_log_it(g_currentY++, 74, _("Failed."));
    12121212    } else {
    1213         mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     1213        mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    12141214    }
    12151215    retval += res;
     
    12171217  after_the_nuke:
    12181218    if (retval) {
    1219         log_to_screen("Errors occurred during the nuke phase.");
     1219        log_to_screen(_("Errors occurred during the nuke phase."));
    12201220    } else if (strstr(call_program_and_get_last_line_of_output("cat /proc/cmdline"), "RESTORE"))    // Bruno's thing
    12211221    {
    12221222        log_to_screen
    1223             ("PC was restored successfully. Thank you for using Mondo Rescue.");
     1223            (_("PC was restored successfully. Thank you for using Mondo Rescue."));
    12241224        log_to_screen
    1225             ("Please visit our website at http://www.mondorescue.org for more information.");
     1225            (_("Please visit our website at http://www.mondorescue.org for more information."));
    12261226    } else {
    1227         strcpy(tmp," Mondo has restored your system. Please remove the backup media and reboot.\n\nPlease visit our website at http://www.mondorescue.org for more information.");
     1227        strcpy(tmp,_(" Mondo has restored your system. Please remove the backup media and reboot.\n\nPlease visit our website at http://www.mondorescue.org for more information."));
    12281228        if (strstr(call_program_and_get_last_line_of_output("cat /proc/cmdline"), "restore") == NULL) {
    12291229            popup_and_OK(tmp);
    12301230        }
    12311231        log_to_screen
    1232             ("Mondo has restored your system. Please remove the backup media and reboot.");
     1232            (_("Mondo has restored your system. Please remove the backup media and reboot."));
    12331233        log_to_screen
    1234             ("Please visit our website at http://www.mondorescue.org for more information.");
     1234            (_("Please visit our website at http://www.mondorescue.org for more information."));
    12351235    }
    12361236    g_I_have_just_nuked = TRUE;
     
    12811281    if (!g_restoring_live_from_cd) {
    12821282        popup_and_OK
    1283             ("Please insert tape/CD/boot floppy, then hit 'OK' to continue.");
     1283            (_("Please insert tape/CD/boot floppy, then hit 'OK' to continue."));
    12841284        sleep(1);
    12851285    }
     
    12931293    log_msg(2, "bkpinfo->isodir = %s", bkpinfo->isodir);
    12941294
    1295     open_evalcall_form("Thinking...");
     1295    open_evalcall_form(_("Thinking..."));
    12961296
    12971297    get_cfg_file_from_archive_or_bust(bkpinfo);
     
    13061306        save_filelist(filelist, "/tmp/selected-files.txt");
    13071307        strcpy(old_restpath, bkpinfo->restore_path);
    1308         if (popup_and_get_string("Restore path",
    1309                                  "Restore files to where? )",
     1308        if (popup_and_get_string(_("Restore path"),
     1309                                 _("Restore files to where? )"),
    13101310                                 bkpinfo->restore_path, MAX_STR_LEN / 4)) {
    13111311            iamhere("Restoring everything");
     
    14031403
    14041404    if (!(fin = fopen(slice_fname(bigfileno, 0, ARCHIVES_PATH, ""), "r"))) {
    1405         log_to_screen("Cannot even open bigfile's info file");
     1405        log_to_screen(_("Cannot even open bigfile's info file"));
    14061406        return (1);
    14071407    }
     
    15161516    log_msg(3, "file_to_openout = %s", file_to_openout);
    15171517    if (!(fout = fopen(file_to_openout, "w"))) {
    1518         log_to_screen("Cannot openout outfile_fname - hard disk full?");
     1518        log_to_screen(_("Cannot openout outfile_fname - hard disk full?"));
    15191519        return (1);
    15201520    }
     
    15391539                    g_current_media_number, sliceno);
    15401540            log_msg(2, tmp);
    1541             sprintf(tmp, "Restoring from %s #%d",
     1541            sprintf(tmp, _("Restoring from %s #%d"),
    15421542                    media_descriptor_string(bkpinfo->backup_media_type),
    15431543                    g_current_media_number);
    15441544            log_to_screen(tmp);
    15451545            insist_on_this_cd_number(bkpinfo, g_current_media_number);
    1546             log_to_screen("Continuing to restore.");
     1546            log_to_screen(_("Continuing to restore."));
    15471547        } else {
    15481548            strcpy(tmp,
     
    15731573                    strcpy(suffix, "");
    15741574                } else {
    1575                     log_to_screen("OK, that's pretty fsck0red...");
     1575                    log_to_screen(_("OK, that's pretty fsck0red..."));
    15761576                    return (1);
    15771577                }
     
    20312031            if (run_program_and_log_output(tmp, FALSE)) {
    20322032                log_to_screen
    2033                     ("(compare_a_tarball) Compression program not found - oh no!");
     2033                    (_("(compare_a_tarball) Compression program not found - oh no!"));
    20342034                paranoid_MR_finish(1);
    20352035            }
     
    20892089            if (res) {
    20902090                log_to_screen
    2091                     ("Errors occurred while setting extended attributes");
     2091                    (_("Errors occurred while setting extended attributes"));
    20922092            } else {
    20932093                log_msg(1, "I set xattr OK");
     
    21002100            if (res) {
    21012101                log_to_screen
    2102                     ("Errors occurred while setting access control lists");
     2102                    (_("Errors occurred while setting access control lists"));
    21032103            } else {
    21042104                log_msg(1, "I set ACL OK");
     
    21172117    if (does_file_exist("/PAUSE")) {
    21182118        popup_and_OK
    2119             ("Press ENTER to go on. Delete /PAUSE to stop these pauses.");
     2119            (_("Press ENTER to go on. Delete /PAUSE to stop these pauses."));
    21202120    }
    21212121    unlink(filelist_subset_fname);
     
    23142314
    23152315    if (does_file_exist("/PAUSE") && current_tarball_number >= 50) {
    2316         log_to_screen("Paused after set %ld", current_tarball_number);
    2317         popup_and_OK("Pausing. Press ENTER to continue.");
     2316        log_to_screen(_("Paused after set %ld"), current_tarball_number);
     2317        popup_and_OK(_("Pausing. Press ENTER to continue."));
    23182318    }
    23192319
     
    23782378    read_cfg_var(g_mondo_cfg_file, "total-slices", tmp);
    23792379    total_slices = atol(tmp);
    2380     sprintf(tmp, "Reassembling large files      ");
     2380    sprintf(tmp, _("Reassembling large files      "));
    23812381    mvaddstr_and_log_it(g_currentY, 0, tmp);
    23822382    if (length_of_file(BIGGIELIST) < 6) {
     
    23942394    log_msg(2, tmp);
    23952395
    2396     open_progress_form("Reassembling large files",
    2397                        "I am now reassembling all the large files.",
    2398                        "Please wait. This may take some time.",
     2396    open_progress_form(_("Reassembling large files"),
     2397                       _("I am now reassembling all the large files."),
     2398                       _("Please wait. This may take some time."),
    23992399                       "", total_slices);
    24002400    for (bigfileno = 0, finished = FALSE; !finished;) {
     
    24172417                insist_on_this_cd_number(bkpinfo,
    24182418                                         ++g_current_media_number);
    2419                 sprintf(tmp, "Restoring from %s #%d",
     2419                sprintf(tmp, _("Restoring from %s #%d"),
    24202420                        media_descriptor_string(bkpinfo->
    24212421                                                backup_media_type),
     
    24312431        } else {
    24322432            just_changed_cds = FALSE;
    2433             sprintf(tmp, "Restoring big file %ld", bigfileno + 1);
     2433            sprintf(tmp, _("Restoring big file %ld"), bigfileno + 1);
    24342434            update_progress_form(tmp);
    24352435            res =
     
    24602460    if (does_file_exist("/PAUSE")) {
    24612461        popup_and_OK
    2462             ("Press ENTER to go on. Delete /PAUSE to stop these pauses.");
     2462            (_("Press ENTER to go on. Delete /PAUSE to stop these pauses."));
    24632463    }
    24642464    close_progress_form();
    24652465    if (retval) {
    2466         mvaddstr_and_log_it(g_currentY++, 74, "Errors.");
     2466        mvaddstr_and_log_it(g_currentY++, 74, _("Errors."));
    24672467    } else {
    2468         mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     2468        mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    24692469    }
    24702470    paranoid_free(xattr_fname);
     
    25142514    assert(bkpinfo != NULL);
    25152515
    2516     mvaddstr_and_log_it(g_currentY, 0, "Restoring from archives");
     2516    mvaddstr_and_log_it(g_currentY, 0, _("Restoring from archives"));
    25172517    log_msg(2,
    25182518            "Insisting on 1st CD, so that I can have a look at LAST-FILELIST-NUMBER");
     
    25242524    read_cfg_var(g_mondo_cfg_file, "last-filelist-number", tmp);
    25252525    max_val = atol(tmp) + 1;
    2526     sprintf(progress_str, "Restoring from %s #%d",
     2526    sprintf(progress_str, _("Restoring from %s #%d"),
    25272527            media_descriptor_string(bkpinfo->backup_media_type),
    25282528            g_current_media_number);
    25292529    log_to_screen(progress_str);
    2530     open_progress_form("Restoring from archives",
    2531                        "Restoring data from the archives.",
    2532                        "Please wait. This may take some time.",
     2530    open_progress_form(_("Restoring from archives"),
     2531                       _("Restoring data from the archives."),
     2532                       _("Please wait. This may take some time."),
    25332533                       progress_str, max_val);
    25342534    for (;;) {
     
    25562556            if (current_tarball_number == 0) {
    25572557                log_to_screen
    2558                     ("No tarballs. Strange. Maybe you only backed up freakin' big files?");
     2558                    (_("No tarballs. Strange. Maybe you only backed up freakin' big files?"));
    25592559                return (0);
    25602560            }
     
    25662566            }
    25672567            g_current_media_number++;
    2568             sprintf(progress_str, "Restoring from %s #%d",
     2568            sprintf(progress_str, _("Restoring from %s #%d"),
    25692569                    media_descriptor_string(bkpinfo->backup_media_type),
    25702570                    g_current_media_number);
    25712571            log_to_screen(progress_str);
    25722572        } else {
    2573             sprintf(progress_str, "Restoring from fileset #%ld on %s #%d",
     2573            sprintf(progress_str, _("Restoring from fileset #%ld on %s #%d"),
    25742574                    current_tarball_number,
    25752575                    media_descriptor_string(bkpinfo->backup_media_type),
     
    25832583                                              filelist);
    25842584            }
    2585             sprintf(tmp, "%s #%d, fileset #%ld - restore ",
     2585            sprintf(tmp, _("%s #%d, fileset #%ld - restore "),
    25862586                    media_descriptor_string(bkpinfo->backup_media_type),
    25872587                    g_current_media_number, current_tarball_number);
    25882588            if (res) {
    2589                 strcat(tmp, "reported errors");
     2589                strcat(tmp, _("reported errors"));
    25902590            } else if (attempts > 1) {
    2591                 strcat(tmp, "succeeded");
     2591                strcat(tmp, _("succeeded"));
    25922592            } else {
    2593                 strcat(tmp, "succeeded");
     2593                strcat(tmp, _("succeeded"));
    25942594            }
    25952595            if (attempts > 1) {
    2596                 sprintf(tmp + strlen(tmp), " (%d attempts) - review logs",
     2596                sprintf(tmp + strlen(tmp), _(" (%d attempts) - review logs"),
    25972597                        attempts);
    25982598            }
     
    26092609    close_progress_form();
    26102610    if (retval) {
    2611         mvaddstr_and_log_it(g_currentY++, 74, "Errors.");
     2611        mvaddstr_and_log_it(g_currentY++, 74, _("Errors."));
    26122612    } else {
    2613         mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     2613        mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    26142614    }
    26152615    paranoid_free(tmp);
     
    26942694            noof_biggiefiles);
    26952695    log_msg(2, tmp);
    2696     open_progress_form("Reassembling large files",
    2697                        "I am now reassembling all the large files.",
    2698                        "Please wait. This may take some time.",
     2696    open_progress_form(_("Reassembling large files"),
     2697                       _("I am now reassembling all the large files."),
     2698                       _("Please wait. This may take some time."),
    26992699                       "", total_slices);
    27002700
     
    27162716            p++;
    27172717        }
    2718         sprintf(tmp, "Restoring big file %ld (%lld K)",
     2718        sprintf(tmp, _("Restoring big file %ld (%lld K)"),
    27192719                current_bigfile_number + 1, biggie_size / 1024);
    27202720        update_progress_form(tmp);
     
    27672767    if (does_file_exist("/PAUSE")) {
    27682768        popup_and_OK
    2769             ("Press ENTER to go on. Delete /PAUSE to stop these pauses.");
     2769            (_("Press ENTER to go on. Delete /PAUSE to stop these pauses."));
    27702770    }
    27712771
    27722772    close_progress_form();
    27732773    if (retval) {
    2774         mvaddstr_and_log_it(g_currentY++, 74, "Errors.");
     2774        mvaddstr_and_log_it(g_currentY++, 74, _("Errors."));
    27752775    } else {
    2776         mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     2776        mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    27772777    }
    27782778    paranoid_free(biggies_whose_EXATs_we_should_set);
     
    28302830    malloc_string(xattr_fname);
    28312831    malloc_string(acl_fname);
    2832     mvaddstr_and_log_it(g_currentY, 0, "Restoring from archives");
     2832    mvaddstr_and_log_it(g_currentY, 0, _("Restoring from archives"));
    28332833    read_cfg_var(g_mondo_cfg_file, "last-filelist-number", tmp);
    28342834    max_val = atol(tmp) + 1;
     
    28382838    run_program_and_log_output("pwd", 5);
    28392839
    2840     sprintf(progress_str, "Restoring from media #%d",
     2840    sprintf(progress_str, _("Restoring from media #%d"),
    28412841            g_current_media_number);
    28422842    log_to_screen(progress_str);
    2843     open_progress_form("Restoring from archives",
    2844                        "Restoring data from the archives.",
    2845                        "Please wait. This may take some time.",
     2843    open_progress_form(_("Restoring from archives"),
     2844                       _("Restoring data from the archives."),
     2845                       _("Please wait. This may take some time."),
    28462846                       progress_str, max_val);
    28472847
     
    28772877        }
    28782878        sprintf(tmp,
    2879                 "Restoring from fileset #%ld (name=%s, size=%ld K)",
     2879                _("Restoring from fileset #%ld (name=%s, size=%ld K)"),
    28802880                current_afioball_number, tmp_fname, (long) tmp_size >> 10);
    28812881        res =
     
    28862886        retval += res;
    28872887        if (res) {
    2888             sprintf(tmp, "Fileset %ld - errors occurred",
     2888            sprintf(tmp, _("Fileset %ld - errors occurred"),
    28892889                    current_afioball_number);
    28902890            log_to_screen(tmp);
     
    28982898        current_afioball_number++;
    28992899        g_current_progress++;
    2900         sprintf(progress_str, "Restoring from fileset #%ld on %s #%d",
     2900        sprintf(progress_str, _("Restoring from fileset #%ld on %s #%d"),
    29012901                current_afioball_number,
    29022902                media_descriptor_string(bkpinfo->backup_media_type),
     
    29102910    close_progress_form();
    29112911    if (retval) {
    2912         mvaddstr_and_log_it(g_currentY++, 74, "Errors.");
     2912        mvaddstr_and_log_it(g_currentY++, 74, _("Errors."));
    29132913    } else {
    2914         mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     2914        mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    29152915    }
    29162916    paranoid_free(tmp);
     
    29632963    if (!find_home_of_exe("petris") && !g_text_mode) {
    29642964        newtDrawRootText(0, g_noof_rows - 2,
    2965                          "Press ALT-<left cursor> twice to play Petris :-) ");
     2965                         _("Press ALT-<left cursor> twice to play Petris :-) "));
    29662966        newtRefresh();
    29672967    }
    2968     mvaddstr_and_log_it(g_currentY, 0, "Preparing to read your archives");
     2968    mvaddstr_and_log_it(g_currentY, 0, _("Preparing to read your archives"));
    29692969    if (IS_THIS_A_STREAMING_BACKUP(bkpinfo->backup_media_type)) {
    29702970        mount_cdrom(bkpinfo);
    29712971        mvaddstr_and_log_it(g_currentY++, 0,
    2972                             "Restoring OS and data from streaming media");
     2972                            _("Restoring OS and data from streaming media"));
    29732973        if (bkpinfo->backup_media_type == cdstream) {
    29742974            openin_cdstream(bkpinfo);
     
    29872987    } else {
    29882988        mvaddstr_and_log_it(g_currentY++, 0,
    2989                             "Restoring OS and data from CD       ");
     2989                            _("Restoring OS and data from CD       "));
    29902990        mount_cdrom(bkpinfo);
    29912991        resA = restore_all_tarballs_from_CD(bkpinfo, filelist);
     
    29942994    chdir(cwd);
    29952995    if (resA + resB) {
    2996         log_to_screen("Errors occurred while data was being restored.");
     2996        log_to_screen(_("Errors occurred while data was being restored."));
    29972997    }
    29982998    if (length_of_file("/etc/raidtab") > 0) {
     
    31053105        retval++;
    31063106        log_to_screen
    3107             ("Error(s) occurred while processing filelist and wildcard");
     3107            (_("Error(s) occurred while processing filelist and wildcard"));
    31083108    }
    31093109    iamhere("FIXME");
     
    32003200   *                                                                        *
    32013201   **************************************************************************/
     3202
     3203#ifdef ENABLE_NLS
     3204    setlocale(LC_ALL, "");
     3205    (void) textdomain("mondo");
     3206#endif
     3207
    32023208    if (getuid() != 0) {
    3203         fprintf(stderr, "Please run as root.\r\n");
     3209        fprintf(stderr, _("Please run as root.\n"));
    32043210        exit(127);
    32053211    }
     
    33453351        strcpy(bkpinfo->restore_path, "/tmp/TESTING");
    33463352        bkpinfo->backup_media_type = dvd;
    3347         open_progress_form("Reassembling /dev/hda1",
    3348                            "Shark is a bit of a silly person.",
    3349                            "Please wait. This may take some time.",
     3353        open_progress_form(_("Reassembling /dev/hda1"),
     3354                           _("Shark is a bit of a silly person."),
     3355                           _("Please wait. This may take some time."),
    33503356                           "", 1999);
    33513357        system("rm -Rf /tmp/*pih*");
     
    34233429        retval = run_grub(FALSE, "/dev/hda");
    34243430        if (retval) {
    3425             log_to_screen("Failed to write Master Boot Record");
     3431            log_to_screen(_("Failed to write Master Boot Record"));
    34263432        }
    34273433        paranoid_MR_finish(0);
     
    34343440        if (argc != 1) {
    34353441            popup_and_OK
    3436                 ("Live mode doesn't support command-line parameters yet.");
     3442                (_("Live mode doesn't support command-line parameters yet."));
    34373443            paranoid_MR_finish(1);
    34383444//    return(1);
     
    34663472        log_msg(2, "FYI, MOUNTLIST_FNAME = %s ", g_mountlist_fname);
    34673473        if (argc == 3 && strcmp(argv[1], "--monitas-memorex") == 0) {
    3468             log_to_screen("Uh, that hasn't been implemented yet.");
     3474            log_to_screen(_("Uh, that hasn't been implemented yet."));
    34693475            paranoid_MR_finish(1);
    34703476        }
     
    34953501        if (retval) {
    34963502            log_to_screen
    3497                 ("Warning - load_raidtab_into_raidlist returned an error");
     3503                (_("Warning - load_raidtab_into_raidlist returned an error"));
    34983504        }
    34993505
     
    35493555            }
    35503556            if (retval) {
    3551                 log_to_screen("Failed to write Master Boot Record");
     3557                log_to_screen(_("Failed to write Master Boot Record"));
    35523558            }
    35533559        } else if (argc == 2 && strcmp(argv[1], "--isonuke") == 0) {
     
    35553561            retval = iso_mode(bkpinfo, mountlist, raidlist, TRUE);
    35563562        } else if (argc != 1) {
    3557             log_to_screen("Invalid paremeters");
     3563            log_to_screen(_("Invalid paremeters"));
    35583564            paranoid_MR_finish(1);
    35593565        } else {
     
    35673573        if (does_file_exist("/tmp/changed.files")) {
    35683574            log_to_screen
    3569                 ("See /tmp/changed.files for list of files that have changed.");
     3575                (_("See /tmp/changed.files for list of files that have changed."));
    35703576        }
    35713577        mvaddstr_and_log_it(g_currentY++,
    35723578                            0,
    3573                             "Run complete. Errors were reported. Please review the logfile.");
     3579                            _("Run complete. Errors were reported. Please review the logfile."));
    35743580    } else {
    35753581        if (IS_THIS_A_STREAMING_BACKUP(bkpinfo->backup_media_type)) {
    35763582            mvaddstr_and_log_it(g_currentY++,
    35773583                                0,
    3578                                 "Run complete. Please remove floppy/CD/media and reboot.");
     3584                                _("Run complete. Please remove floppy/CD/media and reboot."));
    35793585        } else {
    35803586            run_program_and_log_output("sync", FALSE);
     
    35973603            mvaddstr_and_log_it(g_currentY++,
    35983604                                0,
    3599                                 "Run complete. Please remove media and reboot.");
     3605                                _("Run complete. Please remove media and reboot."));
    36003606        }
    36013607    }
     
    36073613            if (mount_all_devices(mountlist, TRUE)) {
    36083614                log_to_screen
    3609                     ("Unable to re-mount partitions for post-nuke stuff");
     3615                    (_("Unable to re-mount partitions for post-nuke stuff"));
    36103616            } else {
    36113617                log_msg(1, "Re-mounted partitions for post-nuke stuff");
     
    36403646    run_program_and_log_output(tmp, FALSE);
    36413647    log_to_screen
    3642         ("Restore log copied to /tmp/mondo-restore.log on your hard disk");
     3648        (_("Restore log copied to /tmp/mondo-restore.log on your hard disk"));
    36433649    sprintf(tmp,
    3644             "Mondo-restore is exiting (retval=%d)                                      ",
     3650            _("Mondo-restore is exiting (retval=%d)                                      "),
    36453651            retval);
    36463652    log_to_screen(tmp);
  • branches/stable/mondo/mondo/mondorestore/mondo-rstr-newt.c

    r273 r497  
    156156
    157157    newtPushHelpLine
    158         ("   Add one of the following unallocated RAID partitions to this RAID device.");
    159     sprintf(tmp, "%-26s %s", "Device", "Size");
     158        (_("   Add one of the following unallocated RAID partitions to this RAID device."));
     159    sprintf(tmp, "%-26s %s", _("Device"), _("Size"));
    160160    headerMsg = newtLabel(1, 1, tmp);
    161161    partitionsListbox =
     
    164164                             partitionsListbox);
    165165    i = 7;
    166     bOK = newtCompactButton(i, 9, "  OK  ");
    167     bCancel = newtCompactButton(i += 9, 9, "Cancel");
    168     newtOpenWindow(22, 6, 36, 10, "Unallocated RAID partitions");
     166    bOK = newtCompactButton(i, 9, _("  OK  "));
     167    bCancel = newtCompactButton(i += 9, 9, _("Cancel"));
     168    newtOpenWindow(22, 6, 36, 10, _("Unallocated RAID partitions"));
    169169    myForm = newtForm(NULL, NULL, 0);
    170170    newtFormAddComponents(myForm, headerMsg, partitionsListbox, bOK,
     
    258258    size_str[0] = '\0';
    259259    /* sprintf(size_str,""); */
    260     newtOpenWindow(20, 5, 48, 10, "Add entry");
    261     label0 = newtLabel(2, 1, "Device:    ");
    262     label1 = newtLabel(2, 2, "Mountpoint:");
    263     label2 = newtLabel(2, 3, "Size (MB): ");
    264     label3 = newtLabel(2, 4, "Format:    ");
     260    newtOpenWindow(20, 5, 48, 10, _("Add entry"));
     261    label0 = newtLabel(2, 1, _("Device:    "));
     262    label1 = newtLabel(2, 2, _("Mountpoint:"));
     263    label2 = newtLabel(2, 3, _("Size (MB): "));
     264    label3 = newtLabel(2, 4, _("Format:    "));
    265265    deviceComp =
    266266        newtEntry(14, 1, device_str, 30, (void *) &device_here, 0);
     
    270270        newtEntry(14, 4, format_str, 15, (void *) &format_here, 0);
    271271    sizeComp = newtEntry(14, 3, size_str, 10, (void *) &size_here, 0);
    272     bOK = newtButton(5, 6, "  OK  ");
    273     bCancel = newtButton(17, 6, "Cancel");
     272    bOK = newtButton(5, 6, _("  OK  "));
     273    bCancel = newtButton(17, 6, _("Cancel"));
    274274    newtPushHelpLine
    275         ("To add an entry to the mountlist, please fill in these fields and then hit 'OK'");
     275        (_("To add an entry to the mountlist, please fill in these fields and then hit 'OK'"));
    276276    myForm = newtForm(NULL, NULL, 0);
    277277    newtFormAddComponents(myForm, deviceComp, mountpointComp, sizeComp,
     
    292292        if (b_res == bOK) {
    293293            if (device_str[strlen(device_str) - 1] == '/') {
    294                 popup_and_OK("You left the device nearly blank!");
     294                popup_and_OK(_("You left the device nearly blank!"));
    295295                b_res = NULL;
    296296            }
    297297            if (size_of_specific_device_in_mountlist(mountlist, device_str)
    298298                >= 0) {
    299                 popup_and_OK("Can't add this - you've got one already!");
     299                popup_and_OK(_("Can't add this - you've got one already!"));
    300300                b_res = NULL;
    301301            }
     
    346346    sz_out[0] = '\0';
    347347    if (popup_and_get_string
    348         ("Add variable", "Enter the name of the variable to add", sz_out,
     348        ("Add variable", _("Enter the name of the variable to add"), sz_out,
    349349         MAX_STR_LEN)) {
    350350        strip_spaces(sz_out);
     
    355355        if (i < items) {
    356356            popup_and_OK
    357                 ("No need to add that variable. It is already listed here.");
     357                (_("No need to add that variable. It is already listed here."));
    358358        } else {
    359359            strcpy(raidrec->additional_vars.el[items].label, sz_out);
     
    555555
    556556    sprintf(prompt,
    557             "Please enter the RAID level you want. (concat, striped, raid5)");
     557            _("Please enter the RAID level you want. (concat, striped, raid5)"));
    558558    if (raidrec->raidlevel == -1) {
    559559        strcpy(tmp, "concat");
     
    608608    strcpy(personalities,
    609609           last_line_of_file("/tmp/raid-personalities.txt"));
    610     sprintf(prompt, "Please enter the RAID level you want. %s",
     610    sprintf(prompt, _("Please enter the RAID level you want. %s"),
    611611            personalities);
    612612    if (raidrec->raid_level == -1) {
     
    618618         out != -1 && out != 0 && out != 1 && out != 4 && out != 5
    619619         && out != 10;) {
    620         res = popup_and_get_string("Specify RAID level", prompt, tmp, 10);
     620        res = popup_and_get_string(_("Specify RAID level"), prompt, tmp, 10);
    621621        if (!res) {
    622622            return;
     
    641641        } else {
    642642            if (ask_me_yes_or_no
    643                 ("You have chosen a RAID personality which is not registered with the kernel. Make another selection?"))
     643                (_("You have chosen a RAID personality which is not registered with the kernel. Make another selection?")))
    644644            {
    645645                out = 999;
     
    720720    assert_string_is_neither_NULL_nor_zerolength(raid_device);
    721721
    722     sprintf(tmp, "Delete %s from RAID device %s - are you sure?",
     722    sprintf(tmp, _("Delete %s from RAID device %s - are you sure?"),
    723723            disklist->el[currline].device, raid_device);
    724724    if (!ask_me_yes_or_no(tmp)) {
     
    768768                                                  device);
    769769    if (pos >= 0) {
    770         sprintf(tmp, "Cannot delete %s: it is in use by RAID device %s",
     770        sprintf(tmp, _("Cannot delete %s: it is in use by RAID device %s"),
    771771                mountlist->el[currline].device,
    772772                raidlist->el[pos].OSSWAP(raid_device, volname));
     
    774774        return;
    775775    }
    776     sprintf(tmp, "Delete %s - are you sure?",
     776    sprintf(tmp, _("Delete %s - are you sure?"),
    777777            mountlist->el[currline].device);
    778778    if (!ask_me_yes_or_no(tmp)) {
     
    829829        return;
    830830    }
    831     sprintf(tmp, "Do you want me to delete %s's partitions, too?", device);
     831    sprintf(tmp, _("Do you want me to delete %s's partitions, too?"), device);
    832832    delete_partitions_too = ask_me_yes_or_no(tmp);
    833833    if (delete_partitions_too) {
     
    896896
    897897    av = &raidrec->additional_vars;
    898     sprintf(tmp, "Delete %s - are you sure?", av->el[lino].label);
     898    sprintf(tmp, _("Delete %s - are you sure?"), av->el[lino].label);
    899899    if (ask_me_yes_or_no(tmp)) {
    900900        if (!strcmp(av->el[lino].label, "persistent-superblock")
    901901            || !strcmp(av->el[lino].label, "chunk-size")) {
    902             sprintf(tmp, "%s must not be deleted. It would be bad.",
     902            sprintf(tmp, _("%s must not be deleted. It would be bad."),
    903903                    av->el[lino].label);
    904904            popup_and_OK(tmp);
     
    967967                    warned_already = TRUE;
    968968                    sprintf(tmp,
    969                             "Too many lines. Displaying first %d entries only. Close a directory to see more.",
     969                            _("Too many lines. Displaying first %d entries only. Close a directory to see more."),
    970970                            ARBITRARY_MAXIMUM);
    971971                    popup_and_OK(tmp);
     
    11051105    assert(filelist != NULL);
    11061106
    1107     log_to_screen("Editing filelist");
     1107    log_to_screen(_("Editing filelist"));
    11081108    newtPushHelpLine
    1109         ("   Please edit the filelist to your satisfaction, then click OK or Cancel.");
     1109        (_("   Please edit the filelist to your satisfaction, then click OK or Cancel."));
    11101110    j = 4;
    1111     bLess = newtCompactButton(j, 17, " Less ");
    1112     bMore = newtCompactButton(j += 12, 17, " More ");
    1113     bToggle = newtCompactButton(j += 12, 17, "Toggle");
    1114     bRegex = newtCompactButton(j += 12, 17, "RegEx");
    1115     bCancel = newtCompactButton(j += 12, 17, "Cancel");
    1116     bOK = newtCompactButton(j += 12, 17, "  OK  ");
     1111    bLess = newtCompactButton(j, 17, _(" Less "));
     1112    bMore = newtCompactButton(j += 12, 17, _(" More "));
     1113    bToggle = newtCompactButton(j += 12, 17, _("Toggle"));
     1114    bRegex = newtCompactButton(j += 12, 17, _("RegEx"));
     1115    bCancel = newtCompactButton(j += 12, 17, _("Cancel"));
     1116    bOK = newtCompactButton(j += 12, 17, _("  OK  "));
    11171117    filelistListbox =
    11181118        newtListbox(2, 1, 15, NEWT_FLAG_SCROLL | NEWT_FLAG_RETURNEXIT);
     
    11201120    lines_in_flist_window =
    11211121        redraw_filelist(filelist, keylist, filelistListbox);
    1122     newtOpenWindow(1, 3, 77, 18, "Editing filelist");
     1122    newtOpenWindow(1, 3, 77, 18, _("Editing filelist"));
    11231123    myForm = newtForm(NULL, NULL, 0);
    11241124    newtFormAddComponents(myForm, filelistListbox, bLess, bMore, bToggle,
     
    11291129            finished =
    11301130                ask_me_yes_or_no
    1131                 ("Are you happy with your file selection?");
     1131                (_("Are you happy with your file selection?"));
    11321132        } else if (b_res == bCancel) {
    11331133            finished = TRUE;
    11341134        } else if (b_res == bRegex) {
    1135             popup_and_OK("I haven't implemented this yet...");
     1135            popup_and_OK(_("I haven't implemented this yet..."));
    11361136        } else {
    11371137            curr_choice = newtListboxGetCurrent(filelistListbox);
     
    12691269    sprintf(size_str, "%lld", mountlist->el[currline].size / 1024);
    12701270    newtOpenWindow(20, 5, 48, 10, "Edit entry");
    1271     label0 = newtLabel(2, 1, "Device:");
    1272     label1 = newtLabel(2, 2, "Mountpoint:");
    1273     label2 = newtLabel(2, 3, "Size (MB): ");
    1274     label3 = newtLabel(2, 4, "Format:    ");
     1271    label0 = newtLabel(2, 1, _("Device:"));
     1272    label1 = newtLabel(2, 2, _("Mountpoint:"));
     1273    label2 = newtLabel(2, 3, _("Size (MB): "));
     1274    label3 = newtLabel(2, 4, _("Format:    "));
    12751275    deviceComp =
    12761276        newtEntry(14, 1, device_str, 30, (void *) &device_here, 0);
     
    12851285        sizeComp = newtEntry(14, 3, size_str, 10, (void *) &size_here, 0);
    12861286    }
    1287     bOK = newtButton(2, 6, "  OK  ");
    1288     bCancel = newtButton(14, 6, "Cancel");
     1287    bOK = newtButton(2, 6, _("  OK  "));
     1288    bCancel = newtButton(14, 6, _("Cancel"));
    12891289    if (strstr(mountlist->el[currline].device, RAID_DEVICE_STUB)) {
    12901290        b_raid = newtButton(26, 6, "RAID..");
    12911291    }
    12921292    newtPushHelpLine
    1293         ("       Edit this partition's mountpoint, size and format; then click 'OK'.");
     1293        (_("       Edit this partition's mountpoint, size and format; then click 'OK'."));
    12941294    myForm = newtForm(NULL, NULL, 0);
    12951295    newtFormAddComponents(myForm, deviceComp, mountpointComp, sizeComp,
     
    13071307            && strstr(device_used_to_be, RAID_DEVICE_STUB)
    13081308            && strcmp(device_str, device_used_to_be)) {
    1309             popup_and_OK("You can't change /dev/mdX to /dev/mdY.");
     1309            popup_and_OK(_("You can't change /dev/mdX to /dev/mdY."));
    13101310            b_res = NULL;
    13111311            continue;
    13121312        } else if (b_res == bOK && !strcmp(mountpoint_str, "image")
    13131313                   && strcmp(mountpt_used_to_be, "image")) {
    1314             popup_and_OK("You can't change a regular device to an image.");
     1314            popup_and_OK(_("You can't change a regular device to an image."));
    13151315            b_res = NULL;
    13161316            continue;
     
    13351335                 */
    13361336                popup_and_OK
    1337                     ("You cannot edit the RAID settings until you have OK'd your change to the device node.");
     1337                    (_("You cannot edit the RAID settings until you have OK'd your change to the device node."));
    13381338            } else {
    13391339                j = find_raid_device_in_raidlist(raidlist,
     
    13421342                if (j < 0) {
    13431343                    sprintf(tmp,
    1344                             "/etc/raidtab does not have an entry for %s; please delete it and add it again",
     1344                            _("/etc/raidtab does not have an entry for %s; please delete it and add it again"),
    13451345                            mountlist->el[currline].device);
    13461346                    popup_and_OK(tmp);
    13471347                } else {
    1348                     log_it("edit_raidlist_entry - calling");
     1348                    log_it(_("edit_raidlist_entry - calling"));
    13491349                    edit_raidlist_entry(mountlist, raidlist,
    13501350                                        &raidlist->el[j], currline);
     
    13961396    else if (strcmp(device_used_to_be, device_str)) {
    13971397        popup_and_OK
    1398             ("You are renaming a RAID device as another RAID device. I don't like it but I'll allow it.");
     1398            (_("You are renaming a RAID device as another RAID device. I don't like it but I'll allow it."));
    13991399    }
    14001400#endif
     
    15061506    int currline2 = 0;
    15071507
    1508     log_it("Started edit_raidlist_entry");
     1508    log_it(_("Started edit_raidlist_entry"));
    15091509    memcpy((void *) &bkp_raidrec, (void *) raidrec,
    15101510           sizeof(struct vinum_volume));
    1511     sprintf(title_of_editraidForm_window, "Plexes on %s",
     1511    sprintf(title_of_editraidForm_window, _("Plexes on %s"),
    15121512            raidrec->volname);
    1513     newtPushHelpLine("   Please select a plex to edit");
     1513    newtPushHelpLine(_("   Please select a plex to edit"));
    15141514    newtOpenWindow(13, 5, 54, 15, title_of_editraidForm_window);
    15151515    for (;;) {
     
    15171517        char headerstr[MAX_STR_LEN];
    15181518        snprintf(headerstr, MAX_STR_LEN, "%-14s %-8s  %11s  %8s",
    1519                  "Plex", "Level", "Stripe Size", "Subdisks");
    1520 
    1521         bOK = newtCompactButton(2, 13, "  OK  ");
    1522         bCancel = newtCompactButton(12, 13, "Cancel");
    1523         bAdd = newtCompactButton(22, 13, " Add ");
    1524         bEdit = newtCompactButton(32, 13, " Edit ");
    1525         bDelete = newtCompactButton(42, 13, "Delete");
     1519                 _("Plex"), _("Level",) _("Stripe Size"), _("Subdisks"));
     1520
     1521        bOK = newtCompactButton(2, 13, _("  OK  "));
     1522        bCancel = newtCompactButton(12, 13, _("Cancel"));
     1523        bAdd = newtCompactButton(22, 13, _(" Add "));
     1524        bEdit = newtCompactButton(32, 13, _(" Edit "));
     1525        bDelete = newtCompactButton(42, 13, _("Delete"));
    15261526
    15271527        plexesListbox =
     
    15831583        if (b_res == bDelete) {
    15841584            char msg[MAX_STR_LEN];
    1585             sprintf(msg, "Are you sure you want to delete %s.p%i?",
     1585            sprintf(msg, _("Are you sure you want to delete %s.p%i?"),
    15861586                    raidrec->volname, currline2);
    15871587            if (ask_me_yes_or_no(msg)) {
    1588                 log_it("Deleting RAID plex");
     1588                log_it(_("Deleting RAID plex"));
    15891589                memcpy((void *) &raidrec->plex[currline2],
    15901590                       (void *) &raidrec->plex[raidrec->plexes - 1],
     
    16601660    for (;;) {
    16611661        log_msg(2, "Main loop");
    1662         sprintf(title_of_editraidForm_window, "Edit %s",
     1662        sprintf(title_of_editraidForm_window, _("Edit %s"),
    16631663                raidrec->raid_device);
    16641664        strcpy(sz_raid_level,
     
    16661666        strcpy(sz_data_disks,
    16671667               number_of_disks_as_string(raidrec->data_disks.entries,
    1668                                          "data"));
     1668                                         _("data")));
    16691669        strcpy(sz_spare_disks,
    16701670               number_of_disks_as_string(raidrec->spare_disks.entries,
    1671                                          "spare"));
     1671                                         _("spare")));
    16721672        strcpy(sz_parity_disks,
    16731673               number_of_disks_as_string(raidrec->parity_disks.entries,
    1674                                          "parity"));
     1674                                         _("parity")));
    16751675        strcpy(sz_failed_disks,
    16761676               number_of_disks_as_string(raidrec->failed_disks.entries,
    1677                                          "failed"));
     1677                                         _("failed")));
    16781678        bSelectData = newtButton(1, 1, sz_data_disks);
    16791679        bSelectSpare = newtButton(20, 1, sz_spare_disks);
     
    16811681        bSelectFailed = newtButton(20, 5, sz_failed_disks);
    16821682        bChangeRaid = newtButton(1, 9, sz_raid_level);
    1683         bOK = newtButton(16 + (raidrec->raid_level == -1), 9, "  OK  ");
    1684         bCancel = newtButton(28, 9, "Cancel");
     1683        bOK = newtButton(16 + (raidrec->raid_level == -1), 9, _("  OK  "));
     1684        bCancel = newtButton(28, 9, _("Cancel"));
    16851685        bAdditional =
    16861686            newtCompactButton(1, 13,
    1687                               "Additional settings and information");
     1687                              _("Additional settings and information"));
    16881688        newtPushHelpLine
    1689             ("  Edit the RAID device's settings to your heart's content, then hit OK/Cancel.");
     1689            (_("  Edit the RAID device's settings to your heart's content, then hit OK/Cancel."));
    16901690        editraidForm = newtForm(NULL, NULL, 0);
    16911691        newtFormAddComponents(editraidForm, bSelectData, bSelectParity,
     
    16961696            choose_raid_level(raidrec);
    16971697        } else if (b_res == bSelectData) {
    1698             select_raid_disks(mountlist, raidlist, raidrec, "data",
     1698            select_raid_disks(mountlist, raidlist, raidrec, _("data"),
    16991699                              &raidrec->data_disks);
    17001700        } else if (b_res == bSelectSpare) {
    1701             select_raid_disks(mountlist, raidlist, raidrec, "spare",
     1701            select_raid_disks(mountlist, raidlist, raidrec, _("spare"),
    17021702                              &raidrec->spare_disks);
    17031703        } else if (b_res == bSelectParity) {
    1704             select_raid_disks(mountlist, raidlist, raidrec, "parity",
     1704            select_raid_disks(mountlist, raidlist, raidrec, _("parity"),
    17051705                              &raidrec->parity_disks);
    17061706        } else if (b_res == bSelectFailed) {
    1707             select_raid_disks(mountlist, raidlist, raidrec, "failed",
     1707            select_raid_disks(mountlist, raidlist, raidrec, _("failed"),
    17081708                              &raidrec->failed_disks);
    17091709        } else if (b_res == bAdditional) {
     
    17861786            raidlist->el[currline].volname, currline2);
    17871787    newtPushHelpLine
    1788         ("   Please select a subdisk to edit, or edit this plex's parameters");
     1788        (_("   Please select a subdisk to edit, or edit this plex's parameters"));
    17891789    newtOpenWindow(13, 3, 54, 18, title_of_editraidForm_window);
    17901790    for (;;) {
     
    17921792        char headerstr[MAX_STR_LEN];
    17931793        char tmp[64];
    1794         snprintf(headerstr, MAX_STR_LEN, "%-24s %s", "Subdisk", "Device");
     1794        snprintf(headerstr, MAX_STR_LEN, "%-24s %s", _("Subdisk"), _("Device"));
    17951795
    17961796
     
    18061806            break;
    18071807        default:
    1808             sprintf(tmp, "unknown (%i)", raidrec->raidlevel);
     1808            sprintf(tmp, _("unknown (%i)"), raidrec->raidlevel);
    18091809            break;
    18101810        }
    1811         bLevel = newtCompactButton(2, 2, " RAID level ");
     1811        bLevel = newtCompactButton(2, 2, _(" RAID level "));
    18121812        sLevel = newtLabel(19, 2, tmp);
    18131813
    18141814        if (raidrec->raidlevel >= 0) {
    18151815            sprintf(tmp, "%ik", raidrec->stripesize);
    1816             bStripeSize = newtCompactButton(2, 4, " Stripe size ");
     1816            bStripeSize = newtCompactButton(2, 4, _(" Stripe size "));
    18171817        } else {
    18181818            strcpy(tmp, "N/A");
    1819             bStripeSize = newtLabel(2, 4, "Stripe size:");
     1819            bStripeSize = newtLabel(2, 4, _("Stripe size:"));
    18201820        }
    18211821        sStripeSize = newtLabel(19, 4, tmp);
    18221822
    1823         bOK = newtCompactButton(2, 16, "  OK  ");
    1824         bCancel = newtCompactButton(12, 16, "Cancel");
    1825         bAdd = newtCompactButton(22, 16, " Add ");
    1826         bEdit = newtCompactButton(32, 16, " Edit ");
    1827         bDelete = newtCompactButton(42, 16, "Delete");
     1823        bOK = newtCompactButton(2, 16, _("  OK  "));
     1824        bCancel = newtCompactButton(12, 16, _("Cancel"));
     1825        bAdd = newtCompactButton(22, 16, _(" Add "));
     1826        bEdit = newtCompactButton(32, 16, _(" Edit "));
     1827        bDelete = newtCompactButton(42, 16, _("Delete"));
    18281828
    18291829
     
    19111911            sprintf(tmp, "%i", raidrec->stripesize);
    19121912            if (popup_and_get_string
    1913                 ("Stripe size",
    1914                  "Please enter the stripe size in kilobytes.", tmp, 20)) {
     1913                (_("Stripe size"),
     1914                 _("Please enter the stripe size in kilobytes."), tmp, 20)) {
    19151915                raidrec->stripesize = atoi(tmp);
    19161916            }
     
    19631963
    19641964    strcpy(sz_out, raidrec->additional_vars.el[lino].value);
    1965     sprintf(header, "Edit %s", raidrec->additional_vars.el[lino].label);
    1966     sprintf(comment, "Please set %s's value (currently '%s')",
     1965    sprintf(header, _("Edit %s"), raidrec->additional_vars.el[lino].label);
     1966    sprintf(comment, _("Please set %s's value (currently '%s')"),
    19671967            raidrec->additional_vars.el[lino].label, sz_out);
    19681968    if (popup_and_get_string(header, comment, sz_out, MAX_STR_LEN)) {
     
    20262026    strcpy(flaws_str_C, "xxxxxxxxx");
    20272027    if (mountlist->entries > ARBITRARY_MAXIMUM) {
    2028         log_to_screen("Arbitrary limits suck, man!");
     2028        log_to_screen(_("Arbitrary limits suck, man!"));
    20292029        finish(1);
    20302030    }
    20312031    newtPushHelpLine
    2032         ("   Please edit the mountlist to your satisfaction, then click OK or Cancel.");
     2032        (_("   Please edit the mountlist to your satisfaction, then click OK or Cancel."));
    20332033    i = 4;
    2034     bAdd = newtCompactButton(i, 17, " Add ");
    2035     bEdit = newtCompactButton(i += 11, 17, " Edit ");
    2036     bDelete = newtCompactButton(i += 12, 17, "Delete");
    2037     bReload = newtCompactButton(i += 12, 17, "Reload");
    2038     bCancel = newtCompactButton(i += 12, 17, "Cancel");
    2039     bOK = newtCompactButton(i += 12, 17, "  OK  ");
    2040     sprintf(tmp, "%-24s %-24s %-8s  %s", "Device", "Mountpoint", "Format",
    2041             "Size (MB)");
     2034    bAdd = newtCompactButton(i, 17, _(" Add "));
     2035    bEdit = newtCompactButton(i += 11, 17, _(" Edit "));
     2036    bDelete = newtCompactButton(i += 12, 17, _("Delete"));
     2037    bReload = newtCompactButton(i += 12, 17, _("Reload"));
     2038    bCancel = newtCompactButton(i += 12, 17, _("Cancel"));
     2039    bOK = newtCompactButton(i += 12, 17, _("  OK  "));
     2040    sprintf(tmp, "%-24s %-24s %-8s  %s", _("Device"), _("Mountpoint"), _("Format"),
     2041            _("Size (MB)"));
    20422042    headerMsg = newtLabel(2, 1, tmp);
    20432043    flawsLabelA = newtLabel(2, 13, flaws_str_A);
     
    20472047        newtListbox(2, 2, 10, NEWT_FLAG_SCROLL | NEWT_FLAG_RETURNEXIT);
    20482048    redraw_mountlist(mountlist, keylist, partitionsListbox);
    2049     newtOpenWindow(1, 3, 77, 18, "Editing mountlist");
     2049    newtOpenWindow(1, 3, 77, 18, _("Editing mountlist"));
    20502050    myForm = newtForm(NULL, NULL, 0);
    20512051    newtFormAddComponents(myForm, headerMsg, partitionsListbox,
     
    20642064                finished =
    20652065                    ask_me_yes_or_no
    2066                     ("Your mountlist might not work. Continue anyway?");
     2066                    (_("Your mountlist might not work. Continue anyway?"));
    20672067            } else {
    20682068                finished =
    20692069                    ask_me_yes_or_no
    2070                     ("Are you sure you want to save your mountlist and continue? (No changes will be made to your partition table at this time.)");
     2070                    (_("Are you sure you want to save your mountlist and continue? (No changes will be made to your partition table at this time.)"));
    20712071            }
    20722072        } else if (b_res == bCancel) {
    20732073            finished = TRUE;
    20742074        } else if (b_res == bReload) {
    2075             if (ask_me_yes_or_no("Reload original mountlist?")) {
     2075            if (ask_me_yes_or_no(_("Reload original mountlist?"))) {
    20762076/*
    20772077This would be really dumb. RAIDTAB_FNAME is #define'd.   --- Hugo, 2003/04/24
     
    20912091                 i < mountlist->entries && keylist[i] != curr_choice; i++);
    20922092            if (i == mountlist->entries && mountlist->entries > 0) {
    2093                 log_to_screen("I don't know what that button does!");
     2093                log_to_screen(_("I don't know what that button does!"));
    20942094            } else {
    20952095                currline = i;
     
    21092109                    } else {
    21102110                        popup_and_OK
    2111                             ("Please add an entry. Then press ENTER to edit it.");
     2111                            (_("Please add an entry. Then press ENTER to edit it."));
    21122112                    }
    21132113                }
     
    21192119    newtPopHelpLine();
    21202120    if (b_res == bOK) {
    2121         log_it("You pushed 'OK'. I shall now continue.");
     2121        log_it(_("You pushed 'OK'. I shall now continue."));
    21222122        return (0);
    21232123    } else {
     
    21982198    sprintf(title_of_window, "Additional variables");
    21992199    newtPushHelpLine
    2200         ("  Edit the additional fields to your heart's content, then click OK or Cancel.");
    2201     headerMsg = newtLabel(1, 1, "Label                            Value");
     2200        (_("  Edit the additional fields to your heart's content, then click OK or Cancel."));
     2201    headerMsg = newtLabel(1, 1, _("Label                            Value"));
    22022202    varsListbox =
    22032203        newtListbox(1, 2, 6, NEWT_FLAG_SCROLL | NEWT_FLAG_RETURNEXIT);
    22042204    i = 1;
    2205     bAdd = newtCompactButton(i, 9, " Add ");
    2206     bEdit = newtCompactButton(i += 8, 9, " Edit ");
    2207     bDelete = newtCompactButton(i += 9, 9, "Delete");
    2208     bOK = newtCompactButton(i += 9, 9, "  OK  ");
    2209     bCancel = newtCompactButton(i += 9, 9, "Cancel");
     2205    bAdd = newtCompactButton(i, 9, _(" Add "));
     2206    bEdit = newtCompactButton(i += 8, 9, _(" Edit "));
     2207    bDelete = newtCompactButton(i += 9, 9, _("Delete"));
     2208    bOK = newtCompactButton(i += 9, 9, _("  OK  "));
     2209    bCancel = newtCompactButton(i += 9, 9, _("Cancel"));
    22102210    newtOpenWindow(17, 7, 46, 10, title_of_window);
    22112211    myForm = newtForm(NULL, NULL, 0);
     
    23612361
    23622362    if (popup_and_get_string
    2363         ("ISO Mode - device", "On what device do the ISO files live?",
     2363        (_("ISO Mode - device"), _("On what device do the ISO files live?"),
    23642364         isodir_device, MAX_STR_LEN / 4)) {
    23652365        if (popup_and_get_string
    2366             ("ISO Mode - format",
    2367              "What is the disk format of the device? (Hit ENTER if you don't know.)",
     2366            (_("ISO Mode - format"),
     2367             _("What is the disk format of the device? (Hit ENTER if you don't know.)"),
    23682368             isodir_format, 16)) {
    23692369            if (popup_and_get_string
    2370                 ("ISO Mode - path",
    2371                  "At what path on this device can the ISO files be found?",
     2370                (_("ISO Mode - path"),
     2371                 _("At what path on this device can the ISO files be found?"),
    23722372                 isodir_path, MAX_STR_LEN / 4)) {
    23732373                strip_spaces(isodir_device);
     
    24672467
    24682468    newtPushHelpLine
    2469         ("This is where I nuke your hard drives. Mhahahahaha. No-one can stop Mojo Jojo!");
    2470     newtOpenWindow(24, 3, 32, 13, "Nuking");
    2471     b1 = newtButton(7, 1, "Slowly");
    2472     b2 = newtButton(7, 5, "Medium");
    2473     b3 = newtButton(7, 9, "Quickly");
     2469        (_("This is where I nuke your hard drives. Mhahahahaha. No-one can stop Mojo Jojo!"));
     2470    newtOpenWindow(24, 3, 32, 13, _("Nuking"));
     2471    b1 = newtButton(7, 1, _("Slowly"));
     2472    b2 = newtButton(7, 5, _("Medium"));
     2473    b3 = newtButton(7, 9, _("Quickly"));
    24742474    myForm = newtForm(NULL, NULL, 0);
    24752475    newtFormAddComponents(myForm, b1, b2, b3, NULL);
     
    28372837    iamhere("Post-malloc");
    28382838    strcpy(help_text,
    2839            "   Edit this RAID device's list of partitions. Choose OK or Cancel when done.");
    2840     sprintf(header_text, "%-24s    %s", "Device", "Index");
    2841     sprintf(title_of_window, "%s contains...", raidrec->raid_device);
     2839           _("   Edit this RAID device's list of partitions. Choose OK or Cancel when done."));
     2840    sprintf(header_text, "%-24s    %s", _("Device"), _("Index"));
     2841    sprintf(title_of_window, _("%s contains..."), raidrec->raid_device);
    28422842    newtPushHelpLine(help_text);
    28432843    for (b_res = (newtComponent) 12345; b_res != bOK && b_res != bCancel;) {
     
    28472847        redraw_disklist(disklist, keylist, partitionsListbox);
    28482848        i = 1;
    2849         bAdd = newtCompactButton(i, 9, " Add ");
    2850         bDelete = newtCompactButton(i += 8, 9, "Delete");
    2851         bOK = newtCompactButton(i += 9, 9, "  OK  ");
    2852         bCancel = newtCompactButton(i += 9, 9, "Cancel");
     2849        bAdd = newtCompactButton(i, 9, _(" Add "));
     2850        bDelete = newtCompactButton(i += 8, 9, _("Delete"));
     2851        bOK = newtCompactButton(i += 9, 9, _("  OK  "));
     2852        bCancel = newtCompactButton(i += 9, 9, _("Cancel"));
    28532853        newtOpenWindow(21, 7, 38, 10, title_of_window);
    28542854        myForm = newtForm(NULL, NULL, 0);
     
    28692869                 i++);
    28702870            if (i == disklist->entries && disklist->entries > 0) {
    2871                 log_to_screen("I don't know what that button does!");
     2871                log_to_screen(_("I don't know what that button does!"));
    28722872            } else {
    28732873                currline = i;
    28742874                if (b_res == bAdd) {
    2875                     log_it("Making list of unallocated RAID slices");
     2875                    log_it(_("Making list of unallocated RAID slices"));
    28762876                    make_list_of_unallocated_raid_partitions
    28772877                        (unallocated_raid_partitions, mountlist_dontedit,
     
    28792879                    if (unallocated_raid_partitions->entries <= 0) {
    28802880                        popup_and_OK
    2881                             ("There are no unallocated partitions marked for RAID.");
     2881                            (_("There are no unallocated partitions marked for RAID."));
    28822882                    } else {
    28832883                        log_it
    2884                             ("Done. The user may add one or more of the above to RAID device");
     2884                            (_("Done. The user may add one or more of the above to RAID device"));
    28852885                        add_disklist_entry(disklist, raidrec->raid_device,
    28862886                                           unallocated_raid_partitions);
    2887                         log_it("I have finished adding a disklist entry.");
     2887                        log_it(_("I have finished adding a disklist entry."));
    28882888                        redraw_disklist(disklist, keylist,
    28892889                                        partitionsListbox);
     
    28942894                    redraw_disklist(disklist, keylist, partitionsListbox);
    28952895                } else {
    2896                     sprintf(tmp, "%s's index is %d. What should it be?",
     2896                    sprintf(tmp, _("%s's index is %d. What should it be?"),
    28972897                            raidrec->raid_device,
    28982898                            disklist->el[currline].index);
    28992899                    sprintf(sz_res, "%d", disklist->el[currline].index);
    2900                     if (popup_and_get_string("Set index", tmp, sz_res, 10)) {
     2900                    if (popup_and_get_string(_("Set index"), tmp, sz_res, 10)) {
    29012901                        disklist->el[currline].index = atoi(sz_res);
    29022902                    }
     
    29552955        for (output = 'z'; !strchr("AICE", output); output = tmp[0]) {
    29562956            printf
    2957                 ("Which mode - (A)utomatic, (I)nteractive, \n(C)ompare only, or (E)xit to shell?\n--> ");
     2957                (_("Which mode - (A)utomatic, (I)nteractive, \n(C)ompare only, or (E)xit to shell?\n--> "));
    29582958            fgets(tmp, MAX_STR_LEN - 1, stdin);
    29592959        }
     
    29622962
    29632963    newtPushHelpLine
    2964         ("   Do you want to 'nuke' your system, restore interactively, or just compare?");
    2965     newtOpenWindow(24, 3, 32, 17, "How should I restore?");
    2966     b1 = newtButton(7, 1, "Automatically");
    2967     b2 = newtButton(7, 5, "Interactively");
    2968     b3 = newtButton(7, 9, "Compare only!");
    2969     b4 = newtButton(7, 13, "Exit to shell");
     2964        (_("   Do you want to 'nuke' your system, restore interactively, or just compare?"));
     2965    newtOpenWindow(24, 3, 32, 17, _("How should I restore?"));
     2966    b1 = newtButton(7, 1, _("Automatically"));
     2967    b2 = newtButton(7, 5, _("Interactively"));
     2968    b3 = newtButton(7, 9, _("Compare only!"));
     2969    b4 = newtButton(7, 13, _("Exit to shell"));
    29702970    myForm = newtForm(NULL, NULL, 0);
    29712971    newtFormAddComponents(myForm, b1, b2, b3, b4, NULL);
  • branches/stable/mondo/mondo/mondorestore/mondo-rstr-tools.c

    r425 r497  
    241241
    242242        sprintf(question_ptr,
    243                 "Should I restore the image of %s ?", incoming_ptr);
     243                _("Should I restore the image of %s ?"), incoming_ptr);
    244244
    245245        if (ask_me_yes_or_no(question_ptr)) {
     
    355355    while (get_cfg_file_from_archive(bkpinfo)) {
    356356        if (!ask_me_yes_or_no
    357             ("Failed to find config file/archives. Choose another source?"))
     357            (_("Failed to find config file/archives. Choose another source?")))
    358358        {
    359359            fatal_error("Could not find config file/archives. Aborting.");
     
    459459
    460460    if (is_this_device_mounted(g_isodir_device)) {
    461         log_to_screen("WARNING - isodir is already mounted");
     461        log_to_screen(_("WARNING - isodir is already mounted"));
    462462        already_mounted = TRUE;
    463463    } else {
     
    476476        if (run_program_and_log_output(mount_isodir_command, FALSE)) {
    477477            popup_and_OK
    478                 ("Cannot mount the device where the ISO files are stored.");
     478                (_("Cannot mount the device where the ISO files are stored."));
    479479            return (1);
    480480        }
    481481        log_to_screen
    482             ("I have mounted the device where the ISO files are stored.");
     482            (_("I have mounted the device where the ISO files are stored."));
    483483    }
    484484    if (!IS_THIS_A_STREAMING_BACKUP(bkpinfo->backup_media_type)) {
     
    491491    if (i < 0) {
    492492        popup_and_OK
    493             ("Cannot find ISO images in the directory you specified.");
     493            (_("Cannot find ISO images in the directory you specified."));
    494494        retval = 1;
    495495    }
     
    617617    these_failed[0] = '\0';
    618618
    619     mvaddstr_and_log_it(g_currentY, 0, "Mounting devices         ");
    620     open_progress_form("Mounting devices",
    621                        "I am now mounting all the drives.",
    622                        "This should not take long.",
     619    mvaddstr_and_log_it(g_currentY, 0, _("Mounting devices         "));
     620    open_progress_form(_("Mounting devices"),
     621                       _("I am now mounting all the drives."),
     622                       _("This should not take long."),
    623623                       "", mountlist->entries);
    624624
     
    628628                    "Again with the /proc - why is this in your mountlist?");
    629629        } else if (is_this_device_mounted(mountlist->el[lino].device)) {
    630             sprintf(tmp, "%s is already mounted",
     630            sprintf(tmp, _("%s is already mounted"),
    631631                    mountlist->el[lino].device);
    632632            log_to_screen(tmp);
     
    657657        if (g_partition_table_locked_up > 0) {
    658658            log_to_screen
    659                 ("fdisk's ictol() call to refresh its copy of the partition table causes the kernel to");
     659                (_("fdisk's ioctl() call to refresh its copy of the partition table causes the kernel to"));
    660660            log_to_screen
    661                 ("lock up the partition table. You might have to reboot and use Interactive Mode to");
     661                (_("lock up the partition table. You might have to reboot and use Interactive Mode to"));
    662662            log_to_screen
    663                 ("format and restore *without* partitioning first. Sorry for the inconvenience.");
    664         }
    665         sprintf(tmp, "Could not mount devices %s- shall I abort?",
     663                (_("format and restore *without* partitioning first. Sorry for the inconvenience."));
     664        }
     665        sprintf(tmp, _("Could not mount devices %s- shall I abort?"),
    666666                these_failed);
    667667        if (!ask_me_yes_or_no(tmp)) {
    668668            retval = 0;
    669669            log_to_screen
    670                 ("Continuing, although some devices failed to be mounted");
    671             mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     670                (_("Continuing, although some devices failed to be mounted"));
     671            mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    672672        } else {
    673             mvaddstr_and_log_it(g_currentY++, 74, "Failed.");
     673            mvaddstr_and_log_it(g_currentY++, 74, _("Failed."));
    674674            log_to_screen
    675                 ("Unable to mount some or all of your partitions.");
     675                (_("Unable to mount some or all of your partitions."));
    676676        }
    677677    } else {
    678         log_to_screen("All partitions were mounted OK.");
    679         mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     678        log_to_screen(_("All partitions were mounted OK."));
     679        mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    680680    }
    681681    run_program_and_log_output("df -P -m", 3);
     
    13401340    if (am_I_in_disaster_recovery_mode()
    13411341        &&
    1342         ask_me_yes_or_no("Do you want to retrieve the mountlist as well?"))
     1342        ask_me_yes_or_no(_("Do you want to retrieve the mountlist as well?")))
    13431343    {
    13441344//      sprintf(command, "cp -f tmp/mountlist.txt /tmp");
     
    13661366
    13671367    case 0:
    1368         log_to_screen("Pre-processing filelist");
     1368        log_to_screen(("Pre-processing filelist"));
    13691369        if (!does_file_exist(g_biggielist_txt)) {
    13701370            sprintf(command, "> %s", g_biggielist_txt);
     
    13781378
    13791379    default:
    1380         open_evalcall_form("Pre-processing filelist");
     1380        open_evalcall_form(_("Pre-processing filelist"));
    13811381        while (!waitpid(pid, (int *) 0, WNOHANG)) {
    13821382            usleep(100000);
     
    13911391    unlink(g_filelist_full);
    13921392    if (g_text_mode) {
    1393         printf("Restore which directory? --> ");
     1393        printf(_("Restore which directory? --> "));
    13941394        fgets(tmp, sizeof(tmp), stdin);
    13951395        toggle_path_selection(filelist, tmp, TRUE);
     
    15241524    else {
    15251525        log_to_screen
    1526             ("Unable to determine type of boot loader. Defaulting to LILO.");
     1526            (_("Unable to determine type of boot loader. Defaulting to LILO."));
    15271527        res = run_lilo(offer_to_hack_scripts);
    15281528    }
     
    15301530    retval += res;
    15311531    if (res) {
    1532         log_to_screen("Your boot loader returned an error");
     1532        log_to_screen(_("Your boot loader returned an error"));
    15331533    } else {
    1534         log_to_screen("Your boot loader ran OK");
     1534        log_to_screen(_("Your boot loader ran OK"));
    15351535    }
    15361536    paranoid_free(device);
     
    16131613    }
    16141614    if (offer_to_run_stabgrub
    1615         && ask_me_yes_or_no("Did you change the mountlist?"))
     1615        && ask_me_yes_or_no(_("Did you change the mountlist?")))
    16161616        /* interactive mode */
    16171617    {
    16181618        mvaddstr_and_log_it(g_currentY,
    16191619                            0,
    1620                             "Modifying fstab and grub.conf, and running GRUB...                             ");
     1620                            _("Modifying fstab and grub.conf, and running GRUB...                             "));
    16211621        for (done = FALSE; !done;) {
    1622             popup_and_get_string("Boot device",
    1623                                  "Please confirm/enter the boot device. If in doubt, try /dev/hda",
     1622            popup_and_get_string(_("Boot device"),
     1623                                 _("Please confirm/enter the boot device. If in doubt, try /dev/hda"),
    16241624                                 boot_device, MAX_STR_LEN / 4);
    16251625            sprintf(command, "stabgrub-me %s", boot_device);
     
    16271627            if (res) {
    16281628                popup_and_OK
    1629                     ("GRUB installation failed. Please install manually using 'grub-install' or similar command. You are now chroot()'ed to your restored system. Please type 'exit' when you are done.");
     1629                    (_("GRUB installation failed. Please install manually using 'grub-install' or similar command. You are now chroot()'ed to your restored system. Please type 'exit' when you are done."));
    16301630                newtSuspend();
    16311631                system("chroot " MNT_RESTORING);
    16321632                newtResume();
    1633                 popup_and_OK("Thank you.");
     1633                popup_and_OK(_("Thank you."));
    16341634            } else {
    16351635                done = TRUE;
    16361636            }
    1637             popup_and_OK("You will now edit fstab and grub.conf");
     1637            popup_and_OK(_("You will now edit fstab and grub.conf"));
    16381638            if (!g_text_mode) {
    16391639                newtSuspend();
     
    16521652        mvaddstr_and_log_it(g_currentY,
    16531653                            0,
    1654                             "Running GRUB...                                                 ");
     1654                            _("Running GRUB...                                                 "));
    16551655        iamhere(command);
    16561656        res = run_program_and_log_output(command, 1);
    16571657        if (res) {
    16581658            popup_and_OK
    1659                 ("Because of bugs in GRUB's own installer, GRUB was not installed properly. Please install the boot loader manually now, using this chroot()'ed shell prompt. Type 'exit' when you have finished.");
     1659                (_("Because of bugs in GRUB's own installer, GRUB was not installed properly. Please install the boot loader manually now, using this chroot()'ed shell prompt. Type 'exit' when you have finished."));
    16601660            newtSuspend();
    16611661            system("chroot " MNT_RESTORING);
    16621662            newtResume();
    1663             popup_and_OK("Thank you.");
     1663            popup_and_OK(_("Thank you."));
    16641664        }
    16651665    }
    16661666    if (res) {
    1667         mvaddstr_and_log_it(g_currentY++, 74, "Failed.");
     1667        mvaddstr_and_log_it(g_currentY++, 74, _("Failed."));
    16681668        log_to_screen
    1669             ("GRUB ran w/error(s). See /tmp/mondo-restore.log for more info.");
     1669            (_("GRUB ran w/error(s). See /tmp/mondo-restore.log for more info."));
    16701670        log_msg(1, "Type:-");
    16711671        log_msg(1, "    mount-me");
     
    16781678                "If you're really stuck, please e-mail the mailing list.");
    16791679    } else {
    1680         mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     1680        mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    16811681    }
    16821682    paranoid_free(rootdev);
     
    17161716    strcpy(editor, find_my_editor());
    17171717    if (offer_to_run_stabelilo
    1718         && ask_me_yes_or_no("Did you change the mountlist?"))
     1718        && ask_me_yes_or_no(_("Did you change the mountlist?")))
    17191719
    17201720        /* interactive mode */
     
    17221722        mvaddstr_and_log_it(g_currentY,
    17231723                            0,
    1724                             "Modifying fstab and elilo.conf...                             ");
     1724                            _("Modifying fstab and elilo.conf...                             "));
    17251725        sprintf(command, "stabelilo-me");
    17261726        res = run_program_and_log_output(command, 3);
    17271727        if (res) {
    17281728            popup_and_OK
    1729                 ("You will now edit fstab and elilo.conf, to make sure they match your new mountlist.");
     1729                (_("You will now edit fstab and elilo.conf, to make sure they match your new mountlist."));
    17301730            for (done = FALSE; !done;) {
    17311731                if (!g_text_mode) {
     
    17411741                }
    17421742//              newtCls();
    1743                 if (ask_me_yes_or_no("Edit them again?")) {
     1743                if (ask_me_yes_or_no(_("Edit them again?"))) {
    17441744                    continue;
    17451745                }
     
    17471747            }
    17481748        } else {
    1749             log_to_screen("elilo.conf and fstab were modified OK");
     1749            log_to_screen(_("elilo.conf and fstab were modified OK"));
    17501750        }
    17511751    } else
     
    17911791    strcpy(editor, find_my_editor());
    17921792    if (offer_to_run_stablilo
    1793         && ask_me_yes_or_no("Did you change the mountlist?"))
     1793        && ask_me_yes_or_no(_("Did you change the mountlist?")))
    17941794
    17951795        /* interactive mode */
     
    17971797        mvaddstr_and_log_it(g_currentY,
    17981798                            0,
    1799                             "Modifying fstab and lilo.conf, and running LILO...                             ");
     1799                            _("Modifying fstab and lilo.conf, and running LILO...                             "));
    18001800        sprintf(command, "stablilo-me");
    18011801        res = run_program_and_log_output(command, 3);
    18021802        if (res) {
    18031803            popup_and_OK
    1804                 ("You will now edit fstab and lilo.conf, to make sure they match your new mountlist.");
     1804                (_("You will now edit fstab and lilo.conf, to make sure they match your new mountlist."));
    18051805            for (done = FALSE; !done;) {
    18061806                if (!g_text_mode) {
     
    18151815                }
    18161816//              newtCls();
    1817                 if (ask_me_yes_or_no("Edit them again?")) {
     1817                if (ask_me_yes_or_no(_("Edit them again?"))) {
    18181818                    continue;
    18191819                }
     
    18291829                    done =
    18301830                        ask_me_yes_or_no
    1831                         ("LILO failed. Re-edit system files?");
     1831                        (_("LILO failed. Re-edit system files?"));
    18321832                } else {
    18331833                    done = TRUE;
     
    18351835            }
    18361836        } else {
    1837             log_to_screen("lilo.conf and fstab were modified OK");
     1837            log_to_screen(_("lilo.conf and fstab were modified OK"));
    18381838        }
    18391839    } else
     
    18421842        mvaddstr_and_log_it(g_currentY,
    18431843                            0,
    1844                             "Running LILO...                                                 ");
     1844                            _("Running LILO...                                                 "));
    18451845        res =
    18461846            run_program_and_log_output("chroot " MNT_RESTORING " lilo -L",
     
    18521852        }
    18531853        if (res) {
    1854             mvaddstr_and_log_it(g_currentY++, 74, "Failed.");
     1854            mvaddstr_and_log_it(g_currentY++, 74, _("Failed."));
    18551855            log_to_screen
    1856                 ("Failed to re-jig fstab and/or lilo. Edit/run manually, please.");
     1856                (_("Failed to re-jig fstab and/or lilo. Edit/run manually, please."));
    18571857        } else {
    1858             mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     1858            mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    18591859        }
    18601860    }
     
    19041904
    19051905    if (offer_to_hack_scripts
    1906         && ask_me_yes_or_no("Did you change the mountlist?"))
     1906        && ask_me_yes_or_no(_("Did you change the mountlist?")))
    19071907        /* interactive mode */
    19081908    {
    19091909        mvaddstr_and_log_it(g_currentY, 0,
    1910                             "Modifying fstab and restoring MBR...                           ");
     1910                            _("Modifying fstab and restoring MBR...                           "));
    19111911        for (done = FALSE; !done;) {
    19121912            if (!run_program_and_log_output("which vi", FALSE)) {
    1913                 popup_and_OK("You will now edit fstab");
     1913                popup_and_OK(_("You will now edit fstab"));
    19141914                if (!g_text_mode) {
    19151915                    newtSuspend();
     
    19221922//              newtCls();
    19231923            }
    1924             popup_and_get_string("Boot device",
    1925                                  "Please confirm/enter the boot device. If in doubt, try /dev/hda",
     1924            popup_and_get_string(_("Boot device"),
     1925                                 _("Please confirm/enter the boot device. If in doubt, try /dev/hda"),
    19261926                                 boot_device, MAX_STR_LEN / 4);
    19271927            sprintf(command, "stabraw-me %s", boot_device);
    19281928            res = run_program_and_log_output(command, 3);
    19291929            if (res) {
    1930                 done = ask_me_yes_or_no("Modifications failed. Re-try?");
     1930                done = ask_me_yes_or_no(_("Modifications failed. Re-try?"));
    19311931            } else {
    19321932                done = TRUE;
     
    19371937    {
    19381938        mvaddstr_and_log_it(g_currentY, 0,
    1939                             "Restoring MBR...                                               ");
     1939                            _("Restoring MBR...                                               "));
    19401940        res = run_program_and_log_output(command, 3);
    19411941    }
    19421942    if (res) {
    1943         mvaddstr_and_log_it(g_currentY++, 74, "Failed.");
     1943        mvaddstr_and_log_it(g_currentY++, 74, _("Failed."));
    19441944        log_to_screen
    1945             ("MBR+fstab processed w/error(s). See /tmp/mondo-restore.log for more info.");
     1945            (_("MBR+fstab processed w/error(s). See /tmp/mondo-restore.log for more info."));
    19461946    } else {
    1947         mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     1947        mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    19481948    }
    19491949    paranoid_free(command);
     
    20852085{
    20862086    log_to_screen
    2087         ("Mondorestore is terminating in response to a signal from the OS");
     2087        (_("Mondorestore is terminating in response to a signal from the OS"));
    20882088    paranoid_MR_finish(254);
    20892089}
     
    21072107        return;
    21082108    }
    2109     open_progress_form("CAUTION",
    2110                        "Be advised: I am about to ERASE your hard disk(s)!",
    2111                        "You may press Ctrl+Alt+Del to abort safely.",
     2109    open_progress_form(_("CAUTION"),
     2110                       _("Be advised: I am about to ERASE your hard disk(s)!"),
     2111                       _("You may press Ctrl+Alt+Del to abort safely."),
    21122112                       "", 20);
    21132113    for (i = 0; i < 20; i++) {
    21142114        g_current_progress = i;
    2115         sprintf(tmp, "You have %d seconds left to abort.", 20 - i);
     2115        sprintf(tmp, _("You have %d seconds left to abort."), 20 - i);
    21162116        update_progress_form(tmp);
    21172117        sleep(1);
     
    21692169
    21702170    run_program_and_log_output("df -P -m", 3);
    2171     mvaddstr_and_log_it(g_currentY, 0, "Unmounting devices      ");
    2172     open_progress_form("Unmounting devices",
    2173                        "Unmounting all devices that were mounted,",
    2174                        "in preparation for the post-restoration reboot.",
     2171    mvaddstr_and_log_it(g_currentY, 0, _("Unmounting devices      "));
     2172    open_progress_form(_("Unmounting devices"),
     2173                       _("Unmounting all devices that were mounted,"),
     2174                       _("in preparation for the post-restoration reboot."),
    21752175                       "", mountlist->entries);
    21762176    chdir("/");
     
    22052205            continue;
    22062206        }
    2207         sprintf(tmp, "Unmounting device %s  ", mountlist->el[lino].device);
     2207        sprintf(tmp, _("Unmounting device %s  "), mountlist->el[lino].device);
    22082208
    22092209        update_progress_form(tmp);
     
    22242224            res = run_program_and_log_output(command, 3);
    22252225        } else {
    2226             strcat(tmp, "...not mounted anyway :-) OK");
     2226            strcat(tmp, _("...not mounted anyway :-) OK"));
    22272227            res = 0;
    22282228        }
    22292229        g_current_progress++;
    22302230        if (res) {
    2231             strcat(tmp, "...Failed");
     2231            strcat(tmp, _("...Failed"));
    22322232            retval++;
    22332233            log_to_screen(tmp);
     
    22382238    close_progress_form();
    22392239    if (retval) {
    2240         mvaddstr_and_log_it(g_currentY++, 74, "Failed.");
     2240        mvaddstr_and_log_it(g_currentY++, 74, _("Failed."));
    22412241    } else {
    2242         mvaddstr_and_log_it(g_currentY++, 74, "Done.");
     2242        mvaddstr_and_log_it(g_currentY++, 74, _("Done."));
    22432243    }
    22442244    if (retval) {
    2245         log_to_screen("Unable to unmount some of your partitions.");
     2245        log_to_screen(_("Unable to unmount some of your partitions."));
    22462246    } else {
    2247         log_to_screen("All partitions were unmounted OK.");
     2247        log_to_screen(_("All partitions were unmounted OK."));
    22482248    }
    22492249    free(mountlist);
     
    23282328    malloc_string(tmp);
    23292329    log_msg(2, "gcffa --- starting");
    2330     log_to_screen("I'm thinking...");
     2330    log_to_screen(_("I'm thinking..."));
    23312331    sprintf(mountpt, "%s/mount.bootdisk", bkpinfo->tmpdir);
    23322332    device[0] = '\0';
     
    24392439
    24402440            if (!does_file_exist("tmp/mondo-restore.cfg")) {
    2441                 log_to_screen("Cannot find config info on tape/CD/floppy");
     2441                log_to_screen(_("Cannot find config info on tape/CD/floppy"));
    24422442                return (1);
    24432443            }
     
    25202520        log_msg(1, "%s not found", cfg_file);
    25212521        log_to_screen
    2522             ("Oh dear. Unable to recover configuration file from boot disk");
     2522            (_("Oh dear. Unable to recover configuration file from boot disk"));
    25232523        return (1);
    25242524    }
    25252525
    2526     log_to_screen("Recovered mondo-restore.cfg");
     2526    log_to_screen(_("Recovered mondo-restore.cfg"));
    25272527    if (!does_file_exist(MOUNTLIST_FNAME_STUB)) {
    2528         log_to_screen("...but not mountlist.txt - a pity, really...");
     2528        log_to_screen(_("...but not mountlist.txt - a pity, really..."));
    25292529    }
    25302530/* start SAH */
     
    25962596    while (unfinished_mdstat_devices > 0) {
    25972597        if (read_mdstat(mdstat, mdstat_file)) {
    2598             log_to_screen("Sorry, cannot read %s", mdstat_file);
     2598            log_to_screen(_("Sorry, cannot read %s"), mdstat_file);
    25992599            return;
    26002600        }
     
    26022602            if (mdstat->el[i].progress < wait_for_percentage) {
    26032603                unfinished_mdstat_devices++;
    2604                 sprintf(screen_message, "Sync'ing /dev/md%d",
     2604                sprintf(screen_message, _("Sync'ing /dev/md%d"),
    26052605                        mdstat->el[i].md);
    26062606                open_evalcall_form(screen_message);
Note: See TracChangeset for help on using the changeset viewer.