diff options
author | Matthew Johnson <mjj29@hecate.matthew.ath.cx> | 2007-12-13 09:44:56 +0000 |
---|---|---|
committer | Matthew Johnson <mjj29@hecate.matthew.ath.cx> | 2007-12-13 09:44:56 +0000 |
commit | a1826fa0ea6118fef426bcea8bdf7cee7388db72 (patch) | |
tree | 86f64e06f9746307a8bca9da46975da8ff0bc915 |
import ipmitool
-rw-r--r-- | debian/changelog | 313 | ||||
-rw-r--r-- | debian/control | 28 | ||||
-rw-r--r-- | debian/copyright | 36 | ||||
-rw-r--r-- | debian/dirs | 4 | ||||
-rw-r--r-- | debian/docs | 2 | ||||
-rw-r--r-- | debian/ipmitool.ipmievd.init | 102 | ||||
-rw-r--r-- | debian/ipmitool.postinst | 14 | ||||
-rw-r--r-- | debian/ipmitool.postrm | 7 | ||||
-rw-r--r-- | debian/ipmitool.prerm | 7 | ||||
-rw-r--r-- | debian/patches/00list | 1 | ||||
-rw-r--r-- | debian/patches/20-linux-libc-dev.dpatch | 29 | ||||
-rwxr-xr-x | debian/rules | 118 |
12 files changed, 661 insertions, 0 deletions
diff --git a/debian/changelog b/debian/changelog new file mode 100644 index 0000000..c5d9592 --- /dev/null +++ b/debian/changelog @@ -0,0 +1,313 @@ +ipmitool (1.8.9-1) unstable; urgency=low + + * Adopt package (Closes: #432027) + * New upstream release + + -- Matthew Johnson <mjj29@debian.org> Thu, 13 Dec 2007 09:41:47 +0000 + +ipmitool (1.8.8-3.1) unstable; urgency=high + + * Non-maintainer upload. + * High urgency for RC bug fix. + * Fix build with linux-libc-dev (closes: #428929). + * Fix debian/rules to not rerun configure in the binary target. + + -- Julien Cristau <jcristau@debian.org> Fri, 20 Jul 2007 16:29:18 +0200 + +ipmitool (1.8.8-3) unstable; urgency=low + + * Ported fix to ipmievd from upstream version 1.8.9 (Closes: #408536): + - fix ipmievd fd closing bug. Patch from Rupert Hair. + * Started using dpatch to apply patches. Added dpatch to build dependencies. + * Add powerpc to the list of supported archs (Closes: #405455) + + -- Petter Reinholdtsen <pere@debian.org> Tue, 03 Apr 2007 16:37:45 +0200 + +ipmitool (1.8.8-2) unstable; urgency=low + + * Add handler for the ipmievd init.d script failure during removal and + installation. If it fail during installation, update + /etc/default/ipmievd to disable ipmievd. + + -- Petter Reinholdtsen <pere@debian.org> Sun, 1 Oct 2006 11:21:44 +0200 + +ipmitool (1.8.8-1) unstable; urgency=low + + * New upstream release. + - Daemon now tries to access device before it forks, and thus will + report errors to the init.d script if it fail. (Closes: #362425) + * Make it possible to disable ipmievd by setting ENABLED=false in + /etc/defaults/ipmievd. (Closes: #370511) + * Add --oknodo as start-stop-daemon argument when stopping ipmievd, + to avoid returning an error if it is not running. (Closes: #370509) + * Update standards-version from 3.6.2.1 to 3.7.2. No changes needed. + * Correct dependency and runlevel info in init.d script. + + -- Petter Reinholdtsen <pere@debian.org> Fri, 29 Sep 2006 19:16:41 +0200 + +ipmitool (1.8.7-2) unstable; urgency=low + + * Fix typo in init.d/ipmievd. (Closes: #361309) + + -- Petter Reinholdtsen <pere@debian.org> Sat, 8 Apr 2006 06:44:31 +0200 + +ipmitool (1.8.7-1) unstable; urgency=low + + * New upstream version. + - Dropped nuclear clause from the copyright. Updated debian/copyright + to reflect this. + - ipmievd now store pid in /var/run/ipmievd.pid. Adjust init.d + script to use it. + * Rename /etc/default/ipmievd variable IPMIEVD_OPTS is renamed to + IPMIEVD_OPTIONS to stay compatible with upstream and other + distributions. Add backwards compatibility code with a warning to + the users of the old variable. + + -- Petter Reinholdtsen <pere@debian.org> Sun, 26 Mar 2006 21:11:08 +0200 + +ipmitool (1.8.6-2) unstable; urgency=low + + * Add ia64 as an supported arch. (Closes: #355930) + + -- Petter Reinholdtsen <pere@debian.org> Fri, 10 Mar 2006 23:34:50 +0100 + +ipmitool (1.8.6-1) unstable; urgency=low + + * New upstream version. + - Avoid crashing when setting lan IP address. (Closes: #351205) + * Avoid changing history by reverding upstream change + to email addresses in debian/changelog. + * Correct typo in control file: Suggest -> Suggests. Thanks + to Philipp Matthias Hahn for the report. + * Add init.d/ipmievd script. Based on script from Elmar Hoffmann, + slightly modified to use lsb-base functions. Added dependency on + lsb-base. (Closes: #345994) + + -- Petter Reinholdtsen <pere@debian.org> Sun, 26 Feb 2006 10:31:14 +0100 + +ipmitool (1.8.2-2) unstable; urgency=low + + * Add build-dependency on 'libreadline5-dev | libreadline-dev' to make + sure all archs get readline support. (Closes: #326341) + * Add build-dependency on libssl-dev to enable SSL support on + all archs. + * Updated Standards-Version to 3.6.2.1. (No updates required) + + -- Petter Reinholdtsen <pere@debian.org> Sat, 3 Sep 2005 19:18:51 +0200 + +ipmitool (1.8.2-1) unstable; urgency=low + + * New upstream release. + - Fix FRU reading for large (>255 bytes) areas. + - Overhaul to ipmievd to support SEL polling in addition to OpenIPMI. + - Fix LAN parameter segfault when no Ciphers supported by + BMC. (Closes: #306806) + - Fix IPMIv2 support on Intel v2 BMCs (use -o intelplus). + - Separate option parsing code from main ipmitool source file. + - Add raw I2C support with IPMI Master Read-Write command. + - Add support for new 'sdr elist' extended output format. + - Add support for listing sensors by type with 'sdr type' command. + - Add support for new 'sel elist' extended output format that + cross-references events with sensors. + - Add support for sending dynamically generated platform events + based on existing sensor information. + - New '-S' argument to read local SDR cache created with 'sdr dump'. + - Updated manpage for ipmitool and ipmievd. (Closes: #306894) + * Correct the upstream URL in debian/changelog to the current one. + * Suggest package openipmi. (Closes: #305629) + * Add debian/watch file to detect new source versions. + + -- Petter Reinholdtsen <pere@debian.org> Sun, 5 Jun 2005 10:29:18 +0200 + +ipmitool (1.8.1-1) unstable; urgency=low + + * New upstream release. + * Install ipmievd into /usr/sbin/. + + -- Petter Reinholdtsen <pere@debian.org> Thu, 7 Apr 2005 01:18:44 +0200 + +ipmitool (1.8.0-1) unstable; urgency=low + + * Initial upload into Debian, based on the upstream build + rules. (Closes: #299924) + * Convert debian/changelog to UTF-8. + * Change section from 'contrib' to 'utils'. + * Build-depend on debhelper (>> 4.0.0) to match the rules file. + * Set Standards-version to 3.6.1. + * Make sure binary dependency is properly generated. + * Add long description, copied from the project README. + * Drop useless provides 'ipmitool', as the package is called 'ipmitool'. + * Don't install the COPYING file, as the license text already is + included in debian/copyright. + * Remove unused parts of the rules file. + * Correct clean target in rules file, to use 'distclean' and remove + configure-stamp not bogus config-stamp. + + -- Petter Reinholdtsen <pere@debian.org> Sun, 3 Apr 2005 20:52:02 +0200 + +ipmitool (1.8.0) unstable; urgency=low + + * Fix IPMIv2.0 issues + * Fix chassis boot parameter support + * Add support for linear sensors + + -- Duncan Laurie <duncan@iceblink.org> Wed, 16 Mar 2005 17:08:12 -0700 + +ipmitool (1.7.1) unstable; urgency=low + + * Update bmc plugin to work with new Solaris bmc driver (new ioctl + for interface detection and new STREAMS message-based interface). + + -- Seth Goldberg <sethmeisterg@hotmail.com> Mon, 7 Mar 2005 18:03:00 -0800 + +ipmitool (1.7.0) unstable; urgency=low + + * Propogate errors correctly so exit status will be useful + * More consistent display of errors including completion code text + * Errors and debug is send to stderr now + * New "sel get" command that will print details about SEL entry + and corresponding SDR records as well as FRUs via entity association + * Improved event generator, now supports reading events from text file + * New "-o oemtype" option for specifying OEM boards + exsting types are "supermicro" and "intelwv2" + * New PEF subsystem + * New "bmc" plugin for Solaris 10 x86 + * Many bugfixes and contributed patches + + -- Duncan Laurie <duncan@iceblink.org> Fri, 7 Jan 2005 19:58:22 -0700 + +ipmitool (1.6.2) unstable; urgency=low + + * Support for Supermicro BMC OEM authentication method + + -- Duncan Laurie <duncan@iceblink.org> Mon, 16 Nov 2004 08:20:01 -0700 + +ipmitool (1.6.1) unstable; urgency=low + + * Fix minor problem with LAN parameter setting + + -- Duncan Laurie <duncan@iceblink.org> Wed, 29 Sep 2004 11:19:17 -0700 + +ipmitool (1.6.0) unstable; urgency=low + + * Add a README + * Add support for IPMIv2 and Serial-over-LAN from Newisys + * Add Solaris x86 lipmi interface + * Add support for building Solaris packages + * Add support for building RPMs as non-root user + * Fix segfault when doing "sel list" (from Matthew Braithwaite) + * Fix "chassis identify" on some BMCs (from ebrower@sourceforge) + * Add "bmc info" and related output (from ebrower@sourceforge) + * new "shell" and "exec" commands + * lots of other contributed patches + + -- Duncan Laurie <duncan@iceblink.org> Thu, 9 Sep 2004 21:39:37 -0700 + +ipmitool (1.5.9) unstable; urgency=low + + * Add ability to get a particular sensor by name + * Add ability to set a particular sensor threshold + * Add support for displaying V2 channel authentication levels + * Add README for rrdtool scripts in contrib directory + * Improve lan interface retry handling + * Support prompting for password or reading from environment + * Move chaninfo command into channel subcommand + * Fix reservation ID handling when two sessions open to BMC + * Fix reading of large FRU data + * Add configure option for changing binary to ipmiadm for Solaris + * Fix compile problem on Solaris 8 + + -- Duncan Laurie <duncan@sun.com> Sat, 27 Mar 2004 00:11:37 -0700 + +ipmitool (1.5.8) unstable; urgency=low + + * Enable static compilation of interfaces + * Fix types to be 64-bit safe + * Fix compilation problems on Solaris + * Fix multiple big-endian problems for Solaris/SPARC + * Fix channel access to save settings to NVRAM + * Set channel privilege limit to ADMIN during "access on" + * Enable gratuitous ARP in bmcautoconf.sh + * Add support for Linux kernel panic messages in SEL output + * Add support for type 3 SDR records + + -- Duncan Laurie <duncan@sun.com> Tue, 27 Jan 2004 16:23:25 -0700 + +ipmitool (1.5.7) unstable; urgency=low + + * add IPMIv1.5 eratta fixes + * additions to FRU printing and FRU multirecords + * better handling of SDR printing + * contrib scripts for creating rrdtool graphs + + -- Duncan Laurie <duncan@sun.com> Mon, 5 Jan 2004 17:29:50 -0700 + +ipmitool (1.5.6) unstable; urgency=low + + * Fix SEL event decoding for generic events + * Handle empty SEL gracefully when doing "sel list" + * Fix sdr handling of sensors that do not return a reading + * Fix for CSV display of sensor readings/units from Fredrik Öhrn + + -- Duncan Laurie <duncan@sun.com> Thu, 4 Dec 2003 14:47:19 -0700 + +ipmitool (1.5.5) unstable; urgency=low + + * Add -U option for setting LAN username + * Fix -v usage for plugin interfaces + + -- Duncan Laurie <duncan@sun.com> Tue, 25 Nov 2003 15:10:48 -0700 + +ipmitool (1.5.4) unstable; urgency=low + + * Put interface plugin API into library + * Fix ipmievd + + -- Duncan Laurie <duncan@sun.com> Fri, 14 Nov 2003 15:16:34 -0700 + +ipmitool (1.5.3) unstable; urgency=low + + * Add -g option to work with grizzly bmc + + -- Duncan Laurie <duncan@sun.com> Mon, 3 Nov 2003 18:04:07 -0700 + +ipmitool (1.5.2) unstable; urgency=low + + * add support for setting gratuitous arp interval + + -- Duncan Laurie <duncan@sun.com> Fri, 24 Oct 2003 11:00:00 -0700 + +ipmitool (1.5.1) unstable; urgency=low + + * better SEL support + * fix display bug in SDR list + + -- Duncan Laurie <duncan@sun.com> Wed, 8 Oct 2003 17:28:51 -0700 + +ipmitool (1.5.0) unstable; urgency=low + + * more robust UDP packet handling + * add Intel IMB driver support + * use autoconf/automake/libtool + + -- Duncan Laurie <duncan@sun.com> Fri, 5 Sep 2003 11:57:32 -0700 + +ipmitool (1.2-1) unstable; urgency=low + + * New command line option parsing + * More chassis commands supported + + -- Duncan Laurie <duncan@sun.com> Wed, 2 Apr 2003 17:44:17 -0700 + +ipmitool (1.1-1) unstable; urgency=low + + * Minor fixes. + + -- Duncan Laurie <duncan@sun.com> Tue, 1 Apr 2003 14:31:10 -0700 + +ipmitool (1.0-1) unstable; urgency=low + + * Initial Release. + + -- Duncan Laurie <duncan@sun.com> Sun, 30 Mar 2003 21:30:46 -0700 + diff --git a/debian/control b/debian/control new file mode 100644 index 0000000..bde6a60 --- /dev/null +++ b/debian/control @@ -0,0 +1,28 @@ +Source: ipmitool +Section: utils +Priority: optional +Maintainer: Petter Reinholdtsen <pere@debian.org> +Uploaders: Duncan Laurie <duncan@iceblink.org> +Build-Depends: debhelper (>> 4.0.0), libreadline5-dev | libreadline-dev, libssl-dev, dpatch +Standards-Version: 3.7.2 + +Package: ipmitool +Architecture: i386 amd64 ia64 powerpc +Depends: ${shlibs:Depends}, lsb-base +Suggests: openipmi +Description: utility for IPMI control with kernel driver or LAN interface + A utility for managing and configuring devices that support the + Intelligent Platform Management Interface. IPMI is an open standard + for monitoring, logging, recovery, inventory, and control of hardware + that is implemented independent of the main CPU, BIOS, and OS. The + service processor (or Baseboard Management Controller, BMC) is the + brain behind platform management and its primary purpose is to handle + the autonomous sensor monitoring and event logging features. + . + The ipmitool program provides a simple command-line interface to this + BMC. It features the ability to read the sensor data repository + (SDR) and print sensor values, display the contents of the System + Event Log (SEL), print Field Replaceable Unit (FRU) inventory + information, read and set LAN configuration parameters, and perform + remote chassis power control. + diff --git a/debian/copyright b/debian/copyright new file mode 100644 index 0000000..cb3569d --- /dev/null +++ b/debian/copyright @@ -0,0 +1,36 @@ +This package was debianized by Duncan Laurie before +2003-11-18 17:55:21 +0100. + +It was downloaded from <URL:http://ipmitool.sourceforge.net/> + +Upstream Author: Duncan Laurie <duncan@iceblink.org> + +Copyright (c) 2003 Sun Microsystems, Inc. All Rights Reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + +Redistribution of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + +Redistribution 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. + +Neither the name of Sun Microsystems, Inc. or the names of +contributors may be used to endorse or promote products derived +from this software without specific prior written permission. + +This software is provided "AS IS," without a warranty of any kind. +ALL EXPRESS OR IMPLIED CONDITIONS, REPRESENTATIONS AND WARRANTIES, +INCLUDING ANY IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A +PARTICULAR PURPOSE OR NON-INFRINGEMENT, ARE HEREBY EXCLUDED. +SUN MICROSYSTEMS, INC. ("SUN") AND ITS LICENSORS SHALL NOT BE LIABLE +FOR ANY DAMAGES SUFFERED BY LICENSEE AS A RESULT OF USING, MODIFYING +OR DISTRIBUTING THIS SOFTWARE OR ITS DERIVATIVES. IN NO EVENT WILL +SUN OR ITS LICENSORS BE LIABLE FOR ANY LOST REVENUE, PROFIT OR DATA, +OR FOR DIRECT, INDIRECT, SPECIAL, CONSEQUENTIAL, INCIDENTAL OR +PUNITIVE DAMAGES, HOWEVER CAUSED AND REGARDLESS OF THE THEORY OF +LIABILITY, ARISING OUT OF THE USE OF OR INABILITY TO USE THIS SOFTWARE, +EVEN IF SUN HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. diff --git a/debian/dirs b/debian/dirs new file mode 100644 index 0000000..58600cc --- /dev/null +++ b/debian/dirs @@ -0,0 +1,4 @@ +usr/bin +usr/sbin +usr/share/ipmitool +usr/share/doc/ipmitool diff --git a/debian/docs b/debian/docs new file mode 100644 index 0000000..55bc0a6 --- /dev/null +++ b/debian/docs @@ -0,0 +1,2 @@ +README +AUTHORS diff --git a/debian/ipmitool.ipmievd.init b/debian/ipmitool.ipmievd.init new file mode 100644 index 0000000..d63d1f7 --- /dev/null +++ b/debian/ipmitool.ipmievd.init @@ -0,0 +1,102 @@ +#! /bin/sh +### BEGIN INIT INFO +# Provides: ipmievd +# Required-Start: $remote_fs $syslog +# Required-Stop: $remote_fs $syslog +# Default-Start: 2 3 4 5 +# Default-Stop: 0 1 6 +# Short-Description: IPMI event daemon +# Description: ipmievd is a daemon which will listen for events +# from the BMC that are being sent to the SEL and +# also log those messages to syslog. +### END INIT INFO +# +# Author: Elmar Hoffmann <elho@elho.net> +# Licence: This script is public domain using the same +# licence as ipmitool itself. +# Modified by: Petter Reinholdtsen + +set -e + +PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin +DESC="IPMI event daemon" +NAME=ipmievd +DAEMON=/usr/sbin/$NAME +PIDFILE=/var/run/$NAME.pid +SCRIPTNAME=/etc/init.d/$NAME +ENABLED=true + +# Gracefully exit if the package has been removed. +test -x $DAEMON || exit 0 + +. /lib/lsb/init-functions +. /etc/default/rcS + +# Options used by ipmievd. +# +# "open" uses the asynchronous event notification from the OpenIPMI +# kernel driver, "sel" uses active polling of the contents of the SEL +# for new events. +# +# Need to force 'daemon' mode, to make sure messages are sent to +# syslog and the program forks into the background. +# +# Se ipmievd(8) for more info. +IPMIEVD_OPTIONS="open daemon" + +# Read config file if it is present. +[ -f /etc/default/$NAME ] && . /etc/default/$NAME + +test "$ENABLED" != "false" || exit 0 + +# Backwards compatibility with version 1.8.6-2 and 1.8.6-1. The +# variable was renamed to be compatible with upstream, SuSe and RedHat. +if [ -n "$IPMIEVD_OPTS" ]; then + echo "warning: /etc/default/$NAME variable IPMIEVD_OPTS should be renamed to IPMIEVD_OPTIONS" + IPMIEVD_OPTIONS="$IPMIEVD_OPTS" +fi + +# +# Function that starts the daemon/service. +# +d_start() { + start-stop-daemon --start --quiet --exec $DAEMON --pidfile $PIDFILE -- $IPMIEVD_OPTIONS +} + +# +# Function that stops the daemon/service. +# +d_stop() { + start-stop-daemon --stop --oknodo --quiet --name $NAME --exec $DAEMON --pidfile $PIDFILE +} + +CODE=0 + +case "$1" in + start) + [ "$VERBOSE" != no ] && log_begin_msg "Starting $DESC" "$NAME" + d_start || CODE=$? + [ "$VERBOSE" != no ] && log_end_msg $CODE + exit $CODE + ;; + stop) + log_begin_msg "Stopping $DESC" "$NAME" + d_stop || CODE=$? + log_end_msg $CODE + exit $CODE + ;; + restart|force-reload) + log_begin_msg "Restarting $DESC" "$NAME" + d_stop || true + sleep 1 + d_start || CODE=$? + log_end_msg $CODE + exit $CODE + ;; + *) + echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload}" >&2 + exit 1 + ;; +esac + +exit 0 diff --git a/debian/ipmitool.postinst b/debian/ipmitool.postinst new file mode 100644 index 0000000..fe73290 --- /dev/null +++ b/debian/ipmitool.postinst @@ -0,0 +1,14 @@ +#!/bin/sh + +ipmievd_initd_failed() { + echo "Unable to start ipmievd during installation. Trying to disable." + if [ -f /etc/default/ipmievd ] && \ + grep -q ^ENABLED=false /etc/default/ipmievd ; then + : + else + touch /etc/default/ipmievd + echo "ENABLED=false" >> /etc/default/ipmievd + fi +} + +#DEBHELPER# diff --git a/debian/ipmitool.postrm b/debian/ipmitool.postrm new file mode 100644 index 0000000..ebbaf6b --- /dev/null +++ b/debian/ipmitool.postrm @@ -0,0 +1,7 @@ +#!/bin/sh + +ipmievd_initd_failed() { + : +} + +#DEBHELPER# diff --git a/debian/ipmitool.prerm b/debian/ipmitool.prerm new file mode 100644 index 0000000..ebbaf6b --- /dev/null +++ b/debian/ipmitool.prerm @@ -0,0 +1,7 @@ +#!/bin/sh + +ipmievd_initd_failed() { + : +} + +#DEBHELPER# diff --git a/debian/patches/00list b/debian/patches/00list new file mode 100644 index 0000000..1db6d00 --- /dev/null +++ b/debian/patches/00list @@ -0,0 +1 @@ +20-linux-libc-dev.dpatch diff --git a/debian/patches/20-linux-libc-dev.dpatch b/debian/patches/20-linux-libc-dev.dpatch new file mode 100644 index 0000000..8aecb3c --- /dev/null +++ b/debian/patches/20-linux-libc-dev.dpatch @@ -0,0 +1,29 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 20-linux-libc-dev.dpatch by <jcristau@debian.org> +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: No description. + +@DPATCH@ +diff -urNad ipmitool-1.8.8~/src/ipmievd.c ipmitool-1.8.8/src/ipmievd.c +--- ipmitool-1.8.8~/src/ipmievd.c 2007-07-20 16:01:43.000000000 +0200 ++++ ipmitool-1.8.8/src/ipmievd.c 2007-07-20 16:02:14.000000000 +0200 +@@ -54,7 +54,6 @@ + + #ifdef IPMI_INTF_OPEN + # if defined(HAVE_OPENIPMI_H) +-# include <linux/compiler.h> + # include <linux/ipmi.h> + # elif defined(HAVE_FREEBSD_IPMI_H) + # include <sys/ipmi.h> +diff -urNad ipmitool-1.8.8~/src/plugins/open/open.c ipmitool-1.8.8/src/plugins/open/open.c +--- ipmitool-1.8.8~/src/plugins/open/open.c 2007-07-20 16:01:21.000000000 +0200 ++++ ipmitool-1.8.8/src/plugins/open/open.c 2007-07-20 16:01:43.000000000 +0200 +@@ -50,7 +50,6 @@ + #endif + + #if defined(HAVE_OPENIPMI_H) +-# include <linux/compiler.h> + # include <linux/ipmi.h> + #elif defined(HAVE_FREEBSD_IPMI_H) + /* FreeBSD OpenIPMI-compatible header */ diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000..582b3c1 --- /dev/null +++ b/debian/rules @@ -0,0 +1,118 @@ +#!/usr/bin/make -f + +#export DH_VERBOSE=1 +export DH_COMPAT=4 +export DH_OPTIONS + +CFLAGS = -Wall -g + +ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) + CFLAGS += -O0 +else + CFLAGS += -O2 +endif +ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS))) + INSTALL_PROGRAM += -s +endif + +configure: configure-stamp +configure-stamp: patch-stamp + dh_testdir + ./configure --prefix=/usr \ + --with-kerneldir \ + --mandir=/usr/share/man + touch configure-stamp + +#Architecture +build: build-arch build-indep + +build-arch: build-arch-stamp +build-arch-stamp: configure-stamp + +# Add here commands to compile the arch part of the package. + $(MAKE) + touch build-arch-stamp + +build-indep: build-indep-stamp +build-indep-stamp: configure-stamp + touch build-indep-stamp + +# Add here commands to compile the indep part of the package. +#$(MAKE) doc + +clean: unpatch + dh_testdir + dh_testroot + rm -f build-arch-stamp build-indep-stamp configure-stamp + +# Add here commands to clean up after the build process. + -$(MAKE) distclean + + dh_clean + +install: install-arch #install-indep +install-indep: + dh_testdir + dh_testroot + dh_clean -k -i + dh_installdirs -i + +# Add here commands to install the indep part of the package into +# debian/<package>-doc. +#INSTALLDOC# +# $(MAKE) install-doc DESTDIR=$(CURDIR)/debian/tmp/ipmitool-doc +# dh_movefiles -i + +install-arch: + dh_testdir + dh_testroot + dh_clean -k -a + dh_installdirs -a + +# Add here commands to install the arch part of the package into +# debian/tmp. + $(MAKE) install DESTDIR=$(CURDIR)/debian/ipmitool + + # No need to have two copies of the license text in the package. + $(RM) $(CURDIR)/debian/ipmitool/usr/share/doc/ipmitool/COPYING + + # Move upstream changelog to correct filename. + mv $(CURDIR)/debian/ipmitool/usr/share/doc/ipmitool/ChangeLog \ + $(CURDIR)/debian/ipmitool/usr/share/doc/ipmitool/changelog + + # Compress to avoid lintian warning. Not sure why dh_compress + # isn't fixing this. + gzip -9 $(CURDIR)/debian/ipmitool/usr/share/doc/ipmitool/changelog + +# dh_movefiles -a +# Must not depend on anything. This is to be called by +# binary-arch/binary-multi +# in another 'make' thread. +binary-common: + dh_testdir + dh_testroot + dh_installdocs + dh_installchangelogs + dh_installinit --name ipmievd --error-handler=ipmievd_initd_failed + dh_link + dh_strip + dh_compress + dh_fixperms + dh_makeshlibs + dh_shlibdeps + dh_installdeb + dh_gencontrol + dh_md5sums + dh_builddeb +# Build architecture independant packages using the common target. +binary-indep: build-indep install-indep + $(MAKE) -f debian/rules DH_OPTIONS=-i binary-common + +# Build architecture dependant packages using the common target. +binary-arch: build-arch install-arch + $(MAKE) -f debian/rules DH_OPTIONS=-a binary-common + +binary: binary-arch #binary-indep +.PHONY: build build-arch build-indep clean binary-indep binary-arch binary install install-indep install-arch configure + +include /usr/share/dpatch/dpatch.make |