Skip to content

Modules on Windows and last bits of Summer Of Code

I just commited the last lines to make mmap module compile as a shared library (DLL) on our beloved Windows platform.

I first tried porting my implementation of time module to Windows and it was a lot easier than I thought. Ok… easier… let’s go back a moment. I have to be fair to myself and you reader so I have to summarize what you should to achieve the same goal to make PyPy’s modules toolchain work in Windows:

  • install MS .NET 1.1
  • install MS .NET SDK 1.1
  • install MS Platform SDK for Windows 2003 Server (I have XP in Parallels, but there’s only that available)

After this giga-byte-loola-palooza-taking-ages-to-install you go underground this way:

  • ‘search’ and download the MS Visual C++ 2003 Toolkit that MS kindly retired from its download center after telling everyone it was free for everybody. (I still don’t understand why the biggest company in the world can’t let somewhere in a repository its old packages. I can give you some webspace MS, call me!)
  • hack (I mean H-A-C-K) distutils to make the dream come true. Thank you Mike Fletcher!
  • inject basically every \bin, every \lib, every \include in my entire file system into the batch file. (I always hated DOS batch files, even when I had only DOS 3.0 on the computer. Come on MS, show me what you got!)
  • last but not least: cross your 20 fingers. (remember my fellow Jedi, also the feet have fingers)

I forgot to mention that this easy procedure worked eventually and I was really happy the way things gone. I still hope Martin von Löwis will change its mind sometimes about sticking with the 2003 version of the MS C++ compiler but now that I mastered it, it’s not that urgent.

The implementation of time in Windows lacks altzone, tzname, daylight and timezone because of some limitations in PyPy (I can’t use in_dll() to export global variables) but everything else works well. The other module, mmap, should be equal to the POSIX version.

My Summer of Code project is basically finished and I’ll surely post a report of my experience after the official deadline.

Share and Enjoy:
  • Print
  • Digg
  • StumbleUpon
  • Facebook
  • Twitter
  • Google Bookmarks
  • FriendFeed
  • Google Buzz
  • HackerNews
  • Posterous
  • Reddit
  • Slashdot
  • Tumblr