Hi all -- I've just checked in a bunch of changes to the 'install' command, the net effect of which is that it now WORKS. (In case you hadn't been paying attention, I checked in a version several weeks ago that was only half-finished and has since been abandoned.) If you're interested in playing around: first, read the docs, which are also a complete rewrite. This is the nucleus of the "Installing Python Modules" manual; so far, it only covers "alternate" and "custom" installation. ("Standard" installation is pretty obvious, and anyone reading this sig should know what that means... does need to be documented, though!) Documentation is at http://www.python.org/sigs/distutils-sig/documentation.html Code is in the CVS tree of course, and I've just put out a new snapshot to celebrate the occasion: http://www.python.org/sigs/distutils-sig/implementation.html Enjoy! Greg -- Greg Ward - Linux geek gward@python.net http://starship.python.net/~gward/ I am NOT a nut....
I've just checked in a bunch of changes to the 'install' command, the net effect of which is that it now WORKS.
Sorry to be the bearer of bad news, but I'm not sure about that . . . I removed my distutils distribution, and re-synced with CVS. Here's the tail end of % rm -fr build % python setup.py install running install_lib Traceback (innermost last): File "setup.py", line 22, in ? packages = ['distutils', 'distutils.command'], File "distutils/core.py", line 98, in setup dist.run_commands () File "distutils/core.py", line 531, in run_commands self.run_command (cmd) File "distutils/core.py", line 580, in run_command cmd_obj.run () File "distutils/command/install.py", line 361, in run self.run_peer ('install_lib') File "distutils/core.py", line 877, in run_peer self.distribution.run_command (command) File "distutils/core.py", line 578, in run_command cmd_obj = self.find_command_obj (command) File "distutils/core.py", line 508, in find_command_obj cmd_obj = self.create_command_obj (command) File "distutils/core.py", line 490, in create_command_obj klass = self.find_command_class (command) File "distutils/core.py", line 468, in find_command_class raise DistutilsModuleError, \ distutils.errors.DistutilsModuleError: invalid command 'install_lib' (no class ' install_lib' in module 'distutils.command.install_lib') ========================================================= "python setup.py install_py " did work, however, the result was that distutils seems broken. On my extensions: % python setup.py build Traceback (innermost last): File "setup.py", line 72, in ? ext_modules = [ File "/usr/lib/python1.5/site-packages/distutils/core.py", line 81, in setup dist = klass (attrs) File "/usr/lib/python1.5/site-packages/distutils/core.py", line 245, in __init__ raise DistutilsOptionError, \ distutils.errors.DistutilsOptionError: invalid distribution option 'install_path' -- Joe VanAndel National Center for Atmospheric Research http://www.atd.ucar.edu/~vanandel/ Internet: vanandel@ucar.edu
On 22 March 2000, Joe Van Andel said:
I removed my distutils distribution, and re-synced with CVS. Here's the tail end of % rm -fr build % python setup.py install
running install_lib Traceback (innermost last): [...] File "distutils/core.py", line 468, in find_command_class raise DistutilsModuleError, \ distutils.errors.DistutilsModuleError: invalid command 'install_lib' (no class ' install_lib' in module 'distutils.command.install_lib')
Oops! My mistake -- fixed, will check it in shortly.
"python setup.py install_py " did work, however, the result was that distutils seems broken.
Hmmm, something wrong with your "cvs update" then -- install_py is gone, history, dead, deleted, removed, shuffled-off-its-mortal-coil. That is an EX-module! Well, try again after I checkin the fix. Thanks -- Greg -- Greg Ward - Unix weenie gward@python.net http://starship.python.net/~gward/ All things are possible -- except skiing through a revolving door.
:) > "python setup.py install_py " did work, however, the result was that :) > distutils seems broken. :) :) Hmmm, something wrong with your "cvs update" then -- install_py is gone, :) history, dead, deleted, removed, shuffled-off-its-mortal-coil. That is :) an EX-module! Perhaps the install_py.pyc is still there. I had to delete it by hand. Bastian
My extension modules are installed in /usr/local/python/lib/python1.5/site-packages/Perp/{sub_package} As of 3/23/00, the CVS version of distutils now complains: python setup.py build Traceback (innermost last): File "setup.py", line 72, in ? ext_modules = [ File "/usr/lib/python1.5/site-packages/distutils/core.py", line 81, in setup dist = klass (attrs) File "/usr/lib/python1.5/site-packages/distutils/core.py", line 245, in __init__ raise DistutilsOptionError, \ distutils.errors.DistutilsOptionError: invalid distribution option 'install_path' 'install_path' is documented in USAGE.txt, and worked before. -- Joe VanAndel National Center for Atmospheric Research http://www.atd.ucar.edu/~vanandel/ Internet: vanandel@ucar.edu
On 23 March 2000, Joe Van Andel said:
My extension modules are installed in /usr/local/python/lib/python1.5/site-packages/Perp/{sub_package}
As of 3/23/00, the CVS version of distutils now complains: raise DistutilsOptionError, \ distutils.errors.DistutilsOptionError: invalid distribution option 'install_path'
Oops, shoulda mentioned that on the list: I unilaterally and arbitrarily changed the name of that option to 'extra_path', since I think that's a bit more descriptive. (So I guess it wasn't *completely* arbitrary.) I could put in a backwards compatibility hack if the change is a huge burden (I don't think it should be!), but my excuse for not doing so is that the version number is still < 1.0, and if you follow the CVS code periodic breakage is just a fact of life. Greg -- Greg Ward - just another /P(erl|ython)/ hacker gward@python.net http://starship.python.net/~gward/ Yield to temptation; it may not pass your way again.
Oops, shoulda mentioned that on the list: I unilaterally and arbitrarily changed the name of that option to 'extra_path', since I think that's a bit more descriptive. (So I guess it wasn't *completely* arbitrary.)
I've attached a patch for the USAGE.txt document, to reflect this change. -- Joe VanAndel National Center for Atmospheric Research http://www.atd.ucar.edu/~vanandel/ Internet: vanandel@ucar.edu --- USAGE.txt.orig Mon Mar 27 10:18:58 2000 +++ USAGE.txt Mon Mar 27 10:26:27 2000 @@ -708,7 +708,7 @@ "/usr/local/lib/python1.5/site-packages"] [DOS/Windows default: 'prefix', eg. "C:\Python"] [actually it gets more complicated in the presence of the - 'install_path' option; see below] + 'extra_path' option; see below] install_site_platlib: base installation directory for third-party extension modules @@ -716,18 +716,18 @@ "/usr/local.plat/lib/python1.5/site-packages"] [DOS/Windows default: 'exec_prefix', eg. "C:\Python"] - install_path: + extra_path: information about extra intervening directories to put between 'install_lib' and 'install_sitelib', along with a .pth file to ensure that those directories wind up in sys.path. Can be a 1- or 2-tuple, or a comma-delimited string with 1 or 2 parts. The 1-element case is simpler: the .pth file and directory have the same - name (except for ".pth"). Eg. if install_path is "foo" or ("foo",), + name (except for ".pth"). Eg. if extra_path is "foo" or ("foo",), then Distutils sets 'install_site_lib' to 'install_lib' + "site-packages/foo", and puts foo.path in the "site-packages" directory; it contains just "foo". The 2-element case allows the .pth file and intervening directories to be named differently; eg. - if 'install_path' is ("foo","foo/bar/baz") (or "foo,foo/bar/baz"), + if 'extra_path' is ("foo","foo/bar/baz") (or "foo,foo/bar/baz"), then Distutils will set 'install_site_lib' to 'install_lib' + "site-packages/foo/bar/baz", and put "foo.pth" containing "foo/bar/baz" in the "site-packages" directory.
On 27 March 2000, Joe Van Andel said:
Oops, shoulda mentioned that on the list: I unilaterally and arbitrarily changed the name of that option to 'extra_path', since I think that's a bit more descriptive. (So I guess it wasn't *completely* arbitrary.)
I've attached a patch for the USAGE.txt document, to reflect this change.
OK, thanks -- it's checked in now. Greg -- Greg Ward - Linux geek gward@python.net http://starship.python.net/~gward/ Beware of altruism. It is based on self-deception, the root of all evil.
participants (3)
-
Bastian Kleineidam
-
Greg Ward
-
Joe Van Andel