Packaging Frescobaldi for Debian/Ubuntu
I co-maintain the Debian package for Frescobaldi,
an excellent LilyPond sheet music text editor.
This blog post documents the steps to svn-buildpackage
to prepare
and upload the frescobaldi
Debian package when a new version is available.
(This is still a working draft. Please forgive some of my random disorganized notes.)
What to do when a new upstream version is released?
1. Upgrade the local build environment
sudo apt-get update
sudo apt-get dist-upgrade
sudo cowbuilder --update --override-config
2. Fetch the new upstream version
cd /work/debian/frescobaldi
svn update
cd trunk
debian/rules get-orig-source
mv -vi frescobaldi* ../tarballs/
dch -i
Note: svn-upgrade
is not used because it is not yet aware of uscan’s
repacked package, resulting in the error:
couldn't find the downloaded file at /usr/bin/svn-upgrade line 71.
sudo cowbuilder --update --override-config
- esp. when changing mirror, e.g. from ftp.hk.debian.org to ftp.ca.debian.org
3. Revise–Test Build cycle:
# Research, edit debian/* ...
vim debian/copyright
#
svn-buildpackage -us -uc --svn-ignore-new or svn-do pdebuild
4. Final build
# Change `UNRELEASED` to `unstable`, and update the timestamp
# in debian/changelog
dch -r
# Do a final check
svn status
# Commit all changed files
svn commit -m "Release frescobaldi 2.17.2+ds1-1 for Debian"
# Alternatively, to commit only some specified files:
# svn commit debian/files-to-commit
And finally:
svn-buildpackage --svn-builder="pdebuild --buildresult `pwd`/../build-area --auto-debsign" --svn-lintian --svn-tag --svn-noautodch
5. Final verifications before upload
debc # To look at the file list
sudo debi # To install locally
# Look at the build area:
ls ../build-area/ -lrt
# Examine build log
less ../build-area/frescobaldi_2.17.2+ds1-1_amd64.build
6. Upload!
dput ../build-area/frescobaldi_2.17.2+ds1-1_amd64.changes
Done!
7. Follow-up
- Look for a message titled “frescobaldi_2.17.2+ds1-1_amd64.changes ACCEPTED into unstable” sent by ftpmaster@ftp-master.debian.org to your mailbox.
- A day later, the new package should appear on https://packages.debian.org/frescobaldi and http://packages.ubuntu.com/frescobaldi
Troubleshooting: To revise a commit log message:
ssh svn.debian.org
cd /svn/python-apps/hooks
cp -vi pre-revprop-change.tmpl pre-revprop-change
chmod +x pre-revprop-change
# Local machine
EDITOR=vim svn propedit -r xxxxx --revprop svn:log
# On svn.debian.org
rm pre-revprop-change
Regular maintenance:
sudo cowbuilder --update --override-config
- esp. when changing mirror, e.g. from ftp.hk.debian.org to ftp.ca.debian.org
cd /work/debian/frescobaldi/trunk
svn-do pdebuild
Every half year?
sudo rm -rf /var/cache/pbuilder/base.cow/
sudo pbuilder --clean
- removes /var/cache/pbuilder/build/ and /var/cache/pbuilder/aptcache/
sudo cowbuilder --create
- This will take about 15 minutes?
Hyphenation is missing for many languages…
- Ryan (rak) removed
frescobaldi_app/hyphdict/*
to avoid duplication and the complexity of tracking copyrights. - However Debian’s hyphenation is incomplete. For example,
hyph_nl_NL.dic
,hyph_uk.dic
, etc. are missing.
Ubuntu is improving it:
- openoffice.org-hyphenation (Ubuntu-only package), which contains e.g.
hyph_nl
- libreoffice-dictionaries, replacing the outdated openoffice.org-dictionaries still in Debian.
Licensing issue (OpenOffice.org)
Someone called “doko” filed mass bug reports on openoffice.org:
- meta report for license issues of hyphenation patterns available on the web site https://issues.apache.org/ooo/show_bug.cgi?id=74283
hyph_nl_NL.dic
:
Miscellaneous
- The License field should use
A, and B or C
, notA and (B or C)
- LPPL-1.3c: https://latex-project.org/lppl.txt
- Reflections on the history of the LATEX Project Public License (LPPL) — A software license for LATEX and more http://latex-project.org/papers/tb100mittbach-lppl-history.pdf
- http://opensource.org/licenses/LPPL-1.3c
- SISSL-1.1:
PortMIDI
- https://github.com/wbsoft/frescobaldi/issues/3
frescobaldi_app/portmidi/__init__.py
Key points:
Debian packaging
- Packaged by Ryan. He got too busy with school work in latter half of 2013, and the package fell behind.
- PAPT (Python Application Team): https://alioth.debian.org/projects/python-apps/
- Besides applying to join the team on Alioth, I needed to write
- Build with svn-buildpackage
- Browse: http://anonscm.debian.org/viewvc/python-apps/packages/frescobaldi/
- Note, only the debian/ directory is committed in the SVN repository.
- Repack source… +ds1
- Old method:
clean-up.sh
?XZ_OPT=-9v fakeroot tar cvJf frescobaldi_2.0.13+ds1.tar.xz frescobaldi-2.0.13+ds1
- New method
- TODO
- Old method:
Chinese L10n:
- Fork from upstream author Wilbert Berendsen’s GitHub https://github.com/wbsoft/frescobaldi to https://github.com/anthonyfok/frescobaldi
- To add: zh_CN, zh_HK, zh_TW
- First began translating in
- Start with zh_TW, and auto-convert to zh_CN and zh_HK?
- Lokalize?
Keeping my branch updated: (see http://robots.thoughtbot.com/keeping-a-github-fork-updated)
git fetch upstream
git checkout master
git rebase upstream/master
git push
git checkout l10n-zh
git rebase upstream/master
cd frescobaldi_app/po
make zh_TW.po # runs msgmerge
cd ../..
cd frescobaldi_app/language_names
# ensure my changes are in:
What about my l10n-zh branch?
KDE L10n, esp. zh_HK
- http://l10n.kde.org/stats/gui/trunk-kde4/essential/
- http://community.kde.org/KDE_Localization/zh-cn/Translate
- http://lists.kde.org/?l=kde-i18n-doc&m=137311277131368&w=1
Howard Chan (smartboyhw)
弗雷斯科巴爾迪
http://lilypond.blog.sohu.com/
Working with SVN and svn-buildpackage
Refer to: https://wiki.debian.org/svn-buildpackage
(To be organized)
foka@debian-Aspire-M5-481G:/work/debian/frescobaldi/trunk$ svn proplist ./debian/
Properties on ‘debian’:
mergeWithUpstream
Fetch new upstream source:
go to a previous build-area, e.g. /work/debian/frescobaldi/build-area/frescobaldi-2.0.13+ds1.obsolete.0.119643281520442, and run “uscan”, which reads debian/watch and fetch the tarball from GitHub.
cd .. tar xf frescobaldi-2.0.16.tar.gz cd frescobaldi-2.0.16 ../frescobaldi-2.0.13+ds1.obsolete.0.119643281520442/debian/cleanup.sh mv frescobaldi-2.0.16 frescobaldi-2.0.16+ds1 XZ_OPT=-9v fakeroot tar cvJf frescobaldi_2.0.16+ds1.orig.tar.xz frescobaldi-2.0.16+ds1
After upload (?), do a
svn update
to fetch the tag in svn.
Assorted Links
- http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=729688
- http://community.kde.org/KDE_Localization/zh-cn/Translate
- http://l10n.kde.org/team-infos.php?teamcode=zh_TW
To add:
- https://wiki.debian.org/Teams/PythonAppsPackagingTeam/HowToPBuilder
- https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=685506
- https://wiki.debian.org/UscanEnhancements
- https://workaround.org/debian-subversion-pbuilder
Note to self:
- The upstream Frescobaldi is maintained in GitHub. Ironically, the Debian frescobaldi package is maintained in SVN because the Python Applications Packaging Team python-apps-team@lists.alioth.debian.org maintains everything in SVN.
History / Log
- 2014-01-18: Uploaded frescobaldi_2.0.13+ds1; wrote note in /home/foka/wiki-frescobaldi.txt
- 2014-07-25: Old build in /work/debian/frescobaldi-2.0.16+ds1
- 2014-07-25: Contributed “Initial l10n for Chinese (zh_CN, zh_HK, zh_TW)”
- 2014-07-26: Wilbert Berendsen merged my pull request.
- 2014-08-02: Updated debian/watch
- 2014-08-05: Updated debian/README.source
- 2014-09-17: Moved this document from Google Docs to Hugo Markdown
- 2014-08-07: Last touched debian/copyright
- 2014-12-20: Touching frescobaldi again
- 2014-12-21: Uploaded frescobaldi (2.0.16+ds1-1)
- 2014-12-27: Uploaded frescobaldi (2.17.1+ds1-1)
- 2015-01-25: Uploaded frescobaldi (2.17.2+ds1-1)
- 2015-09-15: Uploaded frescobaldi (2.18.1+ds1-1)
- 2015-09-15: Uploaded frescobaldi (2.18.1+ds1-2)
- 2015-11-21: Uploaded frescobaldi (2.18.1+ds1-3)
- 2015-12-26: Packaged frescobaldi 2.18.2 but not uploaded… It turns out I need to upgrade python-ly from 0.9.2 to 0.9.3 first.