--- rungetty-1.2.orig/debian/rules +++ rungetty-1.2/debian/rules @@ -0,0 +1,100 @@ +#!/usr/bin/make -f +# debian/rules file for rungetty +# copyright 2000-2009 by Gerfried Fuchs +# Licenced under BSD style + +PKG = rungetty +TMP = $(CURDIR)/debian/$(PKG) + +RPM_OPTS = -g +LDFLAGS=-Wl,-warn-common +INSTALL = install +INSTALL_FILE = $(INSTALL) -p -oroot -groot -m644 +INSTALL_PROGRAM = $(INSTALL) -p -oroot -groot -m755 +INSTALL_SCRIPT = $(INSTALL) -p -oroot -groot -m755 +INSTALL_DIR = $(INSTALL) -p -d -oroot -groot -m755 + +ifneq (,$(filter noopt,$(DEB_BUILD_OPTIONS))) + RPM_OPTS += -O0 +else + RPM_OPTS += -O2 +endif +ifeq (,$(filter nostrip,$(DEB_BUILD_OPTIONS))) + INSTALL_PROGRAM += -s + LDFLAGS += -s + STRIP = true +endif + + +include /usr/share/quilt/quilt.make + +clean: unpatch + $(checkdir) + $(checkroot) + -rm -rf $(TMP) debian/substvars debian/files \ + install-stamp build-stamp + $(MAKE) clean + + +build: build-stamp +build-stamp: $(QUILT_STAMPFN) + $(checkdir) + $(MAKE) RPM_OPTS="$(RPM_OPTS)" LDFLAGS="$(LDFLAGS)" + chmod -R g-s . + touch build-stamp + + +install: install-stamp +install-stamp: build + $(checkdir) + $(checkroot) + -rm -rf $(TMP) debian/substvars + $(INSTALL_DIR) $(TMP) + cd $(TMP) && $(INSTALL_DIR) sbin \ + usr/share/man/man8 usr/share/doc/$(PKG) + $(MAKE) install ROOT=$(TMP) + test "$(STRIP)" != true || strip \ + --remove-section=.comment --remove-section=.note \ + $(TMP)/sbin/rungetty + $(INSTALL_FILE) README THANKS $(TMP)/usr/share/doc/$(PKG) + $(INSTALL_FILE) CHANGELOG \ + $(TMP)/usr/share/doc/$(PKG)/changelog + gzip -9 $(TMP)/usr/share/doc/$(PKG)/changelog \ + $(TMP)/usr/share/man/man8/rungetty.8 + touch install-stamp + + +# Build architecture-independent files here. +binary-indep: build install +# We have nothing to do by default. + + +# Build architecture-dependent files here. +binary-arch: build install + $(checkdir) + $(checkroot) + $(INSTALL_DIR) $(TMP)/DEBIAN + $(INSTALL_FILE) debian/README.Debian debian/copyright \ + $(TMP)/usr/share/doc/$(PKG) + $(INSTALL_FILE) debian/changelog \ + $(TMP)/usr/share/doc/$(PKG)/changelog.Debian + gzip -9 $(TMP)/usr/share/doc/$(PKG)/changelog.Debian + dpkg-shlibdeps -Tdebian/substvars -dDepends $(TMP)/sbin/rungetty + dpkg-gencontrol -ldebian/changelog -isp -Tdebian/substvars \ + -p$(PKG) -P$(TMP) + cd $(TMP) && find * -type f ! -regex '^DEBIAN/.*' -print0 | \ + xargs -r0 md5sum > DEBIAN/md5sums + dpkg --build $(TMP) .. + + +binary: binary-indep binary-arch + +define checkdir + test -f debian/rules +endef + +define checkroot + test root = "`whoami`" +endef + +.PHONY: clean build install binary-indep binary-arch binary --- rungetty-1.2.orig/debian/control +++ rungetty-1.2/debian/control @@ -0,0 +1,20 @@ +Source: rungetty +Section: admin +Priority: optional +Maintainer: Gerfried Fuchs +Build-Depends: quilt +Standards-Version: 3.8.1 + +Package: rungetty +Architecture: any +Depends: ${shlibs:Depends} +Description: minimal console getty that can run any process + rungetty might be the getty you were looking for. It is able to run any + program, not just login. If a different program than login is used it usually + is run as nobody:nogroup, or the user/group specified on the commandline. + rungetty can even be configured to autologin, under certain circumstances. + See the manual page for more information. + . + You have to change some lines in /etc/inittab for having any effect after + installing the package. rungetty is based on mingetty and therefore not + suitable for serial use. --- rungetty-1.2.orig/debian/changelog +++ rungetty-1.2/debian/changelog @@ -0,0 +1,130 @@ +rungetty (1.2-15) unstable; urgency=high + + * Using patch in the proper place to make sure building does happen after + patching (closes: #524750) + + -- Gerfried Fuchs Mon, 20 Apr 2009 11:07:11 +0200 + +rungetty (1.2-14) unstable; urgency=low + + * Bumped to Standards-Version 3.8.1. + * Add descriptions to quilt patches. + * allow autologin on all TTYs (closes: #515970) + * Disabled long dysfunctional watch file. + + -- Gerfried Fuchs Fri, 27 Mar 2009 16:55:09 +0100 + +rungetty (1.2-13) unstable; urgency=low + + * Updated manpage-fix to not have minus-signs displayed as hyphens. + * Use filter instead of findstring for DEB_BUILD_OPTIONS parsing as + suggested by policy. + * Strip unneeded sections from binary. + * Updated to Standards-Version 3.8.0: added debian/README.source. + + -- Gerfried Fuchs Mon, 08 Sep 2008 17:16:09 +0200 + +rungetty (1.2-12) unstable; urgency=low + + * Switched to using quilt for patching source, split current stuff into: + - make-install-fix: fix install target for manpage and stripping of binary + - manpage-fix: fix a small error in the manpage + - nogroup-fix: use nogroup as default group instead of nobody + - disable-path: disable setting of PATH + - getc-fix: use signed int for c in do_prompt + - initgroups: use supplementary grous, too + - clear-not-reset: send clear instead of reset + * Linked to GPL-2 in copyright file directly, added hint for later versions. + * Updated copyright file with statement from upstream author about + continuation of the program. + + -- Gerfried Fuchs Mon, 08 Oct 2007 09:10:37 +0200 + +rungetty (1.2-11) unstable; urgency=low + + * Fixed handling of DEB_BUILD_OPTIONS=nostrip (closes: #437942) + * Cleaned up debian/rules a bit. + + -- Gerfried Fuchs Tue, 21 Aug 2007 08:12:03 +0200 + +rungetty (1.2-10) unstable; urgency=low + + * Fixed a bug in the manpage. + + -- Gerfried Fuchs Fri, 08 Sep 2006 12:39:31 -0500 + +rungetty (1.2-9) unstable; urgency=low + + * Enabled watch file again (and updated to version 3), the site was just + down. + * Bumped Standards-Version, no changes needed. + * Send clear instead of reset, thanks to Adeodato Simó both for noticing + and finding the solution (closes: #309866) + * Improved the copyright file a bit. + + -- Gerfried Fuchs Fri, 08 Sep 2006 06:29:15 -0500 + +rungetty (1.2-8) unstable; urgency=low + + * Removed group sticky bit from package (closes: #249105) + * Process gets supplementary groups now, too (closes: #146145) + * Update to Stadards-Version 3.6.1: removed /usr/doc -> /usr/share/doc + handling. + * Removed article from start of synopsis, fixed long description wrt/ + nogroup. + * Disabled watch file -- it isn't there anymore... + * Removed debian/docs cruft file. + + -- Gerfried Fuchs Fri, 02 Jul 2004 10:18:02 +0200 + +rungetty (1.2-7) unstable; urgency=low + + * change type of c in do_prompt to signed int (closes: #160395) + + -- Gerfried Fuchs Wed, 11 Sep 2002 13:24:57 +0200 + +rungetty (1.2-6) unstable; urgency=low + + * Updated watchfile to uscan version=2. + * Moved the debian/docs and debian/dirs content directly into the + debian/rules file. + * Put the install of the manpage back into the Makefile. + * Beautified the copyright file a bit. + * Updated to policy 3.5.7, added support for DEB_BUILD_OPTIONS. + + -- Gerfried Fuchs Sun, 08 Sep 2002 22:14:56 +0200 + +rungetty (1.2-5) unstable; urgency=low + + * Added watch file. + * Un-debhelper-ized the package. + + -- Gerfried Fuchs Mon, 18 Feb 2002 11:19:44 +0100 + +rungetty (1.2-4) unstable; urgency=low + + * Disabled setting the PATH variable (Closes: #113389) + + -- Gerfried Fuchs Mon, 10 Dec 2001 01:06:50 +0100 + +rungetty (1.2-3) unstable; urgency=low + + * Changed default group to nogroup, thanks to Jonas Hoersch (Closes: #87402) + * Bumped Standards-Version (3.5.6.0). + + -- Gerfried Fuchs Sat, 18 Aug 2001 15:49:50 +0200 + +rungetty (1.2-2) unstable; urgency=low + + * Removed watch-example from /debian directory (source). + * Install upstream changelog as changelog (and not it's original name). + * Updated to a more recent policy version (3.5.4.0). + * Revised rules file, for changes in debhelper package. + + -- Gerfried Fuchs Sat, 5 May 2001 22:15:43 +0200 + +rungetty (1.2-1) unstable; urgency=low + + * Initial Release. + + -- Gerfried Fuchs Sun, 3 Dec 2000 22:07:41 +0100 --- rungetty-1.2.orig/debian/copyright +++ rungetty-1.2/debian/copyright @@ -0,0 +1,43 @@ +This package was debianized by Gerfried Fuchs on +Mon, 4 Dec 2000 21:11:08 +0100. + +It was downloaded from +which isn't there anymore. Citing from a recent mail from Jakob: + + I'm actually not maintaining rungetty anymore. The last time I touched + it was in 2001. If you would like to take over maintainership, you have + my full blessing and support, and I will gladly put a link to a new + development location. The source to all releases I made is still + available at ftp://ftp.ndn.net/pub/rungetty/. As the Debian maintainer, + I think you are the de-facto maintainer at this point, anyway. + +Upstream Author: Jakob 'sparky' Kaivo + +Copyright: +========== + Copyright (C) 1999 Jakob 'sparky' Kaivo + + Based on code from mingetty by Florian La Roche. + + This program 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 program 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, write to the Free + Software Foundation, Inc., 51 Franklin St, Fifth Floor, + Boston, MA 02110-1301 USA + +The Debian packaging is Copyright 2000-2009 by +Gerfried Fuchs and is licensed under the BSD license. +See /usr/share/common-licenses/BSD for the full text of it. + +On Debian GNU/Linux systems, the complete text of the GNU General +Public License version 2 can be found in `/usr/share/common-licenses/GPL-2', +later versions can be found in the same directory. --- rungetty-1.2.orig/debian/watch +++ rungetty-1.2/debian/watch @@ -0,0 +1,5 @@ +version=3 +## sorry, the host didn't response for ages +# opts="active" \ +# ftp://ftp.ndn.net/rungetty/ rungetty-([\d\.]+)\.tar\.gz debian uupdate +# Site/Directory Pattern Version Script --- rungetty-1.2.orig/debian/README.Debian +++ rungetty-1.2/debian/README.Debian @@ -0,0 +1,10 @@ +rungetty for Debian +---------------------- + I know that there wasn't done anything on the source of this package in +ages, but I believe that's because it's quite bugfree :-) + + It's not very long... I mainly packaged it for usage with francine, a +spinoff of the fancylogin project but believe that it has to be useful +for others as well.... + + -- Gerfried Fuchs , Mon, 4 Dec 2000 21:02:09 +0100 --- rungetty-1.2.orig/debian/README.source +++ rungetty-1.2/debian/README.source @@ -0,0 +1,2 @@ +This package uses quilt for its patch management, see +/usr/share/doc/quilt/README.source if you are unfamiliar with it. --- rungetty-1.2.orig/debian/patches/series +++ rungetty-1.2/debian/patches/series @@ -0,0 +1,8 @@ +01_make-install-fix +02_manpage-fix +03_nogroup-fix +04_disable-path +05_getc-fix +06_initgroups +07_clear-not-reset +08_autologin-on-all-ttys --- rungetty-1.2.orig/debian/patches/02_manpage-fix +++ rungetty-1.2/debian/patches/02_manpage-fix @@ -0,0 +1,74 @@ +Author: Gerfried Fuchs vim:ft=diff: +Description: Fixes small errors in the manpage + +Index: rungetty-1.2/rungetty.8 +=================================================================== +--- rungetty-1.2.orig/rungetty.8 ++++ rungetty-1.2/rungetty.8 +@@ -16,7 +16,7 @@ rungetty \- a minimal console getty that + [\-\-autologin + .IR username ] + .I tty +-[--] [command] [arguments] ++[\-\-] [command] [arguments] + .PP + .SH DESCRIPTION + .B rungetty +@@ -74,7 +74,7 @@ is specified, it will be displayed. Othe + Working directory of specified program. + .TP + .B \-d n +-Specifying -d will make rungetty wait ++Specifying \-d will make rungetty wait + .I n + seconds before running the specified program. + .TP +@@ -113,7 +113,7 @@ If the automated login request is denied + will revert to performing normal interactive logins for all subsequent + login requests. + .TP +-.B -- ++.B \-\- + Tells + .B rungetty + that there are no more options to parse, useful for passing arguments with +@@ -151,22 +151,22 @@ insert line on which + .B rungetty + is running, + .IP \fB\em\fP +-inserts machine architecture (uname -m), ++inserts machine architecture (uname \-m), + .IP \fB\en\fP +-inserts machine's network node hostname (uname -n), ++inserts machine's network node hostname (uname \-n), + .IP \fB\eo\fP + inserts domain name, + .IP \fB\er\fP +-inserts operating system release (uname -r), ++inserts operating system release (uname \-r), + .IP \fB\et\fP + insert current time (localtime), + .IP \fB\es\fP + inserts operating system name, +-.IP \fB\eu\fP resp. \fB\eU\fP ++.IP \fB\eu\fP\ resp.\ \fB\eU\fP + the current number of users which are currently logged in. + \\U inserts "\fIn\fP users", where as \\u only inserts "\fIn\fP". + .IP \fB\ev\fP +-inserts operating system version (uname -v). ++inserts operating system version (uname \-v). + .PP + .SH EXAMPLE + In +@@ -178,9 +178,9 @@ these lines: + .br + .B r2:2345:respawn:/sbin/rungetty tty2 telnet mail.foo.com + .br +-.B r3:2345:respawn:/sbin/rungetty tty3 -u support top ++.B r3:2345:respawn:/sbin/rungetty tty3 \-u support top + .br +-.B r4:2345:respawn:/sbin/rungetty tty4 -n 20 -w /etc rc5des ++.B r4:2345:respawn:/sbin/rungetty tty4 \-n 20 \-w /etc rc5des + .br + Would run a local login on + .BR /dev/tty1 , a --- rungetty-1.2.orig/debian/patches/04_disable-path +++ rungetty-1.2/debian/patches/04_disable-path @@ -0,0 +1,16 @@ +Author: Gerfried Fuchs vim:ft=diff: +Description: disabling of setting a PATH on our own (BTS #113389) + +Index: rungetty-1.2/rungetty.c +=================================================================== +--- rungetty-1.2.orig/rungetty.c ++++ rungetty-1.2/rungetty.c +@@ -588,7 +588,7 @@ main (int argc, char **argv) + #else + putenv ("TERM=vt100"); + #endif +- putenv ("PATH=/bin:/usr/bin:/usr/ucb:/usr/local/bin"); ++/* disabled -- get path from init putenv ("PATH=/bin:/usr/bin:/usr/ucb:/usr/local/bin"); */ + + /* flush input and output queues, important for modems */ + ioctl (0, TCFLSH, 2); --- rungetty-1.2.orig/debian/patches/05_getc-fix +++ rungetty-1.2/debian/patches/05_getc-fix @@ -0,0 +1,16 @@ +Author: Gerfried Fuchs vim:ft=diff: +Description: change type of c in do_prompt to signed int (BTS #160395) + +Index: rungetty-1.2/rungetty.c +=================================================================== +--- rungetty-1.2.orig/rungetty.c ++++ rungetty-1.2/rungetty.c +@@ -275,7 +275,7 @@ static void + do_prompt (void) + { + FILE *fd; +- char c; ++ signed int c; + + write (1, "\n", 1); /* start a new line */ + if ((fd = fopen (ISSUE, "r"))) --- rungetty-1.2.orig/debian/patches/06_initgroups +++ rungetty-1.2/debian/patches/06_initgroups @@ -0,0 +1,16 @@ +Author: Gerfried Fuchs vim:ft=diff: +Description: call initgroups to get supplementary groups for processes + (BTS #146145) + +Index: rungetty-1.2/rungetty.c +=================================================================== +--- rungetty-1.2.orig/rungetty.c ++++ rungetty-1.2/rungetty.c +@@ -597,6 +597,7 @@ main (int argc, char **argv) + mingetty_login (logname, tty); + + setgid (u_group->gr_gid); ++ initgroups (user->pw_name, user->pw_gid); + setuid (user->pw_uid); + + if (progpath) --- rungetty-1.2.orig/debian/patches/07_clear-not-reset +++ rungetty-1.2/debian/patches/07_clear-not-reset @@ -0,0 +1,16 @@ +Author: Adeodato Simó vim:ft=diff: +Description: send clear instead of reset (BTS #309866) + +Index: rungetty-1.2/rungetty.c +=================================================================== +--- rungetty-1.2.orig/rungetty.c ++++ rungetty-1.2/rungetty.c +@@ -484,7 +484,7 @@ open_tty (void) + /* Write a reset string to the terminal. This is very linux-specific + and should be checked for other systems. */ + if (!noclear) +- write (0, "\033c", 2); ++ write (0, "\033[H\033[J", 6); + + sa.sa_handler = SIG_DFL; + sa.sa_flags = 0; --- rungetty-1.2.orig/debian/patches/08_autologin-on-all-ttys +++ rungetty-1.2/debian/patches/08_autologin-on-all-ttys @@ -0,0 +1,16 @@ +Author: Gerfried Fuchs vim:ft=diff: +Description: allow autologin on all TTYs (BTS #515970) + +Index: rungetty-1.2/rungetty.c +=================================================================== +--- rungetty-1.2.orig/rungetty.c ++++ rungetty-1.2/rungetty.c +@@ -105,7 +105,7 @@ static int delay = 0; + #define AUTO_LAST "/var/log/autologin" + /* AUTO_TTY is the tty on which autologins will be accepted. If set + to an empty string, autologins will be accepted on any tty. */ +-#define AUTO_TTY "tty1" ++#define AUTO_TTY "" + /* If supplied, attempt an automatic login with this username. */ + static char *autologin_name = NULL; + --- rungetty-1.2.orig/debian/patches/01_make-install-fix +++ rungetty-1.2/debian/patches/01_make-install-fix @@ -0,0 +1,20 @@ +Author: Gerfried Fuchs vim:ft=diff: +Description: Fix install target + +Index: rungetty-1.2/Makefile +=================================================================== +--- rungetty-1.2.orig/Makefile ++++ rungetty-1.2/Makefile +@@ -7,9 +7,9 @@ all: rungetty + + install: all + mkdir -p $(ROOT)/sbin +- mkdir -p $(ROOT)/usr/man/man8 +- install -s -m 0755 -o root -g root rungetty $(ROOT)/sbin/ +- install -m 0644 -o root -g root rungetty.8 $(ROOT)/usr/man/man8/ ++ mkdir -p $(ROOT)/usr/share/man/man8 ++ install -m 0755 -o root -g root rungetty $(ROOT)/sbin/ ++ install -m 0644 -o root -g root rungetty.8 $(ROOT)/usr/share/man/man8/ + + rungetty: rungetty.o + --- rungetty-1.2.orig/debian/patches/03_nogroup-fix +++ rungetty-1.2/debian/patches/03_nogroup-fix @@ -0,0 +1,16 @@ +Author: Gerfried Fuchs vim:ft=diff: +Description: Switch from nobody to nogroup for group (BTS #87402) + +Index: rungetty-1.2/rungetty.c +=================================================================== +--- rungetty-1.2.orig/rungetty.c ++++ rungetty-1.2/rungetty.c +@@ -571,7 +571,7 @@ main (int argc, char **argv) + if (!user) + user = getpwnam ("nobody"); + if (!u_group) +- u_group = getgrnam ("nobody"); ++ u_group = getgrnam ("nogroup"); + tty = argv[optind]; + if (!tty) + usage ();