Re: Building on Win7 x64 for python2.6.4 x64 DLL load failed Error

From: Daniele Varrazzo <daniele(dot)varrazzo(at)gmail(dot)com>
To: Jack Straw <jack(dot)straw(at)saddingtonbaynes(dot)com>
Cc: "psycopg(at)postgresql(dot)org" <psycopg(at)postgresql(dot)org>
Subject: Re: Building on Win7 x64 for python2.6.4 x64 DLL load failed Error
Date: 2013-11-28 17:41:14
Message-ID: CA+mi_8YtOTmrGNBTSSVPPzQiVEwgAqA_uh6Ka7qohVMm4H9EQg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: psycopg

On Thu, Nov 28, 2013 at 5:26 PM, Jack Straw
<jack(dot)straw(at)saddingtonbaynes(dot)com> wrote:
> Hi,
>
> I am trying to build psycopg2 for a version of python that is packaged with
> the 3D creation package Maya (version 2013). I can build and install
> psycopg2 to the python install but when load the module I get the following
> error;
>
> # Error: ImportError: file C:\Program
> Files\Autodesk\Maya2013\Python\lib\site-packages\psycopg2\__init__.py line
> 50: DLL load failed: %1 is not a valid Win32 application. #
>
> My build process is;
>
> Run the x64 VS9 build environment setup script
> Build the cextenstion, including the right libs and headers; "C:\Program
> Files\Autodesk\Maya2013\bin\mayapy.exe" setup.py build_ext -"IC:\Program
> Files\Autodesk\Maya2013\include\python2.6" -"LC:\Program
> Files\Autodesk\Maya2013\lib"
> Build the rest of the module
> Install

Smells like a 32/64 bit mess-up between Maya, Python and the compiler.

Googling "python DLL load failed: %1 is not a valid Win32 application"
yields lots of result, for example

http://stackoverflow.com/questions/4676433/solving-dll-load-failed-1-is-not-a-valid-win32-application-for-pygame

Particularly interesting is this resource:

http://www.lfd.uci.edu/~gohlke/pythonlibs/#psycopg

offering alternative win builds of psycopg.

-- Daniele

In response to

Responses

Browse psycopg by date

  From Date Subject
Next Message Jack Straw 2013-11-28 17:58:28 Re: Building on Win7 x64 for python2.6.4 x64 DLL load failed Error
Previous Message Jack Straw 2013-11-28 17:40:17 Re: Building on Win7 x64 for python2.6.4 x64 DLL load failed Error