Tuesday, July 06, 2010

How do I install RomDev mapping for XeLaTeX (Unicode transliteration -> Devanāgarī)?

[Update, February 2011: Somdev has moved his blog to http://pratibham.blogspot.com/.]

Somdev Vasudev's RomDev mapping is installed as follows:
  1. The actual mapping file is published by Somdev in his blog, here:
    http://sarasvatam.blogspot.com/2010/03/updated-teckit-romdev.html 
    [Update Feb 2011: now at http://pratibham.blogspot.com/2010/03/updated-teckit-romdev.html; update March 2012: now at https://github.com/somadeva/RomDev]
  2. Cut and paste this text, and save it in a Unicode file called RomDev.map.  Save that file in a place which XeTeX can "see," e.g., something like local/texmf/fonts/misc/xetex/fontmapping/
  3. You now need to compile the human-readable *.map file into a binary *.tec file, so that XeTeX can read it directly.  This is done by the program Teckit, which you can get here:
    http://scripts.sil.org/cms/scripts/page.php?site_id=nrsi&item_id=TECkitDownloads
  4. I'm working with Ubuntu GNU/Linux.  For me, the command is,

    teckit_compile RomDev.map -o RomDev.tec

    I'm afraid I don't know the Windows or Mac command invocation.

  5. Now you have a file in a place like
    local/texmf/fonts/misc/xetex/fontmapping/RomDev.tec

  6. Run the command that rebuilds the database of files that TeX knows about.  In Linux it's
    sudo mktexlsr
  7. That's it!  XeTeX and XeLaTeX can now see, and make use of the RomDev mapping, that converts Unicode transliteration into Devanāgarī, as exemplified in my earlier blog posts below. 

    10 comments:

    1. Somdev has made a ready-compiled copy of RomDev.tec for the Mac available for download. This is only for Mac users. See the following links:

      http://indology.info/etexts/archive/software/RomDev.readme

      http://indology.info/etexts/archive/software/RomDev.zip

      ReplyDelete
    2. This worked like a charm.

      Many thanks for all the time and energy spent in making RomDev available!

      ReplyDelete
    3. This worked like a charm.

      Many thanks for all the time and energy spent in making RomDev available!

      Tim Lighthiser

      ReplyDelete
    4. You're very welcome. I'll pass your appreciation on to Somdev.

      ReplyDelete
    5. Dominik, how did you install TECkit on Ubuntu? I'm running Debian Testing and compiled from source, but continually get the following error message when I run the teckit_compile command:

      teckit_compile: error while loading shared libraries: libTECkit_Compiler.so.0: cannot open shared object file: No such file or directory

      (The file is there and seems to have all the right permissions, though)

      It seems Ubuntu users run into the same problem (or so Google tells me), but I haven't seen a solution yet. Did you find a way around this?

      ReplyDelete
    6. Dear Urukrama, an executable Linux teckit_compile is included in the TeXlive 2010 distribution.

      I recently tried to compile teckit_compile ab initio, but it failed. I didn't solve the problem, since finding a working binary already in the texlive distribution.

      There's an active and friendly discussion list for XeTeX matters, like this one. See
      http://www.tug.org/mailman/listinfo/xetex

      You'll find several people there who know much more than me about XeTeX matters, including Jonathan Kew.

      Best,
      Dominik

      ReplyDelete
    7. Although the compiled TEC file for RomDev is available, for Mac users who wish to install a Mac version of teckit to run on other maps, one can be retrieved from http://scripts.sil.org/cms/scripts/page.php?site_id=nrsi&id=TECkitDownloads

      If that link is too long, here is a shorter one:
      http://tinyurl.com/3vp3k63

      It must be run in a terminal window from the command line. Mac OS X is, after all, a fancy Apple GUI atop r a Linux operating system.

      Richard

      ReplyDelete
    8. I did not know I had to run mktexlsr at the end, and was struggling. Thanks for the tip!

      ReplyDelete
    9. Now pratibham.blogspot.com disappeard as well. Does anybody know about another source for the mapping file?

      ReplyDelete
    10. https://github.com/somadeva/RomDev

      ReplyDelete