[Po4a-devel] po4a::tex 'Use of uninitialized value $newfilepath' error

Denis Barbier bouzim at gmail.com
Sun Dec 19 18:41:58 UTC 2010


On 2010/12/19 Sergiy Kolesnikov wrote:
> Hi,
>
> on running
>  $ po4a po4a.cfg
> or
>  $ po4a --force po4a.cfg
>
> I get the following error:
>
> Use of uninitialized value $newfilepath in string eq at
> /usr/share/perl5/Locale/Po4a/TeX.pm line 962.
> po4a::tex: Can't find latex/en/iTest-Documentation.tex with kpsewhich
>
> My po4a.cfg:
>
> [po_directory] po
> [type: latex] latex/en/iTest-Documentation.tex \
>              $lang:latex/$lang/iTest-Documentation.tex
> [type: latex] latex/en/iTestServer.tex $lang:latex/$lang/iTestServer.tex
> [type: latex] latex/en/iTestClient.tex $lang:latex/$lang/iTestClient.tex
>
> And my project directory structure:
> .
> |-- latex
> |   |-- en
> |   |   |-- header.tex
> |   |   |-- iTest-Documentation.tex
> |   |   |-- iTestClient.tex
> |   |   `-- iTestServer.tex
> |   `-- uk
> |-- po
> |   |-- itest.pot
> |   `-- uk.po
> `-- po4a.cfg
>
> The only way to get rid of the error is to put the tex files into the root
> directory of the project and change the po4a.cfg accordingly, but it is not
> that convenient to have the files there.
>
> I read man po4a and still not sure if it is a misconfiguration of mine or a
> bug in po4a.  Any help is appreciated.

Hello,

I do not know this module well, but according to sources, the TeX
module has been designed to recognize the \input and \include
commands; you can put only your main document into po4a.cfg, po4a will
automatically adds contents of included files.
I do not fully understand why it works this way, but you may prevent
this error by adding (on a single line)
   [po4a_alias:latex] latex opt:"-o
exclude_include=iTest-Documentation.tex:iTestServer.tex:iTestClient.tex"
in your po4a.cfg file.

Denis



More information about the Po4a-devel mailing list