pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: pkg/39750 (emulators/simh)



The following reply was made to PR pkg/39750; it has been noted by GNATS.

From: Rhialto <rhialto%falu.nl@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc: 
Subject: Re: pkg/39750 (emulators/simh)
Date: Wed, 22 Oct 2008 21:19:24 +0200

 On Mon 20 Oct 2008 at 00:25:02 +0000, OBATA Akio wrote:
 >  Can you provide patch set for update to 3.8?
 
 These patches seem worse than they are.
 
 Index: Makefile
 ===================================================================
 RCS file: /cvsroot/pkgsrc/emulators/simh/Makefile,v
 retrieving revision 1.26
 diff -u -r1.26 Makefile
 --- Makefile   4 Jan 2008 21:45:05 -0000       1.26
 +++ Makefile   22 Oct 2008 18:43:52 -0000
 @@ -1,9 +1,9 @@
  # $NetBSD: Makefile,v 1.26 2008/01/04 21:45:05 joerg Exp $
  #
  
 -DISTNAME=     simhv33-0
 -PKGNAME=      simh-3.3.0
 -PKGREVISION=  1
 +DISTNAME=     simhv38-0
 +PKGNAME=      simh-3.8.0
 +#PKGREVISION= 1
  CATEGORIES=   emulators
  MASTER_SITES= http://simh.trailing-edge.com/sources/
  EXTRACT_SUFX= .zip
 @@ -38,7 +38,9 @@
        (cd ${WRKSRC}/BIN && for BIN in *; do                           \
                ${INSTALL_PROGRAM} $$BIN ${DESTDIR}${PREFIX}/bin/simh-$$BIN;    
\
        done)
 -      ${INSTALL_DATA} ${WRKSRC}/VAX/ka655.bin ${DESTDIR}${PREFIX}/share/simh
 +      ${INSTALL_DATA_DIR} ${DESTDIR}${PREFIX}/share/simh
 +      ${INSTALL_DATA} ${WRKSRC}/VAX/ka655x.bin ${DESTDIR}${PREFIX}/share/simh
 +      ${INSTALL_DATA_DIR} ${DESTDIR}${PREFIX}/share/doc/simh
        (cd ${WRKSRC} && for TXT in *.txt */*.txt; do                   \
                ${INSTALL_DATA} $$TXT ${DESTDIR}${PREFIX}/share/doc/simh;       
        \
        done)
 Index: PLIST
 ===================================================================
 RCS file: /cvsroot/pkgsrc/emulators/simh/PLIST,v
 retrieving revision 1.8
 diff -u -r1.8 PLIST
 --- PLIST      22 Dec 2004 21:07:01 -0000      1.8
 +++ PLIST      22 Oct 2008 18:43:52 -0000
 @@ -23,40 +23,23 @@
  bin/simh-s3
  bin/simh-sds
  bin/simh-vax
 -share/doc/simh/0readme_33.txt
 +share/doc/simh/0readme_38.txt
  share/doc/simh/0readme_ethernet.txt
  share/doc/simh/altair.txt
 -share/doc/simh/altairz80_doc.txt
  share/doc/simh/eclipse.txt
 -share/doc/simh/gri_doc.txt
 -share/doc/simh/h316_doc.txt
  share/doc/simh/haltguide.txt
  share/doc/simh/hp2100_diag.txt
 -share/doc/simh/hp2100_doc.txt
 -share/doc/simh/i1401_doc.txt
 -share/doc/simh/i1620_doc.txt
 +share/doc/simh/i7094_bug_history.txt
  share/doc/simh/id_diag.txt
 -share/doc/simh/id_doc.txt
 -share/doc/simh/lgp_doc.txt
 -share/doc/simh/nova_doc.txt
 -share/doc/simh/pdp10_diag.txt
 -share/doc/simh/pdp10_doc.txt
 -share/doc/simh/pdp11_doc.txt
 +share/doc/simh/pdp10_bug_history.txt
  share/doc/simh/pdp18b_diag.txt
 -share/doc/simh/pdp18b_doc.txt
 -share/doc/simh/pdp1_doc.txt
 -share/doc/simh/pdp8_doc.txt
 +share/doc/simh/pdp1_diag.txt
  share/doc/simh/readme1130.txt
  share/doc/simh/readme_s3.txt
  share/doc/simh/readme_update.txt
  share/doc/simh/sds_diag.txt
 -share/doc/simh/sds_doc.txt
 -share/doc/simh/simh_doc.txt
 -share/doc/simh/simh_faq.txt
 -share/doc/simh/simh_swre.txt
  share/doc/simh/system3.txt
 -share/doc/simh/vax780_doc.txt
 -share/doc/simh/vax_doc.txt
 -share/simh/ka655.bin
 +share/doc/simh/vax780_bug_history.txt
 +share/simh/ka655x.bin
  @dirrm share/simh
  @dirrm share/doc/simh
 Index: distinfo
 ===================================================================
 RCS file: /cvsroot/pkgsrc/emulators/simh/distinfo,v
 retrieving revision 1.12
 diff -u -r1.12 distinfo
 --- distinfo   23 Feb 2005 18:49:20 -0000      1.12
 +++ distinfo   22 Oct 2008 18:43:52 -0000
 @@ -1,8 +1,8 @@
  $NetBSD: distinfo,v 1.12 2005/02/23 18:49:20 agc Exp $
  
 -SHA1 (simhv33-0.zip) = 99a021afe2fd8dfb32bb479e383347e2b883e0f9
 -RMD160 (simhv33-0.zip) = 778cc7836b4558b57f1b9ca54427f3d2e8da94a4
 -Size (simhv33-0.zip) = 2153444 bytes
 -SHA1 (patch-aa) = a1c1e10f81b5883c5388084d1b9f31d3560353fe
 -SHA1 (patch-ab) = aff84028d4184b773b2bd4ebf2ee166357f18924
 -SHA1 (patch-ac) = 0f1ddee6f69c0337c8ea02cf24ed6fdecc0ca1f4
 +SHA1 (simhv38-0.zip) = e1afbebede7dc4b2e0f7b13fca3ee6aa8d34f9c1
 +RMD160 (simhv38-0.zip) = f1986d45f9b17a905957d1dca4eaa70098a7cae6
 +Size (simhv38-0.zip) = 2775593 bytes
 +SHA1 (patch-aa) = 2353cf2e32a97277663f473a999c0d4cb444d1bf
 +SHA1 (patch-ab) = 85b36e3d92a2bfbd886dbb2e08a0af967edeb0bd
 +SHA1 (patch-ac) = 78ecdc9abe248eb8c9a1dc3c297a4a7e5eb812d6
 Index: patches/patch-aa
 ===================================================================
 RCS file: /cvsroot/pkgsrc/emulators/simh/patches/patch-aa,v
 retrieving revision 1.7
 diff -u -r1.7 patch-aa
 --- patches/patch-aa   22 Dec 2004 21:07:01 -0000      1.7
 +++ patches/patch-aa   22 Oct 2008 18:43:52 -0000
 @@ -1,71 +1,81 @@
 -$NetBSD: patch-aa,v 1.7 2004/12/22 21:07:01 skrll Exp $
 -
 ---- Makefile.orig     2004-10-30 18:32:50.000000000 +0100
 -+++ Makefile
 -@@ -3,28 +3,30 @@
 - # Note: -O2 is sometimes broken in GCC when setjump/longjump is being
 - # used. Try -O2 only with released simulators.
 +--- Makefile.dist     2008-06-06 15:00:46.000000000 +0200
 ++++ Makefile  2008-10-17 00:18:29.000000000 +0200
 +@@ -1,32 +1,36 @@
 + #
 + # CC Command
   #
  -ifeq ($(WIN32),)
  +#ifeq ($(WIN32),)
 - #Unix Environments
 --ifeq ($(OSTYPE),solaris)
 --OS_CCDEFS = -lsocket -lnsl -lpthread -D_GNU_SOURCE
 --else
 --OS_CCDEFS = -D_GNU_SOURCE
 --endif
 --CC = gcc -std=c99 -O2 -U__STRICT_ANSI__ -g -lm $(OS_CCDEFS) -I .
 --ifeq ($(USE_NETWORK),)
 --else
 --NETWORK_OPT = -DUSE_NETWORK -isystem /usr/local/include 
/usr/local/lib/libpcap.a
 --endif
 --else
 -+#ifeq ($(OSTYPE),solaris)
 -+#OS_CCDEFS = -lsocket -lnsl -lpthread -D_GNU_SOURCE
 -+#else
 -+#OS_CCDEFS = -D_GNU_SOURCE
 -+#endif
 -+#CC = gcc -std=c99 -O2 -U__STRICT_ANSI__ -g -lm $(OS_CCDEFS) -I .
 -+CC = gcc -O2 -g -lm -I . -DDONT_USE_PCAP_FINDALLDEVS -DNEED_PCAP_SENDPACKET
 -+#ifeq ($(USE_NETWORK),)
 -+#else
 -+#NETWORK_OPT = -DUSE_NETWORK -isystem /usr/local/include 
/usr/local/lib/libpcap.a
 -+NETWORK_OPT = -DUSE_NETWORK -lpcap
 -+#endif
 -+#else
 - #Win32 Environments
 --LDFLAGS = -lm -lwsock32
 --CC = gcc -std=c99 -U__STRICT_ANSI__ -O0 -I.
 --EXE = .exe
 --ifeq ($(USE_NETWORK),)
 +   #Unix Environments
 +-  ifneq (,$(findstring solaris,$(OSTYPE)))
 +-    OS_CCDEFS = -lm -lsocket -lnsl -lrt -lpthread -D_GNU_SOURCE
 +-  else
 +-    ifneq (,$(findstring darwin,$(OSTYPE)))
 +-      OS_CCDEFS = -D_GNU_SOURCE
 +-    else
 +-      OS_CCDEFS = -lrt -lm -D_GNU_SOURCE
 +-    endif
 +-  endif
 +-  CC = gcc -std=c99 -U__STRICT_ANSI__ -g $(OS_CCDEFS) -I .
 +-  ifeq ($(USE_NETWORK),)
 +-  else
 +-    NETWORK_OPT = -DUSE_NETWORK -isystem /usr/local/include 
/usr/local/lib/libpcap.a
 +-  endif
  -else
 --NETWORK_OPT = -DUSE_NETWORK -lwpcap -lpacket
 --endif
 +-  #Win32 Environments
 +-  LDFLAGS = -lm -lwsock32 -lwinmm
 +-  CC = gcc -std=c99 -U__STRICT_ANSI__ -O2 -I.
 +-  EXE = .exe
 +-  ifeq ($(USE_NETWORK),)
 +-  else
 +-    NETWORK_OPT = -DUSE_NETWORK -lwpcap -lpacket
 +-  endif
  -endif
 -+#LDFLAGS = -lm -lwsock32
 -+#CC = gcc -std=c99 -U__STRICT_ANSI__ -O0 -I.
 -+#EXE = .exe
 -+#ifeq ($(USE_NETWORK),)
 ++#  ifneq (,$(findstring solaris,$(OSTYPE)))
 ++#    OS_CCDEFS = -lm -lsocket -lnsl -lrt -lpthread -D_GNU_SOURCE
 ++#  else
 ++#    ifneq (,$(findstring darwin,$(OSTYPE)))
 ++#      OS_CCDEFS = -D_GNU_SOURCE
 ++#    else
 ++#      OS_CCDEFS = -lrt -lm -D_GNU_SOURCE
 ++#    endif
 ++#  endif
 ++#  CC = gcc -std=c99 -U__STRICT_ANSI__ -g $(OS_CCDEFS) -I .
 ++CC ?= gcc
 ++CC := ${CC} -std=c99 -O2 -U__STRICT_ANSI__ -g -lm $(OS_CCDEFS) -I .
 ++#
 ++#  ifeq ($(USE_NETWORK),)
 ++#  else
 ++#    NETWORK_OPT = -DUSE_NETWORK -isystem /usr/local/include 
/usr/local/lib/libpcap.a
 ++     NETWORK_OPT = -DUSE_NETWORK -lpcap
 ++#  endif
  +#else
 -+#NETWORK_OPT = -DUSE_NETWORK -lwpcap -lpacket
 ++#  #Win32 Environments
 ++#  LDFLAGS = -lm -lwsock32 -lwinmm
 ++#  CC = gcc -std=c99 -U__STRICT_ANSI__ -O2 -I.
 ++#  EXE = .exe
 ++#  ifeq ($(USE_NETWORK),)
 ++#  else
 ++#    NETWORK_OPT = -DUSE_NETWORK -lwpcap -lpacket
 ++#  endif
  +#endif
 -+#endif
 - 
   
   #
 -@@ -252,11 +254,11 @@ ALL = ${BIN}pdp1${EXE} ${BIN}pdp4${EXE} 
 + # Common Libraries
 +@@ -259,11 +263,11 @@
   all : ${ALL}
   
   clean :
  -ifeq ($(WIN32),)
 -+#ifeq ($(WIN32),)
 -      ${RM} ${ALL}
 +-     ${RM} ${BIN}*
  -else
  -     if exist BIN\*.exe del /q BIN\*.exe
  -endif
 ++#ifeq ($(WIN32),)
 ++     rm ${BIN}*
  +#else
  +#    if exist BIN\*.exe del /q BIN\*.exe
  +#endif
 + 
   #
   # Individual builds
 - #
 Index: patches/patch-ab
 ===================================================================
 RCS file: /cvsroot/pkgsrc/emulators/simh/patches/patch-ab,v
 retrieving revision 1.5
 diff -u -r1.5 patch-ab
 --- patches/patch-ab   22 Dec 2004 21:07:01 -0000      1.5
 +++ patches/patch-ab   22 Oct 2008 18:43:52 -0000
 @@ -1,11 +1,11 @@
  $NetBSD: patch-ab,v 1.5 2004/12/22 21:07:01 skrll Exp $
  
 ---- sim_ether.c.orig  2004-03-31 13:38:58.000000000 +0100
 +--- sim_ether.c.orig  2007-05-17 12:08:20.000000000 +0200
  +++ sim_ether.c
 -@@ -830,6 +830,15 @@ void eth_callback(u_char* info, const st
 +@@ -1131,6 +1131,15 @@ void eth_callback(u_char* info, const st
 +     /* set data in passed read packet */
       tmp_packet.len = header->len;
       memcpy(tmp_packet.msg, data, header->len);
 - 
  +    /*
  +     * Pad packet to minimum ethernet len, in case it comes from the local
  +     * host.
 @@ -15,26 +15,26 @@
  +        memset(dev->read_packet->msg + header->len, 0, 60 - header->len);
  +    }
  +
 -     eth_packet_trace (dev, tmp_packet.msg, tmp_packet.len, "rcvqd");
 +     if (dev->need_crc)
 +       eth_add_crc32(&tmp_packet);
   
 -     pthread_mutex_lock (&dev->lock);
 -@@ -840,6 +849,15 @@ void eth_callback(u_char* info, const st
 +@@ -1143,6 +1152,15 @@ void eth_callback(u_char* info, const st
 +     /* set data in passed read packet */
       dev->read_packet->len = header->len;
       memcpy(dev->read_packet->msg, data, header->len);
 - 
  +    /*
  +     * Pad packet to minimum ethernet len, in case it comes from the local
  +     * host.
  +     */
  +    if (header->len <60) {
  +        dev->read_packet->len = 60;
 -+        memset(dev->read_packet->msg + header->len, 0, 60 - header->len);
 ++         memset(dev->read_packet->msg + header->len, 0, 60 - header->len);
  +    }
 -+
 -     eth_packet_trace (dev, dev->read_packet->msg, dev->read_packet->len, 
"reading");
 ++ 
 +     if (dev->need_crc)
 +       eth_add_crc32(dev->read_packet);
   
 -     /* call optional read callback function */
 -@@ -1080,8 +1098,10 @@ int eth_host_devices(int used, int max, 
 +@@ -1431,8 +1449,10 @@ int eth_host_devices(int used, int max, 
   
   int eth_devices(int max, ETH_LIST* list)
   {
 Index: patches/patch-ac
 ===================================================================
 RCS file: /cvsroot/pkgsrc/emulators/simh/patches/patch-ac,v
 retrieving revision 1.4
 diff -u -r1.4 patch-ac
 --- patches/patch-ac   22 Dec 2004 21:07:01 -0000      1.4
 +++ patches/patch-ac   22 Oct 2008 18:43:52 -0000
 @@ -1,20 +1,22 @@
  $NetBSD: patch-ac,v 1.4 2004/12/22 21:07:01 skrll Exp $
  
 ---- sim_console.c.orig        2004-11-05 19:39:24.000000000 +0000
 +--- sim_console.c.orig        2006-10-01 14:26:58.000000000 +0200
  +++ sim_console.c
 -@@ -347,13 +347,13 @@ for (i = 0; i < sec; i++) {                             
/* loop *
 -      if (tmxr_poll_conn (&sim_con_tmxr) >= 0) {      /* poll connect */
 -          sim_con_ldsc.rcve = 1;                      /* rcv enabled */
 -          if (i) {                                    /* if delayed */
 --             printf ("Running\n");                   /* print transition */
 -+             printf ("Running\r\n");                 /* print transition */
 -              fflush (stdout);  }
 -          return SCPE_OK;  }                          /* ready to proceed */
 -      c = sim_os_poll_kbd ();                         /* check for stop char 
*/
 -      if ((c == SCPE_STOP) || stop_cpu) return SCPE_STOP;
 -      if ((i % 10) == 0) {                            /* Status every 10 sec 
*/
 --         printf ("Waiting for console Telnet connection\n");
 -+         printf ("Waiting for console Telnet connection\r\n");
 -          fflush (stdout);  }
 -      sim_os_sleep (1);                               /* wait 1 second */
 -      }
 +@@ -391,7 +391,7 @@ for (i = 0; i < sec; i++) {             
 +     if (tmxr_poll_conn (&sim_con_tmxr) >= 0) {          /* poll connect */
 +         sim_con_ldsc.rcve = 1;                          /* rcv enabled */
 +         if (i) {                                        /* if delayed */
 +-            printf ("Running\n");                       /* print transition 
*/
 ++            printf ("Running\r\n");                       /* print 
transition */
 +             fflush (stdout);
 +             }
 +         return SCPE_OK;                                 /* ready to proceed 
*/
 +@@ -399,7 +399,7 @@ for (i = 0; i < sec; i++) {             
 +     c = sim_os_poll_kbd ();                             /* check for stop 
char */
 +     if ((c == SCPE_STOP) || stop_cpu) return SCPE_STOP;
 +     if ((i % 10) == 0) {                                /* Status every 10 
sec */
 +-        printf ("Waiting for console Telnet connection\n");
 ++        printf ("Waiting for console Telnet connection\r\n");
 +         fflush (stdout);
 +         }
 +     sim_os_sleep (1);                                   /* wait 1 second */
 
 -Olaf.
 -- 
 ___ Olaf 'Rhialto' Seibert    -- You author it, and I'll reader it.
 \X/ rhialto/at/xs4all.nl      -- Cetero censeo "authored" delendum esse.
 


Home | Main Index | Thread Index | Old Index