distutils problem

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Michele Petrazzo

    #1

    distutils problem

    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\pyt hon23\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("Free ImagePy/data/*.*")
    if sys.platform == 'win32': prefix = os.path.join(sy s.prefix,
    "Lib/site-packages/FreeImagePy")
    else: prefix = os.path.join(sy s.exec_prefix, "lib/python%s" %
    sys.version[:3], "site-packages/FreeImagePy")
    setup( ....
    packages=['FreeImagePy', 'FreeImagePy.te st', 'FreeImagePy.to ols'],
    data_files=[ (prefix, dataToCopy),],
    )


    How can I modify my script, for make it work with exe package?

    Thanks,
    Michele
Working...