Re: [casetta] Casetta 0.3 Feedback / Windows Installer

[ Thread Index | Date Index | More lists.tuxfamily.org/casetta Archives ]


Florian Birée a écrit :
Actually, the installation on Microsoft Windows is not easy. As there is
no tool to manage dependences this installation is long.
I tried to make a full all-in-one-ready-to-use-out-of-the-box (tm)
*installer for Windows*.
    
You've saved the world for a lot of casetta users :-)
  
I am not really sure casetta have a lot of users for now (You, Asher256, a certain theophile helleboid and me... all using Linux) :-D. But maybe this installer will help some Windows users (I hope so !).

  
I add some problems :
     -> Firstly, py2exe uses a distutils-like script which needs to be
executed in the directory where the script which needs to be compiled is
located, if this script imports other scripts located in its directory.
For example, gasetta.py imports prefs.py, located in the same directory.
Therefore, there are two separate compilation scripts for casetta_cli
and gasetta. This is a problem because some librairies are duplicated
(for example, the casetta python module if copied twince : once in the
gasetta build directory, once in the casetta_cli build directory. One
solution to this problem would be to copy all gasetta and all
casetta_cli files in a common directory and then to create a common
pyexe script but, after, it would be difficult to know which compiled
files belongs to casetta_cli and which belongs to gasetta (especially in
the library.zip, an archive containing all the python modules...) and
make the writing of an installer difficult. So I let things like that.
    
And how py2exe deal with non-standard python modules, like the PIL? The
casetta packages could be 'compiled' like the PIL, isn't it?
  
The casetta python module is currently 'compiled' like the PIL. This means before compiling casetta_cli or gasetta, the casetta module needs to be installed in your-python-root/lib/site-packages/. The PIL and casetta are handled exactly in the same way by py2exe!. This is a problem because theses modules are included twice (in the casetta_cli final directory where binaries are put and in gasetta final dir). To make this clearer , I have a small diagram : http://xion345.olympe-network.com/casetta-work/casetta_cli-gasetta-py2exe-build-process.jpg. An important point : Casetta_cli and gasetta are built separately by two different script (which are called by th "master" script generate-win32-installer.py).
  
    My second problem was with gasetta, py2exe and pyinstaller are not
able to detected all librairies needed and especially, it didn't include
all necessary GTK libraries. I tried to include them one-by-one and I
discovered that all GTK libraries/config files where needed. So I
decided to include the FULL gtk library with Gasetta (This is heavy
especially with locales included...). Gtk library is copied in a subdir
(gtk-lib) of gasetta
    
(And now we know why Windows programs needs a full CD-Rom or DVD-Rom to
be distributed... and not only less-than-500-ko-packages.)
  
Yes, needed libraries are included with most windows software. Because of its lack of a decent dependences mechanism. That's the windows world... I said that to have a good conscience (what I did is bad but everybody does like that)
  
    -> The second step was to make and installer, I choosed NSIS :
Nullsoft Scriptable Install System (http://nsis.sourceforge.net/)
because it is free (zlib/libpng licence), well-known, powerful yet
simple, very well documented. Belive me, this was THE good choice ! ;-)
    
I never used it, but I heard a lot of great things about it.
  
Yes it is very pleasant and powerful !
I decided to make 2 different installers : one which includes GTK (~9Mo,
compressed in LZMA, of course self-extracting installer !), one which
does not includes GTK, because the user can already have GTK included
(If he installed the gimp before) or simply want to install casetta_cli
(~3Mo, compressed in LZMA).
    
Just about the GTK installation from the Gimp: I've read (but never
check it) that the Gimp doesn't use the libglade, and then the GTK
distributed with the Windows installer of the Gimp hasn't the libglade
support. Does your installer check the libglade support? (Or perhaps I'm
wrong about libglade and the GTK of the Gimp.)
Yes, you are right, my installer doesn't check for Glade support ! This is a big problem. I didn't notice. Sorry. I will try to fix this.
Thank you very much for highlighting this point.

  
In both.This installer features a "modern"
look, component choice (Shortcuts, casetta_cli, gasetta), *GTK lib
detection*, Control Panel information add/remove. It is
internationalized and localized in french (language is detected from the
windows settings).
    
This is very good, the choice of component is a good features (most
users will never use the cli), and the look of the installer is far
better than the distutils one.

  
I tried to make my system as reusable as possible, in fact my NSIS
scripts are just templates which are used by a python script who
generates everything. This means, you will by able to generate casetta
0.4 and next installer, just running a simple python script !*
    
Good idea!

  
If you feel confused about what I said, have a look at the screenshots :
http://xion345.olympe-network.com/casetta-work/windows-installer/screenshots/
Try it : (Choose an installer with or without GTK)
http://xion345.olympe-network.com/casetta-work/windows-installer/setup-casetta-gtk.exe
http://xion345.olympe-network.com/casetta-work/windows-installer/setup-casetta-nogtk.exe
    
I haven't fully tried those installer (I've only a win98 SE under qemu,
which need GTK 2.6, and Wine), but I seems to work.
Wow. This may be painful ! You may be interested in the VirtualBox (Virtual Machine, it don't know if you know !), which is now licensed under GPL, http://www.virtualbox.org/wiki/Downloads (There is a GPL, which you need to compile and not-gpl version). It should be faster than Qemu !
  
To create a windows installer you need to (all needed files are on :
http://xion345.olympe-network.com/casetta-work/windows-installer/ ):
1 - Copy setup-py2exe.py inside gasetta directory (You can have a look
at it....)
2 - Copy setup-py2exe.py inside casetta_cli directory
3- Copy NSIS-data, all *.nsi scripts, generate-win32-installer.py in the
parent dir
4- Run generate-win32-installer.py and answer the questions
5- Compile newly created NSIS scripts(casetta-setup-gtk.nsi,
casetta-setup-nogtk.nsi) (Right click -> Compile NSIS script), you will
need the NSIS compiler http://nsis.sourceforge.net/Download
    
The only drawback it's that need a windows (or windows compatible)
system. Actually, I've a script that build the source archive and the
windows (distutils) installer, all on my GNU/Linux system.
Maybe it's possible to use Wine to use the NSIS compiler.
  
No No No ! :-) When I said  NSIS was nearly perfect... It is possible to build Windows installer from Linux using NSIS ! 8-)  There is a version of the NSIS script compiler for linux.
If you are running Debian/Ubuntu, it is in the apt repository (package name : nsis). More specifically, if you are using Ubuntu Linux (I believe it is the case), the version in the feisty repository is out-dated (2.19), I recompiled a quite recent version from gusty for feisty (2.28) : http://xion345.olympe-network.com/debian-packages/nsis_2.28-1_i386.deb . You can use it, if you want !
If you prefer to build (I mean the nsis compiler) it by yourself have a look at : http://nsis.sourceforge.net/Docs/AppendixG.html#G.3 (en).

However, you absolutely need Windows to compile the project with py2exe. If you don't mind, it would prefer to compile the official installer from a real windows... It may be better !

  
Feel free to send me an e-mail for any question, doubt, remark,
feedback, etc... about that.
And especially if something in fuzzy English is not clear (I can
re-explain in French) :-D !
    
All it's clear!

  
If you want me to modify anything in the installer, there is no problem.
And if you don't like the bitmaps humm...
Yeah, I admit it I am not a GIMP-power-user but I got some pictures from
the web, modified them and... the result is not really good... :-D
    
It's not me, with my two left hands in inkscape (see the gasetta icon -
which re-use an icon from the KDE icon set), who'll judge your work! For
the moment, your installer provide a smarter setup than the distutils
one, and its what windows users wants.
  
Hey, the casetta icon is not so bad (but like me you cheated, you used an existing icon as a base). In fact it is not very smarter. It is just easier and faster to use it is however, a bit heavy : full copy of GTK lib etc... Some libraries are duplicated...
  
Known Bugs :
- Required space in the installer is wrong. Don't know why !
    
I've no idea about it.

  
PS : There were also some errors in your w32_postinstall script.
Casetta_gtk was not replace by gasetta. This is not used by my installer
but I corrected it anyway !
    
I'll fix it in the repository, and rebuild the source archive and the
distutils installer. Non-windows packages doesn't need to be updated,
they doesn't use this script. Because it's not in the code of casetta,
I'll not upgrade the version number.
  
Yes, of course
If you think yours installers are ready, I can upload them on the
download repository, and update the website. I'll also made an archive
with the source of the installer, and upload them in the svn repository
(in branches/win-installer or something like).
If you want, I can get you a write access to the repository.
  
No, because of the libglade bug, they are not ready, it'll try to fix it as soon as possible. It is a good idea to add the source code in a branch (the organization of the SVN is now better and professional :-).
When you add them on the website, could you put a link to the mailing list and write I am very interested in getting any feedback and ready to help for install and son. (Could you also put my e-mail, like this people don't have to subscribe to the mailing list f they just want help !)

For the SVN RW access, yes, I think now I have enough experience developing casetta. So that's a good idea (especially if I work in branches (see my next mail), there is not risk for the trunk ). Do I need to create a tuxfamily.org account ? Do I need a special option ?

What's your opinion about that?

Thank you a lot for this great contribution!

Cheers,
  


--
Fabien ANDRE aka Xion345
Linux User #418689 -- fabien.andre.g@xxxxxxxxxx -- xion345@xxxxxxxxxxxxx
No. That's it. The cool name, that is. We worked very hard on creating a name that would appeal to the majority of people, and it certainly paid off: thousands of people are using Gasetta just to be able to say Fx-Interface ? Hah. I've got Gasetta. What a cool name'. FA-124 made the mistake of putting a lot of numbers and weird abbreviations into the name, and is scaring away a lot of people just because it sounds too technical. ( Linus Torvalds, Before 1995, modified by Xion345 )


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/