xref: /onnv-gate/usr/src/cmd/boot/installgrub/message.h (revision 10568:05d6365b5963)
10Sstevel@tonic-gate /*
20Sstevel@tonic-gate  * CDDL HEADER START
30Sstevel@tonic-gate  *
40Sstevel@tonic-gate  * The contents of this file are subject to the terms of the
55589Ssy25831  * Common Development and Distribution License (the "License").
65589Ssy25831  * You may not use this file except in compliance with the License.
70Sstevel@tonic-gate  *
80Sstevel@tonic-gate  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
90Sstevel@tonic-gate  * or http://www.opensolaris.org/os/licensing.
100Sstevel@tonic-gate  * See the License for the specific language governing permissions
110Sstevel@tonic-gate  * and limitations under the License.
120Sstevel@tonic-gate  *
130Sstevel@tonic-gate  * When distributing Covered Code, include this CDDL HEADER in each
140Sstevel@tonic-gate  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
150Sstevel@tonic-gate  * If applicable, add the following below this CDDL HEADER, with the
160Sstevel@tonic-gate  * fields enclosed by brackets "[]" replaced with your own identifying
170Sstevel@tonic-gate  * information: Portions Copyright [yyyy] [name of copyright owner]
180Sstevel@tonic-gate  *
190Sstevel@tonic-gate  * CDDL HEADER END
200Sstevel@tonic-gate  */
210Sstevel@tonic-gate /*
2210021SSheshadri.Vasudevan@Sun.COM  * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
230Sstevel@tonic-gate  * Use is subject to license terms.
240Sstevel@tonic-gate  */
250Sstevel@tonic-gate 
260Sstevel@tonic-gate #ifndef	_MESSAGE_H
270Sstevel@tonic-gate #define	_MESSAGE_H
280Sstevel@tonic-gate 
290Sstevel@tonic-gate #ifdef	__cplusplus
300Sstevel@tonic-gate extern "C" {
310Sstevel@tonic-gate #endif
320Sstevel@tonic-gate 
330Sstevel@tonic-gate #define	USAGE	gettext("Usage: %s [-fm] stage1 stage2 raw-device\n")
340Sstevel@tonic-gate 
350Sstevel@tonic-gate #define	DRY_RUN	gettext("dry run--nothing will be written to disk\n")
360Sstevel@tonic-gate 
37*10568SVikram.Hegde@Sun.COM #define	NOSOLPAR	\
38*10568SVikram.Hegde@Sun.COM 	gettext("Solaris partition not found. Aborting operation.\n")
390Sstevel@tonic-gate 
40*10568SVikram.Hegde@Sun.COM #define	NOBOOTPAR	\
41*10568SVikram.Hegde@Sun.COM 	gettext("Solaris x86 boot partition not found. Aborting operation.\n")
42*10568SVikram.Hegde@Sun.COM 
43*10568SVikram.Hegde@Sun.COM #define	SOLPAR_INACTIVE	gettext("Solaris fdisk partition is inactive.\n")
440Sstevel@tonic-gate 
450Sstevel@tonic-gate #define	BOOTPAR_NOTFOUND	\
460Sstevel@tonic-gate     gettext("Solaris boot partition not found on %s\n")
470Sstevel@tonic-gate 
48*10568SVikram.Hegde@Sun.COM #define	EXTSOLPAR	\
49*10568SVikram.Hegde@Sun.COM 	gettext("Solaris in extended partition. -m (MBR) option required\n")
50*10568SVikram.Hegde@Sun.COM 
510Sstevel@tonic-gate #define	NOT_RAW_DEVICE	gettext("device %s is not a char special device\n")
520Sstevel@tonic-gate 
530Sstevel@tonic-gate #define	NOT_ROOT_SLICE	gettext("raw device must be a root slice (not s2)\n")
540Sstevel@tonic-gate 
550Sstevel@tonic-gate #define	CONVERT_FAIL	gettext("cannot convert %s to a block device.\n")
560Sstevel@tonic-gate 
570Sstevel@tonic-gate #define	MOUNT_FAIL	gettext("cannot mount %s\n")
580Sstevel@tonic-gate 
590Sstevel@tonic-gate #define	MOUNT_FAIL_PCFS	gettext("floppy: cannot mount pcfs\n")
600Sstevel@tonic-gate 
610Sstevel@tonic-gate #define	MBOOT_PROMPT	\
620Sstevel@tonic-gate 	gettext("Updating master boot sector destroys existing boot " \
630Sstevel@tonic-gate 	"managers (if any).\ncontinue (y/n)?")
640Sstevel@tonic-gate 
650Sstevel@tonic-gate #define	MBOOT_NOT_UPDATED	gettext("master boot sector not updated\n")
660Sstevel@tonic-gate 
670Sstevel@tonic-gate #define	OPEN_FAIL	gettext("cannot open/stat device %s\n")
680Sstevel@tonic-gate 
690Sstevel@tonic-gate #define	OPEN_FAIL_FILE	gettext("cannot open %s\n")
700Sstevel@tonic-gate 
710Sstevel@tonic-gate #define	OPEN_FAIL_PCFS	gettext("cannot open /boot/grub/stage2 on pcfs\n")
720Sstevel@tonic-gate 
735589Ssy25831 #define	PART_FAIL	\
745589Ssy25831 	gettext("cannot get the partition information of the disk\n")
755589Ssy25831 
765589Ssy25831 #define	BAD_PART	\
775589Ssy25831 	gettext("Partition %d of the disk has an incorrect offset\n")
785589Ssy25831 
790Sstevel@tonic-gate #define	READ_FAIL_STAGE1	gettext("cannot read stage1 file %s\n")
800Sstevel@tonic-gate 
81322Sjongkis #define	READ_FAIL_STAGE2	gettext("cannot read stage2 file %s\n")
820Sstevel@tonic-gate 
830Sstevel@tonic-gate #define	READ_FAIL_BPB	gettext("cannot read bios parameter block\n")
840Sstevel@tonic-gate 
850Sstevel@tonic-gate #define	READ_FAIL_MBR	gettext("cannot read MBR on %s\n")
860Sstevel@tonic-gate 
870Sstevel@tonic-gate #define	WRITE_FAIL_BOOTSEC	gettext("cannot write master boot sector\n")
880Sstevel@tonic-gate 
890Sstevel@tonic-gate #define	WRITE_FAIL_PBOOT	gettext("cannot write partition boot sector\n")
900Sstevel@tonic-gate 
910Sstevel@tonic-gate #define	WRITE_FAIL_STAGE2	gettext("failed to write stage2\n")
920Sstevel@tonic-gate 
930Sstevel@tonic-gate #define	WRITE_FAIL_STAGE2_BLOCKS	\
940Sstevel@tonic-gate     gettext("stage2 read/write error: read %d bytes, wrote %d bytes\n")
950Sstevel@tonic-gate 
960Sstevel@tonic-gate #define	WRITE_MBOOT	gettext("stage1 written to master boot sector\n")
970Sstevel@tonic-gate 
980Sstevel@tonic-gate #define	WRITE_PBOOT	\
990Sstevel@tonic-gate     gettext("stage1 written to partition %d sector 0 (abs %d)\n")
1000Sstevel@tonic-gate 
1010Sstevel@tonic-gate #define	WRITE_BOOTSEC_FLOPPY	\
1020Sstevel@tonic-gate     gettext("stage1 written to floppy boot sector\n")
1030Sstevel@tonic-gate 
1040Sstevel@tonic-gate #define	WRITE_STAGE2_PCFS	gettext("stage2 written to pcfs\n")
1050Sstevel@tonic-gate 
106322Sjongkis #define	WRITE_STAGE2_DISK	gettext("stage2 written to partition %d," \
107322Sjongkis 	" %d sectors starting at %d (abs %d)\n")
1080Sstevel@tonic-gate 
1090Sstevel@tonic-gate #define	PCFS_FRAGMENTED	\
1100Sstevel@tonic-gate     gettext("cannot install stage2 on pcfs, too many fragments.\n")
1110Sstevel@tonic-gate 
1120Sstevel@tonic-gate #define	OUT_OF_MEMORY	gettext("diskread: out of memory\n")
1130Sstevel@tonic-gate 
11410021SSheshadri.Vasudevan@Sun.COM #define	NO_VIRT_GEOM	gettext("Could not get virtual geometry\n")
11510021SSheshadri.Vasudevan@Sun.COM 
11610021SSheshadri.Vasudevan@Sun.COM #define	NO_PHYS_GEOM	gettext("Could not get physical geometry\n")
11710021SSheshadri.Vasudevan@Sun.COM 
11810021SSheshadri.Vasudevan@Sun.COM #define	NO_LABEL_GEOM	gettext("Could not get label geometry\n")
11910021SSheshadri.Vasudevan@Sun.COM 
12010021SSheshadri.Vasudevan@Sun.COM #define	LIBFDISK_INIT_FAIL	gettext("Failed to initialize libfdisk.\n")
12110021SSheshadri.Vasudevan@Sun.COM 
122*10568SVikram.Hegde@Sun.COM 
123*10568SVikram.Hegde@Sun.COM 
1240Sstevel@tonic-gate #ifdef	__cplusplus
1250Sstevel@tonic-gate }
1260Sstevel@tonic-gate #endif
1270Sstevel@tonic-gate 
1280Sstevel@tonic-gate #endif /* _MESSAGE_H */
129