diff options
Diffstat (limited to '')
-rw-r--r-- | debian/README.Debian | 6 | ||||
-rw-r--r-- | debian/changelog | 5 | ||||
-rw-r--r-- | debian/compat | 1 | ||||
-rw-r--r-- | debian/control | 15 | ||||
-rw-r--r-- | debian/copyright | 51 | ||||
-rw-r--r-- | debian/docs | 1 | ||||
-rw-r--r-- | debian/init.d | 154 | ||||
-rw-r--r-- | debian/nyancat.1 | 35 | ||||
-rw-r--r-- | debian/nyancat.default | 10 | ||||
-rw-r--r-- | debian/nyancat.manpages | 1 | ||||
-rw-r--r-- | debian/patches/01-nyancat-make-install.patch | 54 | ||||
-rw-r--r-- | debian/patches/series | 1 | ||||
-rwxr-xr-x | debian/rules | 13 | ||||
-rw-r--r-- | debian/source/format | 1 |
14 files changed, 348 insertions, 0 deletions
diff --git a/debian/README.Debian b/debian/README.Debian new file mode 100644 index 0000000..9821284 --- /dev/null +++ b/debian/README.Debian @@ -0,0 +1,6 @@ +nyancat for Debian +------------------ + +<possible notes regarding this package - if none, delete this file> + + -- Jonathan McCrohan <jmccrohan@gmail.com> Tue, 21 Feb 2012 12:10:45 +0000 diff --git a/debian/changelog b/debian/changelog new file mode 100644 index 0000000..e553fcb --- /dev/null +++ b/debian/changelog @@ -0,0 +1,5 @@ +nyancat (0.1+git20120319.022782c-1) unstable; urgency=low + + * Initial release (Closes: #661565) + + -- Jonathan McCrohan <jmccrohan@gmail.com> Wed, 07 Mar 2012 23:36:39 +0000 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..7627d0d --- /dev/null +++ b/debian/control @@ -0,0 +1,15 @@ +Source: nyancat +Section: misc +Priority: optional +Maintainer: Jonathan McCrohan <jmccrohan@gmail.com> +Build-Depends: debhelper (>= 8.0.0) +Standards-Version: 3.9.3 +Homepage: https://github.com/klange/nyancat + +Package: nyancat +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: Animated terminal Nyancat + Nyancat is a program to display an animated poptart cat in your terminal. + Nyancat also supports inetd, allowing remote users to view Nyancat over + telnet. diff --git a/debian/copyright b/debian/copyright new file mode 100644 index 0000000..b494750 --- /dev/null +++ b/debian/copyright @@ -0,0 +1,51 @@ +Format: http://dep.debian.net/deps/dep5 +Upstream-Name: nyancat +Source: http://miku.acm.uiuc.edu/ + +Files: * +Copyright: 2011-2012 Kevin Lange <k@dakko.us> + 2011 Peter Hazenberg <peter@haas-en-berg.nl> + 2011 Aaron Peschel <aaron.peschel@gmail.com> +License: NCSA + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to + deal with the Software without restriction, including without limitation the + rights to use, copy, modify, merge, publish, distribute, sublicense, and/or + sell copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimers. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimers in the + documentation and/or other materials provided with the distribution. + 3. Neither the names of the Association for Computing Machinery, Kevin + Lange, nor the names of its contributors may be used to endorse + or promote products derived from this Software without specific prior + written permission. + . + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + CONTRIBUTORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS + WITH THE SOFTWARE. + +Files: debian/* +Copyright: 2012 Jonathan McCrohan <jmccrohan@gmail.com> +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 <http://www.gnu.org/licenses/> + . + On Debian systems, the complete text of the GNU General + Public License version 2 can be found in "/usr/share/common-licenses/GPL-2". diff --git a/debian/docs b/debian/docs new file mode 100644 index 0000000..b43bf86 --- /dev/null +++ b/debian/docs @@ -0,0 +1 @@ +README.md diff --git a/debian/init.d b/debian/init.d new file mode 100644 index 0000000..09c01bc --- /dev/null +++ b/debian/init.d @@ -0,0 +1,154 @@ +#!/bin/sh +### BEGIN INIT INFO +# Provides: nyancat +# Required-Start: $network $local_fs +# Required-Stop: +# Default-Start: 2 3 4 5 +# Default-Stop: 0 1 6 +# Short-Description: <Enter a short description of the sortware> +# Description: <Enter a long description of the software> +# <...> +# <...> +### END INIT INFO + +# Author: Jonathan McCrohan <jmccrohan@gmail.com> + +# PATH should only include /usr/* if it runs after the mountnfs.sh script +PATH=/sbin:/usr/sbin:/bin:/usr/bin +DESC=nyancat # Introduce a short description here +NAME=nyancat # Introduce the short server's name here +DAEMON=/usr/sbin/nyancat # Introduce the server's location here +DAEMON_ARGS="" # Arguments to run the daemon with +PIDFILE=/var/run/$NAME.pid +SCRIPTNAME=/etc/init.d/$NAME + +# Exit if the package is not installed +[ -x $DAEMON ] || exit 0 + +# Read configuration variable file if it is present +[ -r /etc/default/$NAME ] && . /etc/default/$NAME + +# Load the VERBOSE setting and other rcS variables +. /lib/init/vars.sh + +# Define LSB log_* functions. +# Depend on lsb-base (>= 3.0-6) to ensure that this file is present. +. /lib/lsb/init-functions + +# +# Function that starts the daemon/service +# +do_start() +{ + # Return + # 0 if daemon has been started + # 1 if daemon was already running + # 2 if daemon could not be started + start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $DAEMON --test > /dev/null \ + || return 1 + start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $DAEMON -- \ + $DAEMON_ARGS \ + || return 2 + # Add code here, if necessary, that waits for the process to be ready + # to handle requests from services started subsequently which depend + # on this one. As a last resort, sleep for some time. +} + +# +# Function that stops the daemon/service +# +do_stop() +{ + # Return + # 0 if daemon has been stopped + # 1 if daemon was already stopped + # 2 if daemon could not be stopped + # other if a failure occurred + start-stop-daemon --stop --quiet --retry=TERM/30/KILL/5 --pidfile $PIDFILE --name $NAME + RETVAL="$?" + [ "$RETVAL" = 2 ] && return 2 + # Wait for children to finish too if this is a daemon that forks + # and if the daemon is only ever run from this initscript. + # If the above conditions are not satisfied then add some other code + # that waits for the process to drop all resources that could be + # needed by services started subsequently. A last resort is to + # sleep for some time. + start-stop-daemon --stop --quiet --oknodo --retry=0/30/KILL/5 --exec $DAEMON + [ "$?" = 2 ] && return 2 + # Many daemons don't delete their pidfiles when they exit. + rm -f $PIDFILE + return "$RETVAL" +} + +# +# Function that sends a SIGHUP to the daemon/service +# +do_reload() { + # + # If the daemon can reload its configuration without + # restarting (for example, when it is sent a SIGHUP), + # then implement that here. + # + start-stop-daemon --stop --signal 1 --quiet --pidfile $PIDFILE --name $NAME + return 0 +} + +case "$1" in + start) + [ "$VERBOSE" != no ] && log_daemon_msg "Starting $DESC " "$NAME" + do_start + case "$?" in + 0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;; + 2) [ "$VERBOSE" != no ] && log_end_msg 1 ;; + esac + ;; + stop) + [ "$VERBOSE" != no ] && log_daemon_msg "Stopping $DESC" "$NAME" + do_stop + case "$?" in + 0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;; + 2) [ "$VERBOSE" != no ] && log_end_msg 1 ;; + esac + ;; + status) + status_of_proc "$DAEMON" "$NAME" && exit 0 || exit $? + ;; + #reload|force-reload) + # + # If do_reload() is not implemented then leave this commented out + # and leave 'force-reload' as an alias for 'restart'. + # + #log_daemon_msg "Reloading $DESC" "$NAME" + #do_reload + #log_end_msg $? + #;; + restart|force-reload) + # + # If the "reload" option is implemented then remove the + # 'force-reload' alias + # + log_daemon_msg "Restarting $DESC" "$NAME" + do_stop + case "$?" in + 0|1) + do_start + case "$?" in + 0) log_end_msg 0 ;; + 1) log_end_msg 1 ;; # Old process is still running + *) log_end_msg 1 ;; # Failed to start + esac + ;; + *) + # Failed to stop + log_end_msg 1 + ;; + esac + ;; + *) + #echo "Usage: $SCRIPTNAME {start|stop|restart|reload|force-reload}" >&2 + echo "Usage: $SCRIPTNAME {start|stop|status|restart|force-reload}" >&2 + exit 3 + ;; +esac + +: diff --git a/debian/nyancat.1 b/debian/nyancat.1 new file mode 100644 index 0000000..44c829d --- /dev/null +++ b/debian/nyancat.1 @@ -0,0 +1,35 @@ +.TH NYANCAT 1 "March, 2012" +.SH NAME +nyancat \- terminal-based Pop Tart Cat animation +.SH SYNOPSIS +.B nyancat +.RI [ -t ] " files" ... +.br +.B bar +.RI [ options ] " files" ... +.SH DESCRIPTION +This manual page documents briefly the +.B nyancat +command. +.PP +\fBnyancat\fP is a program that... +.SH OPTIONS +These programs follow the usual GNU command line syntax, with long +options starting with two dashes (`-'). +A summary of options is included below. +For a complete description, see the Info files. +.TP +.B \-t, +Enable telnet mode. +.TP +.SH SEE ALSO +.BR inetd (8). +.br +The programs are documented fully by +.IR "The Rise and Fall of a Fooish Bar" , +available via the Info system. +.SH AUTHOR +nyancat was written by Kevin Lange. +.PP +This manual page was written by Jonathan McCrohan <jmccrohan@gmail.com>, +for the Debian project (and may be used by others). diff --git a/debian/nyancat.default b/debian/nyancat.default new file mode 100644 index 0000000..6dcdc00 --- /dev/null +++ b/debian/nyancat.default @@ -0,0 +1,10 @@ +# Defaults for nyancat initscript +# sourced by /etc/init.d/nyancat +# installed at /etc/default/nyancat by the maintainer scripts + +# +# This is a POSIX shell fragment +# + +# Additional options that are passed to the Daemon. +DAEMON_OPTS="" diff --git a/debian/nyancat.manpages b/debian/nyancat.manpages new file mode 100644 index 0000000..e21141e --- /dev/null +++ b/debian/nyancat.manpages @@ -0,0 +1 @@ +debian/nyancat.1 diff --git a/debian/patches/01-nyancat-make-install.patch b/debian/patches/01-nyancat-make-install.patch new file mode 100644 index 0000000..00b6062 --- /dev/null +++ b/debian/patches/01-nyancat-make-install.patch @@ -0,0 +1,54 @@ +diff --git a/Makefile b/Makefile +index 9ac517f..318bce4 100644 +--- a/Makefile ++++ b/Makefile +@@ -1,35 +1,22 @@ ++prefix = /usr ++exec_prefix = ${prefix} ++ ++bindir = ${exec_prefix}/bin ++datarootdir = $(prefix)/share ++mandir = ${datarootdir}/man ++ + package = nyancat + version = 0.1 + tarname = $(package) + distdir = $(tarname)-$(version) + +-all clean check nyancat: +- cd src && $(MAKE) $@ +- +-dist: $(distdir).tar.gz ++SRCDIR = src ++INSTALL = /usr/bin/install -c + +-$(distdir).tar.gz: $(distdir) +- tar chof - $(distdir) | gzip -9 -c > $@ +- rm -rf $(distdir) +- +-$(distdir): FORCE +- mkdir -p $(distdir)/src +- cp Makefile $(distdir) +- cp src/Makefile $(distdir)/src +- cp src/nyancat.c $(distdir)/src +- cp src/animation.h $(distdir)/src +- cp src/telnet.h $(distdir)/src +- +-FORCE: +- -rm $(distdir).tar.gz >/dev/null 2>&1 +- -rm -rf $(distdir) >/dev/null 2>&1 ++all clean check nyancat: ++ cd $(SRCDIR) && $(MAKE) $@ + +-distcheck: $(distdir).tar.gz +- gzip -cd $(distdir).tar.gz | tar xvf - +- cd $(distdir) && $(MAKE) all +- cd $(distdir) && $(MAKE) check +- cd $(distdir) && $(MAKE) clean +- rm -rf $(distdir) +- @echo "*** Package $(distdir).tar.gz is ready for distribution." ++install : ++ $(INSTALL) -Dm 0755 $(SRCDIR)/$(package) $(DESTDIR)$(bindir)/$(package) + +-.PHONY: FORCE all clean check dist distcheck ++.PHONY: all clean check install diff --git a/debian/patches/series b/debian/patches/series new file mode 100644 index 0000000..b90ab15 --- /dev/null +++ b/debian/patches/series @@ -0,0 +1 @@ +01-nyancat-make-install.patch diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000..b760bee --- /dev/null +++ b/debian/rules @@ -0,0 +1,13 @@ +#!/usr/bin/make -f +# -*- makefile -*- +# Sample debian/rules that uses debhelper. +# This file was originally written by Joey Hess and Craig Small. +# As a special exception, when this file is copied by dh-make into a +# dh-make output file, you may use that output file without restriction. +# This special exception was added by Craig Small in version 0.37 of dh-make. + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +%: + 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) |