pkgsrc-Changes-HG archive

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

[pkgsrc/trunk]: pkgsrc/editors/mule Make this ancient mule2 build and work (a...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/5044809e7add
branches:  trunk
changeset: 361913:5044809e7add
user:      tsutsui <tsutsui%pkgsrc.org@localhost>
date:      Sat Apr 29 01:11:55 2017 +0000

description:
Make this ancient mule2 build and work (at least start up) on NetBSD/i386 7.1.

- pull unexelf.c from newer emacs to fix coredump on dump-charset
- in s/netbsd.h use terminfo rather than obsolete termcap that causes SIGSEGV
- also link temacs with "-Wl,-znocombreloc" for X toolkit as emacs22 did
  XXX: this should be into configure
- specify -fno-builtin-malloc to avoid unexpected gcc's optimization
  and remove hacks in alloc.c
- also specify -fno-strict-aliasing for sanity against 90's files

diffstat:

 editors/mule/Makefile                  |     4 +-
 editors/mule/distinfo                  |     8 +-
 editors/mule/patches/patch-aa          |    17 +-
 editors/mule/patches/patch-ab          |  1025 ++++++++++++++++---------------
 editors/mule/patches/patch-src_alloc_c |    35 +-
 5 files changed, 546 insertions(+), 543 deletions(-)

diffs (truncated from 1491 to 300 lines):

diff -r 4db8519cdbb8 -r 5044809e7add editors/mule/Makefile
--- a/editors/mule/Makefile     Fri Apr 28 22:59:48 2017 +0000
+++ b/editors/mule/Makefile     Sat Apr 29 01:11:55 2017 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.51 2015/07/04 16:18:29 joerg Exp $
+# $NetBSD: Makefile,v 1.52 2017/04/29 01:11:55 tsutsui Exp $
 
 DISTNAME=      mule-2.3
 PKGREVISION=   8
@@ -25,7 +25,7 @@
 
 .include "../../mk/bsd.prefs.mk"
 
-CFLAGS+=       -g
+CFLAGS+=       -g -fno-builtin-malloc -fno-strict-aliasing
 
 CONFIGURE_ARGS+=       ${MACHINE_ARCH}--${LOWER_OPSYS} --with-x --with-x-toolkit=lucid
 CONFIGURE_ARGS+=       --terminal-face --mcpath --canna-libraries=${PREFIX}/lib
diff -r 4db8519cdbb8 -r 5044809e7add editors/mule/distinfo
--- a/editors/mule/distinfo     Fri Apr 28 22:59:48 2017 +0000
+++ b/editors/mule/distinfo     Sat Apr 29 01:11:55 2017 +0000
@@ -1,11 +1,11 @@
-$NetBSD: distinfo,v 1.14 2015/11/03 03:32:18 agc Exp $
+$NetBSD: distinfo,v 1.15 2017/04/29 01:11:55 tsutsui Exp $
 
 SHA1 (mule-2.3.tar.gz) = 52737767955caf2fde34b994f367a89c5d8a045f
 RMD160 (mule-2.3.tar.gz) = 52b93e746a7a796549a44104ab1898954df044bf
 SHA512 (mule-2.3.tar.gz) = 5f6a9047e6c9d752787d6cab3573516c6efd65cd901fbab74d314a5967e6c68b2dc7c2aa7454d8588d421553530c87dd3ee9692d523d818e01739580cb1201fd
 Size (mule-2.3.tar.gz) = 10240256 bytes
-SHA1 (patch-aa) = 927ec514204ef97101fb3f4ab77eec1c71af23f1
-SHA1 (patch-ab) = 7c2cf683e87320190af0306cf7d04b3638600944
+SHA1 (patch-aa) = 1bae7875584cdc6a26d02481713d6fe774374ad8
+SHA1 (patch-ab) = edad8003d994d4418b0effe93d0cce4e807d96fe
 SHA1 (patch-ac) = 170fa4f6c17c805dd32a90e8bfb3e38c48a9fc20
 SHA1 (patch-ad) = 7a52802cd614441320221f450cf97d4e30f40f2b
 SHA1 (patch-ae) = 1f020aaeb75cd7dd2b827ab34382e472add09719
@@ -75,7 +75,7 @@
 SHA1 (patch-lib-src_sorted-doc_c) = 9965f6a6722c2735dfc609a7a15c669f3df8fae4
 SHA1 (patch-lib-src_yow_c) = 38fb3e70395525ce8bb4816acd1b9e64c20f3735
 SHA1 (patch-src_abbrev_c) = c8dc21ca974625b8fe20e96bea37c61f709fbc1a
-SHA1 (patch-src_alloc_c) = a5db486e10072ec3738df001aa555e35ae5a5a07
+SHA1 (patch-src_alloc_c) = aaa4315c2487e3b32deb13940609fbcf4b895bce
 SHA1 (patch-src_buffer_h) = 3d2d0dba98a37265cc4df54bd14b6b51941d9c42
 SHA1 (patch-src_bytecode_c) = 93508ddb17e3ba2c7bb921caf85ce1e4e15791f3
 SHA1 (patch-src_callint_c) = 0b44807e049c12d2625c950efb14fd5409aba058
diff -r 4db8519cdbb8 -r 5044809e7add editors/mule/patches/patch-aa
--- a/editors/mule/patches/patch-aa     Fri Apr 28 22:59:48 2017 +0000
+++ b/editors/mule/patches/patch-aa     Sat Apr 29 01:11:55 2017 +0000
@@ -1,6 +1,6 @@
-$NetBSD: patch-aa,v 1.2 2005/12/01 18:13:24 wiz Exp $
+$NetBSD: patch-aa,v 1.3 2017/04/29 01:11:55 tsutsui Exp $
 
---- src/s/netbsd.h.orig        1995-10-12 11:53:15.000000000 +0100
+--- src/s/netbsd.h.orig        1995-10-12 10:53:15.000000000 +0000
 +++ src/s/netbsd.h
 @@ -3,6 +3,10 @@
  /* Get most of the stuff from bsd4.3 */
@@ -13,18 +13,21 @@
  /* For mem-limits.h.  */
  #define BSD4_2
  
-@@ -30,8 +34,8 @@
+@@ -30,9 +34,10 @@
  #define NO_TERMIO
  
  #define LIBS_DEBUG
 -/* -lutil is not needed for NetBSD >0.9.  */
 -#define LIBS_SYSTEM -lutil -lcrypt
+-#define LIBS_TERMCAP -ltermcap
 +#define LIBS_SYSTEM -lcrypt
 +
- #define LIBS_TERMCAP -ltermcap
++#define TERMINFO
++#define LIBS_TERMCAP -lterminfo
  
  #define NEED_ERRNO
-@@ -40,7 +44,9 @@
+ #define SYSV_SYSTEM_DIR
+@@ -40,7 +45,9 @@
  /* Netbsd has POSIX-style pgrp behavior.  */
  #undef BSD_PGRPS
  
@@ -35,7 +38,7 @@
  /* These definitions should work for either dynamic or static linking,
     whichever is the default for `cc -nostdlib'.  */
  #define HAVE_TEXT_START               /* No need to define `start_of_text'.  */
-@@ -54,14 +60,34 @@
+@@ -54,14 +61,34 @@
  #define N_BSSADDR(x) (N_ALIGN(x, N_DATADDR(x)+x.a_data))
  #define N_TRELOFF(x) N_RELOFF(x)
  #endif
@@ -60,7 +63,7 @@
 +/* Here is how to find X Windows.  LD_SWITCH_X_SITE_AUX gives an -R option
 +   says where to find X windows at run time.  We convert it to a -rpath option
 +   which is what OSF1 uses.  */
-+#define LD_SWITCH_SYSTEM `echo LD_SWITCH_X_SITE_AUX | sed -e 's/-R/-Wl,-rpath,/'`
++#define LD_SWITCH_SYSTEM `echo LD_SWITCH_X_SITE_AUX | sed -e 's/-R/-Wl,-rpath,/'` -Wl,-znocombreloc
 +
 +#define HAVE_TEXT_START               /* No need to define `start_of_text'.  */
 +#define UNEXEC unexelf.o
diff -r 4db8519cdbb8 -r 5044809e7add editors/mule/patches/patch-ab
--- a/editors/mule/patches/patch-ab     Fri Apr 28 22:59:48 2017 +0000
+++ b/editors/mule/patches/patch-ab     Sat Apr 29 01:11:55 2017 +0000
@@ -1,9 +1,12 @@
-$NetBSD: patch-ab,v 1.3 2011/12/24 17:07:07 dholland Exp $
+$NetBSD: patch-ab,v 1.4 2017/04/29 01:11:55 tsutsui Exp $
 
---- src/unexelf.c.orig 1994-10-21 05:21:00.000000000 +0100
+Pull unexelf.c from newer emacs.
+
+--- src/unexelf.c.orig 1994-10-21 04:21:00.000000000 +0000
 +++ src/unexelf.c
 @@ -1,19 +1,22 @@
- /* Copyright (C) 1985, 1986, 1987, 1988, 1990, 1992
+-/* Copyright (C) 1985, 1986, 1987, 1988, 1990, 1992
++/* Copyright (C) 1985, 1986, 1987, 1988, 1990, 1992, 1999, 2000, 01, 02
     Free Software Foundation, Inc.
  
 -    This program is free software; you can redistribute it and/or modify
@@ -57,245 +60,36 @@
   *
   * The boundaries within the a.out file may be adjusted with the data_start
   * and bss_start arguments.  Either or both may be given as 0 for defaults.
-@@ -98,64 +101,64 @@ temacs:
-         Link    Info    Adralgn      Entsize
- 
- [1]     1       2       0x80480d4    0xd4         0x13          .interp
--        0       0       0x1          0            
-+        0       0       0x1          0
- 
- [2]     5       2       0x80480e8    0xe8         0x388         .hash
--        3       0       0x4          0x4          
-+        3       0       0x4          0x4
- 
- [3]     11      2       0x8048470    0x470        0x7f0         .dynsym
--        4       1       0x4          0x10         
-+        4       1       0x4          0x10
- 
- [4]     3       2       0x8048c60    0xc60        0x3ad         .dynstr
--        0       0       0x1          0            
-+        0       0       0x1          0
- 
- [5]     9       2       0x8049010    0x1010       0x338         .rel.plt
--        3       7       0x4          0x8          
-+        3       7       0x4          0x8
- 
- [6]     1       6       0x8049348    0x1348       0x3           .init
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [7]     1       6       0x804934c    0x134c       0x680         .plt
--        0       0       0x4          0x4          
-+        0       0       0x4          0x4
- 
- [8]     1       6       0x80499cc    0x19cc       0x3c56f       .text
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [9]     1       6       0x8085f3c    0x3df3c      0x3           .fini
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [10]    1       2       0x8085f40    0x3df40      0x69c         .rodata
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [11]    1       2       0x80865dc    0x3e5dc      0xd51         .rodata1
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [12]    1       3       0x8088330    0x3f330      0x20afc       .data
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [13]    1       3       0x80a8e2c    0x5fe2c      0x89d         .data1
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [14]    1       3       0x80a96cc    0x606cc      0x1a8         .got
--        0       0       0x4          0x4          
-+        0       0       0x4          0x4
- 
- [15]    6       3       0x80a9874    0x60874      0x80          .dynamic
--        4       0       0x4          0x8          
-+        4       0       0x4          0x8
- 
- [16]    8       3       0x80a98f4    0x608f4      0x449c        .bss
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [17]    2       0       0            0x608f4      0x9b90        .symtab
--        18      371     0x4          0x10         
-+        18      371     0x4          0x10
- 
- [18]    3       0       0            0x6a484      0x8526        .strtab
--        0       0       0x1          0            
-+        0       0       0x1          0
- 
- [19]    3       0       0            0x729aa      0x93          .shstrtab
--        0       0       0x1          0            
-+        0       0       0x1          0
- 
- [20]    1       0       0            0x72a3d      0x68b7        .comment
--        0       0       0x1          0            
-+        0       0       0x1          0
- 
- raid:/nfs/raid/src/dist-18.56/src> dump -h xemacs
- 
-@@ -166,67 +169,67 @@ xemacs:
-         Link    Info    Adralgn      Entsize
- 
- [1]     1       2       0x80480d4    0xd4         0x13          .interp
--        0       0       0x1          0            
-+        0       0       0x1          0
- 
- [2]     5       2       0x80480e8    0xe8         0x388         .hash
--        3       0       0x4          0x4          
-+        3       0       0x4          0x4
- 
- [3]     11      2       0x8048470    0x470        0x7f0         .dynsym
--        4       1       0x4          0x10         
-+        4       1       0x4          0x10
- 
- [4]     3       2       0x8048c60    0xc60        0x3ad         .dynstr
--        0       0       0x1          0            
-+        0       0       0x1          0
- 
- [5]     9       2       0x8049010    0x1010       0x338         .rel.plt
--        3       7       0x4          0x8          
-+        3       7       0x4          0x8
- 
- [6]     1       6       0x8049348    0x1348       0x3           .init
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [7]     1       6       0x804934c    0x134c       0x680         .plt
--        0       0       0x4          0x4          
-+        0       0       0x4          0x4
+@@ -49,11 +52,6 @@ what you give them.   Help stamp out sof
+  * The value you specify may be rounded down to a suitable boundary
+  * as required by the machine you are using.
+  *
+- * Specifying zero for data_start means the boundary between text and data
+- * should not be the same as when the program was loaded.
+- * If NO_REMAP is defined, the argument data_start is ignored and the
+- * segment boundaries are never changed.
+- *
+  * Bss_start indicates how much of the data segment is to be saved in the
+  * a.out file and restored when the program is executed.  It gives the lowest
+  * unsaved address, and is rounded up to a page boundary.  The default when 0
+@@ -63,9 +61,6 @@ what you give them.   Help stamp out sof
+  *
+  * The new file is set up to start at entry_address.
+  *
+- * If you make improvements I'd like to get them too.
+- * harpo!utah-cs!thomas, thomas@Utah-20
+- *
+  */
  
- [8]     1       6       0x80499cc    0x19cc       0x3c56f       .text
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [9]     1       6       0x8085f3c    0x3df3c      0x3           .fini
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [10]    1       2       0x8085f40    0x3df40      0x69c         .rodata
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [11]    1       2       0x80865dc    0x3e5dc      0xd51         .rodata1
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [12]    1       3       0x8088330    0x3f330      0x20afc       .data
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [13]    1       3       0x80a8e2c    0x5fe2c      0x89d         .data1
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [14]    1       3       0x80a96cc    0x606cc      0x1a8         .got
--        0       0       0x4          0x4          
-+        0       0       0x4          0x4
- 
- [15]    6       3       0x80a9874    0x60874      0x80          .dynamic
--        4       0       0x4          0x8          
-+        4       0       0x4          0x8
- 
- [16]    8       3       0x80c6800    0x7d800      0             .bss
--        0       0       0x4          0            
-+        0       0       0x4          0
- 
- [17]    2       0       0            0x7d800      0x9b90        .symtab
--        18      371     0x4          0x10         
-+        18      371     0x4          0x10
- 
- [18]    3       0       0            0x87390      0x8526        .strtab



Home | Main Index | Thread Index | Old Index