According http://sphinx-doc.org/config.html#options-for-internationalization
The language should support zh_CN, however I changed language to zh_CN, it raise following error and can not generate pdf.
#!shell
docs $ make html
.....
processing phone-buddy-ng.tex... index overview network software hardware deployment
resolving references...
writing... WARNING: no Babel option known for language 'zh_CN'
done
detail error log:
#!tex
$ xelatex *.tex
.......
.......
.......
(./sphinxmanual.cls
Document Class: sphinxmanual 2009/06/02 Document class (Sphinx manual)
(/usr/local/texlive/2012/texmf-dist/tex/latex/base/report.cls
Document Class: report 2007/10/19 v1.4h Standard LaTeX document class
(/usr/local/texlive/2012/texmf-dist/tex/latex/base/size12.clo)))
(/usr/local/texlive/2012/texmf-dist/tex/latex/base/inputenc.sty
(/usr/local/texlive/2012/texmf-dist/tex/latex/base/utf8.def
(/usr/local/texlive/2012/texmf-dist/tex/latex/base/t1enc.dfu)
(/usr/local/texlive/2012/texmf-dist/tex/latex/base/ot1enc.dfu)
(/usr/local/texlive/2012/texmf-dist/tex/latex/base/omsenc.dfu)))
(/usr/local/texlive/2012/texmf-dist/tex/latex/base/fontenc.sty
(/usr/local/texlive/2012/texmf-dist/tex/latex/base/t1enc.def))
(/usr/local/texlive/2012/texmf-dist/tex/generic/babel/babel.sty
! Package babel Error: You haven't specified a language option.
See the babel package documentation for explanation.
Type H <return> for immediate help.
...
l.149 ...ry to proceed from here, type x to quit.}
?
Is there anything missing ?
_From Georg Brandl on 2013-04-01 10:28:25+00:00_
I'm guessing that Chinese (and Korean) need special support similar to Japanese, which is already handled special (see sphinx/writers/latex.py line 225.)
_From Georg Brandl on 2013-04-01 10:28:54+00:00_
If you know how to best produce LaTeX documents in Chinese, it would be great to work on a patch.
_From Santiago Gala on 2014-12-03 22:08:06+00:00_
I'm seeing exactly the same problem with spanish and 'es': html gets produced correctly, but latexpdf ends with the error: "! Package babel Error: You haven't specified a language option." I'm guessing something else is needed in the latex part of sphinx.
_From Santiago Gala on 2014-12-03 22:10:01+00:00_
This https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=712772 seems to be it
If no special support for Chinese until 1.5-b1 release, I will postpone this to "some future version".
We always need support to resolve i18n problem like this.
same problem here
Some Chinese developer there ?
I see the issue is still open and, thus, I get the same warnings when trying to generate Simplified Chinese (zh_CN) translations:
[exec] WARNING: no Babel option known for language u'zh_CN'
[exec] WARNING: no Babel option known for language u'zh_CN'
[exec] WARNING: no Babel option known for language u'zh_CN'
[exec] WARNING: no Babel option known for language u'zh_CN'
[exec] WARNING: no Babel option known for language u'zh_CN'
I also tried (zh), but I still get the same results:
[exec] WARNING: no Babel option known for language u'zh'
[exec] WARNING: no Babel option known for language u'zh'
[exec] WARNING: no Babel option known for language u'zh'
[exec] WARNING: no Babel option known for language u'zh'
[exec] WARNING: no Babel option known for language u'zh'
Are there any plans to fix this issue?
@Znni
I got the error message too
@Znni We received #3272, but reviewing and discussion is stopped now. So we have to improve it and merge into sphinx-core. If you're interested in, please check it.
This was already fixed by #6398.
Closing now.
Most helpful comment
I see the issue is still open and, thus, I get the same warnings when trying to generate Simplified Chinese (zh_CN) translations:
[exec] WARNING: no Babel option known for language u'zh_CN'[exec] WARNING: no Babel option known for language u'zh_CN'[exec] WARNING: no Babel option known for language u'zh_CN'[exec] WARNING: no Babel option known for language u'zh_CN'[exec] WARNING: no Babel option known for language u'zh_CN'I also tried (zh), but I still get the same results:
[exec] WARNING: no Babel option known for language u'zh'[exec] WARNING: no Babel option known for language u'zh'[exec] WARNING: no Babel option known for language u'zh'[exec] WARNING: no Babel option known for language u'zh'[exec] WARNING: no Babel option known for language u'zh'Are there any plans to fix this issue?