I am using unoconv
to convert different file formats to pdf. It is working well on my local machine for all formats. But on my ubuntu 12.04 server unoconv
is failing for some formats such as xls, ppt, pptx etc. However it is working fine for doc files. It shows the following error for the ppt conversion.
$unoconv -f pdf Googling.ppt
unoconv: UnoException during conversion in <class '__main__.com.sun.star.lang.IllegalArgumentException'>: Unsupported URL <file:///home/pythonuser/almamapper/media/library/files/c1cb92e62ce54b29a017a6e8eaa23c/Googling.ppt>: ""
Traceback (most recent call last):
File "/usr/bin/unoconv", line 790, in <module>
main()
File "/usr/bin/unoconv", line 769, in main
convertor.convert(inputfn)
File "/usr/bin/unoconv", line 679, in convert
error("ERROR: The provided document cannot be converted to the desired format. (code: %s)" % e.ErrCode)
File "/usr/lib/python2.7/dist-packages/uno.py", line 337, in _uno_struct__getattr__
return __builtin__.getattr(self.__dict__["value"],name)
AttributeError: ErrCode
I know I have to install openoffice-headless version on my server. But from this link I understand that Ubuntu switched to libreoffice instead of openoffice quite a while ago. So I installed libreoffice by the following command.
apt-get install libreoffice-core libreoffice-writer libreoffice-calc
But still am getting the same error. Am I missing something to install? Do anyone have any thoughts on this issue?