By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,172 Members | 762 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,172 IT Pros & Developers. It's quick & easy.

distutils problem

P: n/a
I create a setup script for distribute my application, but I have a
problems with the exe package.

When I create the package with:
python setup.py win bdist_wininst

and execute if after, it'll copy the data file specified by data_files
directive into the C:\python23\python23\lib\site-package\my_lib, so not
on the right site-package directory (python23 + python23).
Otherwise if I use the same script from the source (python setup.py
install) it work well, so it copy on C:\python23\lib\site-package\my_lib
or /usr/lib/python23/site-package/ on linux. (this for python 2.3, of
course :) )

My script:

dataToCopy = glob.glob("FreeImagePy/data/*.*")
if sys.platform == 'win32': prefix = os.path.join(sys.prefix,
"Lib/site-packages/FreeImagePy")
else: prefix = os.path.join(sys.exec_prefix, "lib/python%s" %
sys.version[:3], "site-packages/FreeImagePy")
setup( ....
packages=['FreeImagePy', 'FreeImagePy.test', 'FreeImagePy.tools'],
data_files=[ (prefix, dataToCopy),],
)
How can I modify my script, for make it work with exe package?

Thanks,
Michele
Sep 16 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.