← Back to team overview

ubuntu-packaging-guide-team team mailing list archive

[Merge] lp:~kinggoddard/ubuntu-packaging-guide/913934-fix into lp:ubuntu-packaging-guide

 

Goddard has proposed merging lp:~kinggoddard/ubuntu-packaging-guide/913934-fix into lp:ubuntu-packaging-guide.

Requested reviews:
  Ubuntu Packaging Guide Team (ubuntu-packaging-guide-team)
Related bugs:
  Bug #913934 in Ubuntu Packaging Guide: "[Packaging New Software] Example does not build"
  https://bugs.launchpad.net/ubuntu-packaging-guide/+bug/913934

For more details, see:
https://code.launchpad.net/~kinggoddard/ubuntu-packaging-guide/913934-fix/+merge/91773

Updated version of kqrcode which also fixes other errors in the guide.
-- 
https://code.launchpad.net/~kinggoddard/ubuntu-packaging-guide/913934-fix/+merge/91773
Your team Ubuntu Packaging Guide Team is requested to review the proposed merge of lp:~kinggoddard/ubuntu-packaging-guide/913934-fix into lp:ubuntu-packaging-guide.
=== modified file 'packaging-new-software.rst'
--- packaging-new-software.rst	2011-12-02 18:49:07 +0000
+++ packaging-new-software.rst	2012-02-07 07:40:23 +0000
@@ -8,20 +8,20 @@
 creating a package for Ubuntu or a PPA. This guide will take you through the 
 steps of packaging new software.
 
-Checking the Programme
+Checking the Program
 ----------------------
 
 The first stage in packaging is to get the released tar from upstream (we call
 the authors of applications "upstream") and check that it compiles and runs.
 
 This guide will take you through packaging a simple application called KQRCode
-which has been `posted on KDE-apps.org`_.  Download `version 0.4 from
+which has been `posted on KDE-apps.org`_.  Download `version 0.6.0 from
 Sourceforge`_ and put it in a new directory.
 
 Now uncompress it::
 
-    $ tar xf kqrcode-0.4.tar.gz
-    $ cd kqrcode-0.4
+    $ tar xf kqrcode-0.6.0.tar.gz
+    $ cd kqrcode-0.6.0
 
 This application uses the CMake build system so we want to run cmake to prepare
 for compilation::
@@ -36,23 +36,14 @@
 packages. If you do not have the development files for these libraries installed
 it will fail, you can install them and run CMake again::
 
-    $ sudo apt-get install build-essential libqt4-dev kdelibs5-dev
+    $ sudo apt-get install build-essential libqt4-dev kdelibs5-dev libqrencode-dev libzbar-dev libzbarqt-dev
     $ cmake ..
 
 Now you can compile the source::
 
     $ make
 
-Running this gives some errors about missing headers.  This means there are
-other libraries missing which were not checked by CMake.  Make a note to inform
-upstream of this problem.  `packages.ubuntu.com`_ can be used to find which
-packages these headers come from, install these packages and continue the
-compile::
-
-    $ sudo apt-get install libqrencode-dev libzbar-dev libzbarqt-dev
-    $ make
-
-If the compile completes successfully you can install and run the programme::
+If the compile completes successfully you can install and run the program::
 
     $ sudo make install
     $ kqrcode
@@ -61,10 +52,11 @@
 ------------------
 
 ``bzr-builddeb`` includes a plugin to create a new package from a template,
-the plugin is a wrapper around the ``dh_make`` command::
+the plugin is a wrapper around the ``dh_make`` additionally make sure your
+in the directory where you have your kqrcode tar file. command::
 
     $ sudo apt-get install dh-make
-    $ bzr dh-make kqrcode 0.4 kqrcode-0.4.tar.gz
+    $ bzr dh-make kqrcode 0.6.0 kqrcode-0.6.0.tar.gz
 
 When it asks what type of package type ``s`` for single binary.
 
@@ -79,7 +71,7 @@
 You should now customise each of the files.  
 
 In ``debian/changelog`` change the
-version number to an Ubuntu version: ``0.4-0ubuntu1`` (upstream version 0.4,
+version number to an Ubuntu version: ``0.6.0-0ubuntu1`` (upstream version 0.6.0,
 Debian version 0, Ubuntu version 1).  Also change ``unstable`` to the current
 development Ubuntu release such as ``oneiric``.
 
@@ -90,14 +82,14 @@
 recent version which is ``8``.
 
 ``control`` contains all the metadata of the package.  The first paragraph
-describes the source package.  The second and and following paragraphs describe
+describes the source package. The second and and following paragraphs describe
 the binary packages to be built.  We will need to add the packages needed to
 compile the application to ``Build-Depends:`` so set that to::
 
     Build-Depends: debhelper (>= 7.0.50~), cmake, libqt4-dev, kdelibs5-dev,
     libqrencode-dev, libzbar-dev, libzbarqt-dev
 
-You will also need to fill in a description of the programme in the
+You will also need to fill in a description of the program in the
 ``Description:`` field.
 
 ``copyright`` needs to be filled in to follow the licence of the upstream
@@ -135,11 +127,11 @@
 
 You can view the contents of the package with::
 
-    $ lesspipe kqrcode_0.4-0ubuntu1_amd64.deb
+    $ lesspipe kqrcode_0.6.0-0ubuntu1_amd64.deb
 
 Install the package and check it works::
 
-    $ sudo dpkg --install kqrcode_0.4-0ubuntu1_amd64.deb
+    $ sudo dpkg --install kqrcode_0.6.0-0ubuntu1_amd64.deb
 
 Next Steps
 ----------
@@ -149,8 +141,8 @@
 ``lintian`` which can be run on both the source .dsc metadata file and
 the .deb binary package::
 
-    $ lintian kqrcode_0.4-0ubuntu1.dsc
-    $ lintian kqrcode_0.4-0ubuntu1_amd64.deb
+    $ lintian kqrcode_0.6.0-0ubuntu1.dsc
+    $ lintian kqrcode_0.6.0-0ubuntu1_amd64.deb
 
 A description of each of the problems it reports can be found on the
 `lintian website`_.
@@ -165,7 +157,7 @@
 
     $ bzr builddeb -S
     $ cd ../build-area
-    $ pbuilder-dist oneiric build kqrcode_0.4-0ubuntu1.dsc
+    $ pbuilder-dist oneiric build kqrcode_0.6.0-0ubuntu1.dsc
 
 When you are happy with your package you will want others to review it.  You
 can upload the branch to Launchpad for review::
@@ -176,7 +168,7 @@
 and give an easy way for you and others to test the binary packages.
 You will need to set up a PPA in Launchad then upload with ``dput``::
 
-    $ dput ppa:<lp-username> kqrcode_0.4-0ubuntu1.dsc
+    $ dput ppa:<lp-username> kqrcode_0.6.0-0ubuntu1.dsc
 
 See :doc:`uploading</udd-uploading>` for more information.
 
@@ -212,7 +204,7 @@
 process is documented on the `"New Packages" section of the Ubuntu wiki`_.
 
 .. _`posted on KDE-apps.org`: http://kde-apps.org/content/show.php/KQRCode?content=143544
-.. _`version 0.4 from Sourceforge`: http://sourceforge.net/projects/kqrcode/files/kqrcode-0.4.tar.gz/download
+.. _`version 0.6.0 from Sourceforge`: http://sourceforge.net/projects/kqrcode/files/KQRCode/kqrcode-0.6.0.tar.gz/download
 .. _`packages.ubuntu.com`:  http://packages.ubuntu.com/
 .. _`lintian website`: http://lintian.debian.org/tags.html
 .. _`MOTU mailing list`: https://lists.ubuntu.com/mailman/listinfo/ubuntu-motu


Follow ups