469,353 Members | 2,066 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,353 developers. It's quick & easy.

pywin32 support for CreateTypeLib2

I was just wondering if there are any plans to support the
CreateTypeLib2 API either instead of, or in addition to, the
CreateTypeLib API.

I am currently using pythoncom to generate type libraries, but
I ran into an issue supporting optional parameters. After a
lot of digging I discovered that the old CreateTypeLib API doesn't
support them. I have currently built a custom version of pywin32
that uses the new CreateTypeLib2 API, and everything works great.
I'm hoping that the CreateTypeLib2 support can be added to the
official release.
Thanks,
Phil

Jul 18 '05 #1
4 1731
Since you already have working code, the best bet would be
to submit a patch to the Pywin32 project on Sourceforge.
It would probably go over better as an addition rather than a
replacement so it doesn't break any working code.
Roger

"Philip Rittenhouse" <ph***@dspfactory.com> wrote in message
news:MP************************@nntp.wcom.ca...
I was just wondering if there are any plans to support the
CreateTypeLib2 API either instead of, or in addition to, the
CreateTypeLib API.

I am currently using pythoncom to generate type libraries, but
I ran into an issue supporting optional parameters. After a
lot of digging I discovered that the old CreateTypeLib API doesn't
support them. I have currently built a custom version of pywin32
that uses the new CreateTypeLib2 API, and everything works great.
I'm hoping that the CreateTypeLib2 support can be added to the
official release.
Thanks,
Phil

Jul 18 '05 #2
Philip Rittenhouse <ph***@dspfactory.com> writes:
I was just wondering if there are any plans to support the
CreateTypeLib2 API either instead of, or in addition to, the
CreateTypeLib API.

I am currently using pythoncom to generate type libraries, but
I ran into an issue supporting optional parameters. After a
lot of digging I discovered that the old CreateTypeLib API doesn't
support them. I have currently built a custom version of pywin32
that uses the new CreateTypeLib2 API, and everything works great.
I'm hoping that the CreateTypeLib2 support can be added to the
official release.


As Roger already said, upload a patch to the pywin32 project.

OTOH, it should (hopefully!) been easier to do it with ctypes - I assume
creating typelibs isn't that performance critical. Currently ctypes.com
can use but not create typelibs: readtlb.py creates ctypes Python
wrappers from type libraries - my plan it to also create typelibs from
the Python wrappers.

Thomas
Jul 18 '05 #3
"Roger Upole" <ru****@hotmail.com> wrote in message news:<40********@127.0.0.1>...
For some reason, the name of lib file that comes with the
active debugging kit has changed. I had to modify the
project options for library files and replace msdbg.lib with ad1.lib.

Roger


Thanks Roger.

I have uploaded the patch (finally), but I ran into a few other build
issues that I'd like to share in case someone else runs into them,
or there are better solutions than what I used.

o In setup_win32all.py, the "pre_install_script" option does not appear to be
supported by any version of distutils I could find. Is it a customization?
I just commented it out to get things to build.

o The following files appear to be missing from the source distribution for
build 201:

com/win32comext/taskscheduler/src/PyIProvideTaskPage.cpp
com/win32comext/taskscheduler/src/PyIProvideTaskPage.h
pywin32_preinstall.py
PyWin32.chm

I copied these from CVS, except for PyWin32.chm, which I copied from
site-packages after installing build 201.

o In addition to the MS Platform SDK you need the source files from Microsoft's
Scriptng.exe zip file. Copy them all to: \com\win32comext\AXDebug\src

Phil
Jul 18 '05 #4
ph**@dspfactory.com (Phil Rittenhouse) writes:
"Roger Upole" <ru****@hotmail.com> wrote in message news:<40********@127.0.0.1>...
For some reason, the name of lib file that comes with the
active debugging kit has changed. I had to modify the
project options for library files and replace msdbg.lib with ad1.lib.

Roger


Thanks Roger.

I have uploaded the patch (finally), but I ran into a few other build
issues that I'd like to share in case someone else runs into them,
or there are better solutions than what I used.

o In setup_win32all.py, the "pre_install_script" option does not appear to be
supported by any version of distutils I could find. Is it a customization?
I just commented it out to get things to build.


It is officially supported in the Python CVS version.
Maybe it should go into the 2.3 branch, but this would break the 'no new
features' policy.

But you can copy the head CVS distutils tree into the Python 2.3
installation, and then build the installer with 2.3.

Thomas
Jul 18 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Michael Jordan | last post: by
4 posts views Thread by Bob Chapman | last post: by
reply views Thread by Aljosa Mohorovic | last post: by
5 posts views Thread by Egor Bolonev | last post: by
1 post views Thread by mg | last post: by
2 posts views Thread by Chris Lott | last post: by
1 post views Thread by livibetter | last post: by
7 posts views Thread by vml | last post: by
1 post views Thread by kernel1983 | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by zhoujie | last post: by
reply views Thread by suresh191 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.