Tim Gardner [Tue, 6 Oct 2015 16:07:03 +0000 (10:07 -0600)]
UBUNTU: [Debian] config-check and prepare using ${DEBIAN}/config/annotations
Annotations are unique to the derivative. Therefore, use annotations
found in the derivative config directory.
Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
(cherry picked from commit 4f92f80963c358c9716e70d912449a7c2a5808aa) Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com>
Andy Whitcroft [Wed, 23 Sep 2015 10:54:24 +0000 (11:54 +0100)]
UBUNTU: [Debian] rebuild should only trigger for non-linux packages
BugLink: http://bugs.launchpad.net/bugs/1498862 Signed-off-by: Andy Whitcroft <apw@canonical.com> Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
Andy Whitcroft [Thu, 3 Sep 2015 21:44:08 +0000 (22:44 +0100)]
UBUNTU: [Debian] control -- prepare for new kernel-wedge semantics
We have been carrying a nastly little patch for kernel-wedge to cope with
the fact we use control.stub. But it is simpler to just go with the flow
and emit the stub by hand. Do this in such a way we keep a fake
debian/control.stub such that we will work with either Debian or Ubuntu
kernel-wedge.
Andy Whitcroft [Thu, 2 Apr 2015 14:51:04 +0000 (15:51 +0100)]
UBUNTU: [Debian] do_common_tools should always be on
do_common_tools is a mode specifier, it is on when we want tools and off
when we do not want tools. It is intended to be flipped by the bootstrap
modes. Whether those common tools are actually built is determined by
whether we are calling binary or binary-arch not related to whether we
want those packages to have content.
Enable this unconditionally. This allows us to build the indep packages
on any arch is needed.
Andy Whitcroft [Wed, 21 Jan 2015 12:52:13 +0000 (12:52 +0000)]
UBUNTU: [Debian] hyper-v -- fix comment handing in /etc/network/interfaces
We are duplicating the opening comment marker every time we rebuild the
file, such that we end up with multiple of those comments:
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
# The following stanza(s) added by hv_set_ifconfig
# The following stanza(s) added by hv_set_ifconfig
# The following stanza(s) added by hv_set_ifconfig
auto eth0
iface eth0 inet static
address 10.100.20.108
gateway 10.100.20.1
dns-nameservers 8.8.4.4
#End of hv_set_ifconfig stanzas
Fix handling of these such that we only insert new markers if they do
not already exist. Where they do, simply inject the new stanzas at the
end of the block before the end marker. At the same time deduplicate
sequential begin and end markers to clean up previously dammaged files.
Andy Whitcroft [Tue, 6 Jan 2015 11:05:22 +0000 (11:05 +0000)]
UBUNTU: [Debian] uploadnum should be the remainder of the version
The uploadnum variable in debian/rules is somewhat confusingly named,
it should be the "remainder of the version after <version>-<abinum>", not
just the uploadnum itself. This version is only used for identification
in uname -v and there it is completely appropriate for this to be complete
with backport versions etc.
Andy Whitcroft [Fri, 3 Oct 2014 16:43:13 +0000 (17:43 +0100)]
UBUNTU: [Debian] linux-image-extra postrm is not needed on purge
Signed-off-by: Andy Whitcroft <apw@canonical.com>
(cherry picked from commit 920e8acdb5b860086618e436f572717b631e65ec) Signed-off-by: Andy Whitcroft <apw@canonical.com>
Andy Whitcroft [Thu, 2 Oct 2014 10:00:45 +0000 (11:00 +0100)]
UBUNTU: [Debian] linux-image-extra is additive to linux-image
linux-image-extra is special, it is only additive to linux-image, this
means really cannot use the standard kernel postinst/postrm for this
package. As it also depends on linux-image we know that linux-image will
have been installed before it, and will be removed after it. On change
(installation/update/removal) of linux-image-extra we want to run the
kernel postinst to rebuilt the initramfs and update the bootloader
as necessary. To this end switch to package specific postinst/postrm
which trigger the /etc/kernel/postinst.d hooks. We need to do it this
way to get the specially parameterised incantations of update-initramfs,
to ensure we trigger the correct build rather than mearly dpkg triggering
a rebuild of the running kernel.
dann frazier [Wed, 30 Jul 2014 16:57:11 +0000 (10:57 -0600)]
UBUNTU: [Debian] Fix 'printchanges' to work with versions containing '+'
I maintain several topic kernel branches/builds where I like to use version
strings that contain a '+' character. Today this means I can't use targets
like printchanges and insertchanges because '+' characters aren't escaped.
Signed-off-by: dann frazier <dann.frazier@canonical.com> Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
Andy Whitcroft [Wed, 5 Nov 2014 10:28:29 +0000 (10:28 +0000)]
UBUNTU: [Debian] basic hook support
Add the infrastructure for Makefile macro overrides. This
is primarily used by LTS backport branches to supersede master
branch settings such as do_tools_common, etc.
Tim Gardner [Mon, 27 Oct 2014 20:14:08 +0000 (14:14 -0600)]
UBUNTU: [Debian] Fix linux-doc dangling symlinks
BugLink: https://bugs.launchpad.net/bugs/661306 Signed-off-by: Tim Gardner <tim.gardner@canonical.com> Acked-by: Stefan Bader <stefan.bader@canonical.com> Acked-by: Chris J Arges <chris.j.arges@canonical.com>
Tim Gardner [Fri, 26 Sep 2014 19:30:28 +0000 (13:30 -0600)]
UBUNTU: [Debian] Don't fail if a symlink already exists
A restarted build (dpkg-buildpackage -nc) currently fails if the linux-tools
symlinks remain from a previous build. Use ln -sf to allow the build to
continue by overwriting any existing links.
Signed-off-by: dann frazier <dann.frazier@canonical.com> Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
dann frazier [Fri, 15 Aug 2014 19:40:08 +0000 (13:40 -0600)]
UBUNTU: [debian] Fix regression with ABI subversions and backport
Tim pointed out that 443b5814ee77f8c9083079ce0e6a0806e087630f broke the parsing
of backport versions, such as 8.13~14.10+ppa.1. This should fix it. I used the
following script to validate the regular expressions:
dannf@fluid:~$ cat test.sh
set -e
splitver() {
local ver="$1"
local abinum="$(echo $ver | sed -r -e 's/([^\+~]*)\.[^\.]+(~.*)?(\+.*)?$/\1/')"
local uploadnum="$(echo $ver | sed -r -e 's/[^\+~]*\.([^\.~]+)(~.*)?(\+.*)?$/\1/')"
echo "$abinum $uploadnum"
}
do_test() {
local ver="$1"
local expected="$2"
local actual="$(splitver $ver)"
if [ "$actual" = "$expected" ]; then
echo "PASS: $ver"
return 0
fi
echo "FAIL: $ver split as $actual"
return 1
}
dann frazier [Mon, 11 Aug 2014 19:50:02 +0000 (13:50 -0600)]
UBUNTU: [debian] Allow for package revisions condusive for branching
TLDR; This changes the way that version strings are parsed in the packaging to
make it easier for me to maintain topic branches/PPA builds. There should
be no changes to how things work today for standard Ubuntu kernels. But,
it allows for topic-branch maintainers to add an optional ".X" in the ABI
name, for reasons described below.
<Regression Testing>
------------------
Old Parsing:
= abinum =
$ echo "33.58" | sed -e 's/\..*//'
33
= uploadnum =
$ echo "33.58" | sed -e 's/.*\.//'
58
= abi =
$ echo "33.58" | gawk -F. '{print $1}'
33
New Parsing:
= abinum =
$ echo "33.58" | sed -r -e 's/([^\+]*)\.[^\.]+(\+.*)?$/\1/'
33
= uploadnum =
$ echo "33.58" | sed -r -e 's/[^\+]*\.([^\.]+(\+.*)?$$)/\1/'
58
= abi =
$ echo "33.58" | sed -r -e 's/([^\+]*)\.[^\.]+(\+.*)?$/\1/'
33
</Regression Testing>
When maintaining topic customizations that track Ubuntu kernel releases, it
is nice have the following features:
1) Ability to decipher the base Ubuntu kernel revision used from the topic
kernel's revision number
2) Use a version that dpkg sorts > the base Ubuntu version
3) Use a version that dpkg sorts < the next expected Ubuntu version
4) Ability to retains the same ABI as the base Ubuntu version when the
ABI has indeed not changed. This helps with e.g. d-i compatibility.
5) Make use of ABI tracking facilities (vs. just disabling them)
This is difficult to do with the current version scheme, which encodes the
ABI number in the version string:
<upstream-version>-<abi>.<rev>
I can tack a "+topic.<N>" to the end of rev, we can solve 1-3, but only as
long as as the ABI is the same. Once the ABI changes, I don't have a good way
to bump it. If I increment the ABI, we'll overlap with the next Ubuntu ABI
(breaking #4). If we jump to a huge ABI number (e.g. x100 to go from 32 to
3200), we'll have a package revision that will never again upgrade to an Ubuntu
version (breaking #3), and never get back to the Ubuntu ABI (again breaking #4).
I can of course use a linux-meta package to e.g. transition from a 3200 ABI back
to a 32 ABI at the packaging level, but the bootloader will still consider
3200 to be newer and therefore the default.
I've therefore started using the following scheme:
Andy Whitcroft [Thu, 5 Dec 2013 18:14:04 +0000 (18:14 +0000)]
UBUNTU: [Debian] Improve tools version message
BugLink: http://bugs.launchpad.net/bugs/1257715 Signed-off-by: Andy Whitcroft <apw@canonical.com> Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
Tim Gardner [Tue, 26 Nov 2013 17:35:47 +0000 (10:35 -0700)]
UBUNTU: [Debian] Re-sign modules after debug objcopy
BugLink: http://bugs.launchpad.net/bugs/1253155
Adding a GNU debug link to a module ELF destroys the
module signature, so re-sign the module file after the objcopy.
When the symlinks are made we attempt to use relative links if that
would work. However this relies on the file we are making the link to to
actually exist. When it does not we fall back to absolute. This impacts
the initrd links which are made before we make the initrd itself.
When the caller has asked us to use a specific handle file and that file
does not yet exist, see if there are any other files we can use in that
directory. In the common case this will be a version specific file and
highly unique.
Andy Whitcroft [Sat, 22 Jun 2013 11:52:29 +0000 (12:52 +0100)]
UBUNTU: [Debian] autopkgtest: switch Depends: to build-essential
autopkgtest control Depends: as empty now seems to be an error, we want
to say 'install nothing' so switch it to depend on packages which by
definition are always installed.
Andy Whitcroft [Wed, 31 Jul 2013 12:41:32 +0000 (13:41 +0100)]
UBUNTU: [Debian] supply perf with appropriate prefix to ensure use of local config
If we do not supply an installation prefix when we are building perf
it will assume it is designed to run relative to the builders HOME.
This means that as built on a buildd we will check for the system
configuration relative to the buildd users home rather than in /etc.
This implies a local user could use this to compromise other users _if_
there is a buildd user installed on the system and they have access to it.
Stefan Bader [Tue, 9 Apr 2013 17:18:46 +0000 (19:18 +0200)]
UBUNTU: (debian) Abort build on unresolved symbols
When splitting the flavours of a module into the extras and base
package, we already run depmod. Unfortunately this only produces
warnings when modules in the base package have unresolved depen-
dencies.
This change will abort the build in that case, so we can fix things.
Kamal Mostafa [Wed, 13 Mar 2013 22:20:04 +0000 (15:20 -0700)]
UBUNTU: [debian] do not use ../.$(series)-env file
Trying to use a file from ../ outside the tree seems like a bad idea, and
the series="oneiric" value here is stale by three releases now. Kill this
apparently unused "feature".
Signed-off-by: Kamal Mostafa <kamal@canonical.com> Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
Tim Gardner [Fri, 22 Mar 2013 12:53:48 +0000 (06:53 -0600)]
UBUNTU: [debian] Build extras package only for specific arches
An unwanted side effect of renaming arm omap4 to generic is that
the default rule is to create an extras package for flavours named 'generic'.
Furthermore, We stupidly tied the extras package logic to the flavour name 'generic'.
Defeat this side effect by specifying which architectures get an extras package
split, e.g., x86_64 and i386 in the arch specific make file.
Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
Paolo Pisati [Wed, 9 Jan 2013 10:27:47 +0000 (10:27 +0000)]
UBUNTU: [debian] DTB: add support for multiple DTBs
Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com> Acked-by: Andy Whitcroft <andy.whitcroft@canonical.com> Signed-off-by: Leann Ogasawara <leann.ogasawara@canonical.com>
Andy Whitcroft [Wed, 21 Nov 2012 11:13:50 +0000 (11:13 +0000)]
UBUNTU: [debian] add an autopkgtest rebuild test
The plan here is for linux, gcc, binutils, and eglibc to all depends on
each other and to all have a rebuild test. That way the entire set is
rebuild tested for any one in the set being uploaded.
Andy Whitcroft [Wed, 21 Nov 2012 11:01:09 +0000 (11:01 +0000)]
UBUNTU: [debian] move build tests out of the way
The new Debian autopkgtest system takes ownership of the debian/tests
directory, in such a way that is incompatible with our usage. Move our
tests to debian/tests-build as they are build tests.