Compiling Webkit-Glib and PyWebkitGTK for Win32

lkcl luke.leighton at googlemail.com
Tue Oct 14 13:12:33 CEST 2008


On Oct 13, 4:03 pm, Propad <npropado... at googlemail.com> wrote:
> > the bottom line is: if you want a windows version of pywebkitgtk, i'm
> > happy to assist and advise anyone of the process- it should be quite
> > straightforward _if_ you have MSVC and follow the standard

> If Visual Studio 2005 suffices, I'd give it a try.

 ok.  let's change the subject....

 it's bog-standard compile-procedure for webkit, under VS, but you
must add in the patch for the glib bindings.

 you'll need a _hell_ of a lot of libraries.  read this:
http://lkcl.net/webkit/cross-compile-gtk.notes.txt

and of course ignore mingw32 bits - use it to track down the locations
for the various libraries in win32 form, including the .a files.
you'll need cairo, gtk, gdk, libxml, libxslt and libicu.  ibm's moved
that on to version 4 and it's compiled up for win32 already.

do make yourself known to the #webkit-gtk team on irc.freenode.net and
ask for their help.

_do_ use the code i have at github.org, use the 16401.master branch, i
do not recommend attempting to use the latest svn plus the patch at
bugs.webkit.org because alp has moved things on a bit and i haven't
the time to update to the latest svn and redo the patch.

   http://github.com/lkcl/webkit/tree/16401.master


then, once you have a libwebkit.dll, you'll be in a position to
recompile pywebkitgtk for windows.  this should be very very
straightforward: there's nothing out-of-the-ordinary, other than you
must patch it, use the last download / attachment from here:

http://code.google.com/p/pywebkitgtk/issues/detail?id=13

i'm not _entirely_ sure how you go about compiling a c-based python
module under windows, esp. one that requires autoconf: perhaps someone
else here can advise, but if i was to be doing it, i'd start off by
installing MSYS, locating a windows version of autoconf and gnu make
and friends, and seeing how far i could get from there.

you'll definitely need a windows version of python-gtk2 first, though,
which will, aside from anything, give you lots of clues as to how to
go about compiling pywebkitgtk - it's exactly the same principle.

the reason why you'll need python-gtk2 is because of codegen.py - that
is used to turn the webkit.defs into a webkit.c file.

good luck! :)

l.



More information about the Python-list mailing list