[Tutor] Problem installing the Pymqi module
Robert, Andrew
ARobert at MFS.com
Thu Apr 7 20:12:52 CEST 2005
Hi Everyone,
I've tried installing the pymqi Python module on Windows but no luck so
far.
Has anyone had any success in doing this?
Any help you can provide on this would be greatly appreciated.
To install the module under Python v2.4, I did the following steps:
1. Download MinGW Gcc from http://mingw.org
2. Install MinGW GCC
3. Edit path and add GCC area c:\MinGW\bin
4. Verify that GCC is functioning
c:\ gcc --version
5. Download pexports from
http://starship.python.net/crew/kernr/mingw32/.
6. Extract pexports to C:\pexports
7. Add C:\pexports\pexports-0.42h\bin to path
8. Locate the file python2?.dll
On windows XP with Python v2.4 installed, it is typically found as
C:\WINDOWS\system32\python24.dll
9. Open a command prompt
10. Change your working directory to C:\WINDOWS\system32
11. Extract all of the symbols from the Python library
C:\WINDOWS\system32\ pexports python24.dll > python24.def
12. Create a new python library
C:\WINDOWS\system32\dlltool --dllname python24.dll --def
python24.def --output-lib libpython24.a
The dlltool command is part of the MinGW utilities
13. Copy the newly created python library to its permanent location
C:\WINDOWS\system32\copy libpython24.a C:\Python24\lib
14. Download pymqi from
http://prdownloads.sourceforge.net/pymqi/pymqi-0.5c.tar.gz?download and
extract to c:\pymqi
15. Edit the file C:\pymqi\pymqi-0.5c\setup.py and change include_dirs
to the following path and save
C:/Program Files/IBM/WebSphere MQ/Tools/Lib
16. Open command prompt and change working directort to
C:\pymqi\pymqi-0.5c
17. Initiate a client or server build
For a client:
setup.py build -cmingw32 client
For a server:
setup.py build -cmingw32 server
In either case, I received the following compile errors.
pymqe.c:78:18: cmqc.h: No such file or directory
pymqe.c:79:19: cmqxc.h: No such file or directory
pymqe.c: In function `pymqe_MQCONN':
pymqe.c:130: `MQHCONN' undeclared (first use in this function)
pymqe.c:130: (Each undeclared identifier is reported only once
pymqe.c:130: for each function it appears in.)
pymqe.c:130: parse error before "handle"
pymqe.c:131: `MQLONG' undeclared (first use in this function)
pymqe.c:137: warning: implicit declaration of function `MQCONN'
pymqe.c:137: `handle' undeclared (first use in this function)
pymqe.c:137: `compCode' undeclared (first use in this function)
pymqe.c:137: `compReason' undeclared (first use in this function)
pymqe.c: In function `pymqe_MQCONNX':
pymqe.c:162: `MQHCONN' undeclared (first use in this function)
pymqe.c:162: parse error before "handle"
pymqe.c:163: `MQLONG' undeclared (first use in this function)
pymqe.c:166: `MQCNO' undeclared (first use in this function)
pymqe.c:166: parse error before "connectOpts"
pymqe.c:181: `options' undeclared (first use in this function)
pymqe.c:186: `MQCD_CURRENT_LENGTH' undeclared (first use in this
function)
pymqe.c:199: `connectOpts' undeclared (first use in this function)
pymqe.c:199: `MQCNO_VERSION_2' undeclared (first use in this function)
pymqe.c:201: `MQCD' undeclared (first use in this function)
pymqe.c:201: parse error before ')' token
pymqe.c:205: warning: implicit declaration of function `MQCONNX'
pymqe.c:205: `handle' undeclared (first use in this function)
pymqe.c:205: `compCode' undeclared (first use in this function)
pymqe.c:205: `compReason' undeclared (first use in this function)
pymqe.c: In function `pymqe_MQDISC':
pymqe.c:220: `MQHCONN' undeclared (first use in this function)
pymqe.c:220: parse error before "handle"
pymqe.c:221: `MQLONG' undeclared (first use in this function)
pymqe.c:223: `handle' undeclared (first use in this function)
pymqe.c:227: warning: implicit declaration of function `MQDISC'
pymqe.c:227: `compCode' undeclared (first use in this function)
pymqe.c:227: `compReason' undeclared (first use in this function)
pymqe.c: In function `pymqe_MQOPEN':
pymqe.c:250: `MQHCONN' undeclared (first use in this function)
pymqe.c:250: parse error before "qmgrHandle"
pymqe.c:251: `MQOD' undeclared (first use in this function)
pymqe.c:251: `qDescP' undeclared (first use in this function)
pymqe.c:254: `MQLONG' undeclared (first use in this function)
pymqe.c:254: parse error before "options"
pymqe.c:255: `MQHOBJ' undeclared (first use in this function)
pymqe.c:258: `qmgrHandle' undeclared (first use in this function)
pymqe.c:259: `options' undeclared (first use in this function)
pymqe.c:262: `MQOD_CURRENT_LENGTH' undeclared (first use in this
function)
pymqe.c:266: parse error before ')' token
pymqe.c:268: warning: implicit declaration of function `MQOPEN'
pymqe.c:268: `qHandle' undeclared (first use in this function)
pymqe.c:268: `compCode' undeclared (first use in this function)
pymqe.c:268: `compReason' undeclared (first use in this function)
pymqe.c: In function `pymqe_MQCLOSE':
pymqe.c:285: `MQHCONN' undeclared (first use in this function)
pymqe.c:285: parse error before "qmgrHandle"
pymqe.c:286: `MQLONG' undeclared (first use in this function)
pymqe.c:287: `MQHOBJ' undeclared (first use in this function)
pymqe.c:290: `qmgrHandle' undeclared (first use in this function)
pymqe.c:290: `qHandle' undeclared (first use in this function)
pymqe.c:290: `options' undeclared (first use in this function)
pymqe.c:294: warning: implicit declaration of function `MQCLOSE'
pymqe.c:294: `compCode' undeclared (first use in this function)
pymqe.c:294: `compReason' undeclared (first use in this function)
pymqe.c: In function `mqputN':
pymqe.c:305: `MQHCONN' undeclared (first use in this function)
pymqe.c:305: parse error before "qmgrHandle"
pymqe.c:306: `MQHOBJ' undeclared (first use in this function)
pymqe.c:307: `MQLONG' undeclared (first use in this function)
pymqe.c:310: `MQMD' undeclared (first use in this function)
pymqe.c:310: `mDescP' undeclared (first use in this function)
pymqe.c:313: `MQPMO' undeclared (first use in this function)
pymqe.c:313: `pmoP' undeclared (first use in this function)
pymqe.c:318: `MQOD' undeclared (first use in this function)
pymqe.c:318: `qDescP' undeclared (first use in this function)
pymqe.c:322: `qmgrHandle' undeclared (first use in this function)
pymqe.c:322: `qHandle' undeclared (first use in this function)
pymqe.c:338: `MQOD_CURRENT_LENGTH' undeclared (first use in this
function)
pymqe.c:342: parse error before ')' token
pymqe.c:349: parse error before ')' token
pymqe.c:351: `MQPMO_CURRENT_LENGTH' undeclared (first use in this
function)
pymqe.c:355: parse error before ')' token
pymqe.c:358: warning: implicit declaration of function `MQPUT'
pymqe.c:359: `compCode' undeclared (first use in this function)
pymqe.c:359: `compReason' undeclared (first use in this function)
pymqe.c:363: warning: implicit declaration of function `MQPUT1'
pymqe.c: In function `pymqe_MQGET':
pymqe.c:441: `MQHCONN' undeclared (first use in this function)
pymqe.c:441: parse error before "qmgrHandle"
pymqe.c:442: `MQHOBJ' undeclared (first use in this function)
pymqe.c:443: `MQLONG' undeclared (first use in this function)
pymqe.c:446: `MQMD' undeclared (first use in this function)
pymqe.c:446: `mDescP' undeclared (first use in this function)
pymqe.c:449: `MQGMO' undeclared (first use in this function)
pymqe.c:449: `gmoP' undeclared (first use in this function)
pymqe.c:454: `qmgrHandle' undeclared (first use in this function)
pymqe.c:454: `qHandle' undeclared (first use in this function)
pymqe.c:463: parse error before ')' token
pymqe.c:469: parse error before ')' token
pymqe.c:477: warning: implicit declaration of function `MQGET'
pymqe.c:478: `compCode' undeclared (first use in this function)
pymqe.c:478: `compReason' undeclared (first use in this function)
pymqe.c: In function `pymqe_MQBEGIN':
pymqe.c:510: `MQHCONN' undeclared (first use in this function)
pymqe.c:510: parse error before "handle"
pymqe.c:511: `MQLONG' undeclared (first use in this function)
pymqe.c:512: `MQBO' undeclared (first use in this function)
pymqe.c:514: `handle' undeclared (first use in this function)
pymqe.c:518: warning: implicit declaration of function `MQBEGIN'
pymqe.c:518: `beginOpts' undeclared (first use in this function)
pymqe.c:518: `compCode' undeclared (first use in this function)
pymqe.c:518: `compReason' undeclared (first use in this function)
pymqe.c: In function `pymqe_MQCMIT':
pymqe.c:533: `MQHCONN' undeclared (first use in this function)
pymqe.c:533: parse error before "handle"
pymqe.c:534: `MQLONG' undeclared (first use in this function)
pymqe.c:536: `handle' undeclared (first use in this function)
pymqe.c:540: warning: implicit declaration of function `MQCMIT'
pymqe.c:540: `compCode' undeclared (first use in this function)
pymqe.c:540: `compReason' undeclared (first use in this function)
pymqe.c: In function `pymqe_MQBACK':
pymqe.c:554: `MQHCONN' undeclared (first use in this function)
pymqe.c:554: parse error before "handle"
pymqe.c:555: `MQLONG' undeclared (first use in this function)
pymqe.c:557: `handle' undeclared (first use in this function)
pymqe.c:561: warning: implicit declaration of function `MQBACK'
pymqe.c:561: `compCode' undeclared (first use in this function)
pymqe.c:561: `compReason' undeclared (first use in this function)
pymqe.c: In function `pymqe_MQINQ':
pymqe.c:585: `MQHCONN' undeclared (first use in this function)
pymqe.c:585: parse error before "qmgrHandle"
pymqe.c:586: `MQHOBJ' undeclared (first use in this function)
pymqe.c:587: `MQLONG' undeclared (first use in this function)
pymqe.c:593: `MQCHAR' undeclared (first use in this function)
pymqe.c:596: `qmgrHandle' undeclared (first use in this function)
pymqe.c:596: `objHandle' undeclared (first use in this function)
pymqe.c:596: `selectors' undeclared (first use in this function)
pymqe.c:599: `MQIA_FIRST' undeclared (first use in this function)
pymqe.c:599: `MQIA_LAST' undeclared (first use in this function)
pymqe.c:600: `intAttrCount' undeclared (first use in this function)
pymqe.c:602: `charAttrCount' undeclared (first use in this function)
pymqe.c:602: `charAttrs' undeclared (first use in this function)
pymqe.c:607: warning: implicit declaration of function `MQINQ'
pymqe.c:607: `selectorCount' undeclared (first use in this function)
pymqe.c:608: `intAttrs' undeclared (first use in this function)
pymqe.c:608: `compCode' undeclared (first use in this function)
pymqe.c:608: `compReason' undeclared (first use in this function)
pymqe.c: In function `pymqe_MQSET':
pymqe.c:629: `MQHCONN' undeclared (first use in this function)
pymqe.c:629: parse error before "qmgrHandle"
pymqe.c:630: `MQHOBJ' undeclared (first use in this function)
pymqe.c:631: `MQLONG' undeclared (first use in this function)
pymqe.c:637: `MQCHAR' undeclared (first use in this function)
pymqe.c:640: `qmgrHandle' undeclared (first use in this function)
pymqe.c:640: `objHandle' undeclared (first use in this function)
pymqe.c:640: `selectors' undeclared (first use in this function)
pymqe.c:643: `MQIA_FIRST' undeclared (first use in this function)
pymqe.c:643: `MQIA_LAST' undeclared (first use in this function)
pymqe.c:648: `intAttrs' undeclared (first use in this function)
pymqe.c:649: `intAttrCount' undeclared (first use in this function)
pymqe.c:655: `charAttrs' undeclared (first use in this function)
pymqe.c:656: `charAttrCount' undeclared (first use in this function)
pymqe.c:660: warning: implicit declaration of function `MQSET'
pymqe.c:660: `selectorCount' undeclared (first use in this function)
pymqe.c:661: `compCode' undeclared (first use in this function)
pymqe.c:661: `compReason' undeclared (first use in this function)
error: command 'gcc' failed with exit status 1
Thank you,
Andrew Robert
Systems Architect
Information Technologies
MFS Investment Management
Phone: 617-954-5882
Pager: 781-945-1742
E-mail: arobert at mfs.com
Linux User Number: #201204
"MFS Relay Service" made the following
annotations on 04/07/2005 02:20:47 PM
------------------------------------------------------------------------------
This email communication and any attachments may contain proprietary, confidential, or privileged information. If you are not the intended recipient, you are hereby notified that you have received this email in error and that any review, disclosure, dissemination, distribution or copying of it or its contents is prohibited. The sender does not waive confidentiality or any privilege by mistransmission. If you have received this email in error, please notify the sender immediately, delete this email, and destroy all copies and any attachments.
==============================================================================
More information about the Tutor
mailing list