Re: [PyCUDA] mac64 PyCUDA

2010-09-20 Thread Bryan Catanzaro
I think it should be changed to check to see if the Python interpreter is currently running in 32 bit mode, and then compile to match: if 'darwin' in sys.platform and sys.maxint == 2147483647: # The Python interpreter is running in 32 bit mode on OS X if -arch not in conf[CXXFLAGS]:

Re: [PyCUDA] mac64 PyCUDA

2010-09-20 Thread MinRK
Bryan, Note that in 3.2, all files in cuda/lib are UB, including cudart (finally!). I build fat-binary on OS-X (up to date 10.6.4, cuda 3.2, etc.), simply by setting the usual arch flags in siteconf.py: CXXFLAGS = [-arch, x86_64, -arch, i386] LDFLAGS = [-arch, x86_64, -arch, i386] The build

Re: [PyCUDA] mac64 PyCUDA

2010-09-20 Thread MinRK
Okay, with a tiny tweak to compiler.compile, I have UB pycuda working in both 64 and 32-bit. All I did was tell compile() to add '-m64' to options if it detects 64-bit mode, in the same way as Bryan's trick. I pushed a branch with the patch to my GitHub: http://github.com/minrk/pycuda, as well

Re: [PyCUDA] mac64 PyCUDA

2010-09-20 Thread Art
On Mon, Sep 20, 2010 at 2:08 PM, MinRK mi...@berkeley.edu wrote: Okay, with a tiny tweak to compiler.compile, I have UB pycuda working in both 64 and 32-bit. All I did was tell compile() to add '-m64' to options if it detects 64-bit mode, in the same way as Bryan's trick. I pushed a branch