Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
localedef(1)			 User Commands			  localedef(1)

NAME
       localedef - define locale environment

SYNOPSIS
       localedef   [-c]	  [-C compiler_options]	 [-f charmap]  [-i sourcefile]
       [-L linker_options] [-m model] [-u code_set_name] [ -W cc, arg] [-x ex-
       tensions_file] localename

DESCRIPTION
       The localedef utility converts source definitions for locale categories
       into a format usable by the functions and utilities  whose  operational
       behavior	 is  determined	by the setting of the locale environment vari-
       ables; see environ(5).

       The utility reads source	definitions for	one or more locale  categories
       belonging  to  the same locale from the file named in the -i option (if
       specified) or from standard input.

       Each category source definition is identified by	the corresponding  en-
       vironment  variable  name and terminated	by an END category-name	state-
       ment. The following categories are supported.

       LC_CTYPE		       Defines character classification	and case  con-
			       version.

       LC_COLLATE	       Defines collation rules.

       LC_MONETARY	       Defines	the format and symbols used in format-
			       ting of monetary	information.

       LC_NUMERIC	       Defines the  decimal  delimiter,	 grouping  and
			       grouping	 symbol	for non-monetary numeric edit-
			       ing.

       LC_TIME		       Defines the format and content of date and time
			       information.

       LC_MESSAGES	       Defines	the  format  and values	of affirmative
			       and negative responses.

OPTIONS
       The following options are supported:

       -c		       Creates permanent output	even if	 warning  mes-
			       sages have been issued.

       -C compiler_options     Passes  the  compiler_options to	the C compiler
			       (cc). If	more than  one	option	is  specified,
			       then  the  options  must	 be enclosed in	quotes
			       ("").

			       This is an old option. Use the -W cc,arg	option
			       instead.

       -f charmap	       Specifies  the  pathname	of a file containing a
			       mapping of character symbols and	collating ele-
			       ment  symbols  to  actual  character encodings.
			       This option must	be specified if	symbolic names
			       (other than collating symbols defined in	a col-
			       lating-symbol keyword) are used.	If the -f  op-
			       tion is not present, the	default	character map-
			       ping will be used.

       -i sourcefile	       The path	name of	a file containing  the	source
			       definitions.  If	 this  option  is not present,
			       source definitions will be read	from  standard
			       input.

       -L linker_options       Passes  the  linker_options  to	the C compiler
			       (cc) that follows the  C	 source	 filename.  If
			       more than one option is specified, then the op-
			       tions must be enclosed in quotes	("").

			       This is an old option. Use the -W cc,arg	option
			       instead.

       -m model		       Specifies  whether  localedef  will  generate a
			       64-bit or a 32-bit locale object.

			       Specify model as	ilp32 to generate a 32-bit lo-
			       cale  object. Specify lp64 to generate a	64-bit
			       locale object. If the -m	option is  not	speci-
			       fied,  localedef	 generates a 32-bit locale ob-
			       ject. And if no other options than -c, -f,  and
			       -i options are specified	and if the system run-
			       ning localedef supports the 64-bit environment,
			       localedef  additionally	generates a 64-bit lo-
			       cale object.

       -u code_set_name	       Specifies the name of a	codeset	 used  as  the
			       target mapping of character symbols and collat-
			       ing element symbols whose encoding  values  are
			       defined	in  terms of the ISO/IEC 10646-1: 2000
			       standard	position constant values. See NOTES.

       -W cc,arg	       Passes arg options to the C compiler. Each  ar-
			       gument  must be separated from the preceding by
			       only a comma. A comma can be part of  an	 argu-
			       ment  by	escaping it withan immediately preced-
			       ing backslash character;	the backslash  is  re-
			       moved from the resulting	argument.

			       Use  this  option  instead of the -C and	-L op-
			       tions.

       -x extensions_file      Specifies the name of an	extension  file	 where
			       various	localedef  options are listed. See lo-
			       cale(5).

OPERANDS
       The following operand is	supported:

       localename      Identifies the locale. If the name contains one or more
		       slash  characters,  localename will be interpreted as a
		       path name where the created locale definitions will  be
		       stored. This capability may be restricted to users with
		       appropriate privileges. (As a consequence of specifying
		       one localename, although	several	categories can be pro-
		       cessed in one execution,	only categories	 belonging  to
		       the same	locale can be processed.)

OUTPUT
       localedef  creates  a  temporary	 C source file that represents the lo-
       cale's data. localedef then calls the C	compiler  to  compile  this  C
       source file into	a shared object.

       If the -m ilp32 option is specified, localedef calls the	C compiler for
       generating 32-bit objects and generates a 32-bit	locale object. If  the
       -m  lp64	option is specified, localedef calls the C compiler for	gener-
       ating 64-bit objects and	generates a 64-bit locale object.

       If the -m option	is not specified, localedef calls the C	 compiler  for
       generating  32-bit  objects and generates a 32-bit locale object. If no
       other options than -c, -f, and -i options are specified and if the sys-
       tem  running localedef supports the 64-bit environment, localedef addi-
       tionally	calls the C compiler for generating 64-bit objects and	gener-
       ates a 64-bit locale object.

       If  no  option  to the C	compiler is explicitly specified using the -W,
       -C, or -L options, localedef calls the C	compiler  with	appropriate  C
       compiler	options	to generate a locale object or objects.

       If  the	-m ilp32 option	is specified, localedef	generates a 32-bit lo-
       cale object named:

       localename.so.version_number

       If the -m lp64 option is	specified, localedef generates a 64-bit	locale
       object named:

       localename.so.version_number

       If  the -m option is not	specified, localedef generates a 32-bit	locale
       object named:

       localename.so.version_number

       and, if appropriate, generates a	64-bit locale object named:

       64-bit_architecture_name/localename.so.version_number

       The shared object for the 32-bit	environment must be moved to:

       /usr/lib/locale/localename/localename.so.version_number

       The shared object for the 64-bit	environment on SPARC must be moved to:

       /usr/lib/locale/localename/sparcv9/localename.so.version_number

       The shared object for the 64-bit	environment on AMD64 must be moved to:

       /usr/lib/locale/_localename_/amd64/_localename_.so._version_number_

       localedef also generates	a text file named localename that is used  for
       information only.

ENVIRONMENT VARIABLES
       See  environ(5)	for definitions	of the following environment variables
       that affect the	execution  of  localedef:  LANG,  LC_ALL,  LC_COLLATE,
       LC_CTYPE, LC_MESSAGES, and NLSPATH.

EXIT STATUS
       The following exit values are returned:

       0	No errors occurred and the locales were	successfully created.

       1	Warnings occurred and the locales were successfully created.

       2	The locale specification exceeded implementation limits	or the
		coded character	set or sets used were not supported by the im-
		plementation, and no locale was	created.

       3	The  capability	 to create new locales is not supported	by the
		implementation.

       >3	Warnings or errors occurred and	no output was created.

       If an error is detected,	no permanent output will be created.

FILES
       /usr/lib/localedef/extensions/generic_eucbc.x

	   Describes what a generic EUC	locale uses in the system.  This  file
	   is used by default.

       /usr/lib/localedef/extensions/single_byte.x

	   Describes a generic single-byte file	used in	the system.

       /usr/lib/locale/localename/localename.so.version_number

	   The shared object for the 32-bit environment.

       /usr/lib/locale/localename/sparcv9/localename.so.version_number

	   The shared object for the 64-bit environment	on SPARC.

       /usr/lib/locale/_localename_/amd64/_localename_.so._version_number_

	   The shared object for the 64-bit environment	on AMD64.

ATTRIBUTES
       See attributes(5) for descriptions of the following attributes:

       +-----------------------------+-----------------------------+
       |      ATTRIBUTE	TYPE	     |	    ATTRIBUTE VALUE	   |
       +-----------------------------+-----------------------------+
       |Availability		     |SUNWcsu			   |
       +-----------------------------+-----------------------------+
       |Interface Stability	     |Standard			   |
       +-----------------------------+-----------------------------+

SEE ALSO
       locale(1),    iconv_open(3C),	nl_langinfo(3C),   strftime(3C),   at-
       tributes(5), charmap(5),	environ(5),  extensions(5),  locale(5),	 stan-
       dards(5)

WARNINGS
       If  warnings  occur,  permanent output will be created if the -c	option
       was specified. The following conditions will cause warning messages  to
       be issued:

	 o  If	a  symbolic name not found in the charmap file is used for the
	    descriptions of the	LC_CTYPE or LC_COLLATE categories  (for	 other
	    categories,	this will be an	error conditions).

	 o  If	optional  keywords  not	 supported  by	the implementation are
	    present in the source.

NOTES
       When the	-u option is used, the code_set_name option-argument is	inter-
       preted  as a name of a codeset to which the ISO/IEC 10646-1: 2000 stan-
       dard position constant values are converted. Both the ISO/IEC  10646-1:
       2000  standard  position	 constant  values  and other formats (decimal,
       hexadecimal, or octal) are valid	as encoding values within the  charmap
       file.  The  codeset  can	 be  any  codeset  that	 is  supported	by the
       iconv_open(3C) function on the system.

       When   conflicts	  occur	  between   the	  charmap   specification   of
       code_set_name,  mb_cur_max,  or	mb_cur_min and the corresponding value
       for the codeset represented by the  -u  option-argument	code_set_name,
       the localedef utility fails as an error.

       When  conflicts occur between the charmap encoding values specified for
       symbolic	names of characters of the  portable  character	 set  and  the
       character  encoding  values  defined by the US-ASCII, the result	is un-
       specified.

       If a non-printable character in the charmap has a width specified  that
       is not -1, localedef generates a	warning.

SunOS 5.10			  11 Oct 2004			  localedef(1)

NAME | SYNOPSIS | DESCRIPTION | OPTIONS | OPERANDS | OUTPUT | ENVIRONMENT VARIABLES | EXIT STATUS | FILES | ATTRIBUTES | SEE ALSO | WARNINGS | NOTES

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=localedef&sektion=1&manpath=SunOS+5.10>

home | help