--- rungetty-1.2.orig/Makefile +++ rungetty-1.2/Makefile @@ -7,9 +7,9 @@ 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/rungetty.c +++ rungetty-1.2/rungetty.c @@ -275,7 +275,7 @@ do_prompt (void) { FILE *fd; - char c; + signed int c; write (1, "\n", 1); /* start a new line */ if ((fd = fopen (ISSUE, "r"))) @@ -571,7 +571,7 @@ if (!user) user = getpwnam ("nobody"); if (!u_group) - u_group = getgrnam ("nobody"); + u_group = getgrnam ("nogroup"); tty = argv[optind]; if (!tty) usage (); @@ -588,7 +588,7 @@ #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); @@ -597,6 +597,7 @@ 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/rules +++ rungetty-1.2/debian/rules @@ -0,0 +1,92 @@ +#!/usr/bin/make -f +# rules file for rungetty + +RPM_OPTS = -g +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 (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) + RPM_OPTS += -O0 +else + RPM_OPTS += -O2 +endif +ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS))) + INSTALL_PROGRAM += -s + STRIP = true +endif + + +clean: + $(checkdir) + $(checkroot) + -rm -rf debian/rungetty debian/substvars debian/files \ + install-stamp build-stamp + -$(MAKE) clean + + +build: build-stamp +build-stamp: + $(checkdir) + $(MAKE) RPM_OPTS="$(RPM_OPTS)" + chmod -R g-s . + touch build-stamp + + +install: install-stamp +install-stamp: build + $(checkdir) + $(checkroot) + -rm -rf debian/rungetty debian/substvars + $(INSTALL_DIR) debian/rungetty + cd debian/rungetty && $(INSTALL_DIR) sbin \ + usr/share/man/man8 usr/share/doc/rungetty + $(MAKE) install ROOT=$(CURDIR)/debian/rungetty + -test "$(STRIP)" = "true" && \ + strip --remove-section=.comment --remove-section=.note \ + --strip-unneeded debian/rungetty/sbin/rungetty + $(INSTALL_FILE) README THANKS debian/rungetty/usr/share/doc/rungetty + $(INSTALL_FILE) CHANGELOG \ + debian/rungetty/usr/share/doc/rungetty/changelog + gzip -9 debian/rungetty/usr/share/man/man8/rungetty.8 \ + debian/rungetty/usr/share/doc/rungetty/changelog + 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) debian/rungetty/DEBIAN + $(INSTALL_FILE) debian/README.Debian debian/copyright \ + debian/rungetty/usr/share/doc/rungetty + $(INSTALL_FILE) debian/changelog \ + debian/rungetty/usr/share/doc/rungetty/changelog.Debian + gzip -9 debian/rungetty/usr/share/doc/rungetty/changelog.Debian + dpkg-shlibdeps -Tdebian/substvars -dDepends \ + debian/rungetty/sbin/rungetty + dpkg-gencontrol -ldebian/changelog -isp -Tdebian/substvars -prungetty \ + -Pdebian/rungetty + cd debian/rungetty && find * -type f ! -regex '^DEBIAN/.*' -print0 | \ + xargs -r0 md5sum > DEBIAN/md5sums + dpkg --build debian/rungetty .. + + +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,19 @@ +Source: rungetty +Section: admin +Priority: optional +Maintainer: Gerfried Fuchs +Standards-Version: 3.6.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/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 must be useful for +others as well.... + + -- Gerfried Fuchs , Mon, 4 Dec 2000 21:02:09 +0100 --- rungetty-1.2.orig/debian/changelog +++ rungetty-1.2/debian/changelog @@ -0,0 +1,64 @@ +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/watch +++ rungetty-1.2/debian/watch @@ -0,0 +1,3 @@ +version=2 +# use active Site/Directory/Pattern Version Script +#opts=active ftp://ftp.ndn.net/rungetty/rungetty-([\d\.]+)\.tar\.gz debian uupdate --- rungetty-1.2.orig/debian/copyright +++ rungetty-1.2/debian/copyright @@ -0,0 +1,20 @@ +This package was debianized by Gerfried Fuchs on +Mon, 4 Dec 2000 21:11:08 +0100. + +It was downloaded from http://www.nodomainname.net/software/rungetty/ + +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. + +On Debian GNU/Linux systems, the complete text of the GNU General +Public License can be found in `/usr/share/common-licenses/GPL'.