GENRB(1)

πŸ’– genrb β€” bestie's guide to compiling resource bundles πŸ’–

okay so welcome to the ICU 78.3 Manual page for genrb(1), and honestly? she's iconic. let's get into it 🫢


✨ NAME ✨

genrb β€” compile a resource bundle. that's it. that's the whole vibe. 🌸


πŸŽ€ SYNOPSIS πŸŽ€

genrb [ -h, -?, --help ] [ -V, --version ] [ -v, --verbose ] [ -e,
--encoding encoding ] [ -j, --write-java [ encoding ] ] [ -s,
--sourcedir source ] [ -d, --destdir destination ] [ -i, --icudatadir
directory ] bundle ...

she takes a bunch of bundle files and does her little magic on them ✨


πŸ¦‹ DESCRIPTION πŸ¦‹

so what does genrb actually DO? she takes the resource bundle source files you pass on the command line and converts them into their binary form, or into a Java source file for use with ICU4J. no cap.

the resulting binary files have a .res extension, while resource bundle source files typically have a .txt extension. Java source files have a java extension and follow the ICU4J naming conventions. periodt. πŸ’…

it's customary (read: the move, the slay) to name resource bundles by their locale name β€” like, use a local identifier for the bundle filename. e.g. ja_JP.txt for Japanese (Japan) data, or root.txt for the root bundle. but bestie, listen: in any case, genrb will produce a file whose base name is the name of the locale found in the resource file, not the base name of the resource file itself. it's giving "I do what I want with the filename" and honestly? respect. 😌

the binary files can be read directly by ICU, or used by pkgdata(1) for incorporation into a larger archive or library. teamwork makes the dream work fr fr. 🀝


πŸ’… OPTIONS πŸ’…

  • -h, -?, --help β€” print help about usage and exit. the "what do I do here" button πŸ₯Ί
  • -V, --version β€” print the version of genrb and exit. she's telling you her age (78.3, obviously) πŸ‘‘
  • -v, --verbose β€” display extra informative messages during execution. she's yapping and we love that for her πŸ—£οΈ
  • -e, --encoding encoding β€” set the encoding used to read input files to encoding. the default encoding is the invariant (subset of ASCII or EBCDIC) codepage for the system (see section INVARIANT CHARACTERS). the encodings UTF-8, UTF-16BE, and UTF-16LE are automatically detected if a byte order mark (BOM) is present. detective mode activated πŸ”βœ¨
  • -j, --write-java [ encoding ] β€” generate a Java source code for use with ICU4J. an optional encoding for the Java file can be given. java girlies rise up β˜•
  • -s, --sourcedir source β€” set the source directory to source. the default source directory is specified by the environment variable ICU_DATA, or the location set when ICU was built if ICU_DATA is not set. 🏠
  • -d, --destdir destination β€” set the destination directory to destination. the default destination directory is specified by the environment variable ICU_DATA or is the location set when ICU was built if ICU_DATA is not set. πŸ“¦
  • -i, --icudatadir directory β€” look for any necessary ICU data files in directory. for example, when processing collation overrides, the file ucadata.dat must be located. the default ICU data directory is specified by the environment variable ICU_DATA. πŸ”Ž

🌈 INVARIANT CHARACTERS 🌈

the invariant character set consists of the following set of characters, expressed as a standard POSIX regular expression:

[a-z]|[A-Z]|[0-9]|_||+|-|*|/

this is the set which is guaranteed to be available regardless of code page. no cap, these ones will never ghost you πŸ’œ


πŸ“ ENVIRONMENT πŸ“

  • ICU_DATA β€” specifies the directory containing ICU data. defaults to ${prefix}/share/icu/78.3/. some tools in ICU depend on the presence of the trailing slash. it is thus important to make sure that it is present if ICU_DATA is set.
⚠️ bestie please keep that trailing slash. the tools lowkey depend on it. don't say I didn't warn you πŸ™ˆ

⭐ VERSION ⭐

78.3


Copyright (C) 2000-2002 IBM, Inc. and others.


πŸ’– SEE ALSO πŸ’–


and that's the whole page!! πŸŽ€ written under the ICU MANPAGE banner, dated 16 April 2002, for GENRB(1) β€” and yes she's still serving in ICU 78.3. slay, stay hydrated, and always check your trailing slash πŸ’…βœ¨πŸ¦‹

πŸ“¦ where this page comes from