Hi!

I've been trying to build an updated doudoulinux-l10n-fi package using the latest translations from Transifex and the scripts found in the DDL SVN repository, so that I could try out my translations for real (instant gratification, if you remember my previous posting about translator motivation).

However, I couldn't yet make it work. I'm using a laptop with DDL 2.1 (Debian Squeeze based) installed on the hard drive.

Here's what I did:

0. Install prerequisites:

# apt-get install subversion unaccent debhelper fakeroot python-polib python-pip
# pip install transifex-client

(transifex-client is not available as deb for squeeze, so this will install the latest version 0.10 from PyPI)

1. Checkout DDL l10n code from SVN:

$ export LANG=en_US.utf8
(just to get all errors in English so I can post them here!)
$ mkdir doudoulinux-svn
$ cd doudoulinux-svn
$ for dir in lang live packages; do mkdir $dir; svn co http://svn.gna.org/svn/doudoulinux/$dir/trunk $dir/trunk; done
(this took a while and requires around 1GB disk space)

2. Set up transifex connection

$ cd lang/trunk
$ ./transifex init all
(this prompts for transifex username and password and stores them in ~/.transifexrc)

I had some trouble with this at first, because the Transifex URL used by transifex-client has changed from http://www.transifex.net to https://www.transifex.com and the client complains about the changed URL. I had to change the URL in the transifex script and also in all .tx/config files. Patch available here: http://iki.fi/osma/transifex.net-com.patch

3. Pull the latest translations from Transifex

$ ./transifex pull all fi

This seemed to get the latest Finnish translation updates - actually only one change I deliberately did to gcalctool translations, the others seemed to be already up to date in SVN. This takes a while to run.

4. Prepare the localization source package

$ cd ../../packages/trunk/l10n
$ nano make-l10n.sh
(edited the AUTHOR declaration near the beginning, in order not to impersonate Jean-Michel!)
$ ./make-l10n.sh fi

I get output with some complaints about missing directories:

--cut--
*** processing language fi ***
updating 'doudoulinux-l10n-fi'
compiling PO files
compiling Songwrite PO files
compiling GmChess PO files
compiling TS files
mv: cannot stat `../../../lang/trunk/apps/work/goldendict/ts/fi.qm': No such 
file or directory
mv: cannot stat `../../../lang/trunk/apps/education/tanglet/ts/tanglet_fi.qm': 
No such file or directory
mv: cannot stat 
`../../../lang/trunk/apps/multimedia/pianobooster/ts/pianobooster_fi.qm': No 
such file or directory
mv: cannot stat 
`../../../lang/trunk/apps/multimedia/stopmotion/ts/stopmotion_fi.qm': No such 
file or directory
mv: cannot stat 
`../../../lang/trunk/apps/multimedia/hydrogen/ts/hydrogen.fi.qm': No such file 
or directory
mv: cannot stat `../../../lang/trunk/apps/multimedia/vmpk/ts/vmpk_fi.qm': No 
such file or directory
copying extra l10n files
ERROR: no script '../../../lang/trunk/apps/work/laby/.locale.sh' for 
'../../../lang/trunk/apps/work/laby/.locale'
ERROR: no script '../../../lang/trunk/apps/work/laby/levels.orig.sh' for 
'../../../lang/trunk/apps/work/laby/levels.orig'
WARNING: no data directory 
'../../../lang/trunk/apps/education/gcompris/voices/fi', aborting…
  copying '../../../lang/trunk/apps/education/khangman/data/fi' into 
'doudoulinux-l10n/data/usr/share/kde4/apps/kvtml'
WARNING: no data directory 
'../../../lang/trunk/apps/education/childsplay_sp/lfc/fi', aborting…
WARNING: no data directory 
'../../../lang/trunk/apps/education/childsplay_sp/alphabet/fi', aborting…
WARNING: no data directory 
'../../../lang/trunk/apps/education/childsplay_sp/wordlist/fi', aborting…
WARNING: no data directory 
'../../../lang/trunk/apps/education/childsplay_sp/pongdata/fi', aborting…
WARNING: no data directory 
'../../../lang/trunk/apps/education/childsplay_sp/images/fi', aborting…
  copying '../../../lang/trunk/apps/education/ktuberling/sounds/fi' into 
'doudoulinux-l10n/data/usr/share/kde4/apps/ktuberling/sounds'
WARNING: no data directory 
'../../../lang/trunk/apps/education/pysycache/lang/fi', aborting…
WARNING: no data directory 
'../../../lang/trunk/apps/education/kanagram/data/fi', aborting…
ERROR: no script '../../../lang/trunk/apps/system/dansguardian/lists.sh' for 
'../../../lang/trunk/apps/system/dansguardian/lists'
ERROR: no script '../../../lang/trunk/apps/games/gmchess/orig.sh' for 
'../../../lang/trunk/apps/games/gmchess/orig'
WARNING: no data directory 
'../../../lang/trunk/apps/doudoulinux/doudoulinux-utils/sounds/fi', aborting…
compiling Laby translation files
/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n/data/usr/share/laby
processing texts.orig
processing levels.orig/0.laby
processing levels.orig/1a.laby
processing levels.orig/1b.laby
processing levels.orig/1c.laby
processing levels.orig/2a.laby
processing levels.orig/2b.laby
processing levels.orig/2c.laby
processing levels.orig/3a.laby
processing levels.orig/3b.laby
processing levels.orig/4a.laby
processing levels.orig/4b.laby
removing temp files and .svn dirs

Please check the debian/changelog file before recompiling the packages
--cut--

Anyway I continued, assuming that the errors are simply due to missing translations and not any show-stoppers.

$ less doudoulinux-l10n/debian/changelog
(checked that it looks sane and has my author information)

5. Build the source package

$ cd ..
$ ./build-debs.sh doudoulinux-l10n

Here's where things start going seriously wrong I think. Output:

--cut--
*** building custom package 'doudoulinux-l10n'
[: 250: doudoulinux-l10n: unexpected operator
dpkg-source: warning: no source format specified in debian/source/format, see 
dpkg-source(1)
dpkg-source: info: using source format `1.0'
dpkg-source: info: building doudoulinux-l10n in 
doudoulinux-l10n_2.2-4+20140223.tar.gz
dpkg-source: info: building doudoulinux-l10n in 
doudoulinux-l10n_2.2-4+20140223.dsc
dh_testdir
# Add here commands to configure the package.
touch configure-stamp
dh_testdir
# Add here commands to compile the package.
/usr/bin/make
make[1]: Entering directory 
`/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory 
`/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n'
#docbook-to-man debian/doudoulinux-l10n.sgml > doudoulinux-l10n.1
touch build-stamp
dh_testdir
dh_testroot
dh_prep dh_installdirs
# Add here commands to install the package into debian/doudoulinux-l10n.
/usr/bin/make 
DESTDIR=/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n/debian/doudoulinux-l10n
 install
make[1]: Entering directory 
`/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n'
# copy all data files
if ! [ -d 
/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n/debian/doudoulinux-l10n
 ]; then mkdir 
/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n/debian/doudoulinux-l10n;
 fi
cp -a data/* 
/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n/debian/doudoulinux-l10n
# copy scripts
mkdir -p 
/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n/debian/doudoulinux-l10n/usr/lib/doudoulinux-l10n
cp src/update-l10n 
/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n/debian/doudoulinux-l10n/usr/lib/doudoulinux-l10n/
cp src/update-kde-settings 
/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n/debian/doudoulinux-l10n/usr/lib/doudoulinux-l10n/
mkdir -p 
/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n/debian/doudoulinux-l10n/usr/share/doudoulinux-l10n
cp gdm/locale.conf 
/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n/debian/doudoulinux-l10n/usr/share/doudoulinux-l10n/
# clean useless files
find 
/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n/debian/doudoulinux-l10n
 -depth -name .svn -exec rm -fr {}/ \;
make[1]: Leaving directory 
`/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n'
dh_testdir
dh_testroot
dh_installchangelogs dh_installdocs
dh_installexamples
dh_install 
--sourcedir=/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n/debian/doudoulinux-l10n
cp: cannot stat `debian/tmp//usr/share/apps/goldendict/locale/fi.qm': No such 
file or directory
dh_install: cp -a debian/tmp//usr/share/apps/goldendict/locale/fi.qm 
debian/doudoulinux-l10n-fi-updates///usr/share/apps/goldendict/locale/ returned 
exit code 1
make: *** [binary-arch] Error 2
dh_testdir
dh_testroot
rm -f build-stamp configure-stamp
# Add here commands to clean up after the build process.
/usr/bin/make 
DESTDIR=/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n/debian/doudoulinux-l10n
 clean
make[1]: Entering directory 
`/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n'
rm -fr 
/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n/debian/doudoulinux-l10n
make[1]: Leaving directory 
`/home/tux/svn/doudoulinux/packages/trunk/l10n/doudoulinux-l10n'
dh_clean *** moved source packages to 'sources'
--cut--

The end result is that I get source packages under sources/, but the binary package is not built.

I could go on investigating why the script fails, but since I've already tried a number of things I thought this would be a good time to ask for help. I'm not sure which of the above warnings and errors are serious and which are expected. So what am I doing wrong above? Are the scripts supposed to work on DDL 2.1 (squeeze), or should I try a wheezy-based system instead?

If I can get this working this could be easily turned into a HOWTO for the website. This way translators could actually see the results of their hard work without having to prod Jean-Michel or wait for the next release :)

-Osma

--
*** Osma Suominen / Osuuskunta Sange *** [email protected] ***
***      PL 197, 00131 Helsinki      ***     040 - 5255 882     ***
_______________________________________________
Doudoulinux-lang mailing list
[email protected]
https://mail.gna.org/listinfo/doudoulinux-lang

Reply via email to