Issue 31784 - postset.mk: simplify handling of languages for build
Summary: postset.mk: simplify handling of languages for build
Status: CLOSED FIXED
Alias: None
Product: Build Tools
Classification: Code
Component: solenv (show other issues)
Version: current
Hardware: All All
: P3 Trivial (vote)
Target Milestone: OOo 2.0
Assignee: hjs
QA Contact: issues@tools
URL:
Keywords:
Depends on: 35233
Blocks:
  Show dependency tree
 
Reported: 2004-07-20 16:52 UTC by pavel
Modified: 2006-03-14 21:03 UTC (History)
6 users (show)

See Also:
Issue Type: PATCH
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
micro-specification (6.92 KB, application/vnd.sun.xml.writer)
2004-10-09 06:11 UTC, pavel
no flags Details
Patch for config_office (4.05 KB, patch)
2004-10-09 06:12 UTC, pavel
no flags Details | Diff
Patch for solenv (4.35 KB, patch)
2004-10-09 06:12 UTC, pavel
no flags Details | Diff
Updated specs and patches (9.89 KB, application/x-gzip)
2004-10-09 21:28 UTC, pavel
no flags Details
new version of spec - some TODOs fixed or magically disappeared (8.44 KB, application/vnd.sun.xml.writer)
2004-10-11 18:49 UTC, pavel
no flags Details
updated specification (9.08 KB, application/vnd.sun.xml.writer)
2004-10-23 20:42 UTC, pavel
no flags Details
Final update of the specs. (9.42 KB, application/vnd.sun.xml.writer)
2004-10-24 20:13 UTC, pavel
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description pavel 2004-07-20 16:52:09 UTC
pavel@linux:~/.ooo/ooo_cws_src680_ooo20040704_src/solenv/inc> grep
give_me_all_languages postset.mk |wc -l
32

There are 32 references to this variable in postset.mk. Remove them and leave
only one. If it is non-empty, define alllangiso to be equal to completelangiso.

Also think of using macros to define language. For every language we currently have:

.IF "$(RES_CZECH)"!="" || "$(give_me_all_languages)"!=""  
alllangiso+=cs
.ENDIF
completelangiso+=cs

After reducing the handling of give_me_all_languages, we will have:

.IF "$(RES_CZECH)"!=""
alllangiso+=cs
.ENDIF
completelangiso+=cs

There are two parameters: RES_CZECH (or simply put CZECH) and cs. The same with
only two variable parts will be repeated for all languages...

This is only single step from using RES_cs for cs iso code...
Comment 1 hjs 2004-07-20 17:06:58 UTC
i would rather focus on replacing multiple "RES_*" variables with a single blank
seperated variable containing  all active languages.
"postset.mk" would just keep "completelangiso", the list of know languages which
may be used to extend "alllangiso" if give_me_.... is set.

this can be done in just one step, i think.
Comment 2 pavel 2004-07-20 17:41:28 UTC
We discussed this more on IRC:

- configure will use --with-lang="cs sk en de ..."

- the default is en-US (if with-lang is not specified to empty)
  solenv/inc/postset.mk:defaultlangiso=en-US will contain the default value

- allow using --with-lang="ALL cs"
Comment 3 pavel 2004-10-09 06:11:49 UTC
Created attachment 18255 [details]
micro-specification
Comment 4 pavel 2004-10-09 06:12:29 UTC
Created attachment 18256 [details]
Patch for config_office
Comment 5 pavel 2004-10-09 06:12:56 UTC
Created attachment 18257 [details]
Patch for solenv
Comment 6 pavel 2004-10-09 06:14:31 UTC
Hi,

I attached three files - micro-specification of how it should work and actual
implementation of proposed changes in config_office and solenv modules.

Please test and report results.

As hjs is on vacation, I won't commit it and will test it in my build system
from now on.
Comment 7 pavel 2004-10-09 07:43:59 UTC
BUG: autocorr_en-US is not generated.
Comment 8 pavel 2004-10-09 17:48:10 UTC
autocorr_en-US is fixed now. autocorr* files use completelangiso where en-US is
missing. OK, I added it there.

I'll attached fixed files tonight.
Comment 9 pavel 2004-10-09 21:27:18 UTC
OK, new version of files coming. I'll attach all of them in one tar.gz file.

Spec-#i31784#.sxw - updated specification, see TODOs section

OOo_SRC680_m56_source-i31784-dmake-languages.diff - this file adds top-level
target "languages" to print configured languages. This is mainly for debugging.

OOo_SRC680_m56_source-i31784-config_office.diff
OOo_SRC680_m56_source-i31784-solenv.diff

Updated patches.
Comment 10 pavel 2004-10-09 21:28:04 UTC
Created attachment 18264 [details]
Updated specs and patches
Comment 11 pavel 2004-10-11 18:49:16 UTC
Created attachment 18288 [details]
new version of spec - some TODOs fixed or magically disappeared
Comment 12 pavel 2004-10-17 14:11:57 UTC
Ause: welcome back from vacation. Hope you are fresh for providing comment :-)
Comment 13 ivo.hinkelmann 2004-10-19 12:06:23 UTC
ihi CC
Comment 14 ivo.hinkelmann 2004-10-19 19:02:16 UTC
solenv/config/ssrc680.ini
solenv/config/ssrx645.ini

Those files are needed by the localize_sl tool to fetch the module list,
I think you can remove any RES_* , but please test/ensure that localize_sl is
extracting source languages after the removal.

When #i34408# is fixed those files are obsolete
Comment 15 pavel 2004-10-19 20:34:41 UTC
ihi: these files are not used for anything else right now? Should I really edit
also *645*? Why we have it in 680?
Comment 16 ivo.hinkelmann 2004-10-20 11:57:10 UTC
Pavel, I confound those files with stand.lst . Ause told me that those *.ini
files will be importent in the future for OOo and are very importend for us here
in HH, so do not thouch them!
Comment 17 pavel 2004-10-23 20:41:39 UTC
I fixed everything (except en-US always first for which I have to find optimal
solution) to withlang child workspace. Please test.

New specs attached.
Comment 18 pavel 2004-10-23 20:42:43 UTC
Created attachment 18623 [details]
updated specification
Comment 19 pavel 2004-10-24 18:11:40 UTC
en-US will always be the first one with this line (it should really be one line
in postset.mk):

alllangiso=$(strip $(defaultlangiso) $(subst,$(defaultlangiso), $(uniq
$(subst,ALL,$(completelangiso) $(WITH_LANG)))))

hjs: what do you think about it? Can it be simplified?
Comment 20 pavel 2004-10-24 20:13:20 UTC
Created attachment 18630 [details]
Final update of the specs.
Comment 21 pavel 2004-10-24 20:14:24 UTC
OK, fixed in cws withlang. Reassigning to hjs for verification and update of RE
environment.
Comment 22 pavel 2004-10-24 20:14:57 UTC
Fixed.
Comment 23 hjs 2004-10-25 12:48:34 UTC
.
Comment 24 pavel 2004-11-03 08:15:13 UTC
closing.