QEMU0002
      ˆÂ‘äÇò 8àd	Dé
ßþÁƒh¹À¿¾  /   ˆ{‹„„-i[D<†ªoZƒ›Ù«Â498_‘I|¥‰ÓMdœv ©ƒ†ü+=ÂÁ      QEMU0002
 ò    ‹      ½”QoÚ0Çßû)n~Ø¹$´¬¢N¦Ž �¢LÓ4MÈ‰±HâÈ1KÛO?‡€ŠVPWMÚ“�óßÿ»ß96}M‹ï³!|^Ü�aöõÓx4 ÒAüÖ F‹¨]¸t\q8!@RcÊ>b]×NÝu”^ãbŽ©É³K¬Œ–‰q¸á$¼ M,¼ š
ÆíÔH“‰pTpñ j¨¶¦’\ø‡Éat}|byÎ8f2FÍ’æ’óLÔLŠ­�5Æ½3�lzÿnn=v¥²x—£™ê�š~±L®‹€U’�Ê|•N‚2QE…qÆŠ�³–+,3ù1LZš´ÙR©«€|“›ipKÂ	Ëm>vZs×jÆ¬2�+.WRð³âûV|/ŸÎF­&U¢ei¤*ž¥h�Q•U%³¬W– ÕÇªVÂ_ë†íêq3f·óád�æmKxcñ\Ý[ŽŠ„3{L…�Hj‘¥÷­çû"®Ê›Ã'ì‹Ôr�tà¤òdÛbS¨º8†³�;‰U‰d«ÅÒn3âÁ8:&á‹ÐqñTë»~¯ãö:Þ5øÝ¾ß8#ì¹×ÿ+OÊesß–™Ìe‹õ"ô–çuüàöúWç±<§ûå<Ö_þ­¸¿ÇwOÅöMúê´èö       ˆÀ¿Ã451¾ÂÁ Ã    ‹      •“QoÓ0…ß÷+.~à­¹m—´9F#©D¥®­º „Nì$ÖÒ8²=Âøõ8Maµƒ=Å±¿{|ÎµM_%«8ý¼žÁ‡ôvë�ïóÈñÓyŒ˜¤É°ã	âlI€TÎµWˆ]×Ýy M‰é+·­C´Î¨ÜÂ	ÂÎh?ÇÎ€V’ÿê”«%›7B~] êg•�^™·-nµ�µE#[m¶Fª–‡"/ƒ{šiñØËO^*å+v6x¶Sì‡†QWÁ7^«²‰ˆÓ-aTmK°&�ª\7³š7÷A©
¼vù2�W_=‡®ê«åPYDä]-¯WÑaK¾õûñãÌíÀ,¸uà�ªBIq¾ópBØ�úqZ0is£Z§tó„¢�x5×µm¹ÏzáTæ�ñ¯nðü�f¬o6³ešÌ7CKD/ñäîÙƒ!lÍ�l$ÊÈÜió¸÷=ˆ¼n2Û^ÿú…½+£ÊÊ0‚£ä¢<4÷�îšÃ4¾SGspk¥³�Éû=<4û—»éxz9‡£é˜Œ¯Âàøöòâ™ÿyn¸¿ÑwOƒâðò~*¤Ü    6   	ˆl–Ü4ý('ÔD¨ õÝÀ;q¦”Å£�þe}èÖmöäÀQÈ ùÅ„q—žgÄÃÂ ?÷     	#!/usr/bin/env python3

### This program is free software; you can redistribute it and/or modify
### it under the terms of the GNU General Public License as published by
### the Free Software Foundation; version 2 only
###
### This program is distributed in the hope that it will be useful,
### but WITHOUT ANY WARRANTY; without even the implied warranty of
### MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
### GNU General Public License for more details.
###
### You should have received a copy of the GNU General Public License
### along with this program; if not, write to the Free Software
### Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
### Copyright 2007-2010 Dag Wieers <dag@wieers.com>

from __future__ import print_function

from distutils.version import LooseVersion
import getopt
import glob
import os
import subprocess
import sys
import time

__version__ = '0.7'

doctypes = ('document', 'graphics', 'presentation', 'spreadsheet')

global convertor, office, ooproc, product
ooproc = None
uno = unohelper = None
exitcode = 0

class Office:
    def __init__(self, basepath, urepath, unopath, pyuno, binary, python, pythonhome):
        self.basepath = basepath
        self.urepath = urepath
        self.unopath = unopath
        self.pyuno = pyuno
        self.binary = binary
        self.python = python
        self.pythonhome = pythonhome

    def __str__(self):
        return self.basepath

    def __repr__(self):
        return self.basepath

### Implement a path normalizer in order to make unoconv work on MacOS X
### (on which 'program' is a symlink to 'MacOSX' which seems to break unoconv)
def realpath(*args):
    ''' Implement a combination of os.path.join(), os.path.abspath() and
        os.path.realpath() in order to normalize path constructions '''
    ret = ''
    for arg in args:
        ret = os.path.join(ret, arg)
    return os.path.realpath(os.path.abspath(ret))

### The first thing we ought to do is find a suitable Office installation
### with a compatible pyuno library that we can import.
###
### See: http://user.services.openoffice.org/en/forum/viewtopic.php?f=45&t=36370&p=166783

def find_offices():
    ret = []
    extrapaths = []

    ### Try using UNO_PATH first (in many incarnations, we'll see what sticks)
    if 'UNO_PATH' in os.environ:
        extrapaths += [ os.environ['UNO_PATH'],
                        os.path.dirname(os.environ['UNO_PATH']),
                        os.path.dirname(os.path.dirname(os.environ['UNO_PATH'])) ]

    else:

        if os.name in ( 'nt', 'os2' ):
            if 'PROGRAMFILES' in list(os.environ.keys()):
                extrapaths += glob.glob(os.environ['PROGRAMFILES']+'\\LibreOffice*') + \
                              glob.glob(os.environ['PROGRAMFILES']+'\\OpenOffice.org*')

            if 'PROGRAMFILES(X86)' in list(os.environ.keys()):
                extrapa