Comment 11 for bug 499592

Revision history for this message
Steven Sproat (sproaty) wrote :

Thanks, Gian. I will look into it. I hope you don't mind our discussion/progress taking place here.

I've managed to get somewhat further, now.

I added in these exports in the first post to my msys profile, https://bugzilla.gnome.org/show_bug.cgi?id=589671
I downloaded the latest 3 pycairo, gobject and pygtk from here -- http://www.johnstowers.co.nz/blog/index.php/2010/01/22/misc-hacking/

I edited the makefile so that PYTHON_INCLUDE =
(blank)

then the errors about python.h not found stopped, and were referring to glib/poppler.h not found
I took a look at the include argument in config.status and noticed it was E:\Downloads\poppler-dev\include\poppler\glib
I then changed this to E:\Downloads\poppler-dev\include\poppler

Next up was some problem with PyGTK defs:

make[2]: Entering directory `/e/Downloads/pypoppler-0.12.1'
(cd .\
        && /usr/local/bin/python C:/Python26/Lib/site-packages/gtk-2.0/codegen/codegen.py \
                --override poppler.override \
                --register c:/Python26/share/pygtk/2.0/defs/gdk-types.defs \
                --register c:/Python26/share/pygtk/2.0/defs/pango-types.defs \
                --register c:/Python26/share/pygtk/2.0/defs/gtk-types.defs \
                --prefix py_poppler poppler.defs) > gen-poppler.c \
                && cp gen-poppler.c poppler.c \
                && rm -f gen-poppler.c
Traceback (most recent call last):
  File "C:/Python26/Lib/site-packages/gtk-2.0/codegen/codegen.py", line 1720, in <module>
    sys.exit(main(sys.argv))
  File "C:/Python26/Lib/site-packages/gtk-2.0/codegen/codegen.py", line 1678, in main
    p.startParsing()
  File "C:\Python26\Lib\site-packages\gtk-2.0\codegen\scmexpr.py", line 114, in startParsing
    self.handle(statement)
  File "C:\Python26\Lib\site-packages\gtk-2.0\codegen\scmexpr.py", line 118, in handle
    getattr(self, cmd)(*tup[1:])
  File "C:\Python26\Lib\site-packages\gtk-2.0\codegen\defsparser.py", line 33, in include
    raise IOError("%s not found in include path %s" % (input_filename, inc_path))
IOError: gtk/gtk-2.16-types.defs not found in include path ['c:/Python26/share/pygtk/2.0/defs', '.']

As referenced here - https://bugzilla.gnome.org/show_bug.cgi?id=589671#c39
I edited the files in c:/Python26/share/pygtk/2.0/defs to make sure that no includes were prefixed with gtk/

I also had to edit my config.status to change these values:

S["pkgpyexecdir"]="${pyexecdir}/pypoppler"
S["pyexecdir"]="/C/Python26/Lib/site-packages"
S["pkgpythondir"]="${pythondir}/pypoppler"
S["pythondir"]="/C/Python26/Lib/site-packages" as they were set-up wrong

now I have managed to make/make install, but am pretty sure nothing is being done.

$ make
 /bin/sh ./config.status
config.status: creating Makefile
config.status: creating demo/Makefile
config.status: creating config.h
config.status: config.h is unchanged
config.status: executing depfiles commands
config.status: executing libtool commands
make all-recursive
make[1]: Entering directory `/e/Downloads/pypoppler-0.12.1'
Making all in demo
make[2]: Entering directory `/e/Downloads/pypoppler-0.12.1/demo'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/e/Downloads/pypoppler-0.12.1/demo'
make[2]: Entering directory `/e/Downloads/pypoppler-0.12.1'
make[2]: Leaving directory `/e/Downloads/pypoppler-0.12.1'
make[1]: Leaving directory `/e/Downloads/pypoppler-0.12.1'

Steve@STEVEN /e/Downloads/pypoppler-0.12.1
$ make install
Making install in demo
make[1]: Entering directory `/e/Downloads/pypoppler-0.12.1/demo'
make[2]: Entering directory `/e/Downloads/pypoppler-0.12.1/demo'
make[2]: Nothing to be done for `install-exec-am'.
make[2]: Nothing to be done for `install-data-am'.
make[2]: Leaving directory `/e/Downloads/pypoppler-0.12.1/demo'
make[1]: Leaving directory `/e/Downloads/pypoppler-0.12.1/demo'
make[1]: Entering directory `/e/Downloads/pypoppler-0.12.1'
make[2]: Entering directory `/e/Downloads/pypoppler-0.12.1'
test -z "/C/Python26/Lib/site-packages" || /bin/mkdir -p "/C/Python26/Lib/site-packages"
 /bin/sh ./libtool --mode=install /bin/install -c poppler.la '/C/Python26/Lib/site-packages'
libtool: install: /bin/install -c .libs/poppler.lai /C/Python26/Lib/site-packages/poppler.la
libtool: install: /bin/install -c .libs/poppler.a /C/Python26/Lib/site-packages/poppler.a
libtool: install: chmod 644 /C/Python26/Lib/site-packages/poppler.a
libtool: install: ranlib /C/Python26/Lib/site-packages/poppler.a
libtool: install: warning: remember to run `libtool --finish /usr/local\Lib\site-packages'
make[2]: Nothing to be done for `install-data-am'.
make[2]: Leaving directory `/e/Downloads/pypoppler-0.12.1'
make[1]: Leaving directory `/e/Downloads/pypoppler-0.12.1'

I'm not sure why it's telling me to run libtool in /usr/local/Lib -- I haven't mentioned that path anywhere in my config.status file
Anyway, I executed the command it just created a blank directory. in C:\msys\1.0\local\lib\site-packages

C:\Python26\Lib\site-packages has poppler.a (830kb) and poppler.la (1.6kb) files, but no .py/pyd.

I'll keep playing around.