Re: [PyKDE] How To Publish a pyqt application
At 11:11 29/03/2006 +0200, [EMAIL PROTECTED] wrote: The equivalent in my case would be: cx_freeze -O --install-dir=whatever --include-modules=sip MyApp.py and I need to add the tk, tcl, qt and readline libraries. Hello yesterday i have tried cx-freeze . and it works well (thank you) my command line was $freezepython --install-dir=myfolder --include-modules=sip myapp.py $cp $QTDIR/lib/libqt.so.3 myfolder/libqt.so.3 and that's right , it works well I'm sending a copy of this mail to the list just to let them know you succeeded ;-) I added the readline version of my system because when freezing on SuSE8.2, the frozen application was not running under redhat enterprise 4. After the addition it was running on any platform I have tried. i would ask you about the -O option that i dosen't understand much . and i'd like you to give me some links or an exemple of your build applications with cx-freeze and the command line that you typed to freeze it . From cx_freeze help: 5) Added option -O (or -OO) to FreezePython to set the optimization used when generating bytecode. I do not understand it either, but it should not harm to have any kind of optimization :-) The command I use is the very same you use. I simply add a script to launch the application that takes care of positioning the library path. other thing is : i can't run my application frozen by linux in windows , so is there a way to make that more portable ? You have to setup python, qt, pyqt, cx_freeze etc in windows and once your application is running on windows you can think about freezing it. The good news is that you have many binaries available, so the installation should be quite fast. If you use a commercial version of Qt, you will have to use the VendorID package (available from Riverbank) and build a signed version of cx_freeze. If you use PyQt4 you will not have that problem. Regards, Armando ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
Re: [PyKDE] How To Publish a pyqt application
On Wednesday 29 March 2006 2:20 pm, V. Armando Sole wrote: If you use a commercial version of Qt, you will have to use the VendorID package (available from Riverbank) and build a signed version of cx_freeze. If you use PyQt4 you will not have that problem. If you need to use VendorID with PyQt3 then you will also need to use it with PyQt4 as the commercial licenses are the same. Phil ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
Re: [PyKDE] How To Publish a pyqt application
Hi Phil, At 13:49 29/03/2006 +, Phil Thompson wrote: On Wednesday 29 March 2006 2:20 pm, V. Armando Sole wrote: If you use a commercial version of Qt, you will have to use the VendorID package (available from Riverbank) and build a signed version of cx_freeze. If you use PyQt4 you will not have that problem. If you need to use VendorID with PyQt3 then you will also need to use it with PyQt4 as the commercial licenses are the same. Phil I have an application that may run under PyQt3 with Qt3 and under PyQt4 with Qt4. Since I have installed the commercial PyQt3 and Qt3, and the GPL PyQt4 and Qt4 on the same machine, I only use vendorID when I freeze my application with the commercial bindings. I do not break any license agreement if I do not use VendorID on the GPL PyQt4 and GPL Qt4 binding under those conditions (provided I give access to the source code). Regards, Armando ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
[PyKDE] How To Publish a pyqt application
Hello all thanks for that nice mailling-list ; and also pyqt . but i have a serious problem with pyqt. the problem is that i can't (or i don't know how to) publish my applications written using pyqt . as you know every pyqt application begins with from qt import * and qt itself imports sip and qscintilla . so if i give my .py application to some one who has only linux installed with python it won't work because he don't have pyqt installed i have tried cx-freeze in order to build a binary executable but it comes with a lot of errors . so all that for me is a serious problem and i can't distribute my application is there a way to create a .tar.gz file for my applications ?? so that the other users will just type $python configure.py make makeinstall or provide me with an other solution thanks ! _ Votre mail gratuit avec http://lexpress.net ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
Re: [PyKDE] How To Publish a pyqt application
On Tue, 28 Mar 2006 11:35:21 +0200 [EMAIL PROTECTED] wrote: Hello all thanks for that nice mailling-list ; and also pyqt . but i have a serious problem with pyqt. the problem is that i can't (or i don't know how to) publish my applications written using pyqt . as you know every pyqt application begins with from qt import * and qt itself imports sip and qscintilla . so if i give my .py application to some one who has only linux installed with python it won't work because he don't have pyqt installed i have tried cx-freeze in order to build a binary executable but it comes with a lot of errors . so all that for me is a serious problem and i can't distribute my application is there a way to create a .tar.gz file for my applications ?? so that the other users will just type $python configure.py make makeinstall or provide me with an other solution thanks ! A possibility is to install Python, Qt and PyQt and your application in for instance /home/yourhome/usr. You can do this with Python's ./configure --prefix=/home/yourhome/usr For Qt you have to do something similar. Add /home/yourhome/usr to the front of your PATH environment variable and install PyQt (you have to specify where to find Qt). Make a tar.gz of the /usr directory and distribute the tar.gz. All you have to do is to instruct your users to unpack your tar.gz and to modify their PATH environment variable. The disadvantage is that your tar.gz will be really big. Voila -- Gerard ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
Re: [PyKDE] How To Publish a pyqt application
Gerard Vermeulen wrote: A possibility is to install Python, Qt and PyQt and your application in for instance /home/yourhome/usr. You can do this with Python's ./configure --prefix=/home/yourhome/usr For Qt you have to do something similar. Add /home/yourhome/usr to the front of your PATH environment variable and install PyQt (you have to specify where to find Qt). Make a tar.gz of the /usr directory and distribute the tar.gz. All you have to do is to instruct your users to unpack your tar.gz and to modify their PATH environment variable. The disadvantage is that your tar.gz will be really big. Voila -- Gerard And if you already have Qt installed it would really eat discspace for no reason. Isn't a better way to write a simple bash (or Python for that matter) 'install-script' that checks if the necessary modules is installed and list them as dependencies if they are missing? Maybe also list how to get the required stuff in a readme... Tina -- Project: Tinapt http://tinapt.berlios.de/ SVN repository: http://svn.berlios.de/wsvn/tinapt/trunk/?rev=0sc=0 ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
Re: [PyKDE] How To Publish a pyqt application
Hi, At 11:35 28/03/2006 +0200, [EMAIL PROTECTED] wrote: Hello all thanks for that nice mailling-list ; and also pyqt . but i have a serious problem with pyqt. the problem is that i can't (or i don't know how to) publish my applications written using pyqt . as you know every pyqt application begins with from qt import * and qt itself imports sip and qscintilla . so if i give my .py application to some one who has only linux installed with python it won't work because he don't have pyqt installed i have tried cx-freeze in order to build a binary executable but it comes with a lot of errors . I use cx_freeze on windows and on linux and it is simply the easiest for the end user. I distribute binaries build under SuSE 8.2 and they work on any linux flavour around. The main source or error coming from your code is the reading of (non python) files. You have to find out where your frozen version is looking for them (just a couple of prints before each file load should give you a hint about where it is looking for them). Some libraries will not be found and you will have to add them by hand. But that you will see it from the reported errors. My advice is that you should not give up and keep trying with cx_freeze. Greetings, Armando ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
Re: [PyKDE] How To Publish a pyqt application
V. Armando Sole [EMAIL PROTECTED] wrote: thanks for that nice mailling-list ; and also pyqt . but i have a serious problem with pyqt. the problem is that i can't (or i don't know how to) publish my applications written using pyqt . as you know every pyqt application begins with from qt import * and qt itself imports sip and qscintilla . so if i give my .py application to some one who has only linux installed with python it won't work because he don't have pyqt installed i have tried cx-freeze in order to build a binary executable but it comes with a lot of errors . I use cx_freeze on windows and on linux and it is simply the easiest for the end user. I distribute binaries build under SuSE 8.2 and they work on any linux flavour around. The main source or error coming from your code is the reading of (non python) files. You have to find out where your frozen version is looking for them (just a couple of prints before each file load should give you a hint about where it is looking for them). Some libraries will not be found and you will have to add them by hand. But that you will see it from the reported errors. My advice is that you should not give up and keep trying with cx_freeze. Also PyInstaller works under Linux. -- Giovanni Bajo ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
Re: [PyKDE] How To Publish a pyqt application
Am Dienstag, 28. März 2006 12:23 schrieb Tina Isaksen: Gerard Vermeulen wrote: A possibility is to install Python, Qt and PyQt and your application in for instance /home/yourhome/usr. You can do this with Python's ./configure --prefix=/home/yourhome/usr For Qt you have to do something similar. Add /home/yourhome/usr to the front of your PATH environment variable and install PyQt (you have to specify where to find Qt). Make a tar.gz of the /usr directory and distribute the tar.gz. All you have to do is to instruct your users to unpack your tar.gz and to modify their PATH environment variable. The disadvantage is that your tar.gz will be really big. ..and won't work, if arch don't match or gcc/glibc versions differ to much.. Voila -- Gerard And if you already have Qt installed it would really eat discspace for no reason. Isn't a better way to write a simple bash (or Python for that matter) 'install-script' that checks if the necessary modules is installed and list them as dependencies if they are missing? Maybe also list how to get the required stuff in a readme... Using a sane package manager with proper dependencies is the right and the easiest way to go. Or quick n'dirty: try: from qt import * except: popen2(kdialog --sorry 'PyQt (Qt bindings for Python) is required for this script.') raise Pete ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
Re: [PyKDE] How To Publish a pyqt application
The disadvantage is that your tar.gz will be really big. ..and won't work, if arch don't match or gcc/glibc versions differ to much.. Works for us, providing we choose a sufficiently old build host. :-) Nigel ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
Re: [PyKDE] How To Publish a pyqt application
Quoting Hans-Peter Jansen [EMAIL PROTECTED]: Using a sane package manager with proper dependencies is the right and the easiest way to go. Or quick n'dirty: try: from qt import * except: popen2(kdialog --sorry 'PyQt (Qt bindings for Python) is required for this script.') raise Certainly the easiest way to go for the programmer, not for the end user :-) Another advantage of a frozen binary is that does not force a different python/Qt/PyQt installation to the one the end user has. My frozen applications only ask the end user: - to extract a tar file in linux (that will give even a script to position the library path) or - to run a .exe installer in windows. - to extract a tar file in MacOSX (py2app used in this case) Once the build system is properly setup, the time cost to the programmer is less than 5 minutes per platform. We had applications where we asked the end user to install python, numeric, Blt and to compile the source files. The applications never got popular. We offered the same applications as a frozen versions and the users were very enthusiastic about them. If anybody is interested on x-ray fluorescence analysis, I can give him/her a couple of links to frozen applications that run in almost any linux flavour (I have not found a distribution more recent than SuSE82 not supporting them). Greetings, Armando - This mail sent through IMP: http://horde.org/imp/ ___ PyKDE mailing listPyKDE@mats.imk.fraunhofer.de http://mats.imk.fraunhofer.de/mailman/listinfo/pykde