From d12c99394cb86bbf9c0657a596a4a26fe2b1c16d Mon Sep 17 00:00:00 2001 From: Antonio Ospite Date: Wed, 12 Oct 2011 13:02:39 +0200 Subject: [PATCH 1/1] debian: Initial debian packaging import --- debian/README.Debian | 15 ++++++++++ debian/changelog | 5 ++++ debian/compat | 1 + debian/control | 23 +++++++++++++++ debian/copyright | 61 +++++++++++++++++++++++++++++++++++++++ debian/docs | 1 + debian/gbp.conf | 4 +++ debian/install | 2 ++ debian/kinect_fetch_fw.8 | 36 +++++++++++++++++++++++ debian/kinect_upload_fw.8 | 39 +++++++++++++++++++++++++ debian/lintian/kinect-audio-setup | 1 + debian/manpages | 2 ++ debian/postinst | 28 ++++++++++++++++++ debian/postrm | 29 +++++++++++++++++++ debian/rules | 8 +++++ debian/source/format | 1 + 16 files changed, 256 insertions(+) create mode 100644 debian/README.Debian create mode 100644 debian/changelog create mode 100644 debian/compat create mode 100644 debian/control create mode 100644 debian/copyright create mode 100644 debian/docs create mode 100644 debian/gbp.conf create mode 100644 debian/install create mode 100644 debian/kinect_fetch_fw.8 create mode 100644 debian/kinect_upload_fw.8 create mode 100644 debian/lintian/kinect-audio-setup create mode 100644 debian/manpages create mode 100644 debian/postinst create mode 100644 debian/postrm create mode 100755 debian/rules create mode 100644 debian/source/format diff --git a/debian/README.Debian b/debian/README.Debian new file mode 100644 index 0000000..5f5ed87 --- /dev/null +++ b/debian/README.Debian @@ -0,0 +1,15 @@ +kinect-audio-setup for Debian +----------------------------- + +kinect-audio-setup will download the actual firmware at install time, +this is to avoid the problem of distributing the binary blob from the +Microsoft Kinect SDK. + +For the device to work out of the box after kinect-audio-setup installation, a +recent version of pulseaudio is needed, the profile for the Kinect has been +added in commit e93b327: +http://cgit.freedesktop.org/pulseaudio/pulseaudio/commit/?id=e93b32744c1bafb33d5f3ee40b422bab2d017ae1 + +pulseaudio 1.0 will include all the needed bits. + + -- Antonio Ospite Sun, 11 Sep 2011 20:47:50 +0200 diff --git a/debian/changelog b/debian/changelog new file mode 100644 index 0000000..d07e064 --- /dev/null +++ b/debian/changelog @@ -0,0 +1,5 @@ +kinect-audio-setup (0.1-1) unstable; urgency=low + + * Initial release (Closes: #645072) + + -- Antonio Ospite Wed, 12 Oct 2011 12:51:53 +0200 diff --git a/debian/compat b/debian/compat new file mode 100644 index 0000000..45a4fb7 --- /dev/null +++ b/debian/compat @@ -0,0 +1 @@ +8 diff --git a/debian/control b/debian/control new file mode 100644 index 0000000..636a1f5 --- /dev/null +++ b/debian/control @@ -0,0 +1,23 @@ +Source: kinect-audio-setup +Section: contrib/sound +Priority: extra +Maintainer: Antonio Ospite +Build-Depends: debhelper (>= 8.0.0), libusb-1.0-0-dev, pkg-config +Standards-Version: 3.9.2 +Homepage: http://git.ao2.it/kinect-audio-setup.git/ +Vcs-Git: git://git.ao2.it/kinect-audio-setup.git +Vcs-Browser: http://git.ao2.it/kinect-audio-setup.git/ + +Package: kinect-audio-setup +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends}, udev, wget, p7zip-full +Description: enable audio input from the Microsoft Kinect sensor device + When the Kinect is first plugged in the USB port it shows up as a + generic USB device with a bulk endpoint; after uploading a certain + firmware a reenumeration takes place and a USB Audio Class device + becomes available. + . + kinect-audio-setup provides tools to download the firmware off the net + at installation time —since it is not redistributable—, and it sets up + udev rules to call the firmware loader when the device is plugged in to + finally get the USB Audio Class device. diff --git a/debian/copyright b/debian/copyright new file mode 100644 index 0000000..91f048f --- /dev/null +++ b/debian/copyright @@ -0,0 +1,61 @@ +Format: http://anonscm.debian.org/viewvc/dep/web/deps/dep5.mdwn?revision=174 +Upstream-Name: kinect-audio-setup +Source: http://git.ao2.it/kinect-audio-setup.git + +Files: kinect_upload_fw/* +Copyright: 2011 Drew Fisher +License: BSD-2-Clause + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + . + 1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + . + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + . + THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ''AS IS'' AND + ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + ARE DISCLAIMED. IN NO EVENT SHALL DREW FISHER OR CONTRIBUTORS BE LIABLE + FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + SUCH DAMAGE. + . + The views and conclusions contained in the software and documentation are + those of the authors and should not be interpreted as representing official + policies, either expressed or implied, of Drew Fisher. + +Files: debian/* +Copyright: 2011 Antonio Ospite +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. + . + This package is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + . + You should have received a copy of the GNU General Public License + along with this program. If not, see + . + On Debian systems, the complete text of the GNU General + Public License version 2 can be found in "/usr/share/common-licenses/GPL-2". + +Files: kinect_fetch_fw +Copyright: 2011 Antonio Ospite +License: WTFPL + This program is free software. It comes without any warranty, to + the extent permitted by applicable law. You can redistribute it + and/or modify it under the terms of the Do What The Fuck You Want + To Public License, Version 2, as published by Sam Hocevar. See + http://sam.zoy.org/wtfpl/COPYING for more details. diff --git a/debian/docs b/debian/docs new file mode 100644 index 0000000..e845566 --- /dev/null +++ b/debian/docs @@ -0,0 +1 @@ +README diff --git a/debian/gbp.conf b/debian/gbp.conf new file mode 100644 index 0000000..0a80fe8 --- /dev/null +++ b/debian/gbp.conf @@ -0,0 +1,4 @@ +[DEFAULT] +debian-branch = debian +upstream-branch = master +upstream-tag = v%(version)s diff --git a/debian/install b/debian/install new file mode 100644 index 0000000..dd26b90 --- /dev/null +++ b/debian/install @@ -0,0 +1,2 @@ +kinect_fetch_fw /usr/sbin +debian/lintian/kinect-audio-setup usr/share/lintian/overrides/ diff --git a/debian/kinect_fetch_fw.8 b/debian/kinect_fetch_fw.8 new file mode 100644 index 0000000..6af2cd7 --- /dev/null +++ b/debian/kinect_fetch_fw.8 @@ -0,0 +1,36 @@ +.\" Hey, EMACS: -*- nroff -*- +.\" First parameter, NAME, should be all caps +.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection +.\" other parameters are allowed: see man(7), man(1) +.TH KINECT_FETCH_FW 8 "September 11, 2011" +.\" Please adjust this date whenever revising the manpage. +.\" +.\" Some roff macros, for reference: +.\" .nh disable hyphenation +.\" .hy enable hyphenation +.\" .ad l left justify +.\" .ad b justify to both left and right margins +.\" .nf disable filling +.\" .fi enable filling +.\" .br insert line break +.\" .sp insert n+1 empty lines +.\" for manpage-specific macros, see man(7) +.SH NAME +kinect_fetch_fw \- download the Usb Audio Class firmware for the Kinect +.SH SYNOPSIS +.B kinect_fetch_fw [] +.SH DESCRIPTION +.\" TeX users may be more comfortable with the \fB\fP and +.\" \fI\fP escape sequences to invode bold face and italics, +.\" respectively. +\fBkinect_fetch_fw\fP is a program to download the Usb Audio Class device +firmware for the Microsoft Kinect, and to set up udev rules enabling +\fBkinect_upload_fw\fP to be called automatically when the device is detected. +.SH SEE ALSO +.BR kinect_upload_fw (8) +.br +.SH AUTHOR +kinect_fetch_fw was written by Antonio Ospite . +.PP +This manual page was written by Antonio Ospite , +for the Debian project (and may be used by others). diff --git a/debian/kinect_upload_fw.8 b/debian/kinect_upload_fw.8 new file mode 100644 index 0000000..ed02980 --- /dev/null +++ b/debian/kinect_upload_fw.8 @@ -0,0 +1,39 @@ +.\" Hey, EMACS: -*- nroff -*- +.\" First parameter, NAME, should be all caps +.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection +.\" other parameters are allowed: see man(7), man(1) +.TH KINECT_UPLOAD_FW 8 "September 11, 2011" +.\" Please adjust this date whenever revising the manpage. +.\" +.\" Some roff macros, for reference: +.\" .nh disable hyphenation +.\" .hy enable hyphenation +.\" .ad l left justify +.\" .ad b justify to both left and right margins +.\" .nf disable filling +.\" .fi enable filling +.\" .br insert line break +.\" .sp insert n+1 empty lines +.\" for manpage-specific macros, see man(7) +.SH NAME +kinect_upload_fw \- Kinect firmware uploader to have an Usb Audio Class device +.SH SYNOPSIS +.B kinect_upload_fw +.SH DESCRIPTION +.\" TeX users may be more comfortable with the \fB\fP and +.\" \fI\fP escape sequences to invode bold face and italics, +.\" respectively. +\fBkinect_upload_fw\fP is a program that uploads the Usb Audio Class device +firmware to a Microsoft Kinect sensor device. +.PP +Before the firmware is uploaded the device shows up as a generic usb device +with a bulk endpoint, after the firmware upload a reenumeration takes place +and a Usb Audio Class device becomes available. +.SH SEE ALSO +.BR kinect_fetch_fw (8) +.br +.SH AUTHOR +kinect_upload_fw was written by Drew Fisher . +.PP +This manual page was written by Antonio Ospite , +for the Debian project (and may be used by others). diff --git a/debian/lintian/kinect-audio-setup b/debian/lintian/kinect-audio-setup new file mode 100644 index 0000000..681230f --- /dev/null +++ b/debian/lintian/kinect-audio-setup @@ -0,0 +1 @@ +kinect-audio-setup: package-contains-empty-directory lib/firmware/kinect/ diff --git a/debian/manpages b/debian/manpages new file mode 100644 index 0000000..cd10218 --- /dev/null +++ b/debian/manpages @@ -0,0 +1,2 @@ +debian/kinect_fetch_fw.8 +debian/kinect_upload_fw.8 diff --git a/debian/postinst b/debian/postinst new file mode 100644 index 0000000..41a946a --- /dev/null +++ b/debian/postinst @@ -0,0 +1,28 @@ +#!/bin/sh +# postinst script for kinect-audio-setup +# +# see: dh_installdeb(1) + +set -e + +case "$1" in + configure) + kinect_fetch_fw /lib/firmware/kinect /usr/sbin/kinect_upload_fw || true + udevadm control --reload-rules || true + ;; + + abort-upgrade|abort-remove|abort-deconfigure) + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 diff --git a/debian/postrm b/debian/postrm new file mode 100644 index 0000000..422cdde --- /dev/null +++ b/debian/postrm @@ -0,0 +1,29 @@ +#!/bin/sh +# postrm script for kinect-audio-setup +# +# see: dh_installdeb(1) + +set -e + +case "$1" in + purge) + rm -rf /lib/firmware/kinect + # Because piuparts complains about /lib/firmware still there + rmdir --ignore-fail-on-non-empty -p /lib/firmware/ + ;; + + remove|upgrade|failed-upgrade|abort-upgrade|abort-install) + ;; + + *) + echo "postrm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000..ae109ce --- /dev/null +++ b/debian/rules @@ -0,0 +1,8 @@ +#!/usr/bin/make -f +# -*- makefile -*- + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +%: + PREFIX=/usr dh $@ diff --git a/debian/source/format b/debian/source/format new file mode 100644 index 0000000..163aaf8 --- /dev/null +++ b/debian/source/format @@ -0,0 +1 @@ +3.0 (quilt) -- 2.1.4