[Libreoffice] [PATCH] Make pyuno work with system python

Petr Mladek pmladek at suse.cz
Mon Aug 22 10:12:55 PDT 2011

Caolán McNamara píše v Po 22. 08. 2011 v 11:00 +0100:
> On Mon, 2011-08-22 at 11:36 +0200, Tomáš Chvátal wrote:
> > Should apply to master, worth backporting to 3.4.
> I've hacked around this with...
> echo "import sys, os" > uno.py
> echo "sys.path.append('%{basisinstdir}/program')" >> uno.py
> echo "os.putenv('URE_BOOTSTRAP', 'vnd.sun.star.pathname:
> %{baseinstdir}/program/fundamentalrc')" >> uno.py
> cat $RPM_BUILD_ROOT/%{basisinstdir}/program/uno.py >> uno.py
> in our own spec for a while, so integrating the fix would be good.
> However....
> a) do we need the PYTHONPATH hack in soffice.sh, I seem to be able to
> get away without it ?

I guess that PYTHONPATH hack in soffice.sh is not needed when you
install uno.py and unohelper.py into %{python_sitearch}. It might be
needed when you keep it in libreoffice/basis dir.

Hmm, the strange thing is that I did not apply this patch, did not
move .py stuff and the mail merge stuff works in the openSUSE packages.

Is the hack with uno.py needed at all?
Do I test the python stuff a wrong way?

Best Regards,

More information about the LibreOffice mailing list