Marble/MaemoPackaging: Difference between revisions
Earthwings (talk | contribs) |
m 9 revisions imported |
||
(5 intermediate revisions by 4 users not shown) | |||
Line 1: | Line 1: | ||
{{improve|This page needs to reflect Marble's move from svn to git. Additionally the creation of language files must be explained. GHNS map themes are missing as well (osmarender and hikebikemap)}} | |||
Maemo packages are based on the Debian package format. The git repository at marble.garage.maemo.org contains necessary files for quick packaging. | Maemo packages are based on the Debian package format. The git repository at marble.garage.maemo.org contains necessary files for quick packaging. | ||
Line 5: | Line 7: | ||
First, we check out a fresh subversion copy of Marble to a temporary directory. Make sure to do this inside scratchbox with the armel target activated if you intend to use the package on the N900. | First, we check out a fresh subversion copy of Marble to a temporary directory. Make sure to do this inside scratchbox with the armel target activated if you intend to use the package on the N900. | ||
< | <syntaxhighlight lang="bash"> | ||
cd "$(mktemp -d)" | cd "$(mktemp -d)" | ||
repo="svn://anonsvn.kde.org/home/kde/trunk/KDE/kdeedu/marble" | repo="svn://anonsvn.kde.org/home/kde/trunk/KDE/kdeedu/marble" | ||
rev="$(svn info "${repo}" | grep Revision | awk '{ print $2 }')" | rev="$(svn info "${repo}" | grep Revision | awk '{ print $2 }')" | ||
svn co "${repo}" "marble-0.10+svn${rev}" | svn co "${repo}" "marble-0.10+svn${rev}" | ||
</ | </syntaxhighlight> | ||
Inside, we'll add the debian packaging files. | Inside, we'll add the debian packaging files. | ||
< | <syntaxhighlight lang="bash"> | ||
cd "marble-0.10+svn${rev}" | cd "marble-0.10+svn${rev}" | ||
git clone https://vcs.maemo.org/git/marble garage | git clone https://vcs.maemo.org/git/marble garage | ||
ln -s garage/packaging/debian | ln -s garage/packaging/debian | ||
</ | </syntaxhighlight> | ||
Update the changelog, if needed. | Update the changelog, if needed. | ||
< | <syntaxhighlight lang="bash"> | ||
dch | dch | ||
</ | </syntaxhighlight> | ||
Afterwards, build the packages: | Afterwards, build the packages: | ||
< | <syntaxhighlight lang="bash"> | ||
dpkg-buildpackage -rfakeroot | LD_LIBRARY_PATH=debian/marble/opt/marble/lib dpkg-buildpackage -rfakeroot | ||
</ | </syntaxhighlight> | ||
Four debian packages -- marble-$version.deb, marble-plugins-$version.deb, libmarble-$version.deb and marble-data-$version.deb -- will end up in the parent directory. Compared to the original Debian package, they contain the following adjustments: | Four debian packages -- marble-$version.deb, marble-plugins-$version.deb, libmarble-$version.deb and marble-data-$version.deb -- will end up in the parent directory. Compared to the original Debian package, they contain the following adjustments: | ||
Line 40: | Line 42: | ||
To install the four packages on your N900, copy them to the device and install them using dpkg. | To install the four packages on your N900, copy them to the device and install them using dpkg. | ||
< | <syntaxhighlight lang="bash"> | ||
scp ../marble*.deb root@IP-OF-N900:/home/user/MyDocs | scp ../marble*.deb root@IP-OF-N900:/home/user/MyDocs | ||
ssh root@IP-OF-N900 -- "dpkg -i /home/user/MyDocs/marble*.deb" | ssh root@IP-OF-N900 -- "dpkg -i /home/user/MyDocs/marble*.deb" | ||
</ | </syntaxhighlight> | ||
You can start Marble on the N900 from the application menu. To uninstall -- how dare you! -- use the application manager. | You can start Marble on the N900 from the application menu. To uninstall -- how dare you! -- use the application manager. |
Latest revision as of 08:05, 21 October 2016
Maemo packages are based on the Debian package format. The git repository at marble.garage.maemo.org contains necessary files for quick packaging.
Creating fresh packages
We are going to check out a fresh subversion copy of Marble, add the debian specific packaging files from the marble garage git repository and build a Maemo .deb package for the armel target. It will be readily usable on the N900.
First, we check out a fresh subversion copy of Marble to a temporary directory. Make sure to do this inside scratchbox with the armel target activated if you intend to use the package on the N900.
cd "$(mktemp -d)"
repo="svn://anonsvn.kde.org/home/kde/trunk/KDE/kdeedu/marble"
rev="$(svn info "${repo}" | grep Revision | awk '{ print $2 }')"
svn co "${repo}" "marble-0.10+svn${rev}"
Inside, we'll add the debian packaging files.
cd "marble-0.10+svn${rev}"
git clone https://vcs.maemo.org/git/marble garage
ln -s garage/packaging/debian
Update the changelog, if needed.
dch
Afterwards, build the packages:
LD_LIBRARY_PATH=debian/marble/opt/marble/lib dpkg-buildpackage -rfakeroot
Four debian packages -- marble-$version.deb, marble-plugins-$version.deb, libmarble-$version.deb and marble-data-$version.deb -- will end up in the parent directory. Compared to the original Debian package, they contain the following adjustments:
- Split into more packages
- Install prefix changed from /usr to /opt/marble (Maemo suggestion)
- Application manager icon contained in the control file
- bin/marble.sh wrapper script that sets PATH, LD_LIBRARY_PATH and XDG_DATA_HOME
- marble.desktop and marble.service files for application menu integration
- Marble icons copied to /usr/share/icons/hicolor/apps/
Currently there is a bug related to scratchbox which affects the creation of the marble-data.deb package. It will contain too little data when created on the ARMEL target. As this will trigger a segfault on the N900, the marble-data.deb package must be created on the X86 target. Because the -data package is architecture independent, you can just overwrite the faulty package created on ARMEL.
To install the four packages on your N900, copy them to the device and install them using dpkg.
scp ../marble*.deb root@IP-OF-N900:/home/user/MyDocs
ssh root@IP-OF-N900 -- "dpkg -i /home/user/MyDocs/marble*.deb"
You can start Marble on the N900 from the application menu. To uninstall -- how dare you! -- use the application manager.