debian/0000755000000000000000000000000011722426154007172 5ustar debian/README.Debian0000644000000000000000000000125411722425416011235 0ustar Welcome2L for DEBIAN -------------------- Welcome2L does no longer overwrite default /etc/issue file. Instead it writes its logo to /etc/issue.welcome2l (or file specified by ISSUE_FILE variable in /etc/default/welcome2l.) Now, if you want Welcome2L's logo displayed, you have to call getty with a `-f' option in your /etc/inittab file. See an example inittab file provided in examples/ directory. If you have installed non-system fonts on the console, Welcome2L may not display the logo correctly. On UTF-8 consoles please try initializing the console with the utf8 command from the `fonty-rg' package. -- Robert Luberda Sat, 19 Feb 2011 00:49:51 +0100 debian/changelog0000644000000000000000000002142411722425416011047 0ustar welcome2l (3.04-25) unstable; urgency=low * Switch to debhelper v9 and tiny rules file. * debian/rules: Remove .pc/.dpkg-source-unapply file in configure target to fix broken behaviour of dpkg-buildpackage (see Bug#649521). * Refresh patches with gbp-pq import/export. * debian/control: + add VCS fields; + sort dependency fields with wrap-and-sort; + Standards-Version: 3.9.3 (no changes needed). -- Robert Luberda Sun, 26 Feb 2012 13:52:05 +0100 welcome2l (3.04-24) unstable; urgency=low * Switch to the `3.0 (quilt)' source format: split the previous Debian patch into patches 00 to 06. * 07_sprintf_ub.patch: Fix undefined behaviour bugs found by cppcheck. Hopefully this should fix crashes seen on Ubuntu (LP: #581505, #586216). * debian/init.d: + add Required-Start dependency for $remote_fs (lintian); + remove and run levels from Default-Stop, as the stop action does nothing; + use lsb logging functions. * debian/rules: + update debian/default at build time, use lsb_release for getting distributor info. + use dpkg-buildflags for getting CFLAGS/LDFLAGS; + call dh_auto_{configure,build,clean} commands; + provide build-{arch,indep} targets. * debian/preinst: replace ancient stuff with removal of stop scripts from rc0, rc1, and rc6. * Standards-Version: 3.9.1 (no changes). * Bump debhelper compat version to 8. * Replace suggestion on fonty to fonty-rg, update README.Debian for this. * Remove unneeded source.lintian-overrides, and use dh_lintian to install our overrides for binary package. -- Robert Luberda Sat, 19 Feb 2011 13:05:16 +0100 welcome2l (3.04-23) unstable; urgency=low * Add hurd-i386 to supported archs (closes: 482842). * Applied patch from Chris Lamb to fix bashisms in preinst (closes: 480618). * Fix invalid comments in man page (lintian). -- Robert Luberda Mon, 26 May 2008 20:14:31 +0200 welcome2l (3.04-22) unstable; urgency=low * Standards-Version: 3.7.3 (no changes). * Fix hyphens in man page (lintian). * Add copyright notice (lintian). * Add source lintian overrides file for non-standard architecture warning. -- Robert Luberda Sat, 19 Apr 2008 13:33:01 +0200 welcome2l (3.04-21) unstable; urgency=low * sysvinit no longer provides invoke-rc.d, remove unnecessary dependency on it (patch from Ubuntu). * Handle missing invoke-rc.d in the cron.daily script. * Standards-Version: 3.7.2 (no changes). * Bump debhelper compat version to 6. * Add LSB section to init.d script (lintian). * Fix the `debian-rules-ignores-make-clean-error' lintian warning. * Add the `Homepage:' field to debian/control. * Add debian/watch file. -- Robert Luberda Wed, 17 Oct 2007 00:22:15 +0200 welcome2l (3.04-20) unstable; urgency=low * debian/control: add kfreebsd-amd64 to the list of supported architectures. (closes: #361630). * main.c: fix `pointer targets differ in signedness' compiler warning. * Standards-Version: 3.6.2 (no changes). * debian/*: use debhelper v5. -- Robert Luberda Thu, 13 Apr 2006 22:08:56 +0200 welcome2l (3.04-19) unstable; urgency=low * debian/control: add kfreebsd-i386 to the list of supported architectures. (closes: #314284). * Removed lintian source override file. -- Robert Luberda Thu, 16 Jun 2005 22:49:08 +0200 welcome2l (3.04-18) unstable; urgency=low * debian/control: add amd64 to the list of supported architectures. (closes: #249403) * Add lintian source override file for `cvsignore-file-in-source'. -- Robert Luberda Sun, 23 May 2004 13:32:11 +0200 welcome2l (3.04-17) unstable; urgency=low * Read memory info from MemTotal line of /proc/meminfo, not from obsolete Mem line (closes: #230546). -- Robert Luberda Sun, 8 Feb 2004 20:01:07 +0100 welcome2l (3.04-16) unstable; urgency=low * main.c: + get memory information from /proc/meminfo. Previously it have been done by checking size of /proc/kcore, but it seems it does not give correct results on computers with a lot of memory (closes: #230546). + memory information is now printed also in mega-, giga- or even terabytes, depending on its size. * debian/control: I hope welcome2l can work on ia64 machines, so add it to list of supported architectures. * Remove `.IX Header "NAME"' line from the welcome2l(1) man page. It seems it confused the apropos program. -- Robert Luberda Wed, 4 Feb 2004 09:00:10 +0100 welcome2l (3.04-15) unstable; urgency=low * Fix Makefile to work with _POSIX2_VERSION=2000112. * main.c: fix typo in the new year's wishes. * Standards-Version: 3.6.1 (no changes). -- Robert Luberda Sun, 18 Jan 2004 10:34:02 +0100 welcome2l (3.04-14) unstable; urgency=low * debian/README.Debian, debian/default: fix typo (closes: #196668). -- Robert Luberda Mon, 9 Jun 2003 19:57:46 +0200 welcome2l (3.04-13) unstable; urgency=low * Remove diversion of /etc/issue, because dpkg doesn't handle it well (see Bug#61663). Now welcome2l outputs its logo to /etc/issue.welcome2l by default. * Updated README.Debian. Please read it after upgrade! * Add ISSUE_FILE variable to /etc/default/welcome2l. * Remove conflict with linuxlogo (closes: #191757). * Set default umask in our init file. * Add an example login_script stolen from linuxlogo package. * Add an example inittab file with changed getty settings. * Minor fix in the name section of welcome2l's man page. -- Robert Luberda Sun, 18 May 2003 22:31:38 +0200 welcome2l (3.04-12) unstable; urgency=low * Depend on sysvinit (>= 2.80-1) because we use invoke.rc-d in our cron script. * Removed dot from synopsis line (lintian). * Standards-Version: 3.5.9 (no changes). -- Robert Luberda Tue, 25 Mar 2003 10:47:23 +0100 welcome2l (3.04-11) unstable; urgency=low * Added `-noblink' option. It may be useful with `-xmas' or `-xmasauto' on framebuffer devices, which do not support blinking characters. * Standards-Version: 3.5.8 (no changes). -- Robert Luberda Wed, 4 Dec 2002 20:49:46 +0100 welcome2l (3.04-10) unstable; urgency=low * Upgrade to Standards 3.5.7. -- Robert Luberda Tue, 22 Oct 2002 22:22:07 +0200 welcome2l (3.04-9) unstable; urgency=low * Modified cron.daily script: + redirect stdin to /dev/console to get `Login on' line displayed + use invoke-rc.d to run our init script * Build with debhelper v4. * Standards-Version: 3.5.6 -- Robert Luberda Sun, 25 Aug 2002 18:22:19 +0200 welcome2l (3.04-8) unstable; urgency=low * Fix a typo in debian/copyright. -- Robert Luberda Thu, 18 Apr 2002 05:56:17 +0200 welcome2l (3.04-7) unstable; urgency=low * Added alpha to supported architectures (closes: 83562). * Added /etc/default/welcome2l file, sourced by our init script. * Standards-Version: 3.5.2. * Removed from INSTALL file section about compilation of welcome2l. * Made lintian happy by installing override for upstream-install-doc warning. * Use debhelper v3 to build package. -- Robert Luberda Thu, 22 Feb 2001 18:23:24 +0100 welcome2l (3.04-6) unstable; urgency=low * Add cron.daily script and include the upstream INSTALL file in the package. (closes: #77366) * Update welcome2l's manpage. Now all options recognised by the program are briefly explained in the manpage. -- Robert Luberda Mon, 20 Nov 2000 21:01:15 +0100 welcome2l (3.04-5) unstable; urgency=low * First Debian upload. (closes: #76960) * Maintainer address changed. * Minor change in the package description. * Add support for DEB_BUILD_OPTIONS. * Suggests: fonty in debian/control. -- Robert Luberda Fri, 17 Nov 2000 01:00:36 +0100 welcome2l (3.04-4) unstable; urgency=low * Standards-Version: 3.2.1. * Build-Depends: debhelper. * Switch to debhelper v2. * /etc/init.d/welcome2l is conffile. -- Robert Luberda Fri, 29 Sep 2000 00:41:04 +0200 welcome2l (3.04-3) unstable; urgency=low * Add init.d and postinst, prerm scripts with diversion of /etc/issue. * Conflicts with linuxlogo. -- Robert Luberda Tue, 11 Jul 2000 19:10:45 +0200 welcome2l (3.04-2) unstable; urgency=low * Improved my colors patch. * Added screens 4 and 5. -- Robert Luberda Tue, 14 Sep 1999 20:01:15 +0200 welcome2l (3.04-1) unstable; urgency=low * Initial Release. * Changed some colors on the first screen. -- Robert Luberda Mon, 13 Sep 1999 12:00:18 +0100 debian/compat0000644000000000000000000000000211722425416010370 0ustar 9 debian/control0000644000000000000000000000171511722425416010601 0ustar Source: welcome2l Maintainer: Robert Luberda Section: misc Priority: extra Build-Depends: debhelper (>= 9), lsb-release Standards-Version: 3.9.3 Vcs-Git: git://anonscm.debian.org/users/robert/welcome2l.git Vcs-Browser: http://anonscm.debian.org/gitweb/?p=users/robert/welcome2l.git Package: welcome2l Architecture: alpha amd64 hurd-i386 i386 ia64 kfreebsd-amd64 kfreebsd-i386 Depends: lsb-base, ${misc:Depends}, ${shlibs:Depends} Suggests: fonty-rg Homepage: http://www.littleigloo.org/software_003.php3 Description: Linux ANSI boot logo This is a little program that may run at login time to produce nice ANSI login logo. . Welcome2L intends to produce the best looking ANSI screens by making full usage of PC graphic characters. . Therefore an architecture able to display those characters (i386, Alpha with TGA adapter,... ) is required to use it. And, even if it will work on larger screens, it will only produce 80 column ANSI screens. debian/copyright0000644000000000000000000000050311722425416011123 0ustar Welcome2l was downloaded from http://www.littleigloo.org Upstream author: Jean-Marc Jacquet Copyright (c)1998-1999 Jean-Marc Jacquet Welcome2l is available under the GNU General Public License, which should be available as /usr/share/common-licenses/GPL on your Debian system. debian/cron.daily0000644000000000000000000000114011722425416011153 0ustar #!/bin/sh # # In its default init script, the welcome2l is called with the `-xmasauto' # option. This script runs the init script and update /etc/issue daily # to make sure that we don't miss Xmas :) # # Please read /usr/share/doc/welcome2l/INSTALL.gz for details. # test -x /usr/bin/welcome2l || exit 0 PATH="/sbin:/usr/sbin:/bin:/usr/bin" set -e # welcome2l displays the `Login on' line # only if stdin is connected to a terminal... exec < /dev/console > /dev/null if which invoke-rc.d >/dev/null 2>&1; then invoke-rc.d welcome2l restart else /etc/init.d/welcome2l restart fi exit 0 debian/default.in0000644000000000000000000000123111722425416011143 0ustar # This file contains parameters passed to /usr/bin/welcome2l # Please see welcome2l(1) for list of possible options. # Text of message for the -msg option. MSG=" #DISTRO# GNU/Linux" # Cpu name for the -cpu option. # CPU="AMD-K6(tm) 3D" # Other options for welcome2l. Should at least include -getty (or -gettps # if you have gettps installed). # OPTIONS="-getty -scr4 -xmasauto -private" OPTIONS="-getty -scr4 -xmasauto" # This option specifies to which file welcome2l should generate its logo. # You need to pass `-f' option to getty if you want it to work. # Please read /usr/share/doc/welcome2l/README.Debian for details. ISSUE_FILE="/etc/issue.welcome2l" debian/dirs0000644000000000000000000000007011722425416010053 0ustar usr/bin usr/share/man/man1 usr/share/lintian/overrides debian/docs0000644000000000000000000000005411722425416010044 0ustar AUTHORS debian/_tmp_/INSTALL README THANKS debian/examples0000644000000000000000000000005511722425416010733 0ustar debian/misc/login_script debian/misc/inittab debian/init.d0000644000000000000000000000231411722425416010302 0ustar #!/bin/sh # vim:ts=4:et:sts=4 ### BEGIN INIT INFO # Provides: welcome2l # Required-Start: $local_fs $remote_fs # Required-Stop: # Should-Start: # Should-Stop: # Default-Start: 2 3 4 5 # Default-Stop: # Short-Description: Linux ANSI boot logo # Description: Write the Linux ANSI boot logo to the # /etc/issue.welcome2l file ### END INIT INFO PATH="/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin" DAEMON="/usr/bin/welcome2l" NAME="welcome2l" DEFAULTSFILE="/etc/default/$NAME" test -f "$DAEMON" || exit 0 # Read our defaults file test -r "$DEFAULTSFILE" && . "$DEFAULTSFILE" # Set default issue file ISSUE_FILE="${ISSUE_FILE:-/etc/issue.welcome2l}" # Define LSB log_* functions. . /lib/lsb/init-functions set -e umask 022 status=0 case "$1" in start|restart|reload|force-reload) log_action_begin_msg "Updating $ISSUE_FILE" $DAEMON ${OPTIONS:--getty} \ "${MSG:+-msg$MSG}" \ "${CPU:+-cpu$CPU}" > "$ISSUE_FILE" || status=$? echo >> "$ISSUE_FILE" log_action_end_msg $status ;; stop) ;; *) log_failure_msg "Usage: /etc/init.d/$NAME {start|stop|restart|reload|force-reload}" 2>&1 exit 1 ;; esac exit 0 debian/lintian-overrides0000644000000000000000000000007311722425416012553 0ustar welcome2l: package-contains-upstream-install-documentation debian/misc/0000755000000000000000000000000011722425416010125 5ustar debian/misc/inittab0000644000000000000000000000477411722425416011516 0ustar # /etc/inittab: init(8) configuration. # $Id: inittab,v 1.1 2003-05-18 12:11:52 robert Exp $ # The default runlevel. id:2:initdefault: # Boot-time system configuration/initialization script. # This is run first except when booting in emergency (-b) mode. si::sysinit:/etc/init.d/rcS # What to do in single-user mode. ~~:S:wait:/sbin/sulogin # /etc/init.d executes the S and K scripts upon change # of runlevel. # # Runlevel 0 is halt. # Runlevel 1 is single-user. # Runlevels 2-5 are multi-user. # Runlevel 6 is reboot. l0:0:wait:/etc/init.d/rc 0 l1:1:wait:/etc/init.d/rc 1 l2:2:wait:/etc/init.d/rc 2 l3:3:wait:/etc/init.d/rc 3 l4:4:wait:/etc/init.d/rc 4 l5:5:wait:/etc/init.d/rc 5 l6:6:wait:/etc/init.d/rc 6 # Normally not reached, but fallthrough in case of emergency. z6:6:respawn:/sbin/sulogin # What to do when CTRL-ALT-DEL is pressed. ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now # Action on special keypress (ALT-UpArrow). #kb::kbrequest:/bin/echo "Keyboard Request--edit /etc/inittab to let this work." # What to do when the power fails/returns. pf::powerwait:/etc/init.d/powerfail start pn::powerfailnow:/etc/init.d/powerfail now po::powerokwait:/etc/init.d/powerfail stop # /sbin/getty invocations for the runlevels. # # The "id" field MUST be the same as the last # characters of the device (after "tty"). # # Format: # ::: # # Note that on most Debian systems tty7 is used by the X Window System, # so if you want to add more getty's go ahead but skip tty7 if you run X. # # Welcome2L logos 1:2345:respawn:/sbin/getty -f /etc/issue.welcome2l 38400 tty1 2:23:respawn:/sbin/getty -f /etc/issue.welcome2l 38400 tty2 3:23:respawn:/sbin/getty -f /etc/issue.welcome2l 38400 tty3 4:23:respawn:/sbin/getty -f /etc/issue.welcome2l 38400 tty4 5:23:respawn:/sbin/getty -f /etc/issue.welcome2l 38400 tty5 6:23:respawn:/sbin/getty -f /etc/issue.welcome2l 38400 tty6 # Linuxlogo logos #1:2345:respawn:/sbin/getty -f /etc/issue.linuxlogo 38400 tty1 #2:23:respawn:/sbin/getty -f /etc/issue.linuxlogo 38400 tty2 #3:23:respawn:/sbin/getty -f /etc/issue.linuxlogo 38400 tty3 #4:23:respawn:/sbin/getty -f /etc/issue.linuxlogo 38400 tty4 #5:23:respawn:/sbin/getty -f /etc/issue.linuxlogo 38400 tty5 #6:23:respawn:/sbin/getty -f /etc/issue.linuxlogo 38400 tty6 # Example how to put a getty on a serial line (for a terminal) # #T0:23:respawn:/sbin/getty -L ttyS0 9600 vt100 #T1:23:respawn:/sbin/getty -L ttyS1 9600 vt100 # Example how to put a getty on a modem line. # #T3:23:respawn:/sbin/mgetty -x0 -s 57600 ttyS3 debian/misc/login_script0000644000000000000000000000143311722425416012545 0ustar # # LINUX_LOGO # # This sample script by Juhapekka Tolvanen # goes at the end of a .bashrc file. It detects where you are logging # in from, and will run Welcome2L [a intel-specific logo program], # linux_logo, or linux_logo -a depending on term type. # Slighty modified for Debian's welcome2l package # by Robert Luberda on 7 May 2003. R=$(cat /etc/debian_version) #eval resize # if [ $LINES >= 40 ]; then #linux_logo -ascii -y -u #linux_logo -ascii -y -u case "$TERM" in linux) #linux_logo_custom -t "Debian GNU/Linux $R" -y -u Welcome2L -msg"Debian GNU/Linux" uptime echo Debian GNU/Linux $R echo "" ;; xterm-color) #linux_logo -t "Debian GNU/Linux $R" -y -u ;; *) #linux_logo -t "Debian GNU/Linux $R" -y -u -ascii esac # fi debian/patches/0000755000000000000000000000000011722425416010621 5ustar debian/patches/00_Makefile.patch0000644000000000000000000000303011722425416013652 0ustar From: Robert Luberda Date: Mon, 21 Oct 2002 22:32:49 +0100 Subject: 00_Makefile Makefile customizations. --- Makefile | 9 +++++---- 1 files changed, 5 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 1640bbc..5f31452 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ SHELL=/bin/sh CC = gcc -CFLAGS = -Wall -O2 -fno-strength-reduce #-pedantic +CFLAGS += -Wall -fno-strength-reduce #-pedantic DESTDIR = /usr/local INSTALL_BINPATH = $(DESTDIR)/bin INSTALL_MANPATH = $(DESTDIR)/man @@ -11,14 +11,15 @@ VERSION_DATE = 1999 RPM_RELEASE = 1 RPM_BUILDPATH = /usr/src/redhat #RPM_ICONNAME = +STRIP = strip $(PROGNAME): main.o ansi.o $(CC) $(CFLAGS) -v *.o -o $(PROGNAME) - strip ./$(PROGNAME) + $(STRIP) ./$(PROGNAME) install : - /usr/bin/install -s -m 755 $(PROGNAME) $(INSTALL_BINPATH) + /usr/bin/install -m 755 $(PROGNAME) $(INSTALL_BINPATH) /usr/bin/install -m 644 $(PROGNAME).1 $(INSTALL_MANPATH)/man1 ln -fs $(PROGNAME) $(INSTALL_BINPATH)/$(PROGNAME_LNK) ln -fs $(PROGNAME).1 $(INSTALL_MANPATH)/man1/$(PROGNAME_LNK).1 @@ -49,7 +50,7 @@ version.h : FORCE @echo "#define COMPILE_TIME \"`date +%T`\"" >> version.h @echo "#define COMPILE_BY \"`whoami`\"" >> version.h @echo "#define COMPILE_HOST \"`hostname`\"" >> version.h - @echo "#define CC_VERSION \"`$(CC) -v 2>&1 | tail -1`\"">>version.h + @echo "#define CC_VERSION \"`$(CC) -v 2>&1 | tail -n 1`\"">>version.h @echo "#define CODE_LINES `cat *.c *.h | grep -ch -e \"[[:alpha:]|[:punct:]]\"`">>version.h FORCE: -- debian/patches/01_manpage.patch0000644000000000000000000001326111722425416013555 0ustar From: Robert Luberda Date: Sun, 18 May 2003 21:33:59 +0100 Subject: 01_manpage Man page fixes. --- Welcome2L.1 | 131 ++++++++-------------------------------------------------- 1 files changed, 18 insertions(+), 113 deletions(-) diff --git a/Welcome2L.1 b/Welcome2L.1 index 5657855..770961a 100644 --- a/Welcome2L.1 +++ b/Welcome2L.1 @@ -1,8 +1,8 @@ .rn '' }` -''' $RCSfile$$Revision$$Date$ -''' -''' $Log$ -''' +.\" $RCSfile$$Revision$$Date$ +.\" +.\" $Log$ +.\" .de Sh .br .if t .Sp @@ -31,12 +31,12 @@ .fi .. -''' -''' -''' Set up \*(-- to give an unbreakable dash; -''' string Tr holds user defined translation string. -''' Bell System Logo is used as a dummy character. -''' +.\" +.\" +.\" Set up \*(-- to give an unbreakable dash; +.\" string Tr holds user defined translation string. +.\" Bell System Logo is used as a dummy character. +.\" .tr \(*W-|\(bv\*(Tr .ie n \{\ .ds -- \(*W- @@ -45,10 +45,10 @@ .if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch .ds L" "" .ds R" "" -''' \*(M", \*(S", \*(N" and \*(T" are the equivalent of -''' \*(L" and \*(R", except that they are used on ".xx" lines, -''' such as .IP and .SH, which do another additional levels of -''' double-quote interpretation +.\" \*(M", \*(S", \*(N" and \*(T" are the equivalent of +.\" \*(L" and \*(R", except that they are used on ".xx" lines, +.\" such as .IP and .SH, which do another additional levels of +.\" double-quote interpretation .ds M" """ .ds S" """ .ds N" """"" @@ -96,7 +96,7 @@ .TH WELCOME2L 1 "Welcome2L Version 3.04" "28/Jun/99" "Welcome2L User's Manual" .IX Title "WELCOME2L 1" .UC -.IX Name "Welcome2l - Linux ANSI boot logo." +.IX Name "Welcome2L - Linux ANSI boot logo." .if n .hy 0 .if n .na .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' @@ -190,8 +190,7 @@ .\} .rm #[ #] #H #V #F C .SH "NAME" -.IX Header "NAME" -Welcome2l \- Linux ANSI boot logo. +Welcome2L \- Linux ANSI boot logo. .SH "SYNOPSIS" .IX Header "SYNOPSIS" \fBWelcome2L\fR [ \fB\-scr\fR ] [ \fB\-getty\fR ] [ \fB\-msg\fR ] [ \fB\-cpu\fR ] [ \fB\-lcol\fR ] [ \fB\-nolf\fR ] [ \fB\-private\fR ] @@ -214,10 +213,10 @@ Will display more accurate information when launched at boot time. Will not add an empty line to the ansi screen produced. .Ip "\fB\-msg\fR" 8 .IX Item "\fB\-msg\fR" --msg"text of message\*(R" will show the message given as the distribution info. +\-msg"text of message\*(R" will show the message given as the distribution info. .Ip "\fB\-cpu\fR" 8 .IX Item "\fB\-cpu\fR" --cpu"name\*(R" will show the name given as the \s-1CPU\s0 name. +\-cpu"name\*(R" will show the name given as the \s-1CPU\s0 name. .Ip "\fB\-scr\fRxx" 8 .IX Item "\fB\-scr\fRxx" Will display screen number xx. @@ -238,100 +237,6 @@ Will display usage information. .SH "EXAMPLE" .IX Header "EXAMPLE" \&./Welcome2L \-getty \-msg"RedHat Linux\*(R" \-lcol14 - -.SH "INSTALLATION" -.IX Header "INSTALLATION" -.Sh "On RedHat systems " -.IX Subsection "On RedHat systems " -cd to /etc/rc.d/ -edit rc.local, near the end find these lines (may be not exactly the same) : -.PP -.Vb 3 -\& echo "" > /etc/issue -\& echo "Red Hat Linux $R" >> /etc/issue -\& echo "Kernel $(uname r) on $a $(uname m)" >> /etc/issue -.Ve -comment them out and add this one (change the version numbers to yours) : -.PP -.Vb 1 -\& /usr/local/bin/Welcome2L -msg"Red Hat 5.0 (Hurricane)" > /etc/issue -.Ve -.Sh "On Debian systems " -.IX Subsection "On Debian systems " -[ From: Gerd Bavendiek ] - I put a script in - lulu:/etc/rc.boot> ls - 0setserial 1netenv 2hdparm 3Welcome2L - - It's contents is just: - #!/bin/sh - /usr/local/bin/Welcome2L \-getty \-msg"Debian \s-1GNU/\s0Linux 2.0\*(R" > /etc/issue -.Sh "On Slackware systems" -.IX Subsection "On Slackware systems" -[ From: Joe X ] - add these lines in /etc/rc.d/rc.S - /usr/local/bin/Welcome2L > /etc/issue - /usr/local/bin/Welcome2L > /etc/issue.net -.Sh "On \s-1SUSE\s0 5.3 system:" -.IX Subsection "On \s-1SUSE\s0 5.3 system:" -[ From: Ronny Ziegler ] -.PP -.Vb 1 -\& 1) Put the following script called logo into /sbin/init.d -.Ve -.Vb 21 -\& #! /bin/sh -\& # -\& #Author: Ronny Ziegler , 1998 -\& # -\& # /sbin/init.d/logo -\& # -\& case "$1" in -\& start) -\& echo "Starting logo" -\& /usr/local/bin/Welcome2L -\& /bin/sleep 1 -\& ;; -\& stop) -\& ;; -\& reload|restart) -\& ;; -\& *) -\& echo "Usage: $0 {start|stop|reload|restart}" -\& exit 1 -\& esac -\& exit 0 -.Ve -.Vb 7 -\& 2) cd /sbin/init.d/rc2.d -\& 3) mv S99zzreached S98zzreached -\& 4) ln -s ../logo S99logo -\& Now the logo will be executed as last before login-prompt -\& 5) You don't need the old Login-Text any more: -\& mv /etc/issue /etc/issue.orig -\& touch /etc/issue -.Ve -.Sh "On \s-1SUSE\s0 6.0 system:" -.IX Subsection "On \s-1SUSE\s0 6.0 system:" -[ From: Ronny Ziegler ] -.PP -You should have an error-free bootprocess before installing Welcome2L. - - 1) Add the following in your /sbin/init.d/rc file as - the line before last (that´s the one with exit 0) - /usr/local/bin/Welcome2L - where this is the path to your Welcome2L\-executeable -.PP -.Vb 4 -\& 1b)Optional: If you dont´t like Welcome2L to overwrite your -\& boot-messages, add -\& echo -e \e\ev\e\ev\e\ev\e\ev\e\ev\e\ev -\& (or some more \e\ev ´s) in you rc before starting Welcome2L. -.Ve -.Vb 3 -\& 2) Now you don´t need the old Login-Text any more: -\& mv /etc/issue /etc/issue.orig -\& touch /etc/issue .Ve .SH "RESTRICTIONS" .IX Header "RESTRICTIONS" -- debian/patches/02_screens.patch0000644000000000000000000004620311722425416013612 0ustar From: Robert Luberda Date: Sat, 6 Jan 2001 22:03:32 +0100 Subject: 02_screens Added screens 4 and 5 (modified versions of 1 and 2). Changed default screen to 4. Added notime option. Some other small changes. --- Welcome2L.1 | 20 +++++++++-- ansi/welcome1.h | 12 +++--- ansi/welcome2.h | 20 ++++++------ ansi/xmas.h | 10 +++--- main.c | 97 ++++++++++++++++++++++++++++++++++++++++++++++++------- 5 files changed, 122 insertions(+), 37 deletions(-) diff --git a/Welcome2L.1 b/Welcome2L.1 index 770961a..d7792f2 100644 --- a/Welcome2L.1 +++ b/Welcome2L.1 @@ -193,7 +193,7 @@ Welcome2L \- Linux ANSI boot logo. .SH "SYNOPSIS" .IX Header "SYNOPSIS" -\fBWelcome2L\fR [ \fB\-scr\fR ] [ \fB\-getty\fR ] [ \fB\-msg\fR ] [ \fB\-cpu\fR ] [ \fB\-lcol\fR ] [ \fB\-nolf\fR ] [ \fB\-private\fR ] +\fBWelcome2L\fR [ \fB\-scr\fR ] [ \fB\-getty\fR ] [ \fB\-gettps\fR] [ \fB\-msg\fR ] [ \fB\-cpu\fR ] [ \fB-scrrand\fR ] [ \fB-xmas\fR ] [ \fB\-xmasauto\fR ] [ \fB\-lcol\fR ] [ \fB\-nolf\fR ] [ \fB\-private\fR ] [\fB\-notime\fR \] .SH "DESCRIPTION" .IX Header "DESCRIPTION" \fBWelcome2L\fR is a little program that may run at login time to produce a BBS @@ -208,6 +208,9 @@ it will only produce 80 column ANSI screens. .Ip "\fB\-getty\fR" 8 .IX Item "\fB\-getty\fR" Will display more accurate information when launched at boot time. +.Ip "\fB\-gettps\fR" 8 +.IX Item "\fB\-gettps\fR" +Like \fB\-getty\fR, but works with \fIgettyps\fR(8) program. .Ip "\fB\-nolf\fR" 8 .IX Item "\fB\-nolf\fR" Will not add an empty line to the ansi screen produced. @@ -223,6 +226,12 @@ Will display screen number xx. .Ip "\fB\-scrrand\fR" 8 .IX Item "\fB\-scrrand\fR" Will display a random screen. +.Ip "\fB\-xmas\fR" 8 +.IX Item "\fB\-xmasauto\fR" +Will display an Xmas screen. +.Ip "\fB\-xmasauto\fR" 8 +.IX Item "\fB\-xmasauto\fR" +Will automatically display an Xmas screen in December and January. .Ip "\fB\-lcol\fRxx" 8 .IX Item "\fB\-lcol\fRxx" Will change the prompt color to the color number xx. Type Welcome2L \-help to see @@ -230,13 +239,16 @@ what number is attributed to a color. .Ip "\fB\-private\fR" 8 .IX Item "\fB\-private\fR" Display an \*(L"Unauthorized access is prohibited\*(R" line at the bottom -of the \s-1ANSI\s0 screen +of the \s-1ANSI\s0 screen. +.Ip "\fB\-notime\fR" 8 +.IX Item "\fB\-notime\fR" +When dispalying date information, do not display time. .Ip "\fB\-help\fR" 8 .IX Item "\fB\-help\fR" -Will display usage information. +Will display usage information. .SH "EXAMPLE" .IX Header "EXAMPLE" -\&./Welcome2L \-getty \-msg"RedHat Linux\*(R" \-lcol14 +\&/usr/bin/Welcome2L \-getty \-msg"Debian GNU/Linux\*(R" \-lcol14 .Ve .SH "RESTRICTIONS" .IX Header "RESTRICTIONS" diff --git a/ansi/welcome1.h b/ansi/welcome1.h index 245c88a..6774587 100644 --- a/ansi/welcome1.h +++ b/ansi/welcome1.h @@ -37,7 +37,7 @@ unsigned char WELCOME1[] = 'Ü', 0x10, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, - ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, 'þ', 0x08, 'Ü', 0x08, + ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x08, 'Ü', 0x08, 'Ü', 0x08, ' ', 0x08, ' ', 0x08, ' ', 0x08, 'ß', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'ß', 0x10, 'Û', 0x10, 'Û', 0x10, 'Û', 0x10, 'ß', 0x10, ' ', 0x10, ' ', 0x10, ' ', 0x10, 'Û', 0x11, 'Û', 0x11, @@ -101,7 +101,7 @@ unsigned char WELCOME1[] = 'Û', 0x10, 'Ü', 0x10, ' ', 0x10, 'Ü', 0x10, 'Û', 0x10, 'Û', 0x10, 'Û', 0x10, ' ', 0x10, 'Û', 0x10, 'Û', 0x10, 'Û', 0x10, 'Ü', 0x10, ' ', 0x10, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, - ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, 'Û', 0x00, 'þ', 0x08, 'Ü', 0x08, + ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, 'Û', 0x00, 'ß', 0x08, 'Ü', 0x08, 'Ü', 0x08, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, 'ß', 0x08, 'Ü', 0x08, 'Ü', 0x08, ' ', 0x0F, ' ', 0x0F, @@ -118,7 +118,7 @@ unsigned char WELCOME1[] = 'ß', 0x78, 'Ü', 0x08, 'ß', 0x08, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, 'Ü', 0x07, 'ß', 0x78, 'Û', 0x07, 'Û', 0x07, 'Û', 0x07, 'Û', 0x07, 'ß', 0x78, 'Ü', 0x07, 'ß', 0x08, - 'þ', 0x08, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, + ' ', 0x08, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, @@ -154,10 +154,10 @@ unsigned char WELCOME1[] = ' ', 0x08, ' ', 0x08, ' ', 0x08, ' ', 0x08, ' ', 0x08, ' ', 0x08, 'Û', 0x18, 'Û', 0x10, ' ', 0x10, ' ', 0x10, ' ', 0x10, ' ', 0x10, ' ', 0x10, ' ', 0x10, ' ', 0x10, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, - 'Ý', 0x78, 'Ý', 0x7F, ' ', 0x0F, ' ', 0x0F, 'þ', 0x0F, 'ß', 0x07, + 'Ý', 0x78, 'Ý', 0x7F, ' ', 0x0F, ' ', 0x0F, 'ß', 0x0F, ' ', 0x07, ' ', 0x07, 'Þ', 0x0F, '°', 0x7F, 'Ý', 0x08, 'ß', 0x08, 'ß', 0x08, - 'þ', 0x08, 'Ý', 0x78, 'Þ', 0x7F, 'Ý', 0x7F, ' ', 0x0F, ' ', 0x0F, - ' ', 0x0F, 'þ', 0x0F, 'ß', 0x07, ' ', 0x07, 'Þ', 0x7F, 'Û', 0x0F, + ' ', 0x08, 'Ý', 0x78, 'Þ', 0x7F, 'Ý', 0x7F, ' ', 0x0F, ' ', 0x0F, + ' ', 0x0F, 'ß', 0x0F, ' ', 0x07, ' ', 0x07, 'Þ', 0x7F, 'Û', 0x0F, 'Þ', 0x78, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x18, 'Û', 0x08, ' ', 0x08, ':', 0x08, ' ', 0x08, ' ', 0x08, 'W', 0x08, 'e', 0x08, 'l', 0x08, 'c', 0x08, diff --git a/ansi/welcome2.h b/ansi/welcome2.h index 08cde67..e4527ce 100644 --- a/ansi/welcome2.h +++ b/ansi/welcome2.h @@ -64,7 +64,7 @@ unsigned char WELCOME2[] = 'Û', 0x10, 'Û', 0x01, 'Û', 0x10, '±', 0x09, 'Û', 0x10, 'Û', 0x01, 'Ü', 0x01, ' ', 0x00, ' ', 0x07, 'Û', 0x00, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, - ' ', 0x07, ' ', 0x07, 'þ', 0x08, 'ß', 0x08, 'ß', 0x08, 'ß', 0x08, + ' ', 0x07, ' ', 0x07, 'ß', 0x08, 'ß', 0x08, 'ß', 0x08, 'ß', 0x08, 'ß', 0x08, 'Ü', 0x08, 'Ü', 0x08, 'Ü', 0x08, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, 'ß', 0x08, 'ß', 0x08, 'Ü', 0x18, 'Ü', 0x18, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, @@ -77,9 +77,9 @@ unsigned char WELCOME2[] = 'ß', 0x10, 'Û', 0x10, 'Û', 0x10, 'Ü', 0x10, 'Û', 0x00, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, - ' ', 0x07, ' ', 0x07, 'þ', 0x08, ' ', 0x07, ' ', 0x07, 'Ü', 0x08, + ' ', 0x07, ' ', 0x07, 'ß', 0x08, ' ', 0x07, ' ', 0x07, 'Ü', 0x08, 'ß', 0x78, 'Ü', 0x08, ' ', 0x07, ' ', 0x07, ' ', 0x07, 'ß', 0x08, - 'ß', 0x08, 'þ', 0x08, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, + 'ß', 0x08, 'ß', 0x08, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, 'ß', 0x08, 'Ü', 0x18, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, ' ', 0x10, 'Û', 0x10, '°', 0x09, 'Û', 0x10, ' ', 0x10, ' ', 0x10, ' ', 0x10, 'Ü', 0x10, ' ', 0x10, 'Þ', 0x4D, @@ -101,7 +101,7 @@ unsigned char WELCOME2[] = 'Ü', 0x10, 'Û', 0x10, 'Û', 0x10, 'Ü', 0x10, ' ', 0x10, 'ß', 0x10, 'Û', 0x10, 'Û', 0x10, 'Ü', 0x10, 'Ü', 0x10, 'Û', 0x10, 'Û', 0x10, 'Û', 0x10, 'Ü', 0x10, ' ', 0x10, 'Ü', 0x10, 'Û', 0x10, 'Û', 0x10, - 'Û', 0x10, 'þ', 0x10, 'Û', 0x00, 'Û', 0x10, 'Û', 0x00, ' ', 0x07, + 'Û', 0x10, 'ß', 0x10, 'Û', 0x00, 'Û', 0x10, 'Û', 0x00, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, 'Ü', 0x07, 'Ü', 0x7F, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x0F, 'ß', 0x0F, 'ß', 0x0F, @@ -115,7 +115,7 @@ unsigned char WELCOME2[] = 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, 'Û', 0x01, '°', 0x01, - ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x08, 'ß', 0x08, 'þ', 0x08, + ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x08, 'ß', 0x08, 'ß', 0x08, ' ', 0x08, ' ', 0x07, ' ', 0x07, ' ', 0x07, 'Ü', 0x07, 'Ü', 0x7F, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x7F, 'ß', 0x0F, 'ß', 0x18, '±', 0x19, '±', 0x19, '±', 0x19, '°', 0x19, '±', 0x19, 'ß', 0x18, @@ -129,7 +129,7 @@ unsigned char WELCOME2[] = 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Ü', 0x18, 'Û', 0x01, 'Û', 0x01, '°', 0x01, ' ', 0x07, 'Ü', 0x08, 'ß', 0x78, 'Ü', 0x08, ' ', 0x07, - ' ', 0x08, ' ', 0x08, 'þ', 0x08, ' ', 0x07, ' ', 0x07, 'Þ', 0x07, + ' ', 0x08, ' ', 0x08, 'ß', 0x08, ' ', 0x07, ' ', 0x07, 'Þ', 0x07, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x0F, 'ß', 0x0F, 'ß', 0x10, 'ß', 0x01, 'Ü', 0x10, 'Ü', 0x10, 'Ü', 0x1F, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x0F, 'Ü', 0x1F, 'Û', 0x11, '²', 0x01, 'Ý', 0x01, 'Û', 0x0F, @@ -144,7 +144,7 @@ unsigned char WELCOME2[] = 'Û', 0x10, 'Û', 0x61, ' ', 0x07, '²', 0x08, '±', 0x7F, 'ß', 0x0F, '±', 0x01, '°', 0x01, 'Û', 0x00, ' ', 0x07, ' ', 0x07, ' ', 0x07, 'Þ', 0x08, 'Þ', 0x7F, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x0F, - 'Ý', 0x18, 'Ü', 0x19, 'Ý', 0x08, 'ß', 0x08, 'þ', 0x0F, 'Û', 0x00, + 'Ý', 0x18, 'Ü', 0x19, 'Ý', 0x08, 'ß', 0x08, 'ß', 0x0F, 'Û', 0x00, 'ß', 0x08, 'ß', 0x0F, 'ß', 0x7F, 'Û', 0x0F, '²', 0x19, '²', 0x01, 'Ý', 0x01, 'Þ', 0x0F, 'Û', 0x0F, 'Û', 0x0F, 'Þ', 0x78, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x00, @@ -159,7 +159,7 @@ unsigned char WELCOME2[] = ' ', 0x07, ' ', 0x07, 'Þ', 0x08, 'Þ', 0x7F, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x0F, 'Ý', 0x18, 'Û', 0x19, 'Û', 0x19, 'Ü', 0x01, 'Ü', 0x07, 'Ü', 0x0F, 'Ü', 0x08, 'Û', 0x00, ' ', 0x07, ' ', 0x07, - 'þ', 0x08, '±', 0x01, 'Û', 0x00, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x0F, + 'ß', 0x08, '±', 0x01, 'Û', 0x00, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x0F, 'Þ', 0x78, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x00, ' ', 0x18, 'Û', 0x08, ' ', 0x08, ':', 0x08, ' ', 0x08, ' ', 0x08, 'W', 0x09, 'e', 0x09, 'l', 0x09, 'c', 0x09, @@ -291,7 +291,7 @@ unsigned char WELCOME2[] = '°', 0x6E, '²', 0x6E, '°', 0x6E, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x66, - 'Ü', 0x60, 'ß', 0x06, 'þ', 0x60, 'ß', 0x68, 'ß', 0x60, 'ß', 0x68, + 'Ü', 0x60, 'ß', 0x06, 'ß', 0x60, 'ß', 0x68, 'ß', 0x60, 'ß', 0x68, 'Û', 0x66, 'Û', 0x66, 'ß', 0x06, 'ß', 0x06, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x0F, ' ', 0x0F, ' ', 0x18, 'ß', 0x18, @@ -304,7 +304,7 @@ unsigned char WELCOME2[] = 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x66, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Û', 0x06, 'Ü', 0x60, - 'þ', 0x60, 'ß', 0x60, 'ß', 0x68, 'Û', 0x06, 'Û', 0x06, 'Ü', 0x60, + 'ß', 0x60, 'ß', 0x60, 'ß', 0x68, 'Û', 0x06, 'Û', 0x06, 'Ü', 0x60, 'ß', 0x06, 'ß', 0x06, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x07, ' ', 0x0F, ' ', 0x0F, diff --git a/ansi/xmas.h b/ansi/xmas.h index 187089d..fb66056 100644 --- a/ansi/xmas.h +++ b/ansi/xmas.h @@ -62,7 +62,7 @@ unsigned char XMAS[] = 'Ü', 0x7F, 'Ü', 0x7F, 'Û', 0x0F, 'Û', 0x7F, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x0F, 'Û', 0x7F, 'Ü', 0x7F, 'Ü', 0x7F, 'Ü', 0x7F, 'Ü', 0x7F, 'Ü', 0x7F, 'Ü', 0x7F, 'Ü', 0x07, 'ß', 0x04, 'ß', 0x04, 'ß', 0x04, - 'Û', 0x04, 'Û', 0x04, 'Û', 0x04, 'Û', 0x04, 'Û', 0x04, 'þ', 0x4C, + 'Û', 0x04, 'Û', 0x04, 'Û', 0x04, 'Û', 0x04, 'Û', 0x04, 'ß', 0x4C, 'Û', 0x04, 'Ü', 0x04, 'Ü', 0x04, 'Ü', 0x10, ' ', 0x10, ' ', 0x10, ' ', 0x10, ' ', 0x10, ' ', 0x10, ' ', 0x10, '*', 0x19, ' ', 0x10, ' ', 0x10, ' ', 0x10, 'Û', 0x10, '±', 0x09, 'Û', 0x10, ' ', 0x10, @@ -205,10 +205,10 @@ unsigned char XMAS[] = ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ' ', 0x0F, ',', 0x0A, '³', 0x08, 'Û', 0x0F, 'Û', 0x10, ' ', 0x10, ' ', 0x10, ' ', 0x8E, ' ', 0x8E, - ' ', 0x8E, 'Ý', 0x78, 'Ý', 0x7F, ' ', 0x8E, ' ', 0x8E, 'þ', 0x0F, - 'ß', 0x07, ' ', 0x07, 'Þ', 0x0F, '°', 0x7F, 'Ý', 0x08, 'ß', 0x08, - 'ß', 0x08, 'þ', 0x08, 'Ý', 0x78, 'Þ', 0x7F, 'Ý', 0x7F, ' ', 0x8E, - ' ', 0x8E, ' ', 0x8E, 'þ', 0x0F, 'ß', 0x07, ' ', 0x07, 'Þ', 0x7F, + ' ', 0x8E, 'Ý', 0x78, 'Ý', 0x7F, ' ', 0x8E, ' ', 0x8E, 'ß', 0x0F, + ' ', 0x07, ' ', 0x07, 'Þ', 0x0F, '°', 0x7F, 'Ý', 0x08, 'ß', 0x08, + 'ß', 0x08, 'ß', 0x08, 'Ý', 0x78, 'Þ', 0x7F, 'Ý', 0x7F, ' ', 0x8E, + ' ', 0x8E, ' ', 0x8E, 'ß', 0x0F, ' ', 0x07, ' ', 0x07, 'Þ', 0x7F, 'Û', 0x0F, 'Þ', 0x78, ' ', 0x8E, ' ', 0x8E, ' ', 0x8E, ' ', 0x8E, ' ', 0x8E, ' ', 0x8E, 'Þ', 0x07, 'ß', 0x70, 'ß', 0x70, 'Ü', 0x07, 'Ü', 0x10, ' ', 0x10, ' ', 0x10, '*', 0x19, ' ', 0x10, 'Û', 0x07, diff --git a/main.c b/main.c index ca3042c..0494d29 100644 --- a/main.c +++ b/main.c @@ -17,7 +17,13 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ - +/* + * September 1999, Robert Luberda's patch: + * - added screens 4 and 5 (modified versions of 1 and 2); + * - changed default screen to 4; + * - added notime option; + * - some other small changes. + */ #include #include @@ -58,16 +64,39 @@ static char WMESG[25]; static char CPUID[15]; static char CPU_INFO = FALSE; static char want_getty_infos = FALSE; -static char THIS_SCREEN = 1; +static char THIS_SCREEN = 4; /* default screen */ static char last_color = FALSE; static char WANT_NEWLINE = TRUE; static int NEW_YEAR = FALSE; static char XMAS_AUTO = FALSE; static char IS_WELCOME = TRUE; +static char NO_TIME = FALSE; char WSCREEN[10000]; char XMAS_SCREEN = 3; -#define MAX_RAND_SCREEN 2.0 +#define MAX_RAND_SCREEN 4.0 + + +/* + * This function, added by Robert Luberda , + * changes color of 'Welcome to:', 'CPU:', etc. texts. + * It works only with screen 1 or screen 2. + */ +static void +change_text_colors (unsigned char *ansi_screen, int ansi_screen_length, + char color) +{ + register int i, f; + int tab_val[4] = {1609, 2409, 2569, 2729}; + for (i = 0; i < 4; i ++) + { + if (tab_val[i] + 60 > ansi_screen_length) /* this should not happen */ + return; + + for (f = 0; f < 58; f += 2) + ansi_screen[tab_val[i] + f] = color; + } +} static void draw_ansi_screen (unsigned char *ansi_screen, int ansi_screen_length, int ansi_screen_width) @@ -113,6 +142,7 @@ draw_welcome_screen (unsigned char *screen, int screen_length, int screen_width, { ANSI_printxy (xtty, ytty, "Login on "); + ANSI_do_color (color1); if (want_getty_infos) ANSI_print (want_getty_infos == 1 ? "\\l" : "@L"); else @@ -121,7 +151,7 @@ draw_welcome_screen (unsigned char *screen, int screen_length, int screen_width, } - ANSI_do_color (color3); + ANSI_do_color (color2); if (xwmsg + ywmsg) { ANSI_printxy (xwmsg, ywmsg, WMESG); @@ -132,7 +162,14 @@ draw_welcome_screen (unsigned char *screen, int screen_length, int screen_width, if (xtime + ytime) { ANSI_do_color (color2); - ANSI_printxy (xtime, ytime, want_getty_infos == 1 ? "\\d - \\t" : "@D - @T"); + if (NO_TIME == FALSE) + { + ANSI_printxy (xtime, ytime, want_getty_infos == 1 ? " \\d - \\t" : " @D - @T"); + } + else + { + ANSI_printxy (xtime, ytime, want_getty_infos == 1 ? " \\d" : " @D"); + } } if (xrel + yrel) { @@ -178,7 +215,6 @@ draw_this_screen (void) switch (THIS_SCREEN) { - default: case 1: { char buf[80]; @@ -205,6 +241,35 @@ draw_this_screen (void) } break; + default: + case 4: /* R.L. */ + { + char buf[80]; + change_text_colors(WELCOME1, WELCOME1_LENGTH, 0x2); + draw_welcome_screen (WELCOME1, WELCOME1_LENGTH, WELCOME1_WIDTH, + 0x0E, 0x0C, 0x09, + 18, 11, 7, 12, 7, 13, + 7, 15, 16, 16, 16, 17, 16, 18); + ANSI_do_color (0x19); + sprintf (buf, "%s V%s (c)LittleIgloo.Org", PROG_NAME, PROG_VERSION); + ANSI_printxy (0, last_line = 22, buf); + } + break; + + case 5: /* R.L. */ + { + char buf[80]; + change_text_colors(WELCOME2, WELCOME2_LENGTH, 0x2); + draw_welcome_screen (WELCOME2, WELCOME2_LENGTH, WELCOME2_WIDTH, + 0x0E, 0x0C, 0x09, + 18, 11, 7, 12, 7, 13, + 7, 15, 16, 16, 16, 17, 16, 18); + ANSI_do_color (0x19); + sprintf (buf, "%s %s (c)LittleIgloo.Org", PROG_NAME, PROG_VERSION); + ANSI_printxy (0, last_line = 22, buf); + } + break; + case 3: draw_welcome_screen (XMAS, XMAS_LENGTH, XMAS_WIDTH, @@ -293,6 +358,7 @@ usage (void) printf ("\033[0;37m COLOR NUMBERS ARE: %s\n", "\033[0;34m1 \033[32m2 \033[36m3 \033[31m4 \033[35m5 \033[33m6 \033[37m7 \033[1;30m8 \033[34m9 \033[32m10 \033[36m11 \033[31m12 \033[35m13 \033[33m14 \033[37m15"); print_option ("cpu", "\"string\"", "Specifies an alternate CPU description"); print_option ("private", "", "Add an \"Unauthorized access is PROHIBITED\" line"); + print_option ("notime", "", "Do not dispaly current time\n"); printf ("\n\033[1;36mEXAMPLE:\n\033[0;36m"); printf (" ./Welcome2L -getty -msg\"RedHat Linux\" -lcol14"); @@ -368,8 +434,8 @@ main (int argc, char *argv[]) if (strstr (argv[argc], "-xmas") && !XMAS_AUTO) { - printf ("here\n"); - THIS_SCREEN = 3; +/* printf ("here\n"); */ + THIS_SCREEN = XMAS_SCREEN; SEE_ARG = TRUE; } @@ -386,6 +452,11 @@ main (int argc, char *argv[]) SEE_ARG = TRUE; } + if (strstr (argv[argc], "-notime")) + { + NO_TIME = TRUE; + SEE_ARG = TRUE; + } } if (SEE_ARG == NOTSEEN) help_usage (); @@ -400,19 +471,21 @@ main (int argc, char *argv[]) timep = time (NULL); timeptr = localtime (&timep); - strftime (TIME, sizeof (TIME), "%a %d %b %Y - %X", timeptr); - + if (NO_TIME == FALSE) + strftime (TIME, sizeof (TIME), " %a %d %b %Y - %X", timeptr); + else + strftime (TIME, sizeof (TIME), " %a %d %b %Y", timeptr); if ((timeptr->tm_mon < 2) || (timeptr->tm_mon == 11 && timeptr->tm_mday > 25)) NEW_YEAR = timeptr->tm_year + 1900 + (timeptr->tm_mon == 11 && timeptr->tm_mday > 25); if ((XMAS_AUTO) && ((timeptr->tm_mon == 0) || (timeptr->tm_mon == 11))) - THIS_SCREEN = 3; /* Ross Younger's patch (revised) - no Xmas decorations outside of Jan/Dec. (enable it with -xmasauto) */ + THIS_SCREEN = XMAS_SCREEN; /* Ross Younger's patch (revised) - no Xmas decorations outside of Jan/Dec. (enable it with -xmasauto) */ stat ("/proc/kcore", &stat_buf); - sprintf (MEMORY, "%ld Kb", stat_buf.st_size / 1024); + sprintf (MEMORY, "%ld kB", stat_buf.st_size >> 10); draw_this_screen (); -- debian/patches/03_noblink.patch0000644000000000000000000000565511722425416013613 0ustar From: Robert Luberda Date: Wed, 4 Dec 2002 20:54:00 +0100 Subject: 03_noblink Add noblink option. --- Welcome2L.1 | 6 +++++- ansi.c | 7 ++++++- main.c | 12 +++++++++++- 3 files changed, 22 insertions(+), 3 deletions(-) diff --git a/Welcome2L.1 b/Welcome2L.1 index d7792f2..3ff75ad 100644 --- a/Welcome2L.1 +++ b/Welcome2L.1 @@ -242,7 +242,11 @@ Display an \*(L"Unauthorized access is prohibited\*(R" line at the bottom of the \s-1ANSI\s0 screen. .Ip "\fB\-notime\fR" 8 .IX Item "\fB\-notime\fR" -When dispalying date information, do not display time. +When dispalying date information, do not display time. +.Ip "\fB\-noblink\fR" 8 +.IX Item "\fB\-noblink\fR" +Turn blinking off. Useful with \fB\-xmas\fR or \fB\-xmasauto\fR on framebuffer devices, +which do not support blinking. .Ip "\fB\-help\fR" 8 .IX Item "\fB\-help\fR" Will display usage information. diff --git a/ansi.c b/ansi.c index 376b40e..1e90ea0 100644 --- a/ansi.c +++ b/ansi.c @@ -70,6 +70,7 @@ ANSI_col_convert (int col) void ANSI_do_color (unsigned char col) { + extern char NO_BLINK; int this_bg, this_fg, this_attr; char buf[25]; @@ -80,8 +81,12 @@ ANSI_do_color (unsigned char col) else this_attr = 0; - if (((col >> 4) & 15) > 7) + if (((col >> 4) & 15) > 7) { + if (NO_BLINK) + this_attr = 1; + else this_attr = 5; + } if ((this_attr == old_attr) && (this_bg == old_bg) && (this_fg == old_fg)) return; diff --git a/main.c b/main.c index 0494d29..1a31a84 100644 --- a/main.c +++ b/main.c @@ -23,6 +23,9 @@ * - changed default screen to 4; * - added notime option; * - some other small changes. + * + * December 2002, Robert Luberda + * - added noblink option. */ #include @@ -71,6 +74,7 @@ static int NEW_YEAR = FALSE; static char XMAS_AUTO = FALSE; static char IS_WELCOME = TRUE; static char NO_TIME = FALSE; +char NO_BLINK = FALSE; char WSCREEN[10000]; char XMAS_SCREEN = 3; #define MAX_RAND_SCREEN 4.0 @@ -358,7 +362,8 @@ usage (void) printf ("\033[0;37m COLOR NUMBERS ARE: %s\n", "\033[0;34m1 \033[32m2 \033[36m3 \033[31m4 \033[35m5 \033[33m6 \033[37m7 \033[1;30m8 \033[34m9 \033[32m10 \033[36m11 \033[31m12 \033[35m13 \033[33m14 \033[37m15"); print_option ("cpu", "\"string\"", "Specifies an alternate CPU description"); print_option ("private", "", "Add an \"Unauthorized access is PROHIBITED\" line"); - print_option ("notime", "", "Do not dispaly current time\n"); + print_option ("notime", "", "Do not dispaly current time"); + print_option ("noblink", "", "Turn blinking off"); printf ("\n\033[1;36mEXAMPLE:\n\033[0;36m"); printf (" ./Welcome2L -getty -msg\"RedHat Linux\" -lcol14"); @@ -457,6 +462,11 @@ main (int argc, char *argv[]) NO_TIME = TRUE; SEE_ARG = TRUE; } + if (strstr (argv[argc], "-noblink")) + { + NO_BLINK = TRUE; + SEE_ARG = TRUE; + } } if (SEE_ARG == NOTSEEN) help_usage (); -- debian/patches/04_typo.patch0000644000000000000000000000104611722425416013141 0ustar From: Robert Luberda Date: Sun, 18 Jan 2004 10:41:54 +0100 Subject: 04_typo Fix typo on the new year's wishes screen. --- main.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/main.c b/main.c index 1a31a84..26b2bdc 100644 --- a/main.c +++ b/main.c @@ -292,7 +292,7 @@ draw_this_screen (void) { char what_year[50]; sprintf (what_year, "HAPPY NEW YEAR %i", NEW_YEAR); - ANSI_do_char ('n'); +/* ANSI_do_char ('n'); */ ANSI_do_color (0x8F); ANSI_printxy (13, 19, what_year); } -- debian/patches/05_meminfo.patch0000644000000000000000000000471211722425416013604 0ustar From: Robert Luberda Date: Wed, 4 Feb 2004 00:39:06 +0100 Subject: 05_meminfo Get memory info from /proc/meminfo. --- main.c | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++-- 1 files changed, 57 insertions(+), 2 deletions(-) diff --git a/main.c b/main.c index 26b2bdc..44b8985 100644 --- a/main.c +++ b/main.c @@ -26,8 +26,12 @@ * * December 2002, Robert Luberda * - added noblink option. + * + * February 2004, Robert Luberda + * - get memory info from /proc/meminfo */ +#define _GNU_SOURCE #include #include #include @@ -101,6 +105,54 @@ change_text_colors (unsigned char *ansi_screen, int ansi_screen_length, ansi_screen[tab_val[i] + f] = color; } } +/* + * robert@debian.org, 2004 + * get memory info from /proc/meminfo, as stat-ing /proc/kcore + * does not always give correct results (see Debian bug#230546) + */ +static void get_memory_info(void) +{ + FILE * fp; + char * line = NULL; + ssize_t len = 0; + long long int memsize = 0; + char * units = NULL; + + if ((fp = fopen("/proc/meminfo", "r"))) { + + while ( getline(&line, &len, fp) > -1 ) { + if (!strncmp(line, "MemTotal:", 9)) { + memsize = strtoull(line + 9, NULL, 10); + break; // while + } + } + fclose(fp); + if (line) + free(line); + } + + if (!memsize) { + strncpy(MEMORY, "(unknown)", sizeof(MEMORY) - 1); + return; + } + + if (memsize < 1000000) { + units = "kB"; + } else if ((memsize = (memsize >> 10)) < 1000000) { + units = "MB"; + } else if ((memsize = (memsize >> 10)) < 1000000) { + units = "GB"; + } else { + memsize = (memsize >> 10); + units = "TB"; + } + + + snprintf (MEMORY, sizeof(MEMORY), "%Ld %s", memsize, units); +} + + + static void draw_ansi_screen (unsigned char *ansi_screen, int ansi_screen_length, int ansi_screen_width) @@ -377,7 +429,7 @@ usage (void) int main (int argc, char *argv[]) { - struct stat stat_buf; +/* struct stat stat_buf; */ time_t timep; struct tm *timeptr; char SEE_ARG = FALSE; @@ -493,9 +545,12 @@ main (int argc, char *argv[]) if ((XMAS_AUTO) && ((timeptr->tm_mon == 0) || (timeptr->tm_mon == 11))) THIS_SCREEN = XMAS_SCREEN; /* Ross Younger's patch (revised) - no Xmas decorations outside of Jan/Dec. (enable it with -xmasauto) */ - +/* stat ("/proc/kcore", &stat_buf); sprintf (MEMORY, "%ld kB", stat_buf.st_size >> 10); +*/ + get_memory_info(); + draw_this_screen (); -- debian/patches/06_warnings.patch0000644000000000000000000000077311722425416014006 0ustar From: Robert Luberda Date: Thu, 13 Apr 2006 21:09:07 +0100 Subject: 06_warnings Fix `pointer targets differ in signedness' compiler warning. --- main.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/main.c b/main.c index 44b8985..fa859b3 100644 --- a/main.c +++ b/main.c @@ -114,7 +114,7 @@ static void get_memory_info(void) { FILE * fp; char * line = NULL; - ssize_t len = 0; + size_t len = 0; long long int memsize = 0; char * units = NULL; -- debian/patches/07_sprintf_ub.patch0000644000000000000000000000243311722425416014325 0ustar From: Robert Luberda Date: Thu, 3 Feb 2011 19:45:53 +0100 Subject: 07_sprintf_ub Fix undefined behaviour bugs found by cppcheck. --- ansi.c | 9 +++++---- main.c | 2 +- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/ansi.c b/ansi.c index 1e90ea0..1411255 100644 --- a/ansi.c +++ b/ansi.c @@ -117,9 +117,9 @@ ANSI_do_color (unsigned char col) sprintf (buf, "\033[1;5"); if (this_fg != old_fg) - sprintf (buf, "%s;3%i", buf, this_fg); + sprintf (buf + strlen(buf), ";3%i", this_fg); if (this_bg != old_bg) - sprintf (buf, "%s;4%i", buf, this_bg); + sprintf (buf + strlen(buf), ";4%i", this_bg); strcat (buf, "m"); } else @@ -145,14 +145,15 @@ ANSI_do_char (unsigned char c) case 0x0F: c = 14; } - sprintf (WSCREEN, "%s%c", WSCREEN, c); + const char buf[] = { c, '\0' }; + strcat (WSCREEN, buf); } void ANSI_pos (int x, int y) { - sprintf (WSCREEN, "%s\033[%i;%iH", WSCREEN, y, x); + sprintf (WSCREEN + strlen(WSCREEN), "\033[%i;%iH", y, x); } diff --git a/main.c b/main.c index fa859b3..fb3e689 100644 --- a/main.c +++ b/main.c @@ -363,7 +363,7 @@ draw_this_screen (void) ANSI_restore_pos (); ANSI_screen_close (); - printf (WSCREEN); + printf ("%s", WSCREEN); } -- debian/patches/series0000644000000000000000000000021211722425416012031 0ustar 00_Makefile.patch 01_manpage.patch 02_screens.patch 03_noblink.patch 04_typo.patch 05_meminfo.patch 06_warnings.patch 07_sprintf_ub.patch debian/postrm0000644000000000000000000000032011722425416010434 0ustar #!/bin/sh # $Id: postrm,v 1.2 2003-05-18 12:11:49 robert Exp $ set -e W2L="welcome2l" # Remove /etc/issue.welcome2l if [ "$1" = remove ] || [ "$1" = purge ]; then rm -f /etc/issue."$W2L" fi #DEBHELPER# debian/preinst0000644000000000000000000000040411722425416010577 0ustar #!/bin/sh # $Id: preinst 71 2011-02-03 20:05:16Z robert $ set -e W2L="welcome2l" if [ "$1" = "upgrade" ] && dpkg --compare-versions "$2" le-nl "3.04-24~"; then # remove unneeded stop links rm -f /etc/rc[016].d/K??welcome2l fi #DEBHELPER# debian/rules0000755000000000000000000000225311722425416010254 0ustar #!/usr/bin/make -f DH_AUTO_OPTIONS := -v -Smakefile --parallel TDIR := debian/_tmp_ DEFFILE := debian/default export CFLAGS := $(shell dpkg-buildflags --get CFLAGS) -Wall -Wextra %: dh "$@" $(DEFFILE): $(DEFFILE).in debian/rules @set -e; rm -f "$@"; \ distro="`lsb_release -is`" || :; \ echo "Setting $$distro in $@"; \ sed -e "s/#DISTRO#/$${distro:-Debian}/g" \ < "$<" > "$@"; \ chmod 444 "$@" override_dh_auto_build: $(DEFFILE) rm -f .pc/.*unapply # see bug#649521 dh_auto_build $(DH_AUTO_OPTIONS) -- STRIP=: override_dh_auto_install: dh_auto_install $(DH_AUTO_OPTIONS) --destdir=$(CURDIR)/debian/$(shell dh_listpackages)/usr -- \ STRIP=: \ INSTALL_MANPATH='$$(DESTDIR)/share/man' @test -d $(TDIR) || mkdir $(TDIR) # make sure that INSTALL file wasn't changed echo '36cfee5f23009eb94f9fdd62ed767599 INSTALL' | md5sum -c @sed -e '14,140d' -e 's|/usr/local|/usr|g' < INSTALL > $(TDIR)/INSTALL override_dh_auto_clean: dh_auto_clean $(DH_AUTO_OPTIONS) rm -rf $(TDIR) $(DEFFILE) override_dh_installinit: dh_installinit -- start 20 2 3 4 5 . debian/source/0000755000000000000000000000000011722425416010472 5ustar debian/source/format0000644000000000000000000000001411722425416011700 0ustar 3.0 (quilt) debian/watch0000644000000000000000000000022311722425416010220 0ustar # control file for the uscan(1) tool version=3 http://www.littleigloo.org/downloads_003.php3 \ (?:.*/)Welcome2L-([\d\.]+.*)\.src\.tar\.(?:gz|bz2)