New issue 13 by GadgetSt...@hotmail.com: Use of absolute paths reduces the
tools usefulness
http://code.google.com/p/gui2exe/issues/detail?id=13
What steps will reproduce the problem?
1. Generate an install script in the same directory as your source
2. Move/copy the directory, or if it is a removable disk unmount and mount
so it has a different drive letter. If it is a copy then make an obvious
mode to your app - e.g. icon/title/bgcolour change
3. Try running setup.py in the new location
What is the expected output? What do you see instead?
Expect the same output as in old directory, if directory/drive moved lots
of file not found messages, if copy then changes not present in output
files. (Note this is also the issue with the setup.py install in gui2exe
itself).
What version of GUI2Exe, Python and wxPython are you using? On what
operating system?
Please provide any additional information below.
This problem arrises because data_files, icon_resources, etc, all use
absolute paths, in practical use it is not that unusual to have code in
varing locations. The solution is to either use relative paths for all
names that start with the directory that setup.py is stored in or possibly
offer the user the option of using relative paths on any file select.
--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings
Sorry, forgot the version information:
GUI2Exe v0.4.0
Python 2.6 (r26:66721, Oct 2 2008, 11:35:03) [MSC v.1500 32 bit (Intel)]
Python 2.5.2 (r252:60911, Feb 21 2008, 13:11:45) [MSC v.1310 32 bit (Intel)]
Windows 7, Vista & XP
Comment #2 on issue 13 by andrea.gavana: Use of absolute paths reduces the
tools usefulness
http://code.google.com/p/gui2exe/issues/detail?id=13
Hi,
this is a good suggestions, I'll implement it using relative paths instead
of
absolute ones. One thing, however: you wrote:
" Note this is also the issue with the setup.py install in gui2exe itself. "
GUI2Exe is not meant to be installed as site-package with this command:
python Setup.py install
Nor to be compiled as executable. GUI2Exe should be used as-is, like a
normal Python
file, i.e., double-clicking on the GUI2Exe.py file on Windows or writing:
python GUI2Exe.py
This is also mentioned in the main GUI2Exe page, and the old Setup.py file
in the
GUI2Exe distribution is now gone in version 0.5 and SVN.
With the setup file gone users will be less likely to moan about "setup.py
install"
not working, b.t.w. it did work fine if the paths were changed to relative
ones.
A minor suggestion since I and I am sure many others have got into the
habit of
running setup.py install on any new package we get, have you considered
replacing
the contents of setup.py with something like the following?
print "GUI2Exe is not meant to be installed as site-package with this
command:\n"
print "python Setup.py install\n"
print "Please run here or move the entire directory structure to a prefered
location"