debian/0000775000000000000000000000000012602771430007172 5ustar debian/postinst0000664000000000000000000000106312265473465011014 0ustar #!/bin/sh set -e if dpkg --compare-versions "$2" lt-nl "2.0.21.1-1~" ; then if [ -e "/etc/modprobe.d/dkms" ]; then md5sum=$(md5sum /etc/modprobe.d/dkms | sed -e 's/ .*//') old_md5sum=$(dpkg-query -W -f='${Conffiles}' dkms | \ sed -n -e "\' /etc/modprobe.d/dkms ' { s/ obsolete$//; s/.* //; p }") if [ "$md5sum" = "$old_md5sum" ]; then rm -f /etc/modprobe.d/dkms else echo "Moving /etc/modprobe.d/dkms to /etc/modprobe.d/dkms.conf ..." mv /etc/modprobe.d/dkms /etc/modprobe.d/dkms.conf rm -f /etc/modprobe.d/dkms fi fi fi #DEBHELPER# debian/control0000664000000000000000000000176712265473465010624 0ustar Source: dkms Section: kernel Priority: optional Maintainer: Ubuntu Developers XSBC-Original-Maintainer: Dynamic Kernel Modules Support Team Uploaders: David Paleino , Mario Limonciello , Giuseppe Iuculano Build-Depends: debhelper (>= 7.0.50~), quilt Standards-Version: 3.9.2 Homepage: http://linux.dell.com/dkms Vcs-Git: git://git.debian.org/pkg-dkms/dkms.git Vcs-Browser: http://git.debian.org/?p=pkg-dkms/dkms.git Package: dkms Architecture: all Depends: ${misc:Depends}, module-init-tools, gcc, make | build-essential | dpkg-dev, coreutils (>= 7.4), patch Recommends: fakeroot, menu | sudo Suggests: dpkg-dev, debhelper Description: Dynamic Kernel Module Support Framework DKMS is a framework designed to allow individual kernel modules to be upgraded without changing the whole kernel. It is also very easy to rebuild modules as you upgrade kernels. debian/dkms.lintian-overrides0000664000000000000000000000013512265473465013523 0ustar dkms binary: python-script-but-no-python-dep usr/share/apport/package-hooks/dkms_packages.py debian/scripts/0000775000000000000000000000000012600532677010667 5ustar debian/scripts/dh_dkms.10000664000000000000000000001355012265473465012374 0ustar .\" Automatically generated by Pod::Man 2.22 (Pod::Simple 3.07) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is turned on, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .ie \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . nr % 0 . rr F .\} .el \{\ . de IX .. .\} .\" .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). .\" Fear. Run. Save yourself. No user-serviceable parts. . \" fudge factors for nroff and troff .if n \{\ . ds #H 0 . ds #V .8m . ds #F .3m . ds #[ \f1 . ds #] \fP .\} .if t \{\ . ds #H ((1u-(\\\\n(.fu%2u))*.13m) . ds #V .6m . ds #F 0 . ds #[ \& . ds #] \& .\} . \" simple accents for nroff and troff .if n \{\ . ds ' \& . ds ` \& . ds ^ \& . ds , \& . ds ~ ~ . ds / .\} .if t \{\ . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' .\} . \" troff and (daisy-wheel) nroff accents .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' .ds 8 \h'\*(#H'\(*b\h'-\*(#H' .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] .ds ae a\h'-(\w'a'u*4/10)'e .ds Ae A\h'-(\w'A'u*4/10)'E . \" corrections for vroff .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' . \" for low resolution devices (crt and lpr) .if \n(.H>23 .if \n(.V>19 \ \{\ . ds : e . ds 8 ss . ds o a . ds d- d\h'-1'\(ga . ds D- D\h'-1'\(hy . ds th \o'bp' . ds Th \o'LP' . ds ae ae . ds Ae AE .\} .rm #[ #] #H #V #F C .\" ======================================================================== .\" .IX Title "DH_DKMS 1" .TH DH_DKMS 1 "2010-02-17" "2.1.1.1" "DKMS Debhelper" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" dh_dkms \- correctly handle DKMS usage by a kernel module package .SH "SYNOPSIS" .IX Header "SYNOPSIS" \&\fBdh_dkms\fR [\fIdebhelper\ options\fR] [\fB\-l\fR] [\fB\-V\fR[\fIversion\fR]] [\fB\-\-\fR\ \fIfile\fR] .SH "DESCRIPTION" .IX Header "DESCRIPTION" dh_dkms is a debhelper program that is responsible for correctly setting postinst, postrm and dependencies in kernel module packages using \s-1DKMS\s0. .PP If a file named debian/package.dkms exists, then different actions are performed, depending on its contents. .SH "FILES" .IX Header "FILES" .IP "debian/\fIpackage\fR.dkms" 4 .IX Item "debian/package.dkms" .PD 0 .IP "debian/dkms" 4 .IX Item "debian/dkms" .PD It can be a proper configuration file, and in this case it would be installed in the proper directory as dkms.conf. .Sp It can also point to another file (this should be used when the configuration is provided by upstream), and in this case that file will be installed as dkms.conf in the proper directory. .Sp This file can only miss if a filename is provided when calling dh_dkms. .SH "OPTIONS" .IX Header "OPTIONS" .IP "\fB\-l\fR, \fB\-\-legacy\fR" 4 .IX Item "-l, --legacy" Add code to also support \s-1DKMS\s0 versions < 2.1.0.0. .IP "\fB\-V\fR, \fB\-V\fR \fIversion\fR" 4 .IX Item "-V, -V version" If \f(CW\*(C`PACKAGE_VERSION\*(C'\fR in \fIdkms.conf\fR is set to \f(CW\*(C`#MODULE_VERSION#\*(C'\fR, set it to the given \fIversion\fR or, if none is given, default to the upstream version of the current package. Otherwise, leave the value specified in \fIdkms.conf\fR. .IP "\fB\-\-\fR \fIfile\fR" 4 .IX Item "-- file" Don't look for debian/\fIpackage\fR.dkms or debian/dkms, but install \fIfile\fR as dkms.conf. .SH "NOTES" .IX Header "NOTES" Note that this command is not idempotent. \fIdh_prep\fR\|(1) should be called between invocations of this command. Otherwise, it may cause multiple instances of the same text to be added to maintainer scripts. IMPORTANT: binary packages using dh_dkms must have a name that ends in '-dkms'. .SH "SEE ALSO" .IX Header "SEE ALSO" \&\fIdebhelper\fR\|(1) .PP This program is part of the Debian \s-1DKMS\s0 package. .PP \&\fIdkms\fR\|(8) .SH "AUTHOR" .IX Header "AUTHOR" David Paleino debian/scripts/dkms-autopkgtest0000775000000000000000000000374612600532677014135 0ustar #!/bin/sh # Common autopkgtest script for testing a dkms source package. # Author: Martin Pitt # Copyright: (C) 2014 Canonical Ltd. set -eu run_pkg() { pkg="$1" echo "I: Installing binary package $pkg" export DEBIAN_FRONTEND=noninteractive RC=0 apt-get install -yq $pkg "$ADT_ARTIFACTS/$pkg-make-logs.tar" fi if [ "$RC" -ne 0 ]; then echo "E: Package $pkg failed to install" >&2 exit 1 fi echo "I: Testing binary package $pkg" if ! dkms_conf=$(dpkg -L $pkg | grep 'dkms.conf$'); then echo "I: Package $pkg has no dkms.conf, skipping" return fi dkms_pkg=$(bash -c ". $dkms_conf; echo \$PACKAGE_NAME" 2>/dev/null) echo "I: Testing if $dkms_pkg modules are correctly installed" dkmsstatus="$(dkms status $dkms_pkg)" if [ -z "$dkmsstatus" ]; then echo "E: dkms status output is empty!" >&2 exit 1 fi echo "$dkmsstatus" if ! echo "$dkmsstatus" | grep -q "installed$"; then echo "E: not installed" >&2 exit 1 fi # skip modprobing for now; this fails too often (needs particular # hardware/firmware/etc) # for mod in $(awk -F '"' '/^BUILT_MODULE_NAME/ {print $2}' $dkms_conf); do # echo "I: modprobe $mod" # if ! modprobe $mod; then # echo "E: Failed to modprobe module $mod" >&2 # exit 1 # else # echo "I: $modname loaded" # fi # done } # Try and remove dkms to spot packages which miss a dkms dependency dpkg --remove dkms || true for pkg in $(awk '/^Package:/ { print $2 }' debian/control); do # package might be arch: restriction or udeb etc. if ! apt-cache show $pkg >/dev/null 2>&1; then echo "I: Skipping unavailable package $pkg" continue fi run_pkg $pkg done debian/scripts/dkms.pm0000664000000000000000000000017212265473465012171 0ustar #!/usr/bin/perl use warnings; use strict; use Debian::Debhelper::Dh_Lib; insert_before("dh_installinit", "dh_dkms"); 1; debian/scripts/postinst-dkms0000664000000000000000000000147212265473465013443 0ustar # The original file can be found in template-dkms-mkdeb/debian/postinst # in the DKMS tarball, check it for copyright notices. DKMS_NAME=#MODULE_NAME# DKMS_PACKAGE_NAME=$DKMS_NAME-dkms DKMS_VERSION=#MODULE_VERSION# postinst_found=0 case "$1" in configure) for DKMS_POSTINST in /usr/lib/dkms/common.postinst /usr/share/$DKMS_PACKAGE_NAME/postinst; do if [ -f $DKMS_POSTINST ]; then $DKMS_POSTINST $DKMS_NAME $DKMS_VERSION /usr/share/$DKMS_PACKAGE_NAME "" $2 postinst_found=1 break fi done if [ "$postinst_found" -eq 0 ]; then echo "ERROR: DKMS version is too old and $DKMS_PACKAGE_NAME was not" echo "built with legacy DKMS support." echo "You must either rebuild $DKMS_PACKAGE_NAME with legacy postinst" echo "support or upgrade DKMS to a more current version." exit 1 fi ;; esac debian/scripts/prerm-dkms0000664000000000000000000000036712265473465012707 0ustar DKMS_NAME=#MODULE_NAME# DKMS_VERSION=#MODULE_VERSION# case "$1" in remove|upgrade|deconfigure) if [ "$(dkms status -m $DKMS_NAME -v $DKMS_VERSION)" ]; then dkms remove -m $DKMS_NAME -v $DKMS_VERSION --all fi ;; esac debian/scripts/dh_dkms0000775000000000000000000001001412265473465012230 0ustar #!/usr/bin/perl -w =head1 NAME dh_dkms - correctly handle DKMS usage by a kernel module package =cut use strict; use Debian::Debhelper::Dh_Lib; =head1 SYNOPSIS B [S>] [S>] [S[I]>] [S I>] =head1 DESCRIPTION dh_dkms is a debhelper program that is responsible for correctly setting postinst, postrm and dependencies in kernel module packages using DKMS. If a file named debian/package.dkms exists, then different actions are performed, depending on its contents. =head1 FILES =over 4 =item debian/I.dkms =item debian/dkms It can be a proper configuration file, and in this case it would be installed in the proper directory as dkms.conf. It can also point to another file (this should be used when the configuration is provided by upstream), and in this case that file will be installed as dkms.conf in the propery directory. This file can only miss if a filename is provided when calling dh_dkms. =back =head1 OPTIONS =over 4 =item B<-l>, B<--legacy> Add code to also support DKMS versions < 2.1.0.0. =item B<-V>, B<-V> I If C in F is set to C<#MODULE_VERSION#>, set it to the given I or, if none is given, default to the upstream version of the current package. Otherwise, leave the value specified in F. =item B<--> I Don't look for debian/I.dkms or debian/dkms, but install I as dkms.conf. =back =head1 NOTES Note that this command is not idempotent. L should be called between invocations of this command. Otherwise, it may cause multiple instances of the same text to be added to maintainer scripts. =cut init(options => { "l|legacy" => \$dh{LEGACY_DKMS}, }); foreach my $package (@{$dh{DOPACKAGES}}) { #next if is_udeb($package); my $tmp = tmpdir($package); my $dkms_dir = "/usr/lib/dkms/"; my $dkms_conf = pkgfile($package, "dkms"); my $is_snippet = 0; my @other_conf; my $name; my $package_name; my $package_version; if ($dkms_conf) { # let's see if it's a proper snippet open(IN, "< $dkms_conf"); while (my $l = ) { $l =~ /PACKAGE_NAME=(["'])(.*)\1/ && ($is_snippet = 1); } close(IN); if ($is_snippet) { $name = $dkms_conf; } else { @other_conf = filearray($dkms_conf); if ($#other_conf > 1) { error "cannot list more than one file in $dkms_conf!"; } else { $name = $other_conf[0]; } } } elsif ($#ARGV == 0) { $name = $ARGV[0]; } else { next; } verbose_print "installing $name as dkms.conf"; # now, parse our configuration file open(IN, "< $name"); while (my $l = ) { $l =~ /PACKAGE_NAME=(["'])(.*)\1/ && ($is_snippet = 1 && $package_name = $2); $l =~ /PACKAGE_VERSION=(["'])(.*)\1/ && ($package_version = $2); } close(IN); #$ENV{DH_AUTOSCRIPTDIR} = "debian/scripts/"; if ($dh{LEGACY_DKMS}) { doit("install", "-p", "-D", "-m755", "$dkms_dir/common.postinst", "$tmp/usr/share/$package/postinst"); addsubstvar($package, "misc:Depends", "dkms"); } else { addsubstvar($package, "misc:Depends", "dkms", ">= 2.1.0.0"); } if ($dh{V_FLAG_SET}) { $package_version = $dh{V_FLAG}; if ($package_version eq "") { # Call isnative because it sets $dh{VERSION} # as a side effect. isnative($package); $package_version = $dh{VERSION}; # Remove the Debian revision $package_version =~ s/-[^-]+$//; } my $old_name = $name; $name = "debian/".pkgext($package)."dkms.debhelper"; doit("cp", "-a", $old_name, $name); doit("sed", "-i", "s/#MODULE_VERSION#/$package_version/g", $name); } autoscript($package, "prerm", "prerm-dkms", "s/#MODULE_NAME#/$package_name/;s/#MODULE_VERSION#/$package_version/"); autoscript($package, "postinst", "postinst-dkms", "s/#MODULE_NAME#/$package_name/;s/#MODULE_VERSION#/$package_version/"); doit("install", "-p", "-D", "-m644", "$name", "$tmp/usr/src/$package_name-$package_version/dkms.conf"); } =head1 SEE ALSO L This program is part of the Debian DKMS package. L =head1 AUTHOR David Paleino =cut debian/docs0000664000000000000000000000003412265473465010056 0ustar AUTHORS debian/HOWTO.Debian debian/preinst0000664000000000000000000000216012265473465010614 0ustar #!/bin/sh set -e #DEBHELPER# # snippet from http://www.dpkg.org/dpkg/ConffileHandling # Remove a no-longer used conffile rm_conffile() { PKGNAME="$1" CONFFILE="$2" if [ -e "$CONFFILE" ]; then md5sum="`md5sum \"$CONFFILE\" | sed -e \"s/ .*//\"`" old_md5sum="`dpkg-query -W -f='${Conffiles}' $PKGNAME | sed -n -e \"\\\\' $CONFFILE '{s/ obsolete$//;s/.* //p}\"`" if [ "$md5sum" != "$old_md5sum" ]; then echo "Obsolete conffile $CONFFILE has been modified by you." echo "Saving as $CONFFILE.dpkg-bak ..." mv -f "$CONFFILE" "$CONFFILE".dpkg-bak else echo "Removing obsolete conffile $CONFFILE ..." rm -f "$CONFFILE" fi fi } case "$1" in install|upgrade) if dpkg --compare-versions "$2" le "2.1.1.1-2"; then rm_conffile dkms "/etc/dkms/template-dkms-mkdeb/debian/postrm" if [ -e "/etc/init.d/dkms_autoinstaller" ]; then update-rc.d -f dkms_autoinstaller remove >/dev/null 2>&1 rm_conffile dkms "/etc/init.d/dkms_autoinstaller" fi rm_conffile dkms "/etc/init/dkms_autoinstaller.conf" fi esac debian/HOWTO.Debian0000664000000000000000000000327312265473465011217 0ustar HOWTO Build DKMS debs w/ Debian & Ubuntu systems Copyright 2008 Dell Inc. Author: Mario Limonciello ------------ A dkms deb is a common representation of a DKMS package that can be distributed across multiple machines. After you have a functional DKMS package, you can follow these steps to build a DKMS deb. 1) Start out by putting together a tree in /usr/src/PACKAGE-VERSION. For our example, we are going to use the PACKAGE lirc and VERSION 0.8.3~pre1. Create a dkms.conf per the recommendations in the DKMS guide. 2) "Add" the package to the dkms tree system: dkms add -m lirc -v 0.8.3~pre1 3) "Build" the binary modules for the current kernel: dkms build -m lirc -v 0.8.3~pre1 4) Make the deb and/or dsc for the package: dkms mkdeb -m lirc -v 0.8.3~pre1 dkms mkdsc -m lirc -v 0.8.3~pre1 The end result will be a deb and/or dsc in /var/lib/dkms/lirc/0.8.3~pre1/deb or /var/lib/dkms/lirc/0.8.3~pre1/dsc ------------ If you would prefer not to contaminate your system with the changes from building these debs, you should create a framework.conf that contains these variables (adjust for your use case): source_tree="/path/to/source/tree" dkms_tree="/path/to/dkms/tree" You will then call DKMS with an extra variable, '--dkmsframework'. Here is an example of how this would work using the same lirc example above: dkms add -m lirc -v 0.8.3~pre1 --dkmsframework framework.conf dkms build -m lirc -v 0.8.3~pre1 --dkmsframework framework.conf dkms mkdeb -m lirc -v 0.8.3~pre1 --dkmsframework framework.conf dkms mkdsc -m lirc -v 0.8.3~pre1 --dkmsframework framework.conf The end result will be both a debian binary package and a debian source package that you can use. debian/changelog0000664000000000000000000006002312602771430011045 0ustar dkms (2.2.0.3-1.1ubuntu5.14.04.5) trusty-security; urgency=medium * dkms_apport.py: update to the recent apport.utils api changes (lp: #1499842) -- Marc Deslauriers Wed, 30 Sep 2015 07:33:54 -0400 dkms (2.2.0.3-1.1ubuntu5.14.04.3) trusty; urgency=low * d/s/autopkgtest: only collect logs if there are any. (LP: #1498896) -- Andy Whitcroft Wed, 23 Sep 2015 15:21:08 +0100 dkms (2.2.0.3-1.1ubuntu5.14.04.2) trusty; urgency=medium * Backport dkms-autopkgtest helper script, so that we can run DKMS tests for new kernel uploads triggered by britney via autodep8. (LP: #1489045) -- Martin Pitt Thu, 27 Aug 2015 12:32:04 +0200 dkms (2.2.0.3-1.1ubuntu5.14.04.1) trusty; urgency=medium * Add apport_package_key_with_version.patch: Include the package version in the Package data as apport does this with any report it creates and the Error Tracker expects to find the version there. (LP: #1429967) -- Brian Murray Mon, 09 Mar 2015 11:45:07 -0700 dkms (2.2.0.3-1.1ubuntu5.14.04) trusty; urgency=medium * fixed_sed_without_options_issue.patch: Backport of patch to fix sed issues. (LP: #1358373) -- Chris J Arges Mon, 01 Dec 2014 16:53:16 -0600 dkms (2.2.0.3-1.1ubuntu5) trusty; urgency=low [ Mario Limonciello ] * Backport from trunk: Add patch that fixes have_one_kernel for non- zero return code. (LP: #1261116) -- Antonius Riha Fri, 10 Jan 2014 16:50:11 +0100 dkms (2.2.0.3-1.1ubuntu4) saucy; urgency=low * apport_python3.patch: Fix bug links in header. * apport_python3.patch: Call package hook through python3, not python. (LP: #1171344) -- Martin Pitt Wed, 29 May 2013 08:31:34 +0200 dkms (2.2.0.3-1.1ubuntu3) saucy; urgency=low * Add apport_dup_signature.patch: Don't use the whole DKMS build log as duplicate signature, this is way too long. Just use the first actual compiler error, together with the package name and version. (LP: #1175785) -- Martin Pitt Thu, 02 May 2013 15:39:26 -0700 dkms (2.2.0.3-1.1ubuntu2) raring; urgency=low * Don't Recommend any linux-headers packages, our installers all install headers matching your kernel anyway, and this dependency causes more problems than it solves (LP: #960770) -- Adam Conrad Wed, 31 Oct 2012 11:28:52 +0000 dkms (2.2.0.3-1.1ubuntu1) quantal-proposed; urgency=low * Merge from Debian unstable, remaining changes: - Add apport_supported_kernel_packages.diff: Only report bugs about supported kernel versions. - Add Add-support-for-forcing-modules-installation.patch, backported from trunk: Add support to force module installation by adding files to /usr/share/dkms/modules_to_force_install - Add apport_python3.patch: Port apport hook to Python 3 and take care of opening the output file in binary mode - debian/control: added 'dpkg-dev' and 'debhelper' to Suggests. -- Felix Geyer Thu, 26 Jul 2012 11:43:22 +0200 dkms (2.2.0.3-1.1) unstable; urgency=low * Non-maintainer upload. * Do not fail if /lib/modules does not exist. (Closes: #666023) * Remove the directory where the module was installed. (Closes: #657145) -- Andreas Beckmann Thu, 19 Jul 2012 22:20:45 +0200 dkms (2.2.0.3-1ubuntu5) quantal; urgency=low * debian/control: added 'dpkg-dev' and 'debhelper' to Suggests (LP: #989998) -- Aditya Vaidya Wed, 11 Jul 2012 08:28:02 -0400 dkms (2.2.0.3-1ubuntu4) quantal; urgency=low * Add apport_python3.patch: Port apport hook to Python 3 (LP: #1013171) and take care of opening the output file in binary mode (LP: #1008092) -- Martin Pitt Thu, 21 Jun 2012 08:52:35 +0200 dkms (2.2.0.3-1ubuntu3) precise-proposed; urgency=low * Add linux-headers-generic-pae to recommended headers packages so that i386 installs get the right headers (LP: #986475) -- Scott Kitterman Sat, 21 Apr 2012 15:01:27 -0400 dkms (2.2.0.3-1ubuntu2) precise; urgency=low [ Alberto Milone ] * Backport from trunk: Add support to force module installation by adding files to /usr/share/dkms/modules_to_force_install -- Mario Limonciello Tue, 03 Apr 2012 18:03:02 -0500 dkms (2.2.0.3-1ubuntu1) precise; urgency=low * Only report bugs about supported kernel versions. This fixes a regression introduced in 2.2.0.2-1ubuntu2. (LP: #940285) - Add apport_supported_kernel_packages.diff: Check the result of is_distro_package() and fix the check if the kernel header package is installed at all. -- Felix Geyer Fri, 24 Feb 2012 14:08:47 +0100 dkms (2.2.0.3-1) unstable; urgency=low * [e24a52f] Imported Upstream version 2.2.0.3 * [09da5c7] bump standards version * [713ebfd] add missing debhelper token to preinst * [8970435] add versioned build depends for debhelper * [db4238c] switch to dh7 * [13a34c7] update lintian override for DKMS apport rule -- Mario Limonciello Wed, 07 Dec 2011 13:21:33 -0600 dkms (2.2.0.2-1) unstable; urgency=low [ Mario Limonciello ] * [c5846b6] Imported Upstream version 2.2.0.2 - Doesn't leave files in /tmp (Closes: #633802) - Autoinstall works on multiple kernels (Closes: #634979) (LP: #812979) - PRE_BUILD command working directory fix. (LP: #812088) * [83b5f6e] Drop kfreebsd.patch. Merged upstream [ Giuseppe Iuculano ] * [a80ecc5] Updated VCS control field -- Mario Limonciello Fri, 22 Jul 2011 13:36:32 -0500 dkms (2.2.0.1-3) unstable; urgency=low * [c9f7ed0] Fixed kFreeBSD subdirs check * [57c5c9d] Removed improved-error-messages.patch * [370ff7b] Remove debian-lsb.patch. Now Ubuntu can sync from Debian -- Giuseppe Iuculano Fri, 15 Jul 2011 16:44:11 +0200 dkms (2.2.0.1-2) unstable; urgency=low * [6b2d392] Run depmod command only in Linux. Thanks to Robert Millan (Closes: #631657) -- Giuseppe Iuculano Fri, 15 Jul 2011 16:00:05 +0200 dkms (2.2.0.1-1) unstable; urgency=low * [18353fe] Imported Upstream version 2.2.0.1 * [2a56b4e] Refreshed and removed patches merged upstream. * [c552af9] Use linux-headers-686-pae and linux-headers-amd64 in Recommends (Closes: #628873) -- Giuseppe Iuculano Fri, 15 Jul 2011 12:56:08 +0200 dkms (2.1.1.2-6) unstable; urgency=low [ Michael Gilbert ] * [430b97f] Fix logging for compound make statements (closes: #577972) - Thanks to Anders Kaseorg! * [935ae61] Check for debhelper when using 'dkms mkdeb' (closes: #592863) * [e739e8c] fixup logging patch [ Giuseppe Iuculano ] * [46cc01a] Merge from Ubuntu: Before using the current kernel we need to make sure that this kernel doesn't belong to the host of a chroot and we should also be more careful when adding kernels to the candidates list (LP: #602408). - Thanks to Alberto Milone * [313d661] Merge from Ubuntu: depend on patch instead of recommending it, if its missing the "patches" feature of dkms will no longer work and that will cause build failures (LP: #653899) Thanks to Michael Vogt -- Giuseppe Iuculano Sat, 12 Mar 2011 11:07:47 +0100 dkms (2.1.1.2-5) unstable; urgency=low * [bd3b35d] Set DISTRIB_ID=Debian in case lsb_release is missing * [2465627] Removed lsb-release from Pre-Depends * [1732998] Do not use lsb_release to determine the distribution, add a static assignment (Closes: #547353) * [d00ff09] Do not return error if /etc/dkms/framework.conf is missing (LP: #613407) - thanks to pasadrul * [618efc8] Copy from the right directory with mkdsc and copy source.changes when building with mkdsc (LP: #611652) - thanks to David Henningsson * [f23d6b0] Bump to standards-version 3.9.1, no changes needed -- Giuseppe Iuculano Wed, 04 Aug 2010 16:03:16 +0200 dkms (2.1.1.2-4) unstable; urgency=low * [f649aa1] Added coreutils >= 7.4 in Depends (Closes: #586356) * [01c7c14] Remove old modules when removing a kernel (Closes: #586724) - thanks to Jan Muszynski * [b6182ba] Bump to Standards-Version 3.9.0, no changes needed * [eaeddb3] dkms_common.postinst: handle dkms build error gracefully by skipping build for the non matching kernels. (Closes: #588585) - thanks to Jan-Marek Glogowski * [73533c2] Promote lsb-release to Pre-Depends (Closes: #589308) -- Giuseppe Iuculano Sat, 17 Jul 2010 13:23:43 +0200 dkms (2.1.1.2-3) unstable; urgency=low [ Michael Gilbert ] * Update to source format 3 (quilt) for better patch management/handling. * Improve the status info displayed during the kernel postinst, and provide informative/useful messages when things go awry. * Fix bashism in dkms_common.postinst (closes: #581079). * Document odd behavior of MAKE[#] (closes: #553625). * Document package naming convention (closes: #571753). * Use system TMPDIR setting in all scripts (closes: #581568). [ Giuseppe Iuculano ] * [208b229] Added a lintian override for python-script-but-no-python- dep, dkms.py is an apport hook -- Giuseppe Iuculano Fri, 04 Jun 2010 13:53:23 +0200 dkms (2.1.1.2-2) unstable; urgency=low * [67fb76a] Do not remove /etc/header_postinst.d/dkms in preinst. Hopefully now Ubuntu can sync dkms from Debian -- Giuseppe Iuculano Tue, 23 Feb 2010 10:02:40 +0100 dkms (2.1.1.2-1) unstable; urgency=low [ David Paleino ] * [ff95487] dh_dkms: continue the loop if there's nothing to do on the current package. (Closes: #568580) * [73dd83f] dh_dkms: specify that version mangling only happens if PACKAGE_VERSION=#MODULE_VERSION# in dkms.conf * [cdda61c] debian/scripts/postinst-dkms: really make sure the error is thrown when nothing is found. (Closes: #568591) [ Frédéric Brière ] * [2930aa9] Insert the package version directly into postinst at creation time * [9ccbdc7] Skip prerm removal if there are no modules for that version [ Giuseppe Iuculano ] * [898ab8c] Imported Upstream version 2.1.1.2 * [4fff928] Removed 01_shell_error.patch, merged in upstream * [c5566c7] Removed 02_header_postinst.patch to avoid delta with Ubuntu. Hopefully /etc/kernel/header_postinst.d directory will be supported in Debian soon * [e8aeb49] Add a comment in debian/patches/series and fix quilt- build-dep-but-no-series-file lintian warning * [bc89600] Fixed a minor spelling error in dh_dkms man page -- Giuseppe Iuculano Mon, 22 Feb 2010 15:34:12 +0100 dkms (2.1.1.1-2) unstable; urgency=low [ David Paleino ] * [d56bce9] Add -V flag to dh_dkms, thanks to Frédéric Brière for the patch. (Closes: #568589) * [dc7e358] dh_dkms: don't return an error if there's nothing to do (Closes: #568580) * [ecfc1c7] debian/scripts/postinst-dkms: don't exit on success, only do it on errors (Closes: #568591) [ Giuseppe Iuculano ] * [adb3042] Really remove obsolete conffiles * [3fe380c] Do not install /etc/header_postinst.d/dkms, at this moment Debian kernel doesn't support it * [ad6a1f2] Bump Standards-Version (no changes). -- Giuseppe Iuculano Sun, 14 Feb 2010 12:02:42 +0100 dkms (2.1.1.1-1) unstable; urgency=low [ David Paleino ] * [19ac85e] Added DKMS debhelper script (Closes: #553665) [ Giuseppe Iuculano ] * [9d66264] Imported Upstream version 2.1.1.1 * [0735c11] Removed 01_upstart.patch * [ec26539] Merge from Ubuntu: Remove the init script and Upstart job. There is no reason that DKMS needs to run on boot; you can build modules for non-running kernels just fine at installation time. * [48ff9a4] Correct a minor shell error in dkms_autoinstaller * [5c76a45] Fixed a minor spelling error in dh_dkms man page * [c611461] debian/preinst: Use set -e -- Giuseppe Iuculano Wed, 27 Jan 2010 10:02:27 +0100 dkms (2.1.1.0-2) unstable; urgency=low * [8510207] Do not install upstart job file -- Giuseppe Iuculano Tue, 15 Dec 2009 08:57:24 +0100 dkms (2.1.1.0-1) unstable; urgency=low * [3122b6c] Imported Upstream version 2.1.1.0 * [ac6fb91] Removed patches applied in upstream * [d40faf7] debian/rules: Use new make install-debian target * [5d2e1e4] debian/rules: Do not stop /etc/init.d/dkms_autoinstaller on upgrade -- Giuseppe Iuculano Mon, 14 Dec 2009 22:38:54 +0100 dkms (2.1.0.1-4) unstable; urgency=low * [fdaa289] Use new upstream patch for optimized init. (Closes: #560267) -- Giuseppe Iuculano Fri, 11 Dec 2009 09:11:01 +0100 dkms (2.1.0.1-3) unstable; urgency=low [ David Paleino ] * [d3f1e76] debian/control: updated my email address [ Giuseppe Iuculano ] * [ad96cbc] Updated vcs control fields * [40941ad] /etc/init.d/dkms_autoinstaller: - optimize with a single find call instead of multiple loops with ls. - port to POSIX sh and drop the /bin/bash from the shebang. - drop localization of the usage message - this is inconsistent with all other init scripts on the system. - use case instead of grep for string matching - Patch based on work done by Steve Langasek, thanks (LP: #484386) -- Giuseppe Iuculano Sun, 06 Dec 2009 18:36:43 +0100 dkms (2.1.0.1-2) unstable; urgency=low [ David Paleino ] * [47e453e] debian/patches/02-improve_error_message.patch: improve error message, and add Debian/Ubuntu specific suggestion. (Closes: #553600) [ Giuseppe Iuculano ] * [27f707a] Do not build as a nobody user and don't chown the build directory, no files should be owned by nobody. (Closes: #554168) -- Giuseppe Iuculano Tue, 03 Nov 2009 22:52:30 +0100 dkms (2.1.0.1-1) unstable; urgency=low * [34e006a] debian/patches/02_dkms.8.patch: Fix typos in the man page, thanks A. Costa (Closes: #534662) * [7735c89] Imported Upstream version 2.1.0.1 * [3bdb6c1] Removed all patches, they are now merged in upstream. Thanks to Mario Limonciello. * [dbb778c] debian/rules: template-dkms-mkdeb/debian/postrm was removed in upstream, do not chmod it * [09cd9d3] Updated to standards version 3.8.3 (No changes needed) * [96663f0] Updated my email address and removed DM-Upload-Allowed control field. Thanks to Ben Hutchings for his previous sponsorship * [4848db2] debian/patches/01_init.patch: Added dkms_autoinstaller in Provides and fixed init.d-script-does-not-provide-itself lintian warning -- Giuseppe Iuculano Sat, 03 Oct 2009 11:12:04 +0200 dkms (2.0.22.0-1) unstable; urgency=low * [023618e] Imported Upstream version 2.0.22.0 * [d6e0b15] Deleted patches merged in upstream: 01-fix_manpage.patch 02-fix_distribution.patch 04-use_su-to-root.patch 05- do_not_check_admin_group.patch 06-fakeroot.patch 07-exit-if-build- fails.patch 09-lilo_detection.patch 10-lsb.patch 11-bash- completion.patch 12-use_invoke-rc.d.patch 13-template.patch 14_new_module-init-tools.patch 08-support_kernel-img.conf.patch * [c5b7822] debian/patches/15_modprobe.patch: do not create an empty /etc/modprobe.d/package_name.conf. It is opened and parsed every time modprobe is run (and it is run very often at boot time). Create it only if necessary. * [3731c00] debian/patches/08-support_kernel-img.conf.patch: Use update-initramfs, it is the default in Debian/Ubuntu and it also computes and stores some checksums. (Closes: #529038) * [f4a197f] debian/patches/16_old_module.patch: Do not move away the old module, by default dkms install the new one in /lib/modules//updates/dkms (Closes: #529059) * [db7ffe7] debian/patches/01_kernel_postinst.patch: shut up "which" in the the kernel kernel_postinst.d script, only the exit code is needed. -- Giuseppe Iuculano Fri, 05 Jun 2009 22:00:35 +0200 dkms (2.0.21.1-1) unstable; urgency=low * [bcda131] Imported Upstream version 2.0.21.1 * [487ad26] debian/patches/13-template.patch: Updated template-dkms-mkdeb Changes: - Bump to debhelper 7 compatibility levels - Updated to standards version 3.8.1 - Use Dynamic Kernel Modules Support Team as maintainer field - Remove bash and add ${misc:Depends} in Depends - Use dh_prep instead of dh_clean -k * [c75e860] Updated to standards version 3.8.1 (No changes needed) * [0d14f3e] Update dkms to check for /etc/modprobe.d/dkms.conf, dh_installmodules now gives files in /etc/modprobe.d a .conf syntax, as required by new module-init-tools. * [ceff6d3] Move to kernel section as by ftpmasters override * [aa84c76] debian/control: Fix VCS-Browser field * [6cd45ec] debian/patches/15_modprobe.patch: Do not install /etc/modprobe.d/dkms, it only contains comments and is opened and parsed every time modprobe is run (and it is run very often at boot time). Use instead (and create if necessary) /etc/modprobe.d/package_name.conf. (Closes: #525379) * [171907c] debian/postinst: if /etc/modprobe.d/dkms is modified, put its content in /etc/modprobe.d/dkms.conf and remove it. * [426868b] update debian/copyright to add Giuseppe Iuculano to copyright on debian/* * [1ffb2cd] Removed 03-use-new-header_postinst.d_directory.patch, /etc/kernel/header_postinst.d is used only by kernel-package. dkms must use /etc/kernel/postinst.d/ directory. * [eff2f3e] debian/control: demoted linux-headers and linux-image in Recommends, removed kernel-package and build-essential from Depends, and added only gcc and make. * [508c115] debian/postinst: Remove also /etc/kernel/header_postinst.d/dkms and do an init script remove to un-do the "bad" links created by previous version [ Mario Limonciello ] * [848d7f9] update debian/copyright to add Mario Limonciello to copyright on debian/* * [791fc37] Update debian/rules to only run DKMS on the startup targets. This change was proposed from Ubuntu some time back as DKMS doesn't do anything on shutdown. -- Giuseppe Iuculano Mon, 04 May 2009 09:55:18 +0200 dkms (2.0.21.0-1) unstable; urgency=low * [0c2c36b] New Upstream version 2.0.21.0 * First Debian release (Closes: #481590) * [6723982] debian/patches/: Refreshed patches, and deleted 03-remove_dkms_lib_directory_if_empty.patch (now it is in upstream) * [592acec] debian/patches/04-use_su-to-root.patch: Do not test for $DISPLAY as su-to-root does not require an X display * [22d2ce2] debian/patches/09-lilo_detection.patch: grep for do_bootloader instead of postinst_hook * [b910eb3] debian/patches/03-use-new- header_postinst.d_directory.patch: Use new /etc/kernel/header_postinst.d directory introduced in kernel-package 11.017 * [f59cc66] debian/control: Add kernel-package (>= 11.017) in Depends * [6ebb0c4] Removed debian/postinst and debian/prerm -- Giuseppe Iuculano Mon, 16 Feb 2009 11:06:58 +0100 dkms (2.0.20.4-1) unstable; urgency=low [ David Paleino ] * debian/control: - using new Homepage field in source stanza - setting team as Maintainer - adding myself and Mario Limonciello as Uploaders - removed awk and bash dependencies: they are "essential" (de facto) packages (LP: #314774) - DM-Upload-Allowed set - added menu|sudo to Recommends * debian/copyright: - updated to machine-readable format - clarified license for debian/HOWTO.Debian * debian/compat bumped to 7 * debian/docs: - sample.{conf,spec} moved to debian/examples * debian/rules updated * debian/patches/01-fix_manpage.patch added, to fix hyphen-used-as-minus-sign lintian warning * debian/postinst added * debian/HOWTO.Debian from Ubuntu package added * debian/modprobe added * debian/prerm: - use sed instead of tricky grep hack - always do the default thing * added get-svn-source to debian/rules * debian/patches/08-use_update-initramfs.patch: updated to parse /etc/kernel-img.conf * debian/patches/11-bash-completion.patch: - better usage of bash builtins - _filename_parts(): fix wrong behaviour when /usr/src/ is a symlink - added patch description [ Giuseppe Iuculano ] * Added myself as Uploader * Standards-Version bumped to 3.8.0 - Add debian/README.source to document quilt usage * debian/prerm: quiet grep, do not write anything to standard output. * debian/rules: - remove some pointless blank lines - fix dh-clean-k-is-deprecated lintian warning, use dh_prep instead of dh_clean -k * debian/patches/03-remove_dkms_lib_directory_if_empty.patch: Merge from Ubuntu, ensure that the /lib/modules//updates/dkms directory is removed if it is empty after a removal. This allows the modules directory to be removed as it becomes empty. * debian/patches/04-use_su-to-root.patch: Use su-to-root if available * debian/patches/05-do_not_check_admin_group.patch: - Do not check for admin group, this isn't a Debian standard group. - added a g modifier to replace all underscores in function make_debian() * debian/patches/06-fakeroot.patch: Do not use fakeroot for source- only build, and use -rfakeroot for binary build * debian/patches/07-exit-if-build-fails.patch: Fix exit when build fails * debian/patches/08-support_kernel-img.conf.patch: Use update-initramfs if ramdisk value in /etc/kernel-img.conf is missing * debian/patches/09-lilo_detection.patch: check /etc/kernel-img.conf to find if user is using grub * debian/patches/10-lsb.patch: - /etc/lsb-release is not present in Debian, so run run lsb_release - Added Debian as known distro in override_dest_module_location() * debian/control: - Added lsb-release in Recommends - Updated VCS control field - Added build-essential in Depends (LP: #304014), Removed ${shlibs:Depends} from Depends and removed make, dpkg-dev and gcc from Recommends * debian/patches/11-bash-completion.patch: Improve bash-completion support (Origin Mandriva) * debian/patches/01-fix_manpage.patch: fix wrong path into man page (LP: #292289) * debian/patches/12-use_invoke-rc.d.patch: Use invoke-rc.d in kernel_postinst.d_dkms and fix script-calls-init-script-directly lintian warning -- Giuseppe Iuculano Thu, 08 Jan 2009 15:01:39 +0100 dkms (2.0.19-0ubuntu2) hardy; urgency=low * Depend on awk instead of gawk. All variants of awk provide the currently required functionality. -- Mario Limonciello Wed, 26 Mar 2008 16:51:33 -0500 dkms (2.0.19-0ubuntu1) hardy; urgency=low * New upstream version. - Fixes appending date to debian/changelog in mkdeb. -- Mario Limonciello Wed, 26 Mar 2008 10:46:52 -0500 dkms (2.0.17.6-0ubuntu1) hardy; urgency=low [ Matt Domsch ] * Correct kernel uninstall trigger (LP: #192240) * Call udevadm trigger if present, fall back to udevtrigger (LP: #192241) * Fix uninstallation with weak modules (Red Hat BZ#429410) * debian/control: - Update standards version to 3.7.3 - Add Vcs-git repository. -- Mario Limonciello Mon, 18 Feb 2008 09:40:18 -0600 dkms (2.0.17.4-0ubuntu4) hardy; urgency=low * Fix -x call. -- Scott James Remnant Fri, 14 Dec 2007 16:52:51 +0000 dkms (2.0.17.4-0ubuntu3) hardy; urgency=low * dkms: call udevadm instead of udevtrigger -- Scott James Remnant Fri, 14 Dec 2007 16:15:13 +0000 dkms (2.0.17.5-0ubuntu1) hardy; urgency=low * Correct DKMS file install/uninstall problems (LP: #151644) - call udevtrigger if we install a module for the currently running kernel - uninstall from /extra before DEST_MODULE_LOCATION - Run depmod after uninstall -- Matt Domsch Mon, 10 Oct 2007 16:50:00 -0500 dkms (2.0.17.4-0ubuntu1) gutsy; urgency=low * initial debian packaging for Ubuntu (LP: #121676) -- Matt Domsch Mon, 17 Sep 2007 09:58:46 -0500 debian/source/0000775000000000000000000000000012265473656010510 5ustar debian/source/format0000664000000000000000000000001412265473465011714 0ustar 3.0 (quilt) debian/compat0000664000000000000000000000000212265473465010404 0ustar 7 debian/patches/0000775000000000000000000000000012602771420010620 5ustar debian/patches/fix_have_one_kernel_for_non-zero_return_code.diff0000664000000000000000000000213612265473465022551 0ustar Description: Fixes function have_one_kernel in dkms script for non-zero return code Author: Mario Limonciello Origin: upstream Bug-Ubuntu: https://bugs.launchpad.net/bugs/1261116 Index: dkms/dkms =================================================================== --- dkms.orig/dkms 2014-01-10 16:33:48.000168000 +0100 +++ dkms/dkms 2014-01-10 16:44:48.522601051 +0100 @@ -162,11 +162,14 @@ # A little test function for DKMS commands that only work on one kernel. have_one_kernel() { - (( ${#kernelver[@]} > 1 )) && \ - die 4 $"The action $1 does not support multiple kernel version" \ - $"parameters on the command line." - [[ $all ]] && die 5 $"The action $1 does not support the --all" \ - $"parameter." + if (( ${#kernelver[@]} != 1 )); then + die 4 $"The action $1 does not support multiple kernel version" \ + $"parameters on the command line." + fi + if [[ $all ]]; then + die 5 $"The action $1 does not support the --all" \ + $"parameter." + fi } # Set up the kernelver and arch arrays. You must have a 1:1 correspondence -- debian/patches/apport_dup_signature.patch0000664000000000000000000000255112265473465016117 0ustar From c7e7b969a05db19e72f69f3a39aef1c33b5cc5fd Mon Sep 17 00:00:00 2001 From: Martin Pitt Date: Thu, 2 May 2013 15:35:45 -0700 Subject: [PATCH] apport hook: Trim duplicate signature Don't use the whole DKMS build log as duplicate signature, this is way too long. Just use the first actual compiler error, together with the package name and version. https://bugs.launchpad.net/dkms/+bug/1175785 --- dkms_apport.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) Index: dkms-2.2.0.3/dkms_apport.py =================================================================== --- dkms-2.2.0.3.orig/dkms_apport.py 2013-05-02 15:39:01.839557409 -0700 +++ dkms-2.2.0.3/dkms_apport.py 2013-05-02 15:39:01.835557409 -0700 @@ -87,12 +87,10 @@ if 'Segmentation fault' in report['DKMSBuildLog']: sys.stderr.write('ERROR (dkms apport): There was a segmentation fault when trying to build the module\n') sys.exit(1) - dupe_sig = '' for line in report['DKMSBuildLog'].split('\n'): - if line.endswith(this_year): - continue - dupe_sig += line + '\n' - report['DuplicateSignature'] = dupe_sig + if ': error:' in line: + report['DuplicateSignature'] = 'dkms:%s:%s:%s' % (package, version, line.strip()) + break if options.kernel: report['DKMSKernelVersion'] = options.kernel debian/patches/new_apport_utils.patch0000664000000000000000000000137512602771420015245 0ustar Description: Update the the apport.utils api change Author: Sebastien Bacher Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/dkms/+bug/1499842 Index: dkms-2.2.0.3/dkms_apport.py =================================================================== --- dkms-2.2.0.3.orig/dkms_apport.py 2015-09-30 07:33:50.889516751 -0400 +++ dkms-2.2.0.3/dkms_apport.py 2015-09-30 10:34:52.791255837 -0400 @@ -94,5 +94,8 @@ if options.kernel: report['DKMSKernelVersion'] = options.kernel -with open(apport.fileutils.make_report_path(report), 'wb') as f: - report.write(f) +try: + with apport.fileutils.make_report_file(report) as f: + report.write(f) +except (IOError, OSError) as e: + apport.fatal('Cannot create report: ' + str(e)) debian/patches/apport_package_key_with_version.patch0000664000000000000000000000304112477365052020301 0ustar Author: Brian Murray Last-Update: 2014-11-14 Description: Include package version in package data Apport includes the package and version in the package data for any report that it creates. The Ubuntu Error Tracker expects the data to follow this format, and should not have to look up the package version in different fields, so this special hook should follow the format. Index: dkms-2.2.0.3/dkms_apport.py =================================================================== --- dkms-2.2.0.3.orig/dkms_apport.py +++ dkms-2.2.0.3/dkms_apport.py @@ -62,18 +62,18 @@ if options.kernel: make_log=os.path.join('/var','lib','dkms',options.module,options.version,'build','make.log') report = apport.Report('Package') -report['Package'] = package -try: - report['SourcePackage'] = apport.packaging.get_source(package) -except ValueError: - sys.stderr.write('ERROR (dkms apport): unable to determine source package for %s\n' % package) - sys.exit(3) try: version = packaging.get_version(package) except ValueError: version = '(not installed)' if version is None: version = '(not installed)' +report['Package'] = '%s %s' % (package, version) +try: + report['SourcePackage'] = apport.packaging.get_source(package) +except ValueError: + sys.stderr.write('ERROR (dkms apport): unable to determine source package for %s\n' % package) + sys.exit(3) if report['SourcePackage'] == 'fglrx-installer': fglrx_make_log = os.path.join('/var','lib','dkms',options.module,options.version,'build','make.sh.log') debian/patches/657145.patch0000664000000000000000000000204612265473465012433 0ustar From: Andreas Beckmann Subject: remove the directory where the module was installed after removing a module try to remove the path (below /lib/modules/KVERS) were the module was installed to cleanup any remaining empty directories Bug-Debian: http://bugs.debian.org/657145 diff --git a/dkms b/dkms index 042acc0..c96cd8f 100644 --- a/dkms +++ b/dkms @@ -1579,6 +1579,9 @@ do_uninstall() echo $" - Uninstallation" echo $" - Deleting from: $install_tree/$1${real_dest_module_location}/" rm -f "$install_tree/$1${real_dest_module_location}/${dest_module_name[$count]}$module_suffix" + dir_to_remove="${real_dest_module_location#/}" + while [ "${dir_to_remove}" != "${dir_to_remove#/}" ]; do dir_to_remove="${dir_to_remove#/}" ; done + (cd "$install_tree/$1" && rmdir --parents --ignore-fail-on-non-empty "${dir_to_remove}" || true) echo $" - Original module" if [[ -e $dkms_tree/$module/original_module/$1/$2/${dest_module_name[$count]}$module_suffix ]]; then case "$running_distribution" in debian/patches/series0000664000000000000000000000047012602744235012042 0ustar 666023.patch 657145.patch apport_supported_kernel_packages.diff Add-support-for-forcing-modules-installation.patch apport_python3.patch apport_dup_signature.patch fix_have_one_kernel_for_non-zero_return_code.diff fixed_sed_without_options_issue.patch apport_package_key_with_version.patch new_apport_utils.patch debian/patches/apport_supported_kernel_packages.diff0000664000000000000000000000216012265473465020276 0ustar Description: Check the result of is_distro_package() and fix the check if the kernel header package is installed at all. Author: Felix Geyer Bug-Ubuntu: https://bugs.launchpad.net/bugs/940285 --- dkms-2.2.0.3.orig/dkms_apport.py +++ dkms-2.2.0.3/dkms_apport.py @@ -48,12 +48,16 @@ if options.kernel: # TODO: Ubuntu specific kernel_package = "linux-headers-" + options.kernel + supported_kernel = True try: - apport.packaging.is_distro_package(kernel_package) + supported_kernel = apport.packaging.is_distro_package(kernel_package) except ValueError, e: - if e == 'package does not exist': - print >> sys.stderr, 'ERROR (dkms apport): kernel package %s is not supported' % (kernel_package) - sys.exit(1) + if str(e) == 'package does not exist': + supported_kernel = False + + if not supported_kernel: + print >> sys.stderr, 'ERROR (dkms apport): kernel package %s is not supported' % (kernel_package) + sys.exit(1) make_log=os.path.join('/var','lib','dkms',options.module,options.version,'build','make.log') debian/patches/fixed_sed_without_options_issue.patch0000664000000000000000000000167712437171716020364 0ustar --- a/dkms +++ b/dkms @@ -761,16 +766,17 @@ # do all the changes at once, record the diffs for posterity for file in "$@"; do [[ $file && -w $file ]] || continue + _tmpf="$temp_dir_name/${file##*/}.new" if [[ $file = /etc/sysconfig/kernel ]]; then - sed "${sa_sck_o[@]}" "$file" > "$temp_dir_name/${file##*/}.new" + [ -z "${sa_sck_o[@]}" ] || sed "${sa_sck_o[@]}" "$file" > "$_tmpf" else - sed "${sa_mc_o[@]}" "$file" > "$temp_dir_name/${file##*/}.new" + [ -z "${sa_mc_o[@]}" ] || sed "${sa_mc_o[@]}" "$file" > "$_tmpf" fi - if ! mod_diff=$(diff -u "$temp_dir_name/${file##*/}.new" "$file"); then + if [ -f "$_tmpf" ] && ! mod_diff=$(diff -u "$_tmpf" "$file"); then echo $"$file updated to replace obsoleted module references:" echo "$mod_diff" - cp -fp "$temp_dir_name/${file##*/}.new" "$file" - rm -f "$temp_dir_name/${file##*/}.new" + cp -fp "$_tmpf" "$file" + rm -f "$_tmpf" fi done } debian/patches/apport_python3.patch0000664000000000000000000000724512265473465014657 0ustar Description: Port apport hook to Python 3 and take care of opening the output file in binary mode. Author: Martin Pitt Bug-Ubuntu: https://launchpad.net/bugs/1008092 Bug-Ubuntu: https://launchpad.net/bugs/1013171 Index: dkms-2.2.0.3/dkms_apport.py =================================================================== --- dkms-2.2.0.3.orig/dkms_apport.py 2013-05-29 08:04:46.000000000 +0200 +++ dkms-2.2.0.3/dkms_apport.py 2013-05-29 08:28:40.000000000 +0200 @@ -1,4 +1,4 @@ -#!/usr/bin/python +#!/usr/bin/python3 # # Dynamic Kernel Module Support (DKMS) # Copyright (C) 2009 Dell, Inc. @@ -36,12 +36,12 @@ options=optparser.parse_args()[0] if not options.module or not options.version: - print >> sys.stderr, 'ERROR (dkms apport): both -m and -v are required' + sys.stderr.write('ERROR (dkms apport): both -m and -v are required\n') sys.exit(2) package=packaging.get_file_package('/usr/src/' + options.module + '-' + options.version) if package is None: - print >> sys.stderr, 'ERROR (dkms apport): binary package for %s: %s not found' % (options.module,options.version) + sys.stderr.write('ERROR (dkms apport): binary package for %s: %s not found\n' % (options.module,options.version)) sys.exit(1) if options.kernel: @@ -51,12 +51,12 @@ supported_kernel = True try: supported_kernel = apport.packaging.is_distro_package(kernel_package) - except ValueError, e: + except ValueError as e: if str(e) == 'package does not exist': supported_kernel = False if not supported_kernel: - print >> sys.stderr, 'ERROR (dkms apport): kernel package %s is not supported' % (kernel_package) + sys.stderr.write('ERROR (dkms apport): kernel package %s is not supported\n' % (kernel_package)) sys.exit(1) make_log=os.path.join('/var','lib','dkms',options.module,options.version,'build','make.log') @@ -66,7 +66,7 @@ try: report['SourcePackage'] = apport.packaging.get_source(package) except ValueError: - print >> sys.stderr, 'ERROR (dkms apport): unable to determine source package for %s' % package + sys.stderr.write('ERROR (dkms apport): unable to determine source package for %s\n' % package) sys.exit(3) try: version = packaging.get_version(package) @@ -85,7 +85,7 @@ if 'DKMSBuildLog' in report: this_year = str(datetime.today().year) if 'Segmentation fault' in report['DKMSBuildLog']: - print >> sys.stderr, 'ERROR (dkms apport): There was a segmentation fault when trying to build the module' + sys.stderr.write('ERROR (dkms apport): There was a segmentation fault when trying to build the module\n') sys.exit(1) dupe_sig = '' for line in report['DKMSBuildLog'].split('\n'): @@ -96,4 +96,5 @@ if options.kernel: report['DKMSKernelVersion'] = options.kernel -report.write(open(apport.fileutils.make_report_path(report), 'w')) +with open(apport.fileutils.make_report_path(report), 'wb') as f: + report.write(f) Index: dkms-2.2.0.3/dkms =================================================================== --- dkms-2.2.0.3.orig/dkms 2013-05-29 08:04:46.000000000 +0200 +++ dkms-2.2.0.3/dkms 2013-05-29 08:30:55.406135813 +0200 @@ -3032,8 +3032,8 @@ report_build_problem() { #If apport is on the system, files a build problem - if [ -x /usr/share/apport/apport ] && which python>/dev/null; then - python /usr/share/apport/package-hooks/dkms_packages.py -m $module -v $module_version -k ${kernelver[0]} + if [ -x /usr/share/apport/apport ] && which python3 >/dev/null; then + python3 /usr/share/apport/package-hooks/dkms_packages.py -m $module -v $module_version -k ${kernelver[0]} fi die "$@" } debian/patches/666023.patch0000664000000000000000000000104312265473465012422 0ustar From: Andreas Beckmann Subject: do not fail if /lib/modules does not exist Bug-Debian: http://bugs.debian.org/666023 diff --git a/dkms_common.postinst b/dkms_common.postinst index d8cf3a7..0c8cfc1 100644 --- a/dkms_common.postinst +++ b/dkms_common.postinst @@ -146,7 +146,7 @@ if [ -z "$NAME" ] || [ -z "$VERSION" ]; then exit 1 fi -KERNELS=$(ls /lib/modules/) +KERNELS=$(ls /lib/modules/ 2>/dev/null || true) CURRENT_KERNEL=$(uname -r) #We never want to keep an older version side by side to prevent conflicts debian/patches/Add-support-for-forcing-modules-installation.patch0000664000000000000000000000444012265473465022440 0ustar From d878f6c8e5976091da4975600825f484c813fa54 Mon Sep 17 00:00:00 2001 From: Alberto Milone Date: Fri, 23 Mar 2012 15:45:03 +0100 Subject: [PATCH 1/1] Add support for forcing modules installation with configuration files This allows dkms to force the installation of modules whose names are listed in the text files in the following directory: /usr/share/dkms/modules_to_force_install Signed-off-by: Alberto Milone --- dkms | 32 ++++++++++++++++++++++++++++++++ 1 files changed, 32 insertions(+), 0 deletions(-) diff --git a/dkms b/dkms index 042acc0..b26af41 100644 --- a/dkms +++ b/dkms @@ -1270,6 +1270,28 @@ build_module() echo $"DKMS: build completed." } +# Force the installation of a module if this is listed +# in the files in $forced_modules_dir, if any +force_installation() +{ + forced_modules_dir="/usr/share/dkms/modules_to_force_install" + to_force="" + if [ -d $forced_modules_dir ]; then + for elem in $forced_modules_dir/*; do + if [ -e $elem ]; then + to_force="$to_force $(cat $elem)" + fi + done + + for elem in $to_force; do + if [ "${1}" = "${elem}" ]; then + return 0 + fi + done + fi + return 1 +} + # Install a previously built module # There are huge swaths of code here that special-case for various distros. # They should be split into their own functions. @@ -1280,6 +1302,13 @@ install_module() local base_dir="$dkms_tree/$module/$module_version/$kernelver/$arch" check_module_args install + # Save the status of $force + tmp_force="$force" + + # If the module is set to be force-installed + force_installation $module && echo "Forcing installation of $module" \ + && force="true" + # Make sure that kernel exists to install into [[ -e $install_tree/$kernelver ]] || die 6 \ $"The directory $install_tree/$kernelver doesn't exist." \ @@ -1417,6 +1446,9 @@ install_module() } echo $"" echo $"DKMS: install completed." + + # Restore the status of $force + force="$tmp_force" } # List each kernel object that has been installed for a particular module. -- 1.7.5.4 debian/examples0000664000000000000000000000011312265473465010742 0ustar sample.conf sample.spec sample-suse-10-mkkmp.spec sample-suse-9-mkkmp.spec debian/modprobe0000664000000000000000000000017712265473465010745 0ustar # modprobe information used for DKMS modules # # This is a stub file, should be edited when needed, # used by default by DKMS. debian/copyright0000664000000000000000000000170412265473465011143 0ustar Source: http://linux.dell.com/dkms/ Files: debian/HOWTO.Debian Copyright: © 2008, Dell, Inc. Mario Limonciello License: GPL-2+ This package is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. Files: debian/* Copyright: © 2008-2009, David Paleino © 2005-2008, Matt Domsch © 2008-2009, Mario Limonciello © 2008-2009, Giuseppe Iuculano License: GPL-2+ Files: * Copyright: © 2003-2009, Dell, Inc. License: GPL-2+ On Debian systems, the complete text of the GNU General Public License v2 can be found in `/usr/share/common-licenses/GPL-2'. debian/watch0000664000000000000000000000010312265473465010231 0ustar version=3 http://linux.dell.com/dkms/permalink/dkms-(.*)\.tar\.gz debian/install0000664000000000000000000000040612567563376010605 0ustar debian/scripts/dh_dkms usr/bin debian/scripts/dh_dkms.1 usr/share/man/man1/ debian/scripts/*-dkms usr/share/debhelper/autoscripts/ debian/scripts/dkms.pm usr/share/perl5/Debian/Debhelper/Sequence/ debian/scripts/dkms-autopkgtest usr/lib/dkms/ debian/rules0000775000000000000000000000112112265473465010261 0ustar #!/usr/bin/make -f # -*- makefile -*- CURVER = $(shell dpkg-parsechangelog | grep ^Version | cut -d" " -f2 | cut -d"-" -f1 ) %: dh $@ dh_dkms.1: debian/scripts/dh_dkms pod2man \ --center "DKMS Debhelper" \ --release $(CURVER) \ $< > debian/scripts/$@ override_dh_auto_build: override_dh_install: $(MAKE) install-debian DESTDIR=$(CURDIR)/debian/dkms dh_install get-orig-source: uscan \ --force-download \ --download-version $(CURVER) \ --rename get-svn-source: [ -d ../tarballs ] || mkdir ../tarballs cd ../tarballs && make -f $(CURDIR)/debian/rules get-orig-source