From patchwork Thu Mar 4 13:35:05 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andy Whitcroft X-Patchwork-Id: 46908 X-Patchwork-Delegate: apw@canonical.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from chlorine.canonical.com (chlorine.canonical.com [91.189.94.204]) by ozlabs.org (Postfix) with ESMTP id C6BB0B7C59 for ; Fri, 5 Mar 2010 00:35:21 +1100 (EST) Received: from localhost ([127.0.0.1] helo=chlorine.canonical.com) by chlorine.canonical.com with esmtp (Exim 4.69) (envelope-from ) id 1NnBCu-00084w-IP; Thu, 04 Mar 2010 13:35:16 +0000 Received: from adelie.canonical.com ([91.189.90.139]) by chlorine.canonical.com with esmtp (Exim 4.69) (envelope-from ) id 1NnBCk-000833-Sc for kernel-team@lists.ubuntu.com; Thu, 04 Mar 2010 13:35:06 +0000 Received: from hutte.canonical.com ([91.189.90.181]) by adelie.canonical.com with esmtp (Exim 4.69 #1 (Debian)) id 1NnBCk-0003QT-Mx for ; Thu, 04 Mar 2010 13:35:06 +0000 Received: from 79-66-128-92.dynamic.dsl.as9105.com ([79.66.128.92] helo=localhost.localdomain) by hutte.canonical.com with esmtpsa (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.69) (envelope-from ) id 1NnBCk-0004Lj-HH for kernel-team@lists.ubuntu.com; Thu, 04 Mar 2010 13:35:06 +0000 From: Andy Whitcroft To: kernel-team@lists.ubuntu.com Subject: [PATCH 2/2] UBUNTU: perf -- add linux-tools carrying the version switches and manuals Date: Thu, 4 Mar 2010 13:35:05 +0000 Message-Id: <1267709705-30716-3-git-send-email-apw@canonical.com> X-Mailer: git-send-email 1.7.0 In-Reply-To: <1267709705-30716-1-git-send-email-apw@canonical.com> References: <1267709705-30716-1-git-send-email-apw@canonical.com> X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.9 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: kernel-team-bounces@lists.ubuntu.com Errors-To: kernel-team-bounces@lists.ubuntu.com Add a new linux-tools binary independant package which carries the version independant perf wrapper and any manual pages for perf. Signed-off-by: Andy Whitcroft --- debian.master/control.d/flavour-control.stub | 2 +- debian.master/control.stub.in | 10 ++++++++++ debian/rules.d/0-common-vars.mk | 1 + debian/rules.d/3-binary-indep.mk | 25 +++++++++++++++++++++++++ debian/tools/perf | 2 ++ 5 files changed, 39 insertions(+), 1 deletions(-) create mode 100644 debian/tools/perf diff --git a/debian.master/control.d/flavour-control.stub b/debian.master/control.d/flavour-control.stub index ebd57c6..4c66f10 100644 --- a/debian.master/control.d/flavour-control.stub +++ b/debian.master/control.d/flavour-control.stub @@ -27,7 +27,7 @@ Section: admin Priority: optional Pre-Depends: dpkg (>= 1.10.24) Provides: linux-image, linux-image-2.6, fuse-module, =PROVIDES= -Depends: ${misc:Depends}, ${shlibs:Depends}, initramfs-tools (>= 0.36ubuntu6), coreutils | fileutils (>= 4.0), module-init-tools (>= 3.3-pre11-4ubuntu3), wireless-crda +Depends: ${misc:Depends}, ${shlibs:Depends}, initramfs-tools (>= 0.36ubuntu6), coreutils | fileutils (>= 4.0), module-init-tools (>= 3.3-pre11-4ubuntu3), wireless-crda, SRCPKGNAME-tools Conflicts: hotplug (<< 0.0.20040105-1) Recommends: BOOTLOADER Suggests: fdutils, SRCPKGNAME-doc-PKGVER | SRCPKGNAME-source-PKGVER diff --git a/debian.master/control.stub.in b/debian.master/control.stub.in index c6a8404..b319b7f 100644 --- a/debian.master/control.stub.in +++ b/debian.master/control.stub.in @@ -45,6 +45,16 @@ Description: Linux kernel specific documentation for version PKGVER /usr/share/doc/SRCPKGNAME-doc/00-INDEX for a list of what is contained in each file. +Package: SRCPKGNAME-tools +Architecture: all +Section: admin +Priority: optional +Depends: ${misc:Depends} +Conflicts: SRCPKGNAME-tools-2.6 +Replaces: SRCPKGNAME-tools-2.6 +Description: Linux kernel specific tools for version PKGVER + This package provides the various tools in the PKGVER kernel source. + Package: linux-headers-PKGVER-ABINUM Architecture: all Section: devel diff --git a/debian/rules.d/0-common-vars.mk b/debian/rules.d/0-common-vars.mk index 335879f..0909dc7 100644 --- a/debian/rules.d/0-common-vars.mk +++ b/debian/rules.d/0-common-vars.mk @@ -124,6 +124,7 @@ do_tools=false ifneq ($(wildcard $(CURDIR)/tools),) do_tools=true endif +tools_pkg_name=$(src_pkg_name)-tools # Support parallel= in DEB_BUILD_OPTIONS (see #209008) # diff --git a/debian/rules.d/3-binary-indep.mk b/debian/rules.d/3-binary-indep.mk index 094c7c5..9a99736 100644 --- a/debian/rules.d/3-binary-indep.mk +++ b/debian/rules.d/3-binary-indep.mk @@ -62,6 +62,28 @@ ifeq ($(do_source_package_content),true) rm -rf $(srcdir) endif +toolspkg = $(tools_pkg_name) +toolsbin = $(CURDIR)/debian/$(toolspkg)/usr/bin +toolsman = $(CURDIR)/debian/$(toolspkg)/usr/share/man +install-tools: + dh_testdir + dh_testroot + dh_clean -k -p$(toolspkg) + + install -d $(toolsbin) + install -d $(toolsman)/man1 + + install -m755 debian/tools/perf $(toolsbin)/perf + + install -d $(builddir)/tools + for i in *; do ln -s $(CURDIR)/$$i $(builddir)/tools/; done + rm $(builddir)/tools/tools + rsync -a tools/ $(builddir)/tools/tools/ + + cd $(builddir)/tools/tools/perf && make man + install -m644 $(builddir)/tools/tools/perf/Documentation/*.1 \ + $(toolsman)/man1 + install-indep-deps = ifeq ($(do_common_headers_indep),true) install-indep-deps += install-headers @@ -72,6 +94,9 @@ endif ifeq ($(do_source_package),true) install-indep-deps += install-source endif +ifeq ($(do_tools),true) +install-indep-deps += install-tools +endif install-indep: $(install-indep-deps) # This is just to make it easy to call manually. Normally done in diff --git a/debian/tools/perf b/debian/tools/perf new file mode 100644 index 0000000..cfc2f87 --- /dev/null +++ b/debian/tools/perf @@ -0,0 +1,2 @@ +#!/bin/sh +exec perf_`uname -r` "$@"