Help with Distutils

Johan Svedberg johan at svedberg.pp.se
Fri May 14 09:22:15 EDT 2004


* Johan Svedberg <johan at svedberg.pp.se>:
> * Jorge Godoy <godoy at ieee.org>:
>> On Qui 13 Mai 2004 13:14, Johan Svedberg wrote:
>>
>>> I just started playing around with Distutils and there is one thing
>>> I could use some help with. I'm wondering if there is some
>>> convenient way to access the directories where the data_files was
>>> installed?
>>
>> Could you explain when and why you are trying to do that?
>
> Well, the reason is that I've told setup.py to install a bunch of
> templates in <prefix>/share/myapp/templates/ and I want to make sure
> that myapp can find these no matter what <prefix> is.

When I think more about it, the cleanest way would probably be if I
could in some way patch the relevant files so that they point to the
right location. This would ofcourse have to be done after the user has
decided where he wants to install things. Very much like the way
configure and make works together.

I'm going to look around more to see if I can find any good solution by
looking at other peoples projects. I find it really strange that there
isn't some generic way of doing this since application installment is a
pretty central part.

-- 
Johan Svedberg, johan at svedberg.pp.se, http://johan.svedberg.pp.se/



More information about the Python-list mailing list