How to regenerate PostgreSQL's internationalized files

Source: Internet
Author: User
Tags postgresql

  1. First, you must specify--enable-nls= "language name" before compiling, otherwise there will be no multilanguage support, such as--enable-nls= "ZH_CN"

      1. Of course disabling the NLS can lead to a negligible performance boost

      2. When enabled we will see in Makefile.global:

        1. Enable_nls= Yes...ifeq ($ (ENABLE_NLS), yes) Ifneq (, $ (wildcard $ (srcdir)/nls.mk)) include $ (top_srcdir)/src/ NLS-GLOBAL.MKENDIF # nls.mkendif # ENABLE_NLS
      3. As you can see, only the directory has nls.mk this file will have the NLS action, with find it is easy to know which directories need to generate. po File

  2. Let's say we modify the output information of INITDB.

      1. CD Src/bin/initdb

      2. Make Update-po

      3. From the output text can be seen, initdb.pot (translation template) regenerated, and only we need to ZH_CN is merge, generate a new file zh_CN.po.new

  3. Open zh_CN.po.new Edit, change to Zh_cn.po after completion

  4. Make All-po to this point, the new. Mo file has been regenerated

  5. Graphical. po file editing tools recommended: http://poedit.net/, if not open, please turn over the wall.


Shenzhou Flying Elephant (Beijing) Data Technology Co., Ltd.



How to regenerate PostgreSQL's internationalized files

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.