Module Name: xsrc Committed By: mrg Date: Mon Jun 19 06:44:24 UTC 2023
Modified Files: xsrc/external/mit/libXft/dist/src: xftglyphs.c xsrc/external/mit/libXi/dist/man: XGetDeviceKeyMapping.man xsrc/external/mit/libXpm/dist/src: create.c xsrc/external/mit/libXt/dist: compile xsrc/external/mit/libXt/dist/m4: libtool.m4 ltoptions.m4 ltsugar.m4 ltversion.m4 lt~obsolete.m4 xsrc/external/mit/libXt/dist/src: Convert.c NextEvent.c ResConfig.c TMparse.c xsrc/external/mit/libXt/dist/util: makestrs.c xsrc/external/mit/xtrans/dist: Xtranssock.c Log Message: merge libXfixes 6.0.1, libXft 2.3.8, libXi 1.8.1, libXpm 3.5.16, libXt 1.3.0, and xtrans 1.5.0. To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 xsrc/external/mit/libXft/dist/src/xftglyphs.c cvs rdiff -u -r1.2 -r1.3 \ xsrc/external/mit/libXi/dist/man/XGetDeviceKeyMapping.man cvs rdiff -u -r1.5 -r1.6 xsrc/external/mit/libXpm/dist/src/create.c cvs rdiff -u -r1.5 -r1.6 xsrc/external/mit/libXt/dist/compile cvs rdiff -u -r1.4 -r1.5 xsrc/external/mit/libXt/dist/m4/libtool.m4 cvs rdiff -u -r1.3 -r1.4 xsrc/external/mit/libXt/dist/m4/ltoptions.m4 \ xsrc/external/mit/libXt/dist/m4/ltsugar.m4 \ xsrc/external/mit/libXt/dist/m4/ltversion.m4 \ xsrc/external/mit/libXt/dist/m4/lt~obsolete.m4 cvs rdiff -u -r1.4 -r1.5 xsrc/external/mit/libXt/dist/src/Convert.c cvs rdiff -u -r1.8 -r1.9 xsrc/external/mit/libXt/dist/src/NextEvent.c \ xsrc/external/mit/libXt/dist/src/TMparse.c cvs rdiff -u -r1.6 -r1.7 xsrc/external/mit/libXt/dist/src/ResConfig.c cvs rdiff -u -r1.5 -r1.6 xsrc/external/mit/libXt/dist/util/makestrs.c cvs rdiff -u -r1.3 -r1.4 xsrc/external/mit/xtrans/dist/Xtranssock.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: xsrc/external/mit/libXft/dist/src/xftglyphs.c diff -u xsrc/external/mit/libXft/dist/src/xftglyphs.c:1.6 xsrc/external/mit/libXft/dist/src/xftglyphs.c:1.7 --- xsrc/external/mit/libXft/dist/src/xftglyphs.c:1.6 Sun Jan 8 06:03:45 2023 +++ xsrc/external/mit/libXft/dist/src/xftglyphs.c Mon Jun 19 06:44:23 2023 @@ -840,18 +840,22 @@ XftFontLoadGlyphs (Display *dpy, } FT_Vector_Transform(&vector, &font->info.matrix); xftg->metrics.xOff = (short)(TRUNC(ROUND(vector.x))); - xftg->metrics.yOff = (short)(TRUNC(ROUND(vector.y))); + xftg->metrics.yOff = (short)(-TRUNC(ROUND(vector.y))); } else { + short maximum_x = (short)(font->public.max_advance_width); + short maximum_y = (short)(-font->public.max_advance_width); + short trimmed_x = (short)(TRUNC(ROUND(glyphslot->advance.x))); + short trimmed_y = (short)(-TRUNC(ROUND(glyphslot->advance.y))); if (font->info.load_flags & FT_LOAD_VERTICAL_LAYOUT) { xftg->metrics.xOff = 0; - xftg->metrics.yOff = (short)(-TRUNC(ROUND(glyphslot->advance.y))); + xftg->metrics.yOff = min(maximum_y,trimmed_y); } else { - xftg->metrics.xOff = (short)(TRUNC(ROUND(glyphslot->advance.x))); + xftg->metrics.xOff = min(maximum_x,trimmed_x); xftg->metrics.yOff = 0; } } @@ -1245,8 +1249,11 @@ XftFontCheckGlyph (Display *dpy, /* * Make unloading faster by moving newly-referenced glyphs to the front * of the list, leaving the less-used glyphs on the end. + * + * If the glyph is zero, the older/newer data may not have been set. */ - if (font->track_mem_usage + if (glyph != 0 + && font->track_mem_usage && font->total_inuse > 10 && font->newest != FT_UINT_MAX && font->newest != glyph) Index: xsrc/external/mit/libXi/dist/man/XGetDeviceKeyMapping.man diff -u xsrc/external/mit/libXi/dist/man/XGetDeviceKeyMapping.man:1.2 xsrc/external/mit/libXi/dist/man/XGetDeviceKeyMapping.man:1.3 --- xsrc/external/mit/libXi/dist/man/XGetDeviceKeyMapping.man:1.2 Sun May 1 23:12:54 2022 +++ xsrc/external/mit/libXi/dist/man/XGetDeviceKeyMapping.man Mon Jun 19 06:44:23 2023 @@ -1,13 +1,13 @@ '\" t .\" Title: xgetdevicekeymapping -.\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] -.\" Generator: DocBook XSL Stylesheets v1.79.1 <http://docbook.sf.net/> -.\" Date: 09/15/2021 +.\" Author: [FIXME: author] [see http://www.docbook.org/tdg5/en/html/author] +.\" Generator: DocBook XSL Stylesheets vsnapshot <http://docbook.sf.net/> +.\" Date: 05/04/2023 .\" Manual: \ \& .\" Source: \ \& .\" Language: English .\" -.TH "XGETDEVICEKEYMAPPING" "libmansuffix" "09/15/2021" "\ \&" "\ \&" +.TH "XGETDEVICEKEYMAPPING" "libmansuffix" "05/04/2023" "\ \&" "\ \&" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- Index: xsrc/external/mit/libXpm/dist/src/create.c diff -u xsrc/external/mit/libXpm/dist/src/create.c:1.5 xsrc/external/mit/libXpm/dist/src/create.c:1.6 --- xsrc/external/mit/libXpm/dist/src/create.c:1.5 Thu Jan 19 05:18:00 2023 +++ xsrc/external/mit/libXpm/dist/src/create.c Mon Jun 19 06:44:23 2023 @@ -2392,8 +2392,8 @@ ParseAndPutPixels( { /* free all allocated pointers at all exits */ -#define FREE_CIDX {int f; for (f = 0; f < 256; f++) \ -if (cidx[f]) XpmFree(cidx[f]);} +#define FREE_CIDX do {int f; for (f = 0; f < 256; f++) \ +if (cidx[f]) XpmFree(cidx[f]);} while(0) /* array of pointers malloced by need */ unsigned short *cidx[256]; Index: xsrc/external/mit/libXt/dist/compile diff -u xsrc/external/mit/libXt/dist/compile:1.5 xsrc/external/mit/libXt/dist/compile:1.6 --- xsrc/external/mit/libXt/dist/compile:1.5 Mon Apr 26 21:25:13 2021 +++ xsrc/external/mit/libXt/dist/compile Mon Jun 19 06:44:23 2023 @@ -3,7 +3,7 @@ scriptversion=2018-03-07.03; # UTC -# Copyright (C) 1999-2020 Free Software Foundation, Inc. +# Copyright (C) 1999-2021 Free Software Foundation, Inc. # Written by Tom Tromey <tro...@cygnus.com>. # # This program is free software; you can redistribute it and/or modify Index: xsrc/external/mit/libXt/dist/m4/libtool.m4 diff -u xsrc/external/mit/libXt/dist/m4/libtool.m4:1.4 xsrc/external/mit/libXt/dist/m4/libtool.m4:1.5 --- xsrc/external/mit/libXt/dist/m4/libtool.m4:1.4 Mon Apr 26 21:25:13 2021 +++ xsrc/external/mit/libXt/dist/m4/libtool.m4 Mon Jun 19 06:44:23 2023 @@ -1,6 +1,7 @@ # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- # -# Copyright (C) 1996-2001, 2003-2015 Free Software Foundation, Inc. +# Copyright (C) 1996-2001, 2003-2019, 2021-2022 Free Software +# Foundation, Inc. # Written by Gordon Matzigkeit, 1996 # # This file is free software; the Free Software Foundation gives @@ -31,7 +32,7 @@ m4_define([_LT_COPYING], [dnl # along with this program. If not, see <http://www.gnu.org/licenses/>. ]) -# serial 58 LT_INIT +# serial 59 LT_INIT # LT_PREREQ(VERSION) @@ -181,6 +182,7 @@ m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_CHECK_SHELL_FEATURES])dnl m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl m4_require([_LT_CMD_RELOAD])dnl +m4_require([_LT_DECL_FILECMD])dnl m4_require([_LT_CHECK_MAGIC_METHOD])dnl m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl m4_require([_LT_CMD_OLD_ARCHIVE])dnl @@ -219,8 +221,8 @@ esac ofile=libtool can_build_shared=yes -# All known linkers require a '.a' archive for static linking (except MSVC, -# which needs '.lib'). +# All known linkers require a '.a' archive for static linking (except MSVC and +# ICC, which need '.lib'). libext=a with_gnu_ld=$lt_cv_prog_gnu_ld @@ -778,7 +780,7 @@ _LT_EOF # if finds mixed CR/LF and LF-only lines. Since sed operates in # text mode, it properly converts lines to CR/LF. This bash problem # is reportedly fixed, but why not run on old versions too? - sed '$q' "$ltmain" >> "$cfgfile" \ + $SED '$q' "$ltmain" >> "$cfgfile" \ || (rm -f "$cfgfile"; exit 1) mv -f "$cfgfile" "$ofile" || @@ -1042,8 +1044,8 @@ int forced_loaded() { return 2;} _LT_EOF echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD - echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD - $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD + echo "$AR $AR_FLAGS libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD + $AR $AR_FLAGS libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD cat > conftest.c << _LT_EOF @@ -1067,17 +1069,12 @@ _LT_EOF _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; darwin1.*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; - darwin*) # darwin 5.x on - # if running on 10.5 or later, the deployment target defaults - # to the OS version, if on x86, and 10.4, the deployment - # target defaults to 10.4. Don't you love it? - case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in - 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) - _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; - 10.[[012]][[,.]]*) - _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; - 10.*) - _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; + darwin*) + case $MACOSX_DEPLOYMENT_TARGET,$host in + 10.[[012]],*|,*powerpc*-darwin[[5-8]]*) + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; + *) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; esac ;; esac @@ -1126,12 +1123,12 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES], output_verbose_link_cmd=func_echo_all _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" - _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" - _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" + _LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" + _LT_TAGVAR(module_expsym_cmds, $1)="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" m4_if([$1], [CXX], [ if test yes != "$lt_cv_apple_cc_single_mod"; then _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" - _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" + _LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" fi ],[]) else @@ -1245,7 +1242,8 @@ _LT_DECL([], [ECHO], [1], [An echo progr # _LT_WITH_SYSROOT # ---------------- AC_DEFUN([_LT_WITH_SYSROOT], -[AC_MSG_CHECKING([for sysroot]) +[m4_require([_LT_DECL_SED])dnl +AC_MSG_CHECKING([for sysroot]) AC_ARG_WITH([sysroot], [AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@], [Search for dependent libraries within DIR (or the compiler's sysroot @@ -1262,7 +1260,7 @@ case $with_sysroot in #( fi ;; #( /*) - lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"` ;; #( no|'') ;; #( @@ -1292,7 +1290,7 @@ ia64-*-hpux*) # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE=32 ;; @@ -1309,7 +1307,7 @@ ia64-*-hpux*) echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then if test yes = "$lt_cv_prog_gnu_ld"; then - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" ;; @@ -1321,7 +1319,7 @@ ia64-*-hpux*) ;; esac else - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -32" ;; @@ -1343,7 +1341,7 @@ mips64*-*linux*) echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then emul=elf - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *32-bit*) emul="${emul}32" ;; @@ -1351,7 +1349,7 @@ mips64*-*linux*) emul="${emul}64" ;; esac - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *MSB*) emul="${emul}btsmip" ;; @@ -1359,7 +1357,7 @@ mips64*-*linux*) emul="${emul}ltsmip" ;; esac - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *N32*) emul="${emul}n32" ;; @@ -1379,14 +1377,14 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux* # not appear in the list. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.o` in + case `$FILECMD conftest.o` in *32-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_i386_fbsd" ;; x86_64-*linux*) - case `/usr/bin/file conftest.o` in + case `$FILECMD conftest.o` in *x86-64*) LD="${LD-ld} -m elf32_x86_64" ;; @@ -1417,10 +1415,10 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux* x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; - powerpcle-*linux*|powerpc64le-*linux*) + powerpcle-*linux*) LD="${LD-ld} -m elf64lppc" ;; - powerpc-*linux*|powerpc64-*linux*) + powerpc-*linux*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*|s390*-*tpf*) @@ -1454,7 +1452,7 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux* # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.o` in + case `$FILECMD conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in yes*) @@ -1493,9 +1491,22 @@ need_locks=$enable_libtool_lock m4_defun([_LT_PROG_AR], [AC_CHECK_TOOLS(AR, [ar], false) : ${AR=ar} -: ${AR_FLAGS=cru} _LT_DECL([], [AR], [1], [The archiver]) -_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) + +# Use ARFLAGS variable as AR's operation code to sync the variable naming with +# Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have +# higher priority because thats what people were doing historically (setting +# ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS +# variable obsoleted/removed. + +test ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr} +lt_ar_flags=$AR_FLAGS +_LT_DECL([], [lt_ar_flags], [0], [Flags to create an archive (by configure)]) + +# Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override +# by AR_FLAGS because that was never working and AR_FLAGS is about to die. +_LT_DECL([], [AR_FLAGS], [\@S|@{ARFLAGS-"\@S|@lt_ar_flags"}], + [Flags to create an archive]) AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], [lt_cv_ar_at_file=no @@ -1708,18 +1719,13 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [d lt_cv_sys_max_cmd_len=8192; ;; - mint*) - # On MiNT this can take a long time and run out of memory. - lt_cv_sys_max_cmd_len=8192; - ;; - amigaos*) # On AmigaOS with pdksh, this test takes hours, literally. # So we just punt and use a minimum line length of 8192. lt_cv_sys_max_cmd_len=8192; ;; - bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*) + bitrig* | darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` @@ -1762,7 +1768,7 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [d sysv5* | sco5v6* | sysv4.2uw2*) kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` if test -n "$kargmax"; then - lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` + lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[[ ]]//'` else lt_cv_sys_max_cmd_len=32768 fi @@ -2212,26 +2218,35 @@ m4_defun([_LT_CMD_STRIPLIB], striplib= old_striplib= AC_MSG_CHECKING([whether stripping libraries is possible]) -if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - AC_MSG_RESULT([yes]) +if test -z "$STRIP"; then + AC_MSG_RESULT([no]) else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP"; then + if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then + old_striplib="$STRIP --strip-debug" + striplib="$STRIP --strip-unneeded" + AC_MSG_RESULT([yes]) + else + case $host_os in + darwin*) + # FIXME - insert some real tests, host_os isn't really good enough striplib="$STRIP -x" old_striplib="$STRIP -S" AC_MSG_RESULT([yes]) - else + ;; + freebsd*) + if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then + old_striplib="$STRIP --strip-debug" + striplib="$STRIP --strip-unneeded" + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + fi + ;; + *) AC_MSG_RESULT([no]) - fi - ;; - *) - AC_MSG_RESULT([no]) - ;; - esac + ;; + esac + fi fi _LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) _LT_DECL([], [striplib], [1]) @@ -2554,7 +2569,7 @@ cygwin* | mingw* | pw32* | cegcc*) case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' + soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' m4_if([$1], [],[ sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) ;; @@ -2564,14 +2579,14 @@ m4_if([$1], [],[ ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' + library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' ;; - *,cl*) - # Native MSVC + *,cl* | *,icl*) + # Native MSVC or ICC libname_spec='$name' soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' library_names_spec='$libname.dll.lib' @@ -2590,7 +2605,7 @@ m4_if([$1], [],[ done IFS=$lt_save_ifs # Convert to MSYS style. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` ;; cygwin*) # Convert to unix form, then to dos form, then back to unix form @@ -2627,7 +2642,7 @@ m4_if([$1], [],[ ;; *) - # Assume MSVC wrapper + # Assume MSVC and ICC wrapper library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; @@ -2641,11 +2656,11 @@ darwin* | rhapsody*) version_type=darwin need_lib_prefix=no need_version=no - library_names_spec='$libname$release$versuffix$shared_ext $libname$release$major$shared_ext $libname$shared_ext' + library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' soname_spec='$libname$release$major$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .bundle || echo .dylib`' + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' m4_if([$1], [],[ sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' @@ -2660,7 +2675,7 @@ dgux*) shlibpath_var=LD_LIBRARY_PATH ;; -freebsd* | dragonfly*) +freebsd* | dragonfly* | midnightbsd*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then @@ -2671,14 +2686,7 @@ freebsd* | dragonfly*) *) objformat=elf ;; esac fi - # Handle Gentoo/FreeBSD as it was Linux - case $host_vendor in - gentoo) - version_type=linux ;; - *) - version_type=freebsd-$objformat ;; - esac - + version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' @@ -2690,12 +2698,6 @@ freebsd* | dragonfly*) library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' need_version=yes ;; - linux) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - need_lib_prefix=no - need_version=no - ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in @@ -3472,7 +3474,7 @@ beos*) bsdi[[45]]*) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' - lt_cv_file_magic_cmd='/usr/bin/file -L' + lt_cv_file_magic_cmd='$FILECMD -L' lt_cv_file_magic_test_file=/shlib/libc.so ;; @@ -3506,14 +3508,14 @@ darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; -freebsd* | dragonfly*) +freebsd* | dragonfly* | midnightbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then case $host_cpu in i*86 ) # Not sure whether the presence of OpenBSD here was a mistake. # Let's accept both of them until this is cleared up. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac @@ -3527,7 +3529,7 @@ haiku*) ;; hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_cmd=$FILECMD case $host_cpu in ia64*) lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' @@ -3574,7 +3576,7 @@ netbsd*) newos6*) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; @@ -3701,13 +3703,13 @@ else mingw*) lt_bad_file=conftest.nm/nofile ;; *) lt_bad_file=/dev/null ;; esac - case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in + case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in *$lt_bad_file* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" break 2 ;; *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" break 2 @@ -3733,7 +3735,7 @@ else # Let the user override the test. else AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) - case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in + case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in *COFF*) DUMPBIN="$DUMPBIN -symbols -headers" ;; @@ -3973,7 +3975,7 @@ esac if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Gets list of data symbols to import. - lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'" + lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'" # Adjust the below global symbol transforms to fixup imported variables. lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" @@ -3991,20 +3993,20 @@ fi # Transform an extracted symbol line into a proper C declaration. # Some systems (esp. on ia64) link data and code symbols differently, # so use this general approach. -lt_cv_sys_global_symbol_to_cdecl="sed -n"\ +lt_cv_sys_global_symbol_to_cdecl="$SED -n"\ $lt_cdecl_hook\ " -e 's/^T .* \(.*\)$/extern int \1();/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" # Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n"\ +lt_cv_sys_global_symbol_to_c_name_address="$SED -n"\ $lt_c_name_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" # Transform an extracted symbol line into symbol name with lib prefix and # symbol address. -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\ +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\ $lt_c_name_lib_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ @@ -4028,7 +4030,7 @@ for ac_symprfx in "" "_"; do if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Fake it for dumpbin and say T for any non-static function, # D for any global variable and I for any imported variable. - # Also find C++ and __fastcall symbols from MSVC++, + # Also find C++ and __fastcall symbols from MSVC++ or ICC, # which start with @ or ?. lt_cv_sys_global_symbol_pipe="$AWK ['"\ " {last_section=section; section=\$ 3};"\ @@ -4046,9 +4048,9 @@ for ac_symprfx in "" "_"; do " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ " ' prfx=^$ac_symprfx]" else - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" + lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" fi - lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'" # Check to see that the pipe works correctly. pipe_works=no @@ -4335,7 +4337,7 @@ m4_if([$1], [CXX], [ ;; esac ;; - freebsd* | dragonfly*) + freebsd* | dragonfly* | midnightbsd*) # FreeBSD uses GNU C++ ;; hpux9* | hpux10* | hpux11*) @@ -4418,7 +4420,7 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' ;; *) - case `$CC -V 2>&1 | sed 5q` in + case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' @@ -4754,7 +4756,7 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' ;; *) - case `$CC -V 2>&1 | sed 5q` in + case `$CC -V 2>&1 | $SED 5q` in *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) # Sun Fortran 8.3 passes all unrecognized flags to the linker _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' @@ -4937,7 +4939,7 @@ m4_if([$1], [CXX], [ if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else - _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' + _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi ;; pw32*) @@ -4945,7 +4947,7 @@ m4_if([$1], [CXX], [ ;; cygwin* | mingw* | cegcc*) case $cc_basename in - cl*) + cl* | icl*) _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' ;; *) @@ -5002,15 +5004,15 @@ dnl Note also adjust exclude_expsyms for case $host_os in cygwin* | mingw* | pw32* | cegcc*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time + # FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. + # Microsoft Visual C++ or Intel C++ Compiler. if test yes != "$GCC"; then with_gnu_ld=no fi ;; interix*) - # we just hope/assume this is gcc and not c89 (= MSVC++) + # we just hope/assume this is gcc and not c89 (= MSVC++ or ICC) with_gnu_ld=yes ;; openbsd* | bitrig*) @@ -5062,7 +5064,7 @@ dnl Note also adjust exclude_expsyms for _LT_TAGVAR(whole_archive_flag_spec, $1)= fi supports_anon_versioning=no - case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in + case `$LD -v | $SED -e 's/([[^)]]\+)\s\+//' 2>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... @@ -5174,6 +5176,7 @@ _LT_EOF emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' ;; interix[[3-9]]*) @@ -5188,7 +5191,7 @@ _LT_EOF # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) @@ -5231,7 +5234,7 @@ _LT_EOF _LT_TAGVAR(compiler_needs_object, $1)=yes ;; esac - case `$CC -V 2>&1 | sed 5q` in + case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C 5.9 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes @@ -5243,7 +5246,7 @@ _LT_EOF if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi @@ -5259,7 +5262,7 @@ _LT_EOF _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi @@ -5391,7 +5394,7 @@ _LT_EOF if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else - _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' + _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no @@ -5574,12 +5577,12 @@ _LT_EOF cygwin* | mingw* | pw32* | cegcc*) # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. + # Microsoft Visual C++ or Intel C++ Compiler. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. case $cc_basename in - cl*) - # Native MSVC + cl* | icl*) + # Native MSVC or ICC _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=yes @@ -5620,7 +5623,7 @@ _LT_EOF fi' ;; *) - # Assume MSVC wrapper + # Assume MSVC and ICC wrapper _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Tell ltmain to make .lib files, not .a files. @@ -5668,7 +5671,7 @@ _LT_EOF ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | dragonfly*) + freebsd* | dragonfly* | midnightbsd*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes @@ -5879,6 +5882,7 @@ _LT_EOF emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' ;; osf3*) @@ -6649,8 +6653,8 @@ if test yes != "$_lt_caught_CXX_error"; cygwin* | mingw* | pw32* | cegcc*) case $GXX,$cc_basename in - ,cl* | no,cl*) - # Native MSVC + ,cl* | no,cl* | ,icl* | no,icl*) + # Native MSVC or ICC # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' @@ -6748,6 +6752,7 @@ if test yes != "$_lt_caught_CXX_error"; emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' ;; dgux*) @@ -6778,7 +6783,7 @@ if test yes != "$_lt_caught_CXX_error"; _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; - freebsd* | dragonfly*) + freebsd* | dragonfly* | midnightbsd*) # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF # conventions _LT_TAGVAR(ld_shlibs, $1)=yes @@ -6915,7 +6920,7 @@ if test yes != "$_lt_caught_CXX_error"; # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; irix5* | irix6*) case $cc_basename in @@ -7055,13 +7060,13 @@ if test yes != "$_lt_caught_CXX_error"; _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi ;; *) - case `$CC -V 2>&1 | sed 5q` in + case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' @@ -8207,6 +8212,14 @@ _LT_DECL([], [DLLTOOL], [1], [DLL creati AC_SUBST([DLLTOOL]) ]) +# _LT_DECL_FILECMD +# ---------------- +# Check for a file(cmd) program that can be used to detect file type and magic +m4_defun([_LT_DECL_FILECMD], +[AC_CHECK_TOOL([FILECMD], [file], [:]) +_LT_DECL([], [FILECMD], [1], [A file(cmd) program that detects file types]) +])# _LD_DECL_FILECMD + # _LT_DECL_SED # ------------ # Check for a fully-functional sed program, that truncates Index: xsrc/external/mit/libXt/dist/m4/ltoptions.m4 diff -u xsrc/external/mit/libXt/dist/m4/ltoptions.m4:1.3 xsrc/external/mit/libXt/dist/m4/ltoptions.m4:1.4 --- xsrc/external/mit/libXt/dist/m4/ltoptions.m4:1.3 Thu Jul 11 05:43:50 2019 +++ xsrc/external/mit/libXt/dist/m4/ltoptions.m4 Mon Jun 19 06:44:23 2023 @@ -1,7 +1,7 @@ # Helper functions for option handling. -*- Autoconf -*- # -# Copyright (C) 2004-2005, 2007-2009, 2011-2015 Free Software -# Foundation, Inc. +# Copyright (C) 2004-2005, 2007-2009, 2011-2019, 2021-2022 Free +# Software Foundation, Inc. # Written by Gary V. Vaughan, 2004 # # This file is free software; the Free Software Foundation gives Index: xsrc/external/mit/libXt/dist/m4/ltsugar.m4 diff -u xsrc/external/mit/libXt/dist/m4/ltsugar.m4:1.3 xsrc/external/mit/libXt/dist/m4/ltsugar.m4:1.4 --- xsrc/external/mit/libXt/dist/m4/ltsugar.m4:1.3 Thu Jul 11 05:43:50 2019 +++ xsrc/external/mit/libXt/dist/m4/ltsugar.m4 Mon Jun 19 06:44:23 2023 @@ -1,6 +1,6 @@ # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- # -# Copyright (C) 2004-2005, 2007-2008, 2011-2015 Free Software +# Copyright (C) 2004-2005, 2007-2008, 2011-2019, 2021-2022 Free Software # Foundation, Inc. # Written by Gary V. Vaughan, 2004 # Index: xsrc/external/mit/libXt/dist/m4/ltversion.m4 diff -u xsrc/external/mit/libXt/dist/m4/ltversion.m4:1.3 xsrc/external/mit/libXt/dist/m4/ltversion.m4:1.4 --- xsrc/external/mit/libXt/dist/m4/ltversion.m4:1.3 Thu Jul 11 05:43:50 2019 +++ xsrc/external/mit/libXt/dist/m4/ltversion.m4 Mon Jun 19 06:44:23 2023 @@ -1,6 +1,7 @@ # ltversion.m4 -- version numbers -*- Autoconf -*- # -# Copyright (C) 2004, 2011-2015 Free Software Foundation, Inc. +# Copyright (C) 2004, 2011-2019, 2021-2022 Free Software Foundation, +# Inc. # Written by Scott James Remnant, 2004 # # This file is free software; the Free Software Foundation gives @@ -9,15 +10,15 @@ # @configure_input@ -# serial 4179 ltversion.m4 +# serial 4245 ltversion.m4 # This file is part of GNU Libtool -m4_define([LT_PACKAGE_VERSION], [2.4.6]) -m4_define([LT_PACKAGE_REVISION], [2.4.6]) +m4_define([LT_PACKAGE_VERSION], [2.4.7]) +m4_define([LT_PACKAGE_REVISION], [2.4.7]) AC_DEFUN([LTVERSION_VERSION], -[macro_version='2.4.6' -macro_revision='2.4.6' +[macro_version='2.4.7' +macro_revision='2.4.7' _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) _LT_DECL(, macro_revision, 0) ]) Index: xsrc/external/mit/libXt/dist/m4/lt~obsolete.m4 diff -u xsrc/external/mit/libXt/dist/m4/lt~obsolete.m4:1.3 xsrc/external/mit/libXt/dist/m4/lt~obsolete.m4:1.4 --- xsrc/external/mit/libXt/dist/m4/lt~obsolete.m4:1.3 Thu Jul 11 05:43:50 2019 +++ xsrc/external/mit/libXt/dist/m4/lt~obsolete.m4 Mon Jun 19 06:44:23 2023 @@ -1,7 +1,7 @@ # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- # -# Copyright (C) 2004-2005, 2007, 2009, 2011-2015 Free Software -# Foundation, Inc. +# Copyright (C) 2004-2005, 2007, 2009, 2011-2019, 2021-2022 Free +# Software Foundation, Inc. # Written by Scott James Remnant, 2004. # # This file is free software; the Free Software Foundation gives Index: xsrc/external/mit/libXt/dist/src/Convert.c diff -u xsrc/external/mit/libXt/dist/src/Convert.c:1.4 xsrc/external/mit/libXt/dist/src/Convert.c:1.5 --- xsrc/external/mit/libXt/dist/src/Convert.c:1.4 Mon Apr 26 21:25:13 2021 +++ xsrc/external/mit/libXt/dist/src/Convert.c Mon Jun 19 06:44:23 2023 @@ -1,5 +1,5 @@ /*********************************************************** -Copyright (c) 1993, Oracle and/or its affiliates. All rights reserved. +Copyright (c) 1993, Oracle and/or its affiliates. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), @@ -403,7 +403,7 @@ CacheEnter(Heap *heap, else { p->from_is_value = False; p->from.addr = (XPointer) _XtHeapAlloc(heap, from->size); - (void) memmove((char *) p->from.addr, (char *) from->addr, from->size); + (void) memcpy(p->from.addr, (char *) from->addr, from->size); } p->num_args = (unsigned short) num_args; if (num_args && args) { @@ -428,7 +428,7 @@ CacheEnter(Heap *heap, else { p->to_is_value = False; p->to.addr = (XPointer) _XtHeapAlloc(heap, to->size); - (void) memmove((char *) p->to.addr, (char *) to->addr, to->size); + (void) memcpy(p->to.addr, (char *) to->addr, to->size); } UNLOCK_PROCESS; return p; @@ -608,8 +608,8 @@ ComputeArgs(Widget widget, /* Convert in place for next usage */ convert_args[i].address_mode = XtResourceQuark; convert_args[i].address_id = - (XtPointer) (long) XrmStringToQuark((String) convert_args[i]. - address_id); + (XtPointer) (XtIntPtr) XrmStringToQuark((String) convert_args[i]. + address_id); /* Fall through */ case XtResourceQuark: @@ -698,7 +698,7 @@ XtDirectConvert(XtConverter converter, (*to).addr = NULL; (*converter) (args, &num_args, from, to); /* This memory can never be freed since we don't know the Display - * or app context from which to compute the persistance */ + * or app context from which to compute the persistence */ { CacheEnter(&globalHeap, (XtTypeConverter) converter, args, num_args, from, to, (to->addr != NULL), hash, False, False, Index: xsrc/external/mit/libXt/dist/src/NextEvent.c diff -u xsrc/external/mit/libXt/dist/src/NextEvent.c:1.8 xsrc/external/mit/libXt/dist/src/NextEvent.c:1.9 --- xsrc/external/mit/libXt/dist/src/NextEvent.c:1.8 Mon Apr 26 21:25:13 2021 +++ xsrc/external/mit/libXt/dist/src/NextEvent.c Mon Jun 19 06:44:24 2023 @@ -1,5 +1,5 @@ /*********************************************************** -Copyright (c) 1993, Oracle and/or its affiliates. All rights reserved. +Copyright (c) 1993, Oracle and/or its affiliates. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), @@ -144,7 +144,7 @@ static SignalEventRec *freeSignalRecs; #endif static void -AdjustHowLong(unsigned long *howlong, struct timeval *start_time) +AdjustHowLong(unsigned long *howlong, const struct timeval *start_time) { struct timeval new_time, time_spent, lstart_time; @@ -280,10 +280,8 @@ InitFds(XtAppContext app, wf->stack); } else { - wf->fdlist = (struct pollfd *) - XtRealloc((char *) wf->fdlist, - (Cardinal) (sizeof(struct pollfd) * - (size_t) wf->fdlistlen)); + wf->fdlist = XtReallocArray(wf->fdlist, (Cardinal) wf->fdlistlen, + (Cardinal) sizeof(struct pollfd)); } if (wf->fdlistlen) { @@ -332,7 +330,7 @@ InitFds(XtAppContext app, static void AdjustTimes(XtAppContext app, Boolean block, - unsigned long *howlong, + const unsigned long *howlong, Boolean ignoreTimers, wait_times_ptr_t wt) { @@ -601,7 +599,7 @@ _XtWaitForSomething(XtAppContext app, if (app->lock == (ThreadAppProc) NULL) drop_lock = FALSE; #else - drop_lock = drop_lock; /* avoid unsed warning */ + (void) drop_lock; /* avoid unused warning */ #endif InitTimes((Boolean) block, howlong, &wt); @@ -649,14 +647,14 @@ _XtWaitForSomething(XtAppContext app, nfds = IoWait(&wt, &wf); if (nfds == -1) { /* - * interrupt occured recalculate time value and wait again. + * interrupt occurred recalculate time value and wait again. */ if (errno == EINTR || errno == EAGAIN) { if (errno == EAGAIN) { - errno = 0; /* errno is not self reseting */ + errno = 0; /* errno is not self resetting */ continue; } - errno = 0; /* errno is not self reseting */ + errno = 0; /* errno is not self resetting */ /* was it interrupted by a signal that we care about? */ if (!ignoreSignals && app->signalQueue != NULL) { @@ -1002,7 +1000,7 @@ XtNoticeSignal(XtSignalId id) * * Lastly, and perhaps most importantly, since POSIX threads * says that the handling of asynchronous signals in a synchronous - * threads environment is undefined. Therefor it would be an + * threads environment is undefined. Therefore it would be an * error for both signals and threads to be in use in the same * program. */ @@ -1043,11 +1041,8 @@ XtAppAddInput(XtAppContext app, Cardinal n = (Cardinal) (source + 1); int ii; - app->input_list = (InputEvent **) XtRealloc((char *) app->input_list, - (Cardinal) ((size_t) n * - sizeof - (InputEvent - *))); + app->input_list = XtReallocArray(app->input_list, n, + (Cardinal) sizeof(InputEvent *)); for (ii = app->input_max; ii < (int) n; ii++) app->input_list[ii] = (InputEvent *) NULL; app->input_max = (short) n; Index: xsrc/external/mit/libXt/dist/src/TMparse.c diff -u xsrc/external/mit/libXt/dist/src/TMparse.c:1.8 xsrc/external/mit/libXt/dist/src/TMparse.c:1.9 --- xsrc/external/mit/libXt/dist/src/TMparse.c:1.8 Mon Apr 26 21:25:13 2021 +++ xsrc/external/mit/libXt/dist/src/TMparse.c Mon Jun 19 06:44:24 2023 @@ -1,5 +1,5 @@ /*********************************************************** -Copyright (c) 1993, Oracle and/or its affiliates. All rights reserved. +Copyright (c) 1993, Oracle and/or its affiliates. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), @@ -167,15 +167,6 @@ static ModifierRec modifiers[] = { {"l", 0, ParseModImmed, LockMask}, }; -static NameValueRec buttonNames[] = { - {"Button1", 0, Button1}, - {"Button2", 0, Button2}, - {"Button3", 0, Button3}, - {"Button4", 0, Button4}, - {"Button5", 0, Button5}, - {NULL, NULLQUARK, 0}, -}; - static NameValueRec motionDetails[] = { {"Normal", 0, NotifyNormal}, {"Hint", 0, NotifyHint}, @@ -234,6 +225,7 @@ static NameValueRec mappingNotify[] = { static String ParseKeySym(PARSE_PROC_DECL); static String ParseKeyAndModifiers(PARSE_PROC_DECL); static String ParseTable(PARSE_PROC_DECL); +static String ParseButton(PARSE_PROC_DECL); static String ParseImmed(PARSE_PROC_DECL); static String ParseAddModifier(PARSE_PROC_DECL); static String ParseNone(PARSE_PROC_DECL); @@ -253,8 +245,8 @@ static EventKey events[] = { {"KeyUp", NULLQUARK, KeyRelease, ParseKeySym, NULL}, {"KeyRelease", NULLQUARK, KeyRelease, ParseKeySym, NULL}, -{"ButtonPress", NULLQUARK, ButtonPress, ParseTable, (Opaque)buttonNames}, -{"BtnDown", NULLQUARK, ButtonPress, ParseTable, (Opaque)buttonNames}, +{"ButtonPress", NULLQUARK, ButtonPress, ParseButton, NULL }, +{"BtnDown", NULLQUARK, ButtonPress, ParseButton, NULL }, {"Btn1Down", NULLQUARK, ButtonPress, ParseImmed, (Opaque)Button1}, {"Btn2Down", NULLQUARK, ButtonPress, ParseImmed, (Opaque)Button2}, {"Btn3Down", NULLQUARK, ButtonPress, ParseImmed, (Opaque)Button3}, @@ -263,8 +255,8 @@ static EventKey events[] = { /* Event Name, Quark, Event Type, Detail Parser, Closure */ -{"ButtonRelease", NULLQUARK, ButtonRelease, ParseTable, (Opaque)buttonNames}, -{"BtnUp", NULLQUARK, ButtonRelease, ParseTable, (Opaque)buttonNames}, +{"ButtonRelease", NULLQUARK, ButtonRelease, ParseButton, NULL }, +{"BtnUp", NULLQUARK, ButtonRelease, ParseButton, NULL }, {"Btn1Up", NULLQUARK, ButtonRelease, ParseImmed, (Opaque)Button1}, {"Btn2Up", NULLQUARK, ButtonRelease, ParseImmed, (Opaque)Button2}, {"Btn3Up", NULLQUARK, ButtonRelease, ParseImmed, (Opaque)Button3}, @@ -561,10 +553,8 @@ StoreLateBindings(KeySym keysymL, pair = TRUE; } - temp = (LateBindingsPtr) XtRealloc((char *) temp, - (unsigned) ((count + number + - 1) * - sizeof(LateBindings))); + temp = XtReallocArray(temp, (Cardinal) (count + number + 1), + (Cardinal) sizeof(LateBindings)); *lateBindings = temp; XtSetBit(temp[count].knot, notL); XtSetBit(temp[count].pair, pair); @@ -681,7 +671,7 @@ FetchModifierToken(String str, XrmQuark modStr = XtStackAlloc((size_t) (str - start + 1), modStrbuf); if (modStr == NULL) _XtAllocError(NULL); - (void) memmove(modStr, start, (size_t) (str - start)); + (void) memcpy(modStr, start, (size_t) (str - start)); modStr[str - start] = '\0'; *token_return = XrmStringToQuark(modStr); XtStackFree(modStr, modStrbuf); @@ -709,7 +699,7 @@ ParseModifiers(register String str, Even ScanWhitespace(str); return str; } - else if (Qmod == QAny) { /*backward compatability */ + else if (Qmod == QAny) { /*backward compatibility */ event->event.modifierMask = 0; event->event.modifiers = AnyModifier; ScanWhitespace(str); @@ -792,7 +782,7 @@ ParseXtEventType(register String str, eventTypeStr = XtStackAlloc((size_t) (str - start + 1), eventTypeStrbuf); if (eventTypeStr == NULL) _XtAllocError(NULL); - (void) memmove(eventTypeStr, start, (size_t) (str - start)); + (void) memcpy(eventTypeStr, start, (size_t) (str - start)); eventTypeStr[str - start] = '\0'; *tmEventP = LookupTMEventType(eventTypeStr, error); XtStackFree(eventTypeStr, eventTypeStrbuf); @@ -1011,6 +1001,7 @@ ParseKeySym(register String str, */ (*str == '(' && *(str + 1) >= '0' && *(str + 1) <= '9')) { keySymName = keySymNamebuf; /* just so we can stackfree it later */ + keySymName[0] = '\0'; /* no detail */ event->event.eventCode = 0L; event->event.eventCodeMask = 0L; @@ -1023,7 +1014,7 @@ ParseKeySym(register String str, && *str != '\0') str++; keySymName = XtStackAlloc((size_t) (str - start + 1), keySymNamebuf); - (void) memmove(keySymName, start, (size_t) (str - start)); + (void) memcpy(keySymName, start, (size_t) (str - start)); keySymName[str - start] = '\0'; event->event.eventCode = StringToKeySym(keySymName, error); event->event.eventCodeMask = (unsigned long) (~0L); @@ -1069,7 +1060,7 @@ ParseTable(register String str, Opaque c *error = TRUE; return str; } - (void) memmove(tableSymName, start, (size_t) (str - start)); + (void) memcpy(tableSymName, start, (size_t) (str - start)); tableSymName[str - start] = '\0'; signature = StringToQuark(tableSymName); for (; table->signature != NULLQUARK; table++) @@ -1085,6 +1076,47 @@ ParseTable(register String str, Opaque c } static String +ParseButton(String str, Opaque closure, EventPtr event, Boolean *error) +{ + String start = str; + char buttonStr[7]; + size_t len; + static const char buttonPrefix[] = "Button"; + unsigned long button; + + event->event.eventCode = 0L; + if (strncmp(str, buttonPrefix, sizeof(buttonPrefix)-1) != 0) { + event->event.eventCodeMask = 0L; + return str; + } + str += sizeof(buttonPrefix)-1; + start = str; + ScanNumeric(str); + if (str == start) { + Syntax("Missing button number", ""); + *error = TRUE; + return PanicModeRecovery(str); + } + len = (size_t) (str - start); + if (len >= sizeof buttonStr) { + Syntax("Button number too long", ""); + *error = TRUE; + return PanicModeRecovery(str); + } + (void) memcpy(buttonStr, start, len); + buttonStr[len] = '\0'; + button = StrToNum(buttonStr); + if (button < 1 || 255 < button) { + Syntax("Invalid button number", buttonStr); + *error = TRUE; + return PanicModeRecovery(str); + } + event->event.eventCode = button; + event->event.eventCodeMask = (unsigned long) (~0L); + return str; +} + +static String ParseNone(String str, Opaque closure _X_UNUSED, EventPtr event, @@ -1120,7 +1152,7 @@ ParseAtom(String str, Opaque closure _X_ *error = TRUE; return str; } - (void) memmove(atomName, start, (size_t) (str - start)); + (void) memcpy(atomName, start, (size_t) (str - start)); atomName[str - start] = '\0'; event->event.eventCode = (TMLongCard) XrmStringToQuark(atomName); event->event.matchEvent = _XtMatchAtom; @@ -1532,7 +1564,7 @@ ParseRepeat(register String str, int *re ScanNumeric(str); len = (size_t) (str - start); if (len < sizeof repStr) { - (void) memmove(repStr, start, len); + (void) memcpy(repStr, start, len); repStr[len] = '\0'; *reps = (int) StrToNum(repStr); } @@ -1672,7 +1704,7 @@ ParseActionProc(register String str, Xrm *error = TRUE; return str; } - (void) memmove(procName, start, (size_t) (str - start)); + (void) memcpy(procName, start, (size_t) (str - start)); procName[str - start] = '\0'; *actionProcNameP = XrmStringToQuark(procName); return str; @@ -1700,7 +1732,7 @@ ParseString(register String str, _XtStri (*(str + 1) == '\\' && *(str + 2) == '"'))) { len = (unsigned) (prev_len + (str - start + 2)); *strP = XtRealloc(*strP, len); - (void) memmove(*strP + prev_len, start, (size_t) (str - start)); + (void) memcpy(*strP + prev_len, start, (size_t) (str - start)); prev_len = len - 1; str++; (*strP)[prev_len - 1] = *str; @@ -1711,7 +1743,7 @@ ParseString(register String str, _XtStri } len = (unsigned) (prev_len + (str - start + 1)); *strP = XtRealloc(*strP, len); - (void) memmove(*strP + prev_len, start, (size_t) (str - start)); + (void) memcpy(*strP + prev_len, start, (size_t) (str - start)); (*strP)[len - 1] = '\0'; if (*str == '"') str++; @@ -1728,7 +1760,7 @@ ParseString(register String str, _XtStri && *str != '\0') str++; *strP = __XtMalloc((unsigned) (str - start + 1)); - (void) memmove(*strP, start, (size_t) (str - start)); + (void) memcpy(*strP, start, (size_t) (str - start)); (*strP)[str - start] = '\0'; } return str; @@ -1771,8 +1803,7 @@ ParseParamSeq(register String str, Strin } if (num_params != 0) { - String *paramP = (String *) - __XtMalloc((Cardinal) ((num_params + 1) * sizeof(String))); + String *paramP = XtMallocArray(num_params + 1, (Cardinal)sizeof(String)); Cardinal i; *paramSeqP = paramP; @@ -1876,7 +1907,7 @@ ShowProduction(String currentProduction) production = XtStackAlloc(len + 1, productionbuf); if (production == NULL) _XtAllocError(NULL); - (void) memmove(production, currentProduction, len); + (void) memcpy(production, currentProduction, len); production[len] = '\0'; params[0] = production; @@ -1938,7 +1969,7 @@ CheckForPoundSign(String str, start = str; str = ScanIdent(str); len = MIN(19, (int) (str - start)); - (void) memmove(operation, start, (size_t) len); + (void) memcpy(operation, start, (size_t) len); operation[len] = '\0'; if (!strcmp(operation, "replace")) opType = XtTableReplace; @@ -2178,7 +2209,6 @@ _XtTranslateInitialize(void) Compile_XtEventTable(events, XtNumber(events)); Compile_XtModifierTable(modifiers, XtNumber(modifiers)); - CompileNameValueTable(buttonNames); CompileNameValueTable(notifyModes); CompileNameValueTable(motionDetails); #if 0 Index: xsrc/external/mit/libXt/dist/src/ResConfig.c diff -u xsrc/external/mit/libXt/dist/src/ResConfig.c:1.6 xsrc/external/mit/libXt/dist/src/ResConfig.c:1.7 --- xsrc/external/mit/libXt/dist/src/ResConfig.c:1.6 Mon Apr 26 21:25:13 2021 +++ xsrc/external/mit/libXt/dist/src/ResConfig.c Mon Jun 19 06:44:24 2023 @@ -288,7 +288,7 @@ _set_resource_values(Widget w, char *res * remainder the part of the resource string left over * resource the resource string to be matched * value the value to be set - * last_token the last * or . before the final resoruce part + * last_token the last * or . before the final resource part * last_part the last resource part (e.g. *background) * * RETURN VALUES: void @@ -347,7 +347,7 @@ _apply_values_to_children(Widget w, * remainder the remaining part of the resource string * resource the resource string to be matched * value the value to be applied - * last_token the last * or . before the final resoruce part + * last_token the last * or . before the final resource part * last_part the last resource part (e.g. *background) * * RETURN VALUES: none @@ -483,7 +483,7 @@ _match_resource_to_widget(Widget w, char * remainder the part of the resource string left over * resource the resource string to be matched * value the value to be set - * last_token the last * or . before the final resoruce part + * last_token the last * or . before the final resource part * last_part the last resource part (e.g. *background) * * RETURN VALUES: none @@ -620,7 +620,7 @@ _get_last_part(char *remainder, char **p *part = XtNewString(tight); return ('.'); } - if ((tight == NULL) || (loose && (strcoll(tight, loose) < 0))) { + if ((tight == NULL) || (strcoll(tight, loose) < 0)) { *loose++ = '\0'; *part = XtNewString(loose); return ('*'); @@ -665,10 +665,12 @@ _search_widget_tree(Widget w, char *reso Widget parent = w; char *last_part; char *remainder = NULL; - char last_token; char *loose, *tight; int loose_len, tight_len; + if (resource == NULL) + return; + /* * Find the root of the tree given any widget */ @@ -705,6 +707,8 @@ _search_widget_tree(Widget w, char *reso * etc.) */ if (remainder) { + char last_token; + last_token = _get_last_part(remainder, &last_part); /* * this case covers resources of only one level (eg. *background) @@ -777,8 +781,7 @@ _locate_children(Widget parent, Widget * return (0); } - *children = (Widget *) - XtMalloc((Cardinal) (sizeof(Widget) * (size_t) num_children)); + *children = XtMallocArray((Cardinal)num_children, (Cardinal)sizeof(Widget)); if (XtIsComposite(parent)) { for (i = 0; i < comp->composite.num_children; i++) { Index: xsrc/external/mit/libXt/dist/util/makestrs.c diff -u xsrc/external/mit/libXt/dist/util/makestrs.c:1.5 xsrc/external/mit/libXt/dist/util/makestrs.c:1.6 --- xsrc/external/mit/libXt/dist/util/makestrs.c:1.5 Mon Apr 26 21:25:13 2021 +++ xsrc/external/mit/libXt/dist/util/makestrs.c Mon Jun 19 06:44:24 2023 @@ -345,6 +345,7 @@ WriteSourceLine(TableEnt * te, int abi, { char *c; + (void) abi; for (c = te->right; *c; c++) (void) printf("'%c',", *c); (void) printf("%c", '0'); @@ -439,6 +440,7 @@ ArrayperWriteSource(int abi) File *phile; static int done_atom; + (void) abi; for (phile = file; phile; phile = phile->next) { Table *t; TableEnt *te; Index: xsrc/external/mit/xtrans/dist/Xtranssock.c diff -u xsrc/external/mit/xtrans/dist/Xtranssock.c:1.3 xsrc/external/mit/xtrans/dist/Xtranssock.c:1.4 --- xsrc/external/mit/xtrans/dist/Xtranssock.c:1.3 Mon Mar 18 04:27:54 2019 +++ xsrc/external/mit/xtrans/dist/Xtranssock.c Mon Jun 19 06:44:24 2023 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, Oracle and/or its affiliates. * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), @@ -141,7 +141,7 @@ from the copyright holders. /* others don't need this */ #define SocketInitOnce() /**/ -#ifdef linux +#ifdef __linux__ #define HAVE_ABSTRACT_SOCKETS #endif @@ -196,6 +196,20 @@ static Sockettrans2dev Sockettrans2devta static int TRANS(SocketINETClose) (XtransConnInfo ciptr); #endif +#if defined(TCPCONN) || defined(TRANS_REOPEN) +static int +is_numeric (const char *str) +{ + int i; + + for (i = 0; i < (int) strlen (str); i++) + if (!isdigit (str[i])) + return (0); + + return (1); +} +#endif + #ifdef UNIXCONN @@ -227,7 +241,7 @@ static int TRANS(SocketINETClose) (Xtran #if defined HAVE_SOCKLEN_T || (defined(IPv6) && defined(AF_INET6)) # define SOCKLEN_T socklen_t -#elif defined(SVR4) || defined(__SVR4) || defined(__SCO__) +#elif defined(SVR4) || defined(__SVR4) # define SOCKLEN_T size_t #else # define SOCKLEN_T int @@ -611,12 +625,19 @@ TRANS(SocketOpenCOTSServer) (Xtransport break; } if (i < 0) { - if (i == -1) - prmsg (1,"SocketOpenCOTSServer: Unable to open socket for %s\n", - thistrans->TransName); - else + if (i == -1) { + if (errno == EAFNOSUPPORT) { + thistrans->flags |= TRANS_NOLISTEN; + prmsg (1,"SocketOpenCOTSServer: Socket for %s unsupported on this system.\n", + thistrans->TransName); + } else { + prmsg (1,"SocketOpenCOTSServer: Unable to open socket for %s\n", + thistrans->TransName); + } + } else { prmsg (1,"SocketOpenCOTSServer: Unable to determine socket type for %s\n", thistrans->TransName); + } return NULL; } @@ -990,7 +1011,7 @@ TRANS(SocketUNIXCreateListener) (XtransC return TRANS_CREATE_LISTENER_FAILED; } -#if (defined(BSD44SOCKETS) || defined(__UNIXWARE__)) +#if defined(BSD44SOCKETS) sockname.sun_len = strlen(sockname.sun_path); #endif @@ -1068,7 +1089,7 @@ TRANS(SocketUNIXResetListener) (XtransCo if (!abstract && ( stat (unsock->sun_path, &statb) == -1 || ((statb.st_mode & S_IFMT) != -#if defined(NCR) || defined(SCO325) || !defined(S_IFSOCK) +#if !defined(S_IFSOCK) S_IFIFO #else S_IFSOCK @@ -1818,12 +1839,6 @@ TRANS(SocketUNIXConnect) (XtransConnInfo struct sockaddr_un sockname; SOCKLEN_T namelen; - - int abstract = 0; -#ifdef HAVE_ABSTRACT_SOCKETS - abstract = ciptr->transptr->flags & TRANS_ABSTRACT; -#endif - prmsg (2,"SocketUNIXConnect(%d,%s,%s)\n", ciptr->fd, host, port); /* @@ -1859,12 +1874,12 @@ TRANS(SocketUNIXConnect) (XtransConnInfo sockname.sun_family = AF_UNIX; - if (set_sun_path(port, UNIX_PATH, sockname.sun_path, abstract) != 0) { + if (set_sun_path(port, UNIX_PATH, sockname.sun_path, 0) != 0) { prmsg (1, "SocketUNIXConnect: path too long\n"); return TRANS_CONNECT_FAILED; } -#if (defined(BSD44SOCKETS) || defined(__UNIXWARE__)) +#if defined(BSD44SOCKETS) sockname.sun_len = strlen (sockname.sun_path); #endif @@ -1875,16 +1890,6 @@ TRANS(SocketUNIXConnect) (XtransConnInfo #endif - - /* - * Adjust the socket path if using abstract sockets. - * Done here because otherwise all the strlen() calls above would fail. - */ - - if (abstract) { - sockname.sun_path[0] = '\0'; - } - /* * Do the connect() */ @@ -1918,15 +1923,7 @@ TRANS(SocketUNIXConnect) (XtransConnInfo return TRANS_IN_PROGRESS; else if (olderrno == EINTR) return TRANS_TRY_CONNECT_AGAIN; - else if (olderrno == ENOENT || olderrno == ECONNREFUSED) { - /* If opening as abstract socket failed, try again normally */ - if (abstract) { - ciptr->transptr->flags &= ~(TRANS_ABSTRACT); - return TRANS_TRY_CONNECT_AGAIN; - } else { - return TRANS_CONNECT_FAILED; - } - } else { + else { prmsg (2,"SocketUNIXConnect: Can't connect: errno = %d\n", EGET()); @@ -1948,9 +1945,6 @@ TRANS(SocketUNIXConnect) (XtransConnInfo return TRANS_CONNECT_FAILED; } - if (abstract) - sockname.sun_path[0] = '@'; - ciptr->family = AF_UNIX; ciptr->addrlen = namelen; ciptr->peeraddrlen = namelen;