dolibarr/dev/build/launchpad/README

155 lines
5.1 KiB
Plaintext
Raw Permalink Normal View History

2012-01-23 12:37:53 +01:00
README (English)
##################################################
Launchpad Package tools
##################################################
This directory contains files to explain how to publish
a package onto LaunchPad
# This is standard command to work on RPM packaging:
#
# To install all packagers tools:
2012-01-30 01:31:00 +01:00
# sudo apt-get install bzr-builder bzr dpatch pbuilder debootstrap devscripts
2012-01-23 12:37:53 +01:00
2012-01-30 00:42:47 +01:00
# Init local working env
#----------------------------------
2012-01-23 12:37:53 +01:00
- Create account on launchpad.org
- Create Project
- Link project to official SCM server
- Upload SSH public key onto account
2012-01-30 20:08:11 +01:00
- Upload you GPG sign key
2025-01-05 14:28:07 +01:00
- Run from command line:
2012-01-29 20:57:40 +01:00
bzr launchpad-login yourlogin
bzr whoami "Your Name <email@email.com>"
bzr whoami
2012-12-31 03:13:11 +01:00
- Edit file ~/.bashrc to add
2025-01-05 14:28:07 +01:00
DEBFULLNAME="<Your name>"
DEBEMAIL="<Your email address>"
2013-04-23 13:38:00 +02:00
- Create a Bazaar directory
mkdir bzr
2012-12-31 03:13:11 +01:00
If you want to build or test package locally:
- Create a file ~/.pbuilderrc with content
2012-01-30 00:42:47 +01:00
COMPONENTS="main universe multiverse restricted"
- Create chroot ubuntu env
2012-01-30 01:31:00 +01:00
sudo pbuilder create [--distribution sid|squeeze]
2012-01-30 00:42:47 +01:00
2013-04-23 13:38:00 +02:00
# Push/declare Dolibarr sources to Launchpad
#----------------------------------
2025-01-05 14:28:07 +01:00
- From Launchpad project (https://launchpad.net/dolibarr), register a series:
Call it 'trunk' or 'stable'
2013-04-23 13:38:00 +02:00
Use branch (dev):
https://launchpad.net/~eldy/dolibarr/develop
https://launchpad.net/~eldy/dolibarr/stable
2025-01-05 14:28:07 +01:00
or
Use URL pattern (stable):
For stable: http://www.dolibarr.org/files/lastbuild/package_debian-ubuntu/dolibarr_x.z.*.tar.gz
2025-01-05 14:28:07 +01:00
- For Dev, you can also add link series to GIT HEAD.
- For stable, you can init from command line
cd bzr/dolibarr-stable
bzr init
bzr add
bzr commit -m "Init"
bzr push lp:~yourlogin/dolibarr/stable
2013-01-16 12:30:39 +01:00
2013-04-23 13:38:00 +02:00
- List of series are visible here: https://launchpad.net/dolibarr/+series
2014-10-30 22:51:06 +01:00
# To update Dolibarr into launchpad (when remote repository for sources already exists)
#----------------------------------
2014-10-30 22:51:06 +01:00
# create local repository
2013-04-23 13:38:00 +02:00
cd bzr
bzr branch lp:~yourlogin/dolibarr/[develop|stable] dolibarr-[dev|stable]
cd dolibarr-[dev|stable]
2014-10-30 22:51:06 +01:00
# Update
bzr update
-- Update files here: Remove all (except .bzr dir) and overwrite --
2013-04-23 13:38:00 +02:00
bzr status
2014-10-30 22:51:06 +01:00
bzr add *
bzr commit -m "Upstream version x.y"
2013-04-23 13:56:59 +02:00
bzr push
2016-10-30 14:28:30 +01:00
2013-04-23 13:38:00 +02:00
# Init debian dir repository into launchpad (when repository for sources does not exist)
#----------------------------------
- Create debian directory and upload it onto bzr branch lp:~yourlogin/+junk/debian-[dev|stable]
2012-01-29 20:57:40 +01:00
cd bzr
mkdir debian
cd debian
cp -pr dolibarr_root/debian bzr/debian
bzr init
bzr add
bzr commit -m "Init control files"
bzr push lp:~yourlogin/+junk/debian-[dev|stable] (put here any branch name or just bzr push if into a known branch)
2013-04-23 13:38:00 +02:00
- or download it from launchpad bazaar:
2012-01-29 20:57:40 +01:00
cd bzr
bzr branch lp:~yourlogin/+junk/debian-[dev|stable]
2013-01-16 12:30:39 +01:00
2013-04-23 13:38:00 +02:00
# Get debian dir repository from launchpad (when repository for sources already exists)
#----------------------------------
cd bzr
bzr branch lp:~yourlogin/+junk/debian-[dev|stable]
2012-12-31 03:13:11 +01:00
2013-04-23 13:38:00 +02:00
# To update debian dir into launchpad (when repository for sources already exists)
2012-12-31 03:13:11 +01:00
#----------------------------------
cd bzr
bzr branch lp:~yourlogin/+junk/debian-[dev|stable]
cd debian-[dev|stable]
2013-04-23 13:38:00 +02:00
bzr status
-- Update files here: Remove all (except .bzr dir) and overwrite. Restore version into the file changelog --
2013-04-23 13:38:00 +02:00
bzr commit -m "Description of change"
bzr push lp:~yourlogin/+junk/debian-[dev|stable]
2012-12-31 03:13:11 +01:00
2016-10-30 14:28:30 +01:00
# Define a recipe into launchpad (a rule to build packages into a PPA)
#----------------------------------
2016-10-30 14:28:30 +01:00
- Create a file dolibarr-[beta|stable].recipe with content
2012-01-29 20:57:40 +01:00
cd bzr
2016-10-30 14:28:30 +01:00
vi dolibarr-[beta|stable].recipe
For beta/dev:
2012-12-31 03:13:11 +01:00
# bzr-builder format 0.3 deb-version {debupstream}-0~{revno}
lp:dolibarr
merge packaging lp:~yourlogin/+junk/debian-dev
For stable:
2013-03-01 10:04:50 +01:00
# bzr-builder format 0.3 deb-version {debupstream}-2~{revno}
2012-12-31 03:13:11 +01:00
lp:dolibarr/stable
merge packaging lp:~yourlogin/+junk/debian-stable
2012-01-28 00:36:46 +01:00
- Run command
2012-01-29 20:57:40 +01:00
cd bzr
2016-10-30 14:28:30 +01:00
bzr dailydeb dolibarr-[beta|stable].recipe working-dir
This will create a directory "working-dir" with dolibarr sources and will add sources from ~yourlogin/+junk/debian-[dev|stable]
2012-01-28 16:04:48 +01:00
- Test package sources
sudo pbuilder build <working-dir>/<project>_<version>.dsc
2013-01-16 21:31:27 +01:00
List of recipes created
https://code.launchpad.net/~eldy/+recipe/dolibarr-dev
https://code.launchpad.net/~eldy/+recipe/dolibarr-stable
2025-01-05 14:28:07 +01:00
# To get/download package from PPA:
#----------------------------------
2013-04-23 13:38:00 +02:00
- Add signing key of the Launchpad repository:
> gpg --keyserver keyserver.ubuntu.com --recv-key A38BF8FD
> sudo apt-key add ~/.gnupg/pubring.gpg
2013-04-23 13:38:00 +02:00
- Add Dolibarr Launchpad repository to your system setup by adding the two lines to /etc/apt/sources.list
2025-01-05 14:28:07 +01:00
For the development snapshot version:
deb http://ppa.launchpad.net/yourlogin/dolibarr-dev/ubuntu precise main
deb-src http://ppa.launchpad.net/yourlogin/dolibarr-dev/ubuntu precise main
For the stable version:
2025-01-05 14:28:07 +01:00
deb http://ppa.launchpad.net/yourlogin/dolibarr-stable/ubuntu precise main
deb-src http://ppa.launchpad.net/yourlogin/dolibarr-stable/ubuntu precise main
2013-04-23 13:38:00 +02:00
- Update your package cache:
> apt-get update
2025-01-05 14:28:07 +01:00
- Install Dolibarr:
> apt-get install dolibarr