From: Martin P. <ma...@pe...> - 2008-05-27 02:30:12
|
Michal Hocko wrote: > On Mon, May 26, 2008 at 03:47:12AM +0200, Martin Petricek wrote: >>> After some diging it turned out that gui/make_lang does the thing but I >>> don't see any reference to the script from our makefiles. >> That script was never ment to be run automatically, since it rebuilds >> translation sources for menus. > > How should be generate gm files from ts files then? > >>> Is it possible that this is a regression from previous makefiles after I >>> have reorganized them? >> No, this file was not part of any reogranization I know of. > > I didn't get if it is error or not from your response. > >>> I can't see why it works for our released 0.4.1... >> Because generation of .qm files from .ts files is done by "lrelease". This >> is line 34 in makedist script, which is used to create distribution tarball. > > But what if someone wants to build from CVS? > >>> What do you suggest to solve this issue? >> Perhaps add "cd src/gui/lang&& lrelease *.ts" to dev-rebuild if necessary? >> The make_lang does more than just creating the .qm files ... > > This is more hack than solution (it doesn't solve problem building from > CVS). > > What about generic rule in Makefile.rules > .ts.qm: > lrelease $< As the makefile in src/gui is created and managed with qmake, this won't work that easily ... Also, all .qm files must exist before entering src/gui and running qmake, otherwise they won't be included in "make install" in the generated makefile (limitation how qmake handles wildcards). I think lrelease is part of qt build tools, so we can probably rely on it to be present. One solution could be adding (cd gui/lang && lrelease *.ts) to makefile in src/ as prerequisite before entering src/gui and running qmake. And maybe remove the lrelease command from the tarball generation script too. > Or something more similar? > I am not sure what everything is necessary for building, because there > is some menugenarator which is used in make-lang and I don't know its > exact purpose. This is used to keep .ts files up to date, add menu items and things not-in-the-source-code to the translations (and as last step, it regenerates .qm from the .ts) Also, it checks menus for possible bugs and unreachable items and prints warnings if possible bugs found. > But this definitely needs some solution. Agree. Martin Petricek -- GPG/PGP Public key: http://www.petricek.net/petricm.pgp Fingerprint 6AA8 FFCE C061 1CB2 55F0 A1F3 3AA9 EB4F BD50 C1B8 /------------------------------------------------------------\ | WWW: http://www.petricek.net/ | \------------------------------------------------------------/ |