TLS context

Joe Little jlittle at open-it.org
Wed Jan 2 04:14:30 CET 2002


ok.. answers below.

On 1/1/02 6:59 PM, "Michael Ströder" <michael at stroeder.com> wrote:

> Joe Little wrote:
>> 
>> first, another error. It looks like Lib/ldap.py is not found and a warning
>> is thrown.
> 
> Module ldap was turned in a module package. See Lib/ldap/.
> 
>> The generated files are handled differently by setup.py, and I
>> get a different file list. Also, a noticed a version string of
>> python-ldap-2.0.0pre1.. should I use this instead of naming it
>> "python-ldap-cvs-pythonv"
> 
> Use a timestamp until a (pre-)release is done.
> 
>> Here is the file list (/usr/share/doc excepted):
>> 
>> /usr/lib/python2.1/site-packages ....
>> 
>> _ldap.so
>> ldapurl.py
>> ldif.py
>> ldap/__init__.py
>> ldap/async.py
>> ldap/functions.py
>> ldap/ldapobject.py
>> ldap/modlist.py
> 
> Nothing wrong with that.
> 
>> There used to be an ldap.pth generated
> 
> Pre-DistUtils days, was never available on Win32 anyway.
> 
>> and other such, and it definitely include an ldap.py before.
> 
> See ldap/__init__.py.
> 
>> It also does not pre-compile any .py file.
> 
> Can I pass DistUtils an option to enable byte-compiling before
> packaging?
> 

Can't seem to find any

>> This is all changed behaviour so to speak with distutils.
> 
> Was byte-compiling enabled in your RPM before? How?

I did a "make install" into a $DESTDIR (build root) --- make install did
everything correctly in the GNU configure days. setup.py is a bit too smart
:)

> 
>> I cannot perform a
>> "install" since it will only generate onto the real directories and not an
>> alternative build root.
> 
> What's wrong with using python setup.py bdist_rpm ? BTW: It contains
> byte-compiled *.pyc files in my case (tested right now).
> 

It fails for me since it finds python is 1.5 (which doesn't include
distutils). Even changing the env to /usr/bin/python2 causes things to
progress and then die out later when it goes into "Python-LDAP-2.0.0pre1"
and runs setup.py again and can't import distutils (its running python1.5
again). There should be a way to handle this without env variables, since I
want to be as deterministic as possible. Second, it looks like the current
cvs snapshots enforce a 2.0.0pre1 version string. I'd need to diff away from
that but then I couldn't use bdist_rpm (you can't use it within another
RPM... :) )

>> Checking a real install, the only thing lacking is
>> the precompile of .py files, and I believe that is not necessary.
> 
> When installing from source distribution (packaged with python
> setup.py sdist) this will do the trick:
> $ python setup.py install -O1
> $ python setup.py install -O2

what do -01 and -02 do.. or is that O1 O2 (letter 'O')? Again, this sounds
like it invokes actions on its discovered install dirs (/usr/lib instead of
/var/tmp/%var/usr/lib). Please tell me I'm wrong :)

> 
> You could also write a small post-install script using
> compileall.py.
> 
> Ciao, Michael.






More information about the python-ldap mailing list