Uploading to Extras-devel

("non-free" packages)
Line 124: Line 124:
=== "non-free" packages ===
=== "non-free" packages ===
-
Publishing non-free packages in the Maemo Extras repository for Diablo is done via dput. Direct upload of binary packages is allowed for non-free packages only.
+
Publishing non-free packages in the Maemo Extras Testing repository for Diablo is done via dput. Direct upload of binary packages is allowed for non-free packages only.
-
Settings for <code>dput.cf</code> for Diablo Extras-Devel non-free:
+
Settings for <code>dput.cf</code> for Diablo Extras-Testing non-free:
-
  [diablo-extras-devel-non-free]
+
  [diablo-extras-testing-non-free]
  login = <your_garage_login_name>
  login = <your_garage_login_name>
  fqdn = garage.maemo.org
  fqdn = garage.maemo.org
Line 134: Line 134:
  hash = md5
  hash = md5
  allow_unsigned_uploads = 1
  allow_unsigned_uploads = 1
-
  incoming = /var/www/extras-devel/incoming-nonfree/diablo
+
  incoming = /var/www/extras-testing/incoming-nonfree/diablo
   
   
  [diablo-extras-non-free]
  [diablo-extras-non-free]

Revision as of 10:41, 25 November 2009

Extras is the recommended home for all Maemo software. It provides an easy mechanism for users to discover new applications, and can help ensure quality and continued support for applications and their authors.

Contents

Pre-requisites

Three things are necessary to upload to maemo.org Extras:

  • A Garage account: [signup]
  • An "invitation" to upload: [request]
  • ssh-keygen (optional: not needed if only going to use the web-based upload)

Setup

Setting up SSH to upload to extras

This step is unnecessary if you are only going to use the web-based Extras Assistant wizard to upload.

Put your SSH key[1] online:

  • If you need to create an RSA SSH key (make sure it is an RSA key):
    1. ssh-keygen -t rsa (enter, enter, passphrase (if desired), enter).
  • Copy the contents of ~/.ssh/id_rsa.pub in the "Public SSH keys" section of your garage account maintenance page. This will be available once your upload-invitation request has been accepted

Setting up Scratchbox to use the Extras repository

Add the extras repository to your Scratchbox install:

  1. Login to Scratchbox
  2. Create /etc/apt/sources.list.d/extras-repo.list
  3. Update apt's information.

Note: this should be done in both your ARMEL and x86 targets.

/scratchbox/login
cat >/etc/apt/sources.list.d/extras-repo.list <<EOT
#Maemo extras
deb http://repository.maemo.org/extras/ fremantle free non-free
deb-src http://repository.maemo.org/extras/ fremantle free
EOT
fakeroot apt-get update

Preparing a source package

There are three main routes to creating source packages:

  1. Using Debian tooling directly.
  2. Using mud-builder to help repackage existing upstream sources.
  3. Using py2deb for Python applications.

Debian tooling

Once your source tree contains a debian directory, create your package with dpkg-buildpackage in the project source directory:

dpkg-buildpackage -rfakeroot -sa -S -i

If you use git then you may not want to include the entire git repo in your source bundle. With dpkg-source version 1.13.25 the -i option isn't git-aware so you can do:

 dpkg-buildpackage -rfakeroot -sa -S -i -I.git

You may verify that your Build-Depends field in debian/control is complete by running

dpkg-depcheck -m dpkg-buildpackage -rfakeroot -b

in the source tree. (You'll need to fakeroot apt-get install devscripts for this to work).

mud-builder

mud-builder uses a simple XML file to define an upstream source location (such as an svn location, web-based tarball or existing Debian package), it then handles the Maemo packaging specifics, builds a source package ready to upload and can even upload directly to Extras using a few simple commands:

mud build vim
mud upload vim

py2deb

Python applications can be developed outside of Scratchbox. py2deb makes it easy to build packages ready for upload from a Python script.

Upload

"free" packages

There are three mechanisms for uploading packages:

  1. The Extras Assistant is a web-based wizard, which guides you through the process.
  2. Debian's dput tool[2] which uses SSH.
  3. SSH directly (using scp[3]).

dput

The /etc/dput.cf (or ~/.dput.cf) sections for free packages are:

[DEFAULT]
default_host_main = diablo-extras-builder

[chinook-extras-builder]
login = <your_garage_login_name>
fqdn = garage.maemo.org
method = scp
hash = md5
allow_unsigned_uploads = 1
incoming = /var/www/extras-devel/incoming-builder/chinook

[diablo-extras-builder]
login = <your_garage_login_name>
fqdn = garage.maemo.org
method = scp
hash = md5
allow_unsigned_uploads = 1
incoming = /var/www/extras-devel/incoming-builder/diablo

[fremantle-extras-builder]
login = <your_garage_login_name>
fqdn = garage.maemo.org
method = scp
hash = md5
allow_unsigned_uploads = 1
incoming = /var/www/extras-devel/incoming-builder/fremantle


Then run:

dput -f fremantle-extras-builder PACKAGE_VERSION_*.changes
dput -f diablo-extras-builder PACKAGE_VERSION_*.changes
dput -f chinook-extras-builder PACKAGE_VERSION_*.changes


For the single default case you should be able to do:

dput PACKAGE_VERSION_source.changes

and it should go to diablo-extras-builder (because of the DEFAULT:default_host_main setting.

scp

Using scp directly is trivial:

scp *.tar.gz *.diff.gz *.changes *.dsc <your_garage_login_name>@garage.maemo.org:/var/www/extras-devel/incoming-builder/chinook/
scp *.tar.gz *.diff.gz *.changes *.dsc <your_garage_login_name>@garage.maemo.org:/var/www/extras-devel/incoming-builder/diablo/
scp *.tar.gz *.diff.gz *.changes *.dsc <your_garage_login_name>@garage.maemo.org:/var/www/extras-devel/incoming-builder/fremantle/


Note: Make sure you upload your .dsc files last. The .dsc file triggers a build and the autobuider might reject the package because of missing files.

"non-free" packages

Publishing non-free packages in the Maemo Extras Testing repository for Diablo is done via dput. Direct upload of binary packages is allowed for non-free packages only.

Settings for dput.cf for Diablo Extras-Testing non-free:

[diablo-extras-testing-non-free]
login = <your_garage_login_name>
fqdn = garage.maemo.org
method = scp
hash = md5
allow_unsigned_uploads = 1
incoming = /var/www/extras-testing/incoming-nonfree/diablo

[diablo-extras-non-free]
login = <your_garage_login_name>
fqdn = garage.maemo.org
method = scp
hash = md5
allow_unsigned_uploads = 1
incoming = /var/www/extras/incoming-nonfree/diablo

Upload with dput:

dput -f diablo-extras-devel-non-free PACKAGE_VERSION_*.changes

The packages are imported into the repository once per hour.

Please make sure your dependencies are correct. If there is a dependency problem between a free and a non-free package, the non-free package will most likely be removed first. (As we can recompile free packages, but can't do that for non-free ones)

There is no promotion available for non-free. You need to upload your package to the right repository yourself.

Autobuilder special considerations

If it builds under your local Scratchbox but doesn't on the autobuilder, you need to do the above dependency check (dpkg-depcheck) and/or otherwise correct the Build-Depends field: the builder uses the minimal rootstrap and only adds extra packages if they are mentioned in this field. This includes most -dev versions which include the special libraries and includes, and the pkg-config metadata; so applies to almost everything.

See Building packages with sbdmock for information on using the sbdmock tool to test your package build in a clean scratchbox environment before submitting to the autobuilder.

If you do not know what to write in the Build-Depends field, then in your scratchbox, install devscripts (apt-get install devscripts) and then run dpkg-genbuilddeps -rfakeroot in your source directory. The package will build in scratchbox and at the end, you will see a list of Build-Depends. Use common sense to figure out which Build-Depends you need to add. -dev packages are usually a good bet.

Also make sure the Section: in the control file is all lowercase, e.g. "user/navigation" not "user/Navigation", otherwise after building it will silently fail and NOT be moved to extras-devel.

In addition, one additional idea to increase package quality is to introduce Maemian, a lintian-like tool for Maemo . This would help in doing additional checks for common inconsistencies and errors.

Promotion

After the autobuilder builds a package, it will be available in Extras-Devel. This is the experimental repository.

Please make sure your package is ready for users by testing:

  • if it installs without problems
  • if it uninstalls without problems
  • if it doesn't introduce dependency problems for other packages.

You can promote your package to Extras with the promotion interface.

Promotion from Fremantle Extras-devel to Extras-testing and Extras-testing to Extras is done through the maemo.org package interface and the process is described at Promoting packages to extras-testing.

Resources

Reference

Template:Refs


Cite error: <ref> tags exist, but no <references/> tag was found