I have uploaded a NMU to DELAYED/10 to fix this.
diff -Nru xringd-1.20/debian/changelog xringd-1.20/debian/changelog
--- xringd-1.20/debian/changelog        2023-08-16 17:16:35.000000000 +0200
+++ xringd-1.20/debian/changelog        2023-08-16 15:11:44.000000000 +0200
@@ -1,3 +1,10 @@
+xringd (1.20-27.1) unstable; urgency=medium
+
+  * Non-maintainer upload.
+  * Convert to source format 3.0. (Closes: #1007438)
+
+ -- Bastian Germann <b...@debian.org>  Wed, 16 Aug 2023 13:11:44 +0000
+
 xringd (1.20-27) unstable; urgency=low
 
   * Remove /etc/xringd.conf.bak on purge. (Closes: #798378)
diff -Nru xringd-1.20/debian/patches/debian.patch 
xringd-1.20/debian/patches/debian.patch
--- xringd-1.20/debian/patches/debian.patch     1970-01-01 01:00:00.000000000 
+0100
+++ xringd-1.20/debian/patches/debian.patch     2023-08-16 15:11:44.000000000 
+0200
@@ -0,0 +1,169 @@
+--- xringd-1.20.orig/Makefile
++++ xringd-1.20/Makefile
+@@ -1,4 +1,3 @@
+-#
+ # Makefile  --        xringd
+ #
+ # Copyright (c) 1995-1996 Angelo Haritsis. All rights reserved.
+@@ -7,10 +6,10 @@
+ #
+ 
+ VERSION=1.20
+-
++DESTDIR=
+ # where we install
+-BINDIR=/usr/local/sbin
+-MANDIR=/usr/local/man
++BINDIR=${DESTDIR}/usr/sbin
++MANDIR=${DESTDIR}/usr/share/man
+ 
+ # Number of seconds (compiled-in) to wait after resetting the state machine
+ # before accepting any new rings; can also be set on cmd line (-t)
+@@ -21,18 +20,13 @@ INITWAIT=15
+ CONF=/etc/xringd.conf
+ 
+ # compiled-in modem device; can be specified on command line (-c)
+-MODEM=/dev/modem
+-
+-#DBG=-DRINGSM_DUMP -DDEBUG    # include ringsm debug code
++MODEM=/dev/ttyS0
+ 
+ DEFS=-DVERSION=\"$(VERSION)\" -DMODEM_FILE=\"$(MODEM)\" 
-DCONF_FILE=\"$(CONF)\" -DINIT_TIMEOUT=$(INITWAIT) $(DBG)
+ 
+ CC=gcc
+-CFLAGS =-Wall -O2 -m486 $(DEFS) -s
+-#CFLAGS = -g $(DEFS)
+-LDFLAGS=-s
+-#LDFLAGS=-g
+-
++CFLAGS += -Wall -O2 $(DEFS)
++LDFLAGS +=
+ 
+ OBJ = ringsm.o xringd.o
+ 
+@@ -40,23 +34,13 @@ xringd: $(OBJ)
+       $(CC) $(LDFLAGS) $(OBJ) -o $@
+ 
+ install: xringd
+-      -install -o root -g bin -m 755 xringd $(BINDIR)
+-      -install -o root -g root -m 755 xringd.8 $(MANDIR)/man8
+-      @echo "!!! You also need a config file, eg. /etc/xringd.conf"
+-
+-dist:
+-      -mv -f xringd*.lsm xringd-$(VERSION).lsm > /dev/null 2>&1
+-      -perl -pi -e 
"s/Version:\t[0-9.]+/Version:\t$(VERSION)/;s/xringd-[0-9]+\.[0-9]+/xringd-$(VERSION)/g;"
 xringd-$(VERSION).lsm
+-      #-perl -pi -e "s/xringd [0-9.]+/xringd $(VERSION)/;" README 
+-      cp xringd*.lsm $(HOME)/
+-      ( cd .. ; tar --exclude \*.o --exclude RCS --exclude test \
+-              --exclude .gdb_history \
+-              -zcvSf $(HOME)/xringd-$(VERSION).tgz xringd \
+-      )
++      /usr/bin/install -o root -g bin -m 755 xringd $(BINDIR)
++      /usr/bin/install -o root -g root -m 755 xringd.8 $(MANDIR)/man8
++      #/usr/bin/install -o root -g root -m 600 xringd.conf ${DESTDIR}/etc
+ 
+-# util to show the internal kernel mdoem input counters
++# util to show the internal kernel modem input counters
+ uartcount: uartcount.c
+       $(CC) $(CFLAGS) $? -o $@
+ 
+ clean:
+-      rm -f *.o xringd errors tags
++      rm -f *.o xringd errors tags uartcount
+--- xringd-1.20.orig/ringsm.c
++++ xringd-1.20/ringsm.c
+@@ -223,7 +223,7 @@ parse_range(char **p, int *t1, int *t2)
+  * simple parser for the configuration file - check for a few errors
+  * static line_now has the line number where parser is now
+  */
+-static line_now;
++static int line_now;
+ 
+ static int
+ conf_parse(FILE *f, argparse_cback argparse)
+--- xringd-1.20.orig/xringd.c
++++ xringd-1.20/xringd.c
+@@ -44,6 +44,7 @@
+ #include <errno.h>
+ #include <stdio.h>
+ #include <stdlib.h>
++#include <string.h>
+ #include <unistd.h>
+ #include <paths.h>
+ #include <fcntl.h>
+@@ -77,7 +78,7 @@
+ #define MAXLINE 512
+ 
+ #ifndef MODEM_FILE
+-#define MODEM_FILE "/dev/modem"
++#define MODEM_FILE "/dev/ttyS0"
+ #endif
+ #ifndef CONF_FILE
+ #define CONF_FILE "/etc/xringd.conf"
+@@ -128,8 +129,7 @@ void sig_bye(int i);
+ void fork_cmd(char *cmd);
+ 
+ 
+-void
+-main (int argc, char *argv[])
++int main (int argc, char *argv[])
+ {
+       int arg;
+       struct serial_icounter_struct c;
+@@ -204,6 +204,7 @@ main (int argc, char *argv[])
+                       ringsm_dump();
+       }
+       /* NOTREACHED */
++      return 0;
+ }
+ 
+ void
+@@ -271,13 +272,15 @@ log_msg(int priority, int level, char *f
+ 
+       va_start(p, fmt);
+       vsprintf(buf, fmt, p);
+-      if (log_level >= level)
++      if (log_level >= level) {
+               if (debug || -1 == priority) {
+                       fflush(stdout);
+                       fprintf(stderr, PROG ": %s\n", buf);
+                       fflush(stderr);
+-              } else
+-                      syslog(priority, buf);
++              } else {
++                      syslog(priority, "%s", buf);
++              }
++      }
+       va_end(p);
+ }
+ 
+--- xringd-1.20.orig/xringd.conf
++++ xringd-1.20/xringd.conf
+@@ -14,7 +14,8 @@
+ #
+ 
+ # command line options (-c -n silently ignored)
+-#-m /dev/ttyS1
++# modem device
++-m /dev/ttyS0
+ #-a /usr/local/audio/bin/play /usr/local/lib/sounds/ring.au
+ -a 
+ # rings this far are taken as one ring:
+@@ -25,11 +26,14 @@
+ #-l 100
+ 
+ # 2 rings 10-25 sec apart followed by 30 secs silence: ppp connect with 
office1
+-R 10-25 R 30 : /etc/ppp/ppp.start office1
++#R 10-25 R 30 : /etc/ppp/ppp.start office1
+ 
+ # 3 rings with 10-20 secs between each pair => ppp connect with office2
+-R 10-20 R 10-20 R 30 : /etc/ppp/ppp.start office2
++#R 10-20 R 10-20 R 30 : /etc/ppp/ppp.start office2
+ 
+ # 2 nearish rings then 1 ring after 20-26 secs, followed by no ring in
+ # 30 secs => heater on!
+-R 1-6 R 10-16 R 8 : /usr/local/bin/turn-heater on
++#R 1-6 R 10-16 R 8 : /usr/local/bin/turn-heater on
++
++# Debian default, can we say?
++R 20-30 R 30 : /usr/bin/pon provider
diff -Nru xringd-1.20/debian/patches/series xringd-1.20/debian/patches/series
--- xringd-1.20/debian/patches/series   1970-01-01 01:00:00.000000000 +0100
+++ xringd-1.20/debian/patches/series   2023-08-16 15:11:44.000000000 +0200
@@ -0,0 +1 @@
+debian.patch
diff -Nru xringd-1.20/debian/source/format xringd-1.20/debian/source/format
--- xringd-1.20/debian/source/format    1970-01-01 01:00:00.000000000 +0100
+++ xringd-1.20/debian/source/format    2023-08-16 15:11:19.000000000 +0200
@@ -0,0 +1 @@
+3.0 (quilt)
diff -Nru xringd-1.20/Makefile xringd-1.20/Makefile
--- xringd-1.20/Makefile        2023-08-16 17:16:35.000000000 +0200
+++ xringd-1.20/Makefile        1997-07-18 01:09:44.000000000 +0200
@@ -1,3 +1,4 @@
+#
 # Makefile  -- xringd
 #
 # Copyright (c) 1995-1996 Angelo Haritsis. All rights reserved.
@@ -6,10 +7,10 @@
 #
 
 VERSION=1.20
-DESTDIR=
+
 # where we install
-BINDIR=${DESTDIR}/usr/sbin
-MANDIR=${DESTDIR}/usr/share/man
+BINDIR=/usr/local/sbin
+MANDIR=/usr/local/man
 
 # Number of seconds (compiled-in) to wait after resetting the state machine
 # before accepting any new rings; can also be set on cmd line (-t)
@@ -20,13 +21,18 @@
 CONF=/etc/xringd.conf
 
 # compiled-in modem device; can be specified on command line (-c)
-MODEM=/dev/ttyS0
+MODEM=/dev/modem
+
+#DBG=-DRINGSM_DUMP -DDEBUG     # include ringsm debug code
 
 DEFS=-DVERSION=\"$(VERSION)\" -DMODEM_FILE=\"$(MODEM)\" 
-DCONF_FILE=\"$(CONF)\" -DINIT_TIMEOUT=$(INITWAIT) $(DBG)
 
 CC=gcc
-CFLAGS += -Wall -O2 $(DEFS)
-LDFLAGS +=
+CFLAGS =-Wall -O2 -m486 $(DEFS) -s
+#CFLAGS = -g $(DEFS)
+LDFLAGS=-s
+#LDFLAGS=-g
+
 
 OBJ = ringsm.o xringd.o
 
@@ -34,13 +40,23 @@
        $(CC) $(LDFLAGS) $(OBJ) -o $@
 
 install: xringd
-       /usr/bin/install -o root -g bin -m 755 xringd $(BINDIR)
-       /usr/bin/install -o root -g root -m 755 xringd.8 $(MANDIR)/man8
-       #/usr/bin/install -o root -g root -m 600 xringd.conf ${DESTDIR}/etc
+       -install -o root -g bin -m 755 xringd $(BINDIR)
+       -install -o root -g root -m 755 xringd.8 $(MANDIR)/man8
+       @echo "!!! You also need a config file, eg. /etc/xringd.conf"
+
+dist:
+       -mv -f xringd*.lsm xringd-$(VERSION).lsm > /dev/null 2>&1
+       -perl -pi -e 
"s/Version:\t[0-9.]+/Version:\t$(VERSION)/;s/xringd-[0-9]+\.[0-9]+/xringd-$(VERSION)/g;"
 xringd-$(VERSION).lsm
+       #-perl -pi -e "s/xringd [0-9.]+/xringd $(VERSION)/;" README 
+       cp xringd*.lsm $(HOME)/
+       ( cd .. ; tar --exclude \*.o --exclude RCS --exclude test \
+               --exclude .gdb_history \
+               -zcvSf $(HOME)/xringd-$(VERSION).tgz xringd \
+       )
 
-# util to show the internal kernel modem input counters
+# util to show the internal kernel mdoem input counters
 uartcount: uartcount.c
        $(CC) $(CFLAGS) $? -o $@
 
 clean:
-       rm -f *.o xringd errors tags uartcount
+       rm -f *.o xringd errors tags
diff -Nru xringd-1.20/ringsm.c xringd-1.20/ringsm.c
--- xringd-1.20/ringsm.c        2023-08-16 17:16:35.000000000 +0200
+++ xringd-1.20/ringsm.c        1997-07-18 01:05:54.000000000 +0200
@@ -223,7 +223,7 @@
  * simple parser for the configuration file - check for a few errors
  * static line_now has the line number where parser is now
  */
-static int line_now;
+static line_now;
 
 static int
 conf_parse(FILE *f, argparse_cback argparse)
diff -Nru xringd-1.20/xringd.c xringd-1.20/xringd.c
--- xringd-1.20/xringd.c        2023-08-16 17:16:35.000000000 +0200
+++ xringd-1.20/xringd.c        1997-07-18 16:07:50.000000000 +0200
@@ -44,7 +44,6 @@
 #include <errno.h>
 #include <stdio.h>
 #include <stdlib.h>
-#include <string.h>
 #include <unistd.h>
 #include <paths.h>
 #include <fcntl.h>
@@ -78,7 +77,7 @@
 #define MAXLINE 512
 
 #ifndef MODEM_FILE
-#define MODEM_FILE "/dev/ttyS0"
+#define MODEM_FILE "/dev/modem"
 #endif
 #ifndef CONF_FILE
 #define CONF_FILE "/etc/xringd.conf"
@@ -129,7 +128,8 @@
 void fork_cmd(char *cmd);
 
 
-int main (int argc, char *argv[])
+void
+main (int argc, char *argv[])
 {
        int arg;
        struct serial_icounter_struct c;
@@ -204,7 +204,6 @@
                        ringsm_dump();
        }
        /* NOTREACHED */
-       return 0;
 }
 
 void
@@ -272,15 +271,13 @@
 
        va_start(p, fmt);
        vsprintf(buf, fmt, p);
-       if (log_level >= level) {
+       if (log_level >= level)
                if (debug || -1 == priority) {
                        fflush(stdout);
                        fprintf(stderr, PROG ": %s\n", buf);
                        fflush(stderr);
-               } else {
-                       syslog(priority, "%s", buf);
-               }
-       }
+               } else
+                       syslog(priority, buf);
        va_end(p);
 }
 
diff -Nru xringd-1.20/xringd.conf xringd-1.20/xringd.conf
--- xringd-1.20/xringd.conf     2023-08-16 17:16:35.000000000 +0200
+++ xringd-1.20/xringd.conf     1996-02-17 15:27:06.000000000 +0100
@@ -14,8 +14,7 @@
 #
 
 # command line options (-c -n silently ignored)
-# modem device
--m /dev/ttyS0
+#-m /dev/ttyS1
 #-a /usr/local/audio/bin/play /usr/local/lib/sounds/ring.au
 -a 
 # rings this far are taken as one ring:
@@ -26,14 +25,11 @@
 #-l 100
 
 # 2 rings 10-25 sec apart followed by 30 secs silence: ppp connect with office1
-#R 10-25 R 30 : /etc/ppp/ppp.start office1
+R 10-25 R 30 : /etc/ppp/ppp.start office1
 
 # 3 rings with 10-20 secs between each pair => ppp connect with office2
-#R 10-20 R 10-20 R 30 : /etc/ppp/ppp.start office2
+R 10-20 R 10-20 R 30 : /etc/ppp/ppp.start office2
 
 # 2 nearish rings then 1 ring after 20-26 secs, followed by no ring in
 # 30 secs => heater on!
-#R 1-6 R 10-16 R 8 : /usr/local/bin/turn-heater on
-
-# Debian default, can we say?
-R 20-30 R 30 : /usr/bin/pon provider
+R 1-6 R 10-16 R 8 : /usr/local/bin/turn-heater on

Reply via email to