|
From: | Hans Nuecke (vservu) |
Subject: | Re: [Swftools-common] Using rfxview on website |
Date: | Mon, 08 Nov 2010 22:31:25 +0100 |
User-agent: | Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.12) Gecko/20101027 Thunderbird/3.1.6 |
On 04.11.2010 14:59, Chris wrote:
Chris,On Thu, 04 Nov 2010 14:53:09 +0100 "Hans Nuecke (vservu)" <address@hidden> wrote:Hi Chris, your email made me try to install the Python gfx module; finally ;-) So far I used pdf2swf in a batch file...ui But: during the "python setup.py build" process I get the an error File "setup.py", line 4, in <module> from distutils.core import CompileError ImportError: cannot import name CompileError When I take the statement with the import out (in setup.py: "from distutils.core import CompileError") I get the next error (no surprise): "NameError: global name 'CompileError' is not defined" There is a try-except in line 105 that tests for CompileError. Which could not be loaded. I got stuck here and couldn't find a solution so far.afaicr the problem is that CompileError no longer exists in distutils.core with Python 2.7. Commenting out the import line at the top of setup.py, allows the build process to proceed, but the gfx module doesn't actually get created. Have you tried the alternative manual install instructions here? http://wiki.swftools.org/index.php/Python_gfx_tutorialHere my config: Windows7 64 Python 2.7 (I tried both 64 and 32 bit) Latest swftools-2010-10-12-2000 download I will check if it installs under Windows XP with Python 2.6. But if someone has an idea how to get the setup.py working under Python27 and Win7 would be great!It should do since the changes only affect Python 2.7 and up. That said, it's been a good while since I compiled gfx. pdf2swf is not something I tend to use that often, if at all, and neither is gfx. I will go back and look though.Thanks for your great work and support!While it's good to be appreciated, cheers for that, there's not just me here you know (although it sometimes feels that way )! ;o) Besides which, my fields of endeavour are rather limited. Regards, Chris. sorry for my late reply, my hard disk had a problem and I had to setup a new one... Now I did some tests, browsed some forums, analyzed a bit the setup.py file and installed different versions of Python on my 64bit win7. I did not succeed yet, so my last option really will be to install VS2008 or run the compile on a windows xp system with vs2008. One of the comments that confirms my suspects was found here: http://www.eggheadcafe.com/software/aspnet/35969079/download-visual-studio-express-2008-now.aspx Python 2.6, 2.7, and 3.1 are all built with that release (i.e. 2008). Because of another long tradition, Python extension modules must be built with the same compiler version (more specifically, CRT version) as Python itself. So to build extension modules for any of these releases, you need to have a copy of VS 2008 or VS 2008 Express.I tried some patches as recommended here: http://nukeit.org/compile-python-2-7-packages-with-visual-studio-2010-express/ I even installed the setuptools to install a patch utility: http://pypi.python.org/pypi/setuptools#downloads and checked my registry. But still: the mscv9compiler identified version 9 as my vs version with resulting wrong path names. And as consequence the "except CompileError" because the query_vcvarsall failed and vcvarsall.bat could not be found. This batch file to my understanding is needed to patch some more variables to make the compiler run under a 64 bit system. Since I'm not sure if the compiled version would work together with my Python27 (see first link), I for now gave up. If someone successfully could compile swftools for python27 under win7 64 bit I would be happy to know how that was achieved; or to get a compiled lib. Thanks Hans |
[Prev in Thread] | Current Thread | [Next in Thread] |