title: Intel Compiler and Python/ctypes/libffi
body: <p>I am having trouble building a working version of Python with ctypes using the Intel Compiler (11.1). The trouble is, that libffi under the ctypes module does not work properly when interfacing with e.g. OpenGL.</p>
  
  <p>Originally, libffi did not compile using the Intel Compilers as <code>__int128_t</code> is not defined, and I followed the work around that has been listed several places, namely by defining a new type:</p>
  
  <p><code>typedef struct { int64_t m[2]; } __int128_t;</code></p>
  
  <p>This follows a response as given by Intel : <a href="http://software.intel.com/en-us/forums/showthread.php?t=56652" rel="nofollow noreferrer">http://software.intel.com/en-us/forums/showthread.php?t=56652</a> </p>
  
  <p>The patch then suggests something like this:</p>
  
  <pre><code>typedef struct { int64_t m[2]; } __int128_t;
  //and then change where the uint64_t is assigned to this to be:
  sse[x].m[0] = *(uint64_t*) v;
  sse[x].m[1] = 0;
  //and where the uint32_t is assigned to:
  sse[x].m[0] = *(uint32_t*) v;
  sse[x].m[1] = 0;
  </code></pre>
  
  <p>Applying the patch, things compile, and <code>ctypes</code> becomes available for import, however, when interfacing with OpenGL, things do not work. Running PyQt's example program <code>hellogl.py</code> results in a blank view.</p>
  
  <p>Is there a better, working way of doing this?</p>
  
  <p>Dan;</p>