From: Stanley A. K. <sk...@cp...> - 2002-10-22 21:31:48
|
I got it working. Thanks for the advice. I prepared a patch for setup.py to change the include and library locations to the third alternative and revised the spec file to apply it. Somehow, it still built an rpm that installed in /usr/lib/python2.2/site-packages (even though I built the rpm with python 2.1 and there isn't anything else in the python 2.2 directory) but I symlinked it over to /usr/lib/python2.1/site-packages, where it needed to be. I also need to find better documentation on preparing patches, because it had to ask me to name the file that was to receive the patch. Again, thanks. Stan Klein At 01:15 PM 10/21/2002 -0600, Sean Reifschneider wrote: >On Mon, Oct 21, 2002 at 10:55:26AM +0000, Stanley A. Klein wrote: >>I'm running Python 2.1, which if it wasn't provided on the Red Hat 7.2 CD's >>(in addition to the Python 1.5.2 that runs the Red Hat config system) I had >>downloaded from python.org. > >The RPMs you get from python.org should install as the name "python2". >You're probably running a Python that you got elsewhere. > >>I had installed the pypgsql 2.1 and 2.2 rpms downloaded from ftp.tummy.com. >> I tried both. They each created a python2.2 site packages directory and I >>symlinked pypgsql from there to the python2.1 site packages directory. > >Yeah, don't do that. Either install Python 2.2, or re-build the pyPgSQL >with 2.1... > >>My suspicion is that the options in setup.py somehow cause the pypgsql 2.1 >>and 2.2 installed under the rpms as supplied on the ftp site to look in the >>wrong places for some shared objects they need. > >Perhaps. You *DO* have the postgres libraries installed, right? I >believe the package name is "postgresql-libs"? > >>Since the SRPM keeps the source files other than the rpm spec packaged up >>in a tar.gz file that the rpm build uses, I'm not sure how to fix the >>setup.py inside the tar.gz package to select the proper options for Red >>Hat. Alternatively, could I symlink from where Red Hat puts any library or > >You have to provide a patch to the source, and specify it via the >"patch0:" and "%patch0" lines in the .spec file. The tar file in the >SRPM is always a pristine copy of the source, the build process then >applies patches to it. > >You probably don't need to do this though. > >Sean >-- > Reading computer manuals without the hardware is as frustrating as reading > sex manuals without the software. -- Arthur C. Clarke >Sean Reifschneider, Inimitably Superfluous <ja...@tu...> >tummy.com, ltd. - Linux Consulting since 1995. Qmail, Python, SysAdmin > > |