[Distutils] Behaviour of "install_data" changed

Greg Ward gward@python.net
Sat, 24 Jun 2000 13:34:26 -0400

I've just fixed the behaviour of the "install_data" command: the default
directory for installating data files is now just the installation base, 
which is usually sys.prefix.  Thus, if you put

   data_files = ["my_data"]

in your setup script, you will wind up installing (eg.)
/usr/local/my_data -- definitely the wrong thing on Unix, and probably
wrong on Windows too.  (Except for applications that have their own
prefix, but that's not really dealt with yet.)

This is the Right Thing now because of the change to "install_data" that
lets you specify where to put data files; the above should be spelled

   data_files = [("share", ["my_data"])]

which will install /usr/local/share/my_data.

Of course, this still doesn't solve the problem of, "How does my
application/module know where Distutils installed this data file if the
user did some wild funky custom installation?".  Oh well, better than

Greg Ward - Unix nerd                                   gward@python.net
Vote anarchist.