Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 18 Nov 2018 22:06:45 +0000 (UTC)
From:      Mikhail Teterin <mi@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r485281 - in head/lang/scm: . files
Message-ID:  <201811182206.wAIM6j1P062136@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: mi
Date: Sun Nov 18 22:06:44 2018
New Revision: 485281
URL: https://svnweb.freebsd.org/changeset/ports/485281

Log:
  Try to improve chances of successful build - including, but not
  limited to disabling compiler-optimizations.
  
  Proper fixing seems inherently impossible -- even with -O0 valgrind
  flags hundreds of unitilized memory accesses during self-check.
  
  Tested with gcc8 and the base cc (clang) -- remove the GCC-requirement.
  
  Add some patches from Debian.
  
  While here simplify the extract-target a little and remove the BROKEN*
  lines to attempt building on other platforms again...
  
  Bump port-revision.
  
  PR:		 232936

Added:
  head/lang/scm/files/patch-bigrecy_32bit_upstream   (contents, props changed)
  head/lang/scm/files/patch-texinfo5_fixes   (contents, props changed)
Modified:
  head/lang/scm/Makefile
  head/lang/scm/files/patch-scmfig.h
  head/lang/scm/files/patch-warnings

Modified: head/lang/scm/Makefile
==============================================================================
--- head/lang/scm/Makefile	Sun Nov 18 21:54:55 2018	(r485280)
+++ head/lang/scm/Makefile	Sun Nov 18 22:06:44 2018	(r485281)
@@ -3,33 +3,26 @@
 
 PORTNAME=	scm
 PORTVERSION=	5f2
-PORTREVISION=	8
+PORTREVISION=	9
 CATEGORIES=	lang scheme
 MASTER_SITES=	http://groups.csail.mit.edu/mac/ftpdir/scm/%SUBDIR%/
 MASTER_SITE_SUBDIR=	. OLD
 DISTFILES=	${DISTNAME}${EXTRACT_SUFX} slib-3b5.zip slib-psd1-3.tar.gz
-EXTRACT_ONLY=	${DISTNAME}${EXTRACT_SUFX}
+EXTRACT_ONLY=	${DISTNAME}${EXTRACT_SUFX} slib-3b5.zip
 
 MAINTAINER=	mi@aldan.algebra.com
 COMMENT=	Scheme interpreter
 
 LICENSE=	LGPL21
 
-BROKEN_aarch64=		does not link: undefined reference to sbrk
-BROKEN_armv6=		does not build: fails self-tests
-BROKEN_armv7=		does not build: fails self-tests
-BROKEN_mips=		does not build
-BROKEN_mips64=		does not build
-BROKEN_powerpc64=	does not build: error: r4rstest.scm: segment violation 11
-
 WRKSRC=		${WRKDIR}/${PORTNAME}
 
 USES=		readline zip
-USE_GCC=	any
 HAS_CONFIGURE=	yes
 CONFIGURE_ENV=	--prefix=${PREFIX}
 MAKE_JOBS_UNSAFE=	yes
 
+CFLAGS:=	${CFLAGS:N-O*} -O0
 CFLAGS+=	-Wall -Wwrite-strings -Wmissing-declarations -Wredundant-decls -Wcast-qual
 CFLAGS+=	-Wno-unused-label -Wno-uninitialized
 
@@ -69,10 +62,6 @@ EXTRA_PATCHES+=	${FILESDIR}/ia64-patch
 ARCHOBJS=	continue-ia64.S
 .endif
 
-post-extract:
-	# Certain .scm files are needed during build:
-	@${TAR} -C ${WRKDIR} -zxf ${DISTDIR}/${DISTFILES:Mslib*.zip} '*.scm'
-
 post-patch:
 	@${REINPLACE_CMD} -e 's|/usr/include|${LOCALBASE}/include| ; \
 		 /strip/s|^|#|' ${WRKSRC}/Makefile
@@ -84,6 +73,8 @@ post-patch:
 	@${REINPLACE_CMD} -e 's|gnuregex\.h|gnu/regex.h|g' ${WRKSRC}/rgx.c
 	@${REINPLACE_CMD} -e 's|/usr/include|${LOCALBASE}/include|g' \
 		${WRKSRC}/xgen.scm
+	@${REINPLACE_CMD} -e 's|/usr/local|${PREFIX}|g'	\
+		${WRKSRC}/*.info ${WRKSRC}/*.texi
 
 do-install:
 	${INSTALL_PROGRAM} ${WRKSRC}/scm ${WRKSRC}/scmlit \

Added: head/lang/scm/files/patch-bigrecy_32bit_upstream
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/lang/scm/files/patch-bigrecy_32bit_upstream	Sun Nov 18 22:06:44 2018	(r485281)
@@ -0,0 +1,96 @@
+Obtained from Debian
+
+	https://launchpad.net/ubuntu/+source/scm/5f2-2build1
+
+Description: Support ARM64 ("aarch64") platform
+Author: Jakub Bogusz
+--- scl.c	2015/01/03 20:50:15	1.142
++++ scl.c	2016/08/10 02:33:05	1.143
+@@ -166,33 +166,34 @@
+     /* try first with starved precision */
+     {
+       num = scm_ash(mant, MAKINUM(e2 - point));
+-      bigrecy(mant);
++      if (num != mant) bigrecy(mant);
+       quo = scm_round_quotient(num, VELTS(pows5)[(long) point]);
+       if (pmantexp2dbl(quo, point) != f) {
+-	bigrecy(quo); quo = num;
++	if (quo != num) { bigrecy(quo); quo = num; }
+ 	num = scm_ash(quo, MAKINUM(1L));
+-	bigrecy(quo);
++	if (num != quo) bigrecy(quo);
+ 	quo = scm_round_quotient(num, VELTS(pows5)[(long) --point]);
+       }
++      if (num != quo) bigrecy(num);
+     }
+   } else {   /* e2 <= 0 */
+     /* try first with starved precision */
+     {
+       SCM den = scm_ash(MAKINUM(1L), MAKINUM(point - e2));
+       num = product(mant, VELTS(pows5)[- (long) point]);
+-      bigrecy(mant);
++      if (num != mant) { bigrecy(mant); if (mant != MAKINUM(1)) mant = INUM0; }
+       quo = scm_round_quotient(num, den);
+       if (pmantexp2dbl(quo, point) != f) {
+-	bigrecy(quo); quo = num;
++	if (quo != num) { bigrecy(quo); quo = num; }
+ 	point--;
+ 	num = product(quo, MAKINUM(10));
+ 	if (mant != MAKINUM(1)) bigrecy(quo);
+ 	quo = scm_round_quotient(num, den);
+-      }
++	if (quo != num) bigrecy(num);
++      } else if ((mant != MAKINUM(1)) && (quo != num)) bigrecy(num);
+       bigrecy(den);
+     }
+   }
+-  bigrecy(num);
+   a[ch++] = '.';
+   /* if (sizeof(UBIGLONG)>=sizeof(double)) /\* Is ulong larger than mantissa? *\/ */
+   /*   ch += iulong2str(num2ulong(quo, (char *)ARG1, s_number2string), 10, &a[ch]); */
+@@ -680,7 +681,7 @@
+       ans = ldexp(ans, bex + point);
+     }
+     if (num != quo) bigrecy(quo);
+-    if (bmant != MAKINUM(1L)) bigrecy(num);
++    if ((num != bmant) && (bmant != MAKINUM(1L))) bigrecy(num);
+     return ans;
+   } else {
+     int maxpow = LENGTH(pows5) - 1;
+@@ -696,7 +697,7 @@
+       quo = scm_round_quotient(num, scm_ash(scl, MAKINUM(1L)));
+     }
+     if (-point > maxpow) bigrecy(scl);
+-    bigrecy(num);
++    if (num != quo) bigrecy(num);
+     ans = ldexp(int2dbl(quo), bex + point);
+     bigrecy(quo);
+     return ans;
+@@ -2478,7 +2479,7 @@
+ 	tmp = acc;
+ 	acc = product(tmp, tz1);
+ #ifdef BIGDIG
+-	bigrecy(tmp);
++	if (acc != tmp) bigrecy(tmp);
+ #endif
+ 	break;
+       }
+@@ -2486,7 +2487,7 @@
+ 	tmp = acc;
+ 	acc = product(tmp, tz1);
+ #ifdef BIGDIG
+-	bigrecy(tmp);
++	if (acc != tmp) bigrecy(tmp);
+ #endif
+       }
+       tmp = tz1;
+@@ -2841,8 +2842,8 @@
+       bex += j * BITSPERDIG;
+       if (bex > 0) ans = ldexp(ans, bex);
+     }
++    if (quo != num) bigrecy(quo);
+     if (num != b) bigrecy(num);
+-    if (quo != b) bigrecy(quo);
+     if (tc16_bigneg==TYP16(b)) return -ans;
+     return ans;
+   }

Modified: head/lang/scm/files/patch-scmfig.h
==============================================================================
--- head/lang/scm/files/patch-scmfig.h	Sun Nov 18 21:54:55 2018	(r485280)
+++ head/lang/scm/files/patch-scmfig.h	Sun Nov 18 22:06:44 2018	(r485281)
@@ -1,7 +1,6 @@
---- scmfig.h
-+++ scmfig.h
-@@ -256,11 +256,7 @@
- #ifdef __alpha
+--- scmfig.h	2013-04-06 22:23:52.000000000 -0400
++++ scmfig.h	2018-11-18 13:05:53.787326000 -0500
+@@ -257,9 +257,5 @@
  # define SHORT_INT
  #endif
 -#ifdef __ia64__
@@ -9,17 +8,14 @@
 -# define CDR_DOUBLES
 -#endif
 -#ifdef __x86_64
-+#if defined(__amd64__) || defined(__ia64__) || defined(__powerpc64__) || defined(__x86_64__) || defined(__sparc64__)
++#if defined(__amd64__) || defined(__ia64__) || defined(__powerpc64__) || defined(__x86_64__) || defined(__sparc64__) || defined(__arch64__)
  # define SHORT_INT
  # define CDR_DOUBLES
+@@ -394,13 +390,5 @@
  #endif
-@@ -393,14 +389,6 @@
- # define WHITE_SPACES  ' ':case '\t':case '\r':case '\f'
- #endif
  
 -#ifdef __ia64__
 -# define PTR2INT(x) ((long)(x))
-+#define PTR2INT(x) ((intptr_t)(x))
 -#else
 -# ifdef __x86_64
 -#  define PTR2INT(x) ((long)(x))
@@ -27,9 +23,17 @@
 -#  define PTR2INT(x) ((int)(x))
 -# endif
 -#endif
++#define PTR2INT(x) ((intptr_t)(x))
  
  #ifndef __builtin_expect
-@@ -824,5 +816,5 @@
+@@ -538,5 +526,5 @@
+ # define MAKINUM(x) ((((x)<<1)<<1)+2L)
+ #else
+-# define MAKINUM(x) (((x)<<2)+2L)
++# define MAKINUM(x) ((((unsigned long)(x))<<2)+2L)
+ #endif
+ 
+@@ -824,5 +812,5 @@
  # ifdef ARM_ULIB
      extern volatile int errno;
 -# else

Added: head/lang/scm/files/patch-texinfo5_fixes
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/lang/scm/files/patch-texinfo5_fixes	Sun Nov 18 22:06:44 2018	(r485281)
@@ -0,0 +1,201 @@
+Obtained from Debian:
+
+	https://launchpad.net/ubuntu/+source/scm/5f2-2build1
+
+--- Xlibscm.texi
++++ Xlibscm.texi
+@@ -257,8 +257,9 @@ used.
+ Returns the root window for the specified @var{screen-number}.  Use
+ @code{x:root-window} for functions that need a drawable of a particular
+ screen or for creating top-level windows.
++@end defun
+ 
+-@defunx x:root-window window
++@defun x:root-window window
+ Returns the root window for the specified @var{window}'s screen.
+ @end defun
+ 
+@@ -345,7 +346,9 @@ Returns the number of entries in the def
+ 
+ @defun x:screen-depth display screen-number
+ Returns the depth of the root window of the specified screen.
+-@defunx x:screen-depth display
++@end defun
++
++@defun x:screen-depth display
+ @defunx x:screen-depth window
+ @defunx x:screen-depth visual
+ Returns the depth of argument.
+@@ -420,8 +423,9 @@ and the @var{visual} must be one support
+ 
+ The returned window will have the attributes specified by
+ @var{field-name}s and @var{value}.
++@end defun
+ 
+-@defunx x:create-window window position size border-width border background
++@defun x:create-window window position size border-width border background
+ The returned window inherits its depth, class, and visual from its
+ parent.  All other window attributes, except @var{background} and
+ @var{border}, have their default values.
+@@ -909,7 +913,9 @@ those for @code{x:window-set!}:
+ @defun x:get-window-property window property 
+ Returns the (string or list of numbers) value of @var{property} of
+ @var{window}.
+-@defunx x:get-window-property window property #t
++@end defun
++
++@defun x:get-window-property window property #t
+ Removes and returns the (string or list of numbers) value of
+ @var{property} of @var{window}.
+ @end defun
+@@ -1392,8 +1398,9 @@ The hotspot comes from the information s
+ initial colors of a cursor are a black foreground and a white background
+ (see X:Recolor-Cursor).  The names of all cursor shapes are defined with
+ the prefix XC: in @file{x11.scm}.
++@end defun
+ 
+-@defunx x:create-cursor source-font source-char mask-font mask-char fgc bgc
++@defun x:create-cursor source-font source-char mask-font mask-char fgc bgc
+ Creates a cursor from the source and mask bitmaps obtained from the
+ specified font glyphs.  The integer @var{source-char} must be a defined
+ glyph in @var{source-font}.  The integer @var{mask-char} must be a
+@@ -1402,12 +1409,14 @@ and @var{mask-char} glyphs are positione
+ hotspot.  The @var{source-char} and @var{mask-char} need not have the
+ same bounding box metrics, and there is no restriction on the placement
+ of the hotspot relative to the bounding boxes.
++@end defun
+ 
+-@defunx x:create-cursor source-font source-char #f #f fgc bgc
++@defun x:create-cursor source-font source-char #f #f fgc bgc
+ If @var{mask-font} and @var{mask-char} are #f, all pixels of the source
+ are displayed.
++@end defun
+ 
+-@defunx x:create-cursor source-pixmap mask-pixmap fgc bgc origin
++@defun x:create-cursor source-pixmap mask-pixmap fgc bgc origin
+ @var{mask-pixmap} must be the same size as the pixmap defined by the
+ @var{source-pixmap} argument.  The foreground and background RGB values
+ must be specified using @var{foreground-color} and
+@@ -1422,8 +1431,9 @@ source and mask must have depth one but
+ @var{mask-pixmap} defines the shape of the cursor.  The pixels set to 1
+ in @var{mask-pixmap} define which source pixels are displayed, and the
+ pixels set to 0 define which pixels are ignored.
++@end defun
+ 
+-@defunx x:create-cursor source-pixmap #f fgc bgc origin
++@defun x:create-cursor source-pixmap #f fgc bgc origin
+ If @var{mask-pixmap} is #f, all pixels of the source are displayed.
+ @end defun
+ 
+@@ -1539,8 +1549,9 @@ The RGB values of the allocated entries
+ succeeded or #f if it failed.  The first array has the pixels allocated
+ and the second has the plane-masks.
+ 
++@end defun
+ 
+-@defunx x:alloc-colormap-cells colormap ncolors rgb
++@defun x:alloc-colormap-cells colormap ncolors rgb
+ @defunx x:alloc-colormap-cells colormap ncolors rgb contiguous?
+ 
+ The specified @var{ncolors} must be positive; and @var{rgb} a list or
+@@ -1596,8 +1607,9 @@ is in error, the one that gets reported
+ @var{rgb} is a list or vector of 3 integers, describing the red, green,
+ and blue intensities respectively; or an integer @samp{#x@i{rrggbb}},
+ packing red, green and blue intensities in the range 0 - 255.
++@end defun
+ 
+-@defunx x:colormap-find-color colormap color-name
++@defun x:colormap-find-color colormap color-name
+ 
+ The case-insensitive string @var{color_name} specifies the name of a
+ color (for example, @file{red})
+@@ -1630,8 +1642,9 @@ The integer @var{pixel} must be a valid
+ @var{rgb} is a list or vector of 3 integers, describing the red, green,
+ and blue intensities respectively; or an integer @samp{#x@i{rrggbb}},
+ packing red, green and blue intensities in the range 0 - 255.
++@end defun
+ 
+-@defunx X:Color-Set! colormap pixel color-name
++@defun X:Color-Set! colormap pixel color-name
+ 
+ The case-insensitive string @var{color_name} specifies the name of a
+ color (for example, @file{red})
+@@ -1671,8 +1684,9 @@ Flushes the output buffer.  Some client
+ function because the output buffer is automatically flushed as needed by
+ calls to X:Pending, X:Next-Event, and X:Window-Event.  Events generated
+ by the server may be enqueued into the library's event queue.
++@end defun
+ 
+-@defunx x:flush gc
++@defun x:flush gc
+ Forces sending of GC component changes.
+ 
+ Xlib usually defers sending changes to the components of a GC to the
+@@ -1726,12 +1740,14 @@ results.
+ 
+ @defun x:draw-points drawable gc position @dots{}
+ @var{Position} @dots{} specifies coordinates of the point to be drawn.
++@end defun
+ 
+-@defunx x:draw-points drawable gc x y @dots{}
++@defun x:draw-points drawable gc x y @dots{}
+ (@var{x}, @var{y}) @dots{} specifies coordinates of the point to be
+ drawn.
++@end defun
+ 
+-@defunx x:draw-points drawable gc point-array
++@defun x:draw-points drawable gc point-array
+ @var{point-array} is a uniform short array of rank 2, whose rightmost
+ index spans a range of 2.
+ 
+@@ -1748,12 +1764,14 @@ clip-mask.
+ @defun x:draw-segments drawable gc pos1 pos2 @dots{}
+ @var{Pos1}, @var{pos2}, @dots{} specify coordinates to be connected by
+ segments.
++@end defun
+ 
+-@defunx x:draw-segments drawable gc x1 y1 x2 y2 @dots{}
++@defun x:draw-segments drawable gc x1 y1 x2 y2 @dots{}
+ (@var{x1}, @var{y1}), (@var{x2}, @var{y2}) @dots{} specify coordinates
+ to be connected by segments.
++@end defun
+ 
+-@defunx x:draw-segments drawable gc point-array
++@defun x:draw-segments drawable gc point-array
+ @var{point-array} is a uniform short array of rank 2, whose rightmost
+ index spans a range of 2.
+ 
+@@ -1779,12 +1797,14 @@ dash-offset, and dash-list.
+ @defun x:draw-lines drawable gc pos1 pos2 @dots{}
+ @var{Pos1}, @var{pos2}, @dots{} specify coordinates to be connected by
+ lines.
++@end defun
+ 
+-@defunx x:draw-lines drawable gc x1 y1 x2 y2 @dots{}
++@defun x:draw-lines drawable gc x1 y1 x2 y2 @dots{}
+ (@var{x1}, @var{y1}), (@var{x2}, @var{y2}) @dots{} specify coordinates
+ to be connected by lines.
++@end defun
+ 
+-@defunx x:draw-lines drawable gc point-array
++@defun x:draw-lines drawable gc point-array
+ @var{point-array} is a uniform short array of rank 2, whose rightmost
+ index spans a range of 2.
+ 
+@@ -1810,12 +1830,14 @@ dash-offset, and dash-list.
+ 
+ @defun x:fill-polygon drawable gc pos1 pos2 @dots{}
+ @var{Pos1}, @var{pos2}, @dots{} specify coordinates of the border path.
++@end defun
+ 
+-@defunx x:fill-polygon drawable gc x1 y1 x2 y2 @dots{}
++@defun x:fill-polygon drawable gc x1 y1 x2 y2 @dots{}
+ (@var{x1}, @var{y1}), (@var{x2}, @var{y2}) @dots{} specify coordinates
+ of the border path.
++@end defun
+ 
+-@defunx x:fill-polygon drawable gc point-array
++@defun x:fill-polygon drawable gc point-array
+ @var{point-array} is a uniform short array of rank 2, whose rightmost
+ index spans a range of 2.
+ 

Modified: head/lang/scm/files/patch-warnings
==============================================================================
--- head/lang/scm/files/patch-warnings	Sun Nov 18 21:54:55 2018	(r485280)
+++ head/lang/scm/files/patch-warnings	Sun Nov 18 22:06:44 2018	(r485281)
@@ -89,15 +89,15 @@
       SCM sstr, start, args;
  {
 --- bytenumb.c	2013-03-24 19:37:38.000000000 -0400
-+++ bytenumb.c	2015-01-23 18:55:19.000000000 -0500
++++ bytenumb.c	2018-11-18 13:34:10.773431000 -0500
 @@ -27,5 +27,5 @@
  #include "scm.h"
  
 -int get_bytes_length(obj)
-+static int get_bytes_length(obj)
++static ssize_t get_bytes_length(obj)
       SCM obj;
  {
-@@ -47,8 +47,8 @@
+@@ -47,10 +47,10 @@
  }
  
 -static char s_wrong_length[] = "wrong length";
@@ -107,12 +107,16 @@
 -char * get_bytes(obj, minlen, s_name)
 +static void * get_bytes(obj, minlen, s_name)
       SCM obj;
-      int minlen;
+-     int minlen;
++     ssize_t minlen;
+      const char *s_name;
+ {
 @@ -60,13 +60,15 @@
  	 obj, ARG1, s_name);
    {
+-    int byvlen = get_bytes_length(obj);
 +#ifndef RECKLESS
-     int byvlen = get_bytes_length(obj);
++    ssize_t byvlen = get_bytes_length(obj);
 +#endif
      ASRTER((minlen < 0) ? byvlen >= -minlen : byvlen == minlen,
  	   MAKINUM(byvlen), s_wrong_length, s_name);
@@ -127,10 +131,12 @@
 +static SCM scm_bytes_to_integer(sbyts, sn)
       SCM sbyts;
       SCM sn;
-@@ -76,5 +78,5 @@
+@@ -75,6 +77,6 @@
+   if (!(n)) return INUM0;
    {
-     int cnt = abs(n);
+-    int cnt = abs(n);
 -    char *byts = get_bytes(sbyts, -cnt, s_bytes_to_integer);
++    ssize_t cnt = labs(n);
 +    const unsigned char *byts = get_bytes(sbyts, -cnt, s_bytes_to_integer);
      int iu = 0, id = cnt - sizeof(BIGDIG);
      sizet ndigs = (cnt + sizeof(BIGDIG) - 1) / sizeof(BIGDIG);
@@ -321,7 +327,7 @@
  long stack_size P((STACKITEM *start));
  CONTINUATION *make_root_continuation P((STACKITEM *stack_base));
 --- crs.c	2009-10-21 15:41:30.000000000 -0400
-+++ crs.c	2015-01-23 18:55:19.000000000 -0500
++++ crs.c	2018-11-18 13:50:12.053849000 -0500
 @@ -43,5 +43,5 @@
  #define WIN(obj) ((WINDOW*)CDR(obj))
  #define WINP(obj) (tc16_window==TYP16(obj))
@@ -343,7 +349,13 @@
 +     const char *str; WINDOW *win;
  {
    sizet i = 0, prod = siz*num;
-@@ -74,5 +74,5 @@
+@@ -70,9 +70,9 @@
+   bwaddstr,
+   bwwrite,
+-  wrefresh,
+-  wgetch,
++  (int (*)(FILE *))wrefresh,
++  (int (*)(FILE *))wgetch,
    freewindow};
  
 -SCM mkwindow(win)
@@ -533,6 +545,12 @@
 +static SCM lclearok(w, b) SCM w, b;
  {
    if (BOOL_T==w) return ERR==clearok(curscr, BOOL_F != b)?BOOL_F:BOOL_T;
+@@ -388,4 +389,4 @@
+   make_subr(s_box, tc7_subr_3, lbox);
+   add_feature("curses");
+-  add_final(lendwin);
++  add_final((void (*)(void))lendwin);
+ }
 --- debug.c	2008-01-30 22:31:48.000000000 -0500
 +++ debug.c	2015-01-23 18:55:19.000000000 -0500
 @@ -291,5 +291,8 @@
@@ -1030,7 +1048,7 @@
 +static SCM l_dyn_call(symb, shl)
  	SCM symb, shl;
  {
-@@ -419,6 +419,6 @@
+@@ -419,10 +419,10 @@
    return BOOL_T;
  }
 -static char s_main_call[] = "dyn:main-call";
@@ -1039,6 +1057,18 @@
 +static SCM l_dyn_main_call(symb, shl, args)
  	SCM symb, shl, args;
  {
+   int i;
+-  int (*func)P((int argc, const char **argv)) = 0;
++  int (*func)P((int argc, char **argv)) = 0;
+   char **argv;
+ /*  SCM oloadpath = *loc_loadpath; */
+@@ -445,5 +445,5 @@
+   ALLOW_INTS;
+ /*  *loc_loadpath = linkpath; */
+-  i = (*func) ((int)ilength(args), (const char**)argv);
++  i = (*func) ((int)ilength(args), argv);
+ /*  *loc_loadpath = oloadpath; */
+   DEFER_INTS;
 @@ -453,6 +453,6 @@
  }
  
@@ -4524,7 +4554,7 @@
    return (int)INUM(retval);
  }
 --- script.c	2008-01-30 22:32:55.000000000 -0500
-+++ script.c	2015-01-23 18:55:19.000000000 -0500
++++ script.c	2018-11-18
 @@ -54,10 +54,10 @@
      {
        long len = strlen(str1);
@@ -4554,13 +4584,18 @@
 +  char *path = NULL;
  
  #ifdef _WIN32
-@@ -189,5 +189,5 @@
+@@ -189,9 +189,9 @@
      if (!strcmp(sepptr, "exe") || !strcmp(sepptr, "bin") ||
  	!strcmp(sepptr, "EXE") || !strcmp(sepptr, "BIN")) {
 -      char *peer;
 +      const char *peer;
  
        /* Look for initname in peer directory "lib". */
+       if (path) {
+-	strncpy(sepptr, "lib", 3);
++	strcpy(sepptr, "lib");
+ 	path = scm_sep_init_try(path, sep, initname);
+ 	if (path) return path;
 @@ -279,10 +279,10 @@
  }
  



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201811182206.wAIM6j1P062136>