On Mon, Feb 22, 2010 at 8:41 AM, Kris <[email protected]> wrote: > Thanks for the clarifications Anthony.
You're welcome. > On Fri, 2010-02-19 at 21:04 -0700, Anthony Tuininga wrote: >> The executable does not perform an unzipping of anything but it does >> require the .so files since they are C extension modules and the >> application requires them. > > I now understand what the executables need to run. But it is still not > clear to me how to distribute the executables and libraries together. > > For example, the build files contain libpython3.1.so.1.0. Clearly, this > is the python library and should be distributed. But it definitely > shouldn't be distributed in /usr/lib (e.g. as part of a .rpm), since it > would conflict with a packaged version of python. On the other hand, one > needs to guarantee that this library will be available, else the built > executables won't run: "somehow" libpython3.1.so.1.0 needs to be > distributed. > > So, where should the .so files be installed ? > > Additionally, should "other" files produced in the build directory, such > as libsys.sql from the py-postgresql project, be installed ? It seems > that such files sholudn't go in /usr/lib. > > I am wondering if this calls for special support in cx_freeze to have > the executables built with it load their libraries (perhaps by setting > LD_LIBRARY_PATH, or in some other way) from a directory specified at > build time, e.g. /usr/share/<package_name>/lib. > > Do you have any recommendations ? Well, the current "python setup.py install" and the packaged RPMs that are created using cx_Freeze put the binary and the library.zip and all of the associated extension files in <prefix>/lib/<name>-<version> where <name> and <version> are the values defined in the metadata in setup.py and <prefix> is /usr or /usr/local or wherever you specify on the command line. Then a symbolic link is created in <prefix>/bin pointing to the executable(s) found in the above named directory. That ensures that each package is independent but enables you to run it in the normal fashion without changing the PATH environment variable or anything like that. I believe this resolves all of your questions but I'd appreciate your comments. In any case it seems to work well for me. :-) Anthony ------------------------------------------------------------------------------ Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev _______________________________________________ cx-freeze-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/cx-freeze-users
