"Martin v. Löwis" wrote: > Neal Becker wrote: >> 1. Does it make sense to have both >> >> <site-dep>/app/subpackage >> and >> <site-indep>/app/subpackage >> ? >> >> My answer: definitely yes. We already agree that we should have both >> site-dep for binary code and site-indep for python code, so there is no >> way to avoid this. > > I'm not sure I understand what you are talking about. What is site-dep > and site-indep? Where do we have that for binary code and for python > code? I know what prefix and exec_prefix are. > >> 2. What should the module search do? >> >> I don't know the details of the current algorithm, but clearly it's going >> to have to deal correctly with the above. > > It's very simple. Importing traverses sys.path. > >> One possibility (and maybe this is how it already works?) is that the >> module search doesn't know anything about site-dep/site-indep, it simply >> has a list of paths to search. > > Well, I don't know about site-dep/site-indep, so I wouldn't be surprised > if module search didn't, either. >
Sorry, maybe I used confusing terminology. A reference is here: http://fedoraproject.org/wiki/Packaging/Python This is the current setup. For example, this is a standard macro used by Redhat in RPM SPEC files for python: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")} %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} Clearly this practice is widespread. It would seem that module search needs some modification to fully support it. _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com