From 491009ffbaedc312f1588681d2af08cd394a99de Mon Sep 17 00:00:00 2001 From: Bdale Garbee Date: Fri, 14 Apr 2006 23:32:30 -0600 Subject: [PATCH] Imported Debian patch 5.1-8 --- debian/README.debian | 17 +++++++++++++++++ debian/changelog | 15 ++++++++++----- debian/compat | 1 + debian/conffiles | 2 -- debian/control | 4 ++-- debian/copyright | 5 ++++- debian/dirs | 1 + debian/gcpegg.1 | 2 +- debian/init.d | 6 +++--- debian/rules | 25 ++++++++----------------- global.h | 11 +++++++++++ network.c | 2 +- regtest.c | 2 +- 13 files changed, 60 insertions(+), 33 deletions(-) create mode 100644 debian/README.debian create mode 100644 debian/compat delete mode 100644 debian/conffiles diff --git a/debian/README.debian b/debian/README.debian new file mode 100644 index 0000000..1dd777c --- /dev/null +++ b/debian/README.debian @@ -0,0 +1,17 @@ +If the EGG computer is behind a firewall, it must be programmed +to allow UDP packets on port 2510 outgoing packet and UDP port +1105 for an incoming connection. + +This allows the bidirectional communication required for the data +to be transmitted. What happens is that your program sends an +"awake" packet when it has unsent data. The server in Princeton +responds with a "data request" packet, and then the EGG program +will send the data. + + - - - - - + +This package is known to compile but not run successfully on at +least the amd64 architecture. The only architecture it has really +been tested on is i386... If anyone is sufficiently motivated +to chase down and fix whatever the problem is, patches would be +welcomed! diff --git a/debian/changelog b/debian/changelog index 85c3abe..16c7218 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,13 @@ +gcpegg (5.1-8) unstable; urgency=low + + * move to newer debhelper compatibility level, closes: #328793, #359417 + * add -f to openvt invocation in init.d, and create a README.debian with + firewalling information, at suggestion of Fernando Lucas Rodriguez + * improve the existence check in init.d, addresses part of 347778 + * add text to README.debian about know problems on at least amd64 + + -- Bdale Garbee Fri, 14 Apr 2006 23:32:30 -0600 + gcpegg (5.1-7) unstable; urgency=low * change build dependency to use libncurses-dev, closes: #101655 @@ -48,8 +58,3 @@ gcpegg (5.1-1) unstable; urgency=low enough for now. -- Bdale Garbee Sun, 9 May 1999 20:06:40 -0600 - -Local variables: -mode: debian-changelog -add-log-mailing-address: "bdale@gag.com" -End: diff --git a/debian/compat b/debian/compat new file mode 100644 index 0000000..7ed6ff8 --- /dev/null +++ b/debian/compat @@ -0,0 +1 @@ +5 diff --git a/debian/conffiles b/debian/conffiles deleted file mode 100644 index 1a1c11f..0000000 --- a/debian/conffiles +++ /dev/null @@ -1,2 +0,0 @@ -/etc/eggrc -/etc/init.d/gcpegg diff --git a/debian/control b/debian/control index 782c537..052a0d4 100644 --- a/debian/control +++ b/debian/control @@ -2,8 +2,8 @@ Source: gcpegg Section: misc Priority: optional Maintainer: Bdale Garbee -Build-Depends: debhelper, libncurses-dev -Standards-Version: 3.1.1.1 +Build-Depends: debhelper (>= 5), libncurses-dev +Standards-Version: 3.6.2.1 Package: gcpegg Architecture: any diff --git a/debian/copyright b/debian/copyright index 9d2b535..553ae2b 100644 --- a/debian/copyright +++ b/debian/copyright @@ -3,7 +3,7 @@ Wed, 28 Apr 1999 20:43:12 -0600. It was downloaded from http://noosphere.princeton.edu/ -Upstream Author(s): Greg Nelson +Upstream Author: Greg Nelson Copyright: @@ -19,3 +19,6 @@ Copyright: purposes. For details, see the GNU General Public License; a copy is present in this directory in the file gnu.html. +On Debian GNU/Linux systems, the complete text of the GNU General +Public License can be found in `/usr/share/common-licenses/GPL'. + diff --git a/debian/dirs b/debian/dirs index b7995f0..b231714 100644 --- a/debian/dirs +++ b/debian/dirs @@ -1,4 +1,5 @@ etc usr/share/man/man1 usr/sbin +usr/share/lintian/overrides var/spool/gcpegg diff --git a/debian/gcpegg.1 b/debian/gcpegg.1 index 7546442..afbcbc3 100644 --- a/debian/gcpegg.1 +++ b/debian/gcpegg.1 @@ -1,5 +1,5 @@ .TH GCPEGG 1 -.SH GCPEGG +.SH NAME gcpegg \- Global Consciousness Project REG Software .SH SYNOPSIS .B basket diff --git a/debian/init.d b/debian/init.d index 3c38511..74dc49f 100644 --- a/debian/init.d +++ b/debian/init.d @@ -2,7 +2,7 @@ set -e -test -f /usr/sbin/eggsh || exit 0 +test -x /usr/sbin/eggsh || exit 0 test -d /var/spool/gcpegg || exit 0 cd /var/spool/gcpegg @@ -10,7 +10,7 @@ cd /var/spool/gcpegg case "$1" in start) echo -n "Starting GCP EGG software on virtual terminal 8: eggsh" - openvt -c 8 eggsh + openvt -f -c 8 eggsh echo "." ;; stop) @@ -21,7 +21,7 @@ case "$1" in reload|force-reload|restart) echo -n "Restarting GCP EGG software on virtual terminal 8..." start-stop-daemon --stop --quiet --oknodo --exec /usr/sbin/eggsh - openvt -c 8 eggsh + openvt -f -c 8 eggsh echo "done." ;; *) diff --git a/debian/rules b/debian/rules index d7d863e..a9f7ee6 100755 --- a/debian/rules +++ b/debian/rules @@ -1,10 +1,6 @@ #!/usr/bin/make -f -# MAde with the aid of dh_make, by Craig Small -# Sample debian/rules that uses debhelper. GNU copyright 1997 by Joey Hess. -# Some lines taken from debmake, by Cristoph Lameter. -# Uncomment this to turn on verbose mode. -#export DH_VERBOSE=1 +export DH_VERBOSE=1 build: build-stamp build-stamp: @@ -25,15 +21,15 @@ install-stamp: build-stamp dh_testroot dh_clean -k dh_installdirs - /usr/bin/install -o root -g root -m 0755 eggsh debian/tmp/usr/sbin - /usr/bin/install -o root -g root -m 0755 regtest debian/tmp/usr/sbin - /usr/bin/install -o root -g root -m 0755 basket debian/tmp/usr/sbin + /usr/bin/install -o root -g root -m 0755 eggsh debian/gcpegg/usr/sbin + /usr/bin/install -o root -g root -m 0755 regtest debian/gcpegg/usr/sbin + /usr/bin/install -o root -g root -m 0755 basket debian/gcpegg/usr/sbin /usr/bin/install -o root -g root -m 0644 eggrc.sample \ - debian/tmp/etc/eggrc + debian/gcpegg/etc/eggrc /usr/bin/install -o root -g root -m 0644 debian/gcpegg.1 \ - debian/tmp/usr/share/man/man1/gcpegg.1 - gzip -9 debian/tmp/usr/share/man/man1/gcpegg.1 - ( cd debian/tmp/usr/share/man/man1 ; \ + debian/gcpegg/usr/share/man/man1/gcpegg.1 + gzip -9 debian/gcpegg/usr/share/man/man1/gcpegg.1 + ( cd debian/gcpegg/usr/share/man/man1 ; \ ln gcpegg.1.gz basket.1.gz ;\ ln gcpegg.1.gz eggsh.1.gz ;\ ln gcpegg.1.gz regtest.1.gz ) @@ -41,21 +37,17 @@ install-stamp: build-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 -# dh_testversion dh_testdir dh_testroot dh_installdocs dh_installexamples dh_installmenu -# dh_installemacsen dh_installinit dh_installcron dh_installmanpages -# dh_undocumented dh_installchangelogs dh_strip dh_compress @@ -63,7 +55,6 @@ binary-arch: build install dh_installdeb dh_shlibdeps dh_gencontrol -# dh_makeshlibs dh_md5sums dh_builddeb diff --git a/global.h b/global.h index d85b156..09d2005 100644 --- a/global.h +++ b/global.h @@ -32,6 +32,16 @@ #include "byteorder.h" /* Build byte-order independent version */ /* Good for i386, but be careful... */ +#ifdef linux +#include +typedef __u8 byte; +typedef __u8 uint8; +typedef __u16 uint16; +typedef __u32 uint32; +typedef __s8 int8; +typedef __s16 int16; +typedef __s32 int32; +#else typedef unsigned char byte; typedef unsigned char uint8; typedef unsigned short uint16; @@ -39,6 +49,7 @@ typedef unsigned long uint32; typedef char int8; typedef short int16; typedef long int32; +#endif /* linux */ /* Some fixed assumptions: Trial type is always bitsum. diff --git a/network.c b/network.c index b266358..f68d02b 100644 --- a/network.c +++ b/network.c @@ -237,7 +237,7 @@ int NetListen(int sd, char **pktbuf, size = sizeof(*sin); count = recvfrom(sd, buffer, MAXBUFSIZE, 0, - (struct sockaddr *)sin, (int *)&size); + (struct sockaddr *)sin, (socklen_t *)&size); if (count < 0) { /* Don't wait for it. */ if (errno == EWOULDBLOCK) return ERR_COMM_TMOUT; diff --git a/regtest.c b/regtest.c index e4b5123..5d3f6c8 100644 --- a/regtest.c +++ b/regtest.c @@ -49,7 +49,7 @@ int main(int argc, char *argv[]) { } if ((TTY_fd = open(argv[1], O_RDWR | O_NDELAY)) < 0) { - fprintf(stderr, "%s: %s\n", argv[1], sys_errlist[errno]); + fprintf(stderr, "%s: %s\n", argv[1], strerror(errno)); exit(1); } -- 2.30.2