get-build-deps now uses dpkg-checkbuilddeps (which is available in dpkg-dev, which devscripts depends on) instead of a pbuilder script. Added documentation for get-build-deps. Update changelog.

This commit is contained in:
Siegfried-Angel Gevatter Pujals (RainCT) 2007-10-27 23:04:05 +02:00
parent 60577d5d53
commit 4d4faa5b68
8 changed files with 84 additions and 35 deletions

6
README
View File

@ -16,6 +16,12 @@ dch-repeat [--help]
get-branches <directory> <team> [checkout|branch]
... will branch / checkout all the Bazaar branches in a Launchpad team.
get-build-deps [<packages list or file containing a list of packages>]
... will install the build dependencies for a package, if you are inside
it's source file. Alternatively, you can pass it the name of a file
containing a list of packages, one on each line, or just pass them all
as parameters, and it will get their build dependencies.
hugdaylist [-n <number>] <bug list url>
... will create a list of <number> bug list for a hug day listing

5
debian/changelog vendored
View File

@ -7,7 +7,10 @@ ubuntu-dev-tools (0.21) UNRELEASED; urgency=low
[ Kees Cook ]
* mk-sbuild-lv: fix gnupg install, adjust symlink creation
-- Kees Cook <kees@ubuntu.com> Tue, 23 Oct 2007 10:22:44 -0700
[ Siegfried-Angel Gevatter Pujals (RainCT) ]
* Add get-build-deps and it's documentation.
-- Siegfried-Angel Gevatter Pujals (RainCT) <sgevatter@ubuntu.cat> Sat, 27 Oct 2007 23:03:42 +0200
ubuntu-dev-tools (0.20) hardy; urgency=low

2
debian/control vendored
View File

@ -4,7 +4,7 @@ Priority: optional
Maintainer: Ubuntu MOTU Developers <ubuntu-motu@lists.ubuntu.com>
XS-Vcs-Bzr: https://launchpad.net/ubuntu-dev-tools/
XS-Vcs-Browser: http://codebrowse.launchpad.net/~ubuntu-dev/ubuntu-dev-tools/trunk/changes
Build-Depends: cdbs (>= 0.4.43), debhelper (>= 5), python-central (>= 0.5), python-all-dev (>= 2.4)
Build-Depends: cdbs (>= 0.4.43), debhelper (>= 5), python-central (>= 0.5), python-all-dev (>= 2.4)
Build-Depends-Indep: docbook2x
XS-Python-Version: all
Standards-Version: 3.7.2

4
debian/copyright vendored
View File

@ -45,7 +45,7 @@ submittodebian, update-maintainer, and what-patch are licensed under GPLv2:
On Debian systems, the complete text of the GNU General Public License v2
can be found in `/usr/share/common-licenses/GPL-2'.
get-branches and suspicious-source are licensed under GPLv3:
get-branches, suspicious-source and get-build-deps are licensed under GPLv3:
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@ -63,4 +63,4 @@ On Debian systems, the complete text of the GNU General Public License v3
can be found in `/usr/share/common-licenses/GPL-3'.
The following of the scripts can be used, at your option, regarding any later version
of the previously specified license: pbuilder-dist and suspicious-source.
of the previously specified license: pbuilder-dist, suspicious-source and get-build-deps.

55
doc/get-build-deps.1 Normal file
View File

@ -0,0 +1,55 @@
.\" Title: get-build-deps
.\" Author: Siegfried-Angel Gevatter Pujals
.\" Contact details: siggi.gevatter@gmail.com
.\"
.TH GET\-BUILD\-DEPS 1 "October 27, 2007"
.\"
.SH NAME
get\-build\-deps \- install build dependencies for one or more packages
.\"
.SH SYNOPSIS
\fBget\-build\-deps\fP [\fIPACKAGE(S)\fR]
.\"
.SH DESCRIPTION
\fBget\-build\-deps\fP is a script to install the build dependencies for either a
local source package or one or more packages from the repositories.
.PP
In order to obtain all missing build dependencies for a package on which source
you are currently working, just run this script without any argument, and it'll
read it's debian/control file to determine the missing build dependencies.
.PP
Alternatively, you can call it with a list of space-separated package names, or the
name of a single file which contains the package names each on a line. Then it will
install the missing dependencies for those packages using "apt-get build-dep".
.\"
.SH EXAMPLES
.TP
get\-build\-deps
Looks for a the debian/control file in the current working directory and installs the
dependencies listed there.
.TP
get\-build\-deps geany
Installs the build dependencies for version of «geany» that's in the repositories.
.TP
get\-build\-deps geany epiphany-browser rhythmbox
Same as the previous example but also with the dependencies for «epiphany-browser»
and «rhythmbox».
.TP
get\-build\-deps ./package_list.txt
Reads the file «package_list.txt» (relatively to the current working directory),
where each line contains the name of a package, and installs the dependencies
for the versions of all those that's in the repositories.
.\"
.SH KNOWN BUGS AND LIMITATIONS
When it's being used to install the missing dependencies for a local source package
(ie, no arguments are passed to it) it doesn't check for the dependencies to match
the indicated versions, but just installs the newest one available in the repositories.
.\"
.SH SEE ALSO
\fBdpkg-checkbuilddeps(1)\fR,
\fBapt-get(8)\fR
.SH AUTHORS
.\"
\fBget\-build\-deps\fP and this manual page have been written by Siegfried-Angel
Gevatter Pujals <siggi.gevatter@gmail.com>. They are released under the GNU General
Public License, version 3 or later.

View File

@ -22,4 +22,4 @@ It expects to find the .dsc and diff.gz of the current version (which you likely
.BR reportbug (1).
.br
.SH AUTHOR
submittodebian and this man page was written by Soren Hansen <soren@ubuntu.com>.
submittodebian and this man page were written by Soren Hansen <soren@ubuntu.com>.

View File

@ -33,32 +33,17 @@ to use this script."
exit 1
fi
if [ ! -x /usr/lib/pbuilder/pbuilder-satisfydepends ]; then
# The package «pbuilder» isn't installed, but it's required
# to install the build dependencies of a source package.
# Ask the user if he wants to install it automatically.
echo -n "\
This script requires a component that's included in the «pbuilder» \
package, which isn't currently installed, in order to install the \
dependencies required to build the source package in the current \
directory.
Would you like to install pbuilder now? [y/N] "
read install_now
if [ ! $install_now ] || ([ $install_now != 'y' ] && [ $install_now != 'Y' ])
then
# Don't install it. Abort.
exit 1
fi
echo 'Installing package «pbuilder»...'
sudo aptitude install pbuilder
echo; echo
filepath="`pwd`/debian/control"
missing_dependencies=$(dpkg-checkbuilddeps 2>&1)
if [ -z "$missing_dependencies" ]; then
echo "The build dependencies described in «$filepath» are already satisfied."
exit 0
fi
echo "Installing the build dependencies described in «`pwd`/debian/control»..."
sudo /usr/lib/pbuilder/pbuilder-satisfydepends
echo "Installing the build dependencies described in «$filepath»..."
sudo aptitude install $(echo $missing_dependencies | awk -F: '{ print $3 }' | sed 's/([^)]*)//g' | sed 's/|\s[^\s]*//g')
#' <--- Fix to avoid Geanys markup breaking
exit 0
elif [ $# -eq 1 ]
then

View File

@ -12,7 +12,7 @@ if os.path.exists(changelog):
match = re.compile(".*\((.*)\).*").match(head)
if match:
version = match.group(1)
setup(name='ubuntu-dev-tools',
version=version,
scripts=['404main',
@ -27,9 +27,9 @@ setup(name='ubuntu-dev-tools',
'suspicious-source',
'ppaput',
'requestsync',
'hugdaylist',
'massfile',
'submittodebian'
],
'hugdaylist',
'massfile',
'submittodebian',
'get-build-deps'
],
)