diff options
Diffstat (limited to 'gnu/packages/patches')
| -rw-r--r-- | gnu/packages/patches/glibc-2.29-supported-locales.patch | 33 | ||||
| -rw-r--r-- | gnu/packages/patches/glibc-2.31-hurd-clock_gettime_monotonic.patch | 84 | ||||
| -rw-r--r-- | gnu/packages/patches/glibc-CVE-2019-19126.patch | 22 | ||||
| -rw-r--r-- | gnu/packages/patches/glibc-CVE-2019-7309.patch | 76 | ||||
| -rw-r--r-- | gnu/packages/patches/glibc-CVE-2019-9169.patch | 22 | ||||
| -rw-r--r-- | gnu/packages/patches/glibc-locales-2.28.patch | 31 | ||||
| -rw-r--r-- | gnu/packages/patches/glibc-skip-c++.patch | 31 | ||||
| -rw-r--r-- | gnu/packages/patches/htslib-for-stringtie.patch | 26 | ||||
| -rw-r--r-- | gnu/packages/patches/xlispstat-fix-compilation-with-modern-gcc.patch | 213 |
9 files changed, 213 insertions, 325 deletions
diff --git a/gnu/packages/patches/glibc-2.29-supported-locales.patch b/gnu/packages/patches/glibc-2.29-supported-locales.patch deleted file mode 100644 index 05865dc7be..0000000000 --- a/gnu/packages/patches/glibc-2.29-supported-locales.patch +++ /dev/null @@ -1,33 +0,0 @@ -This patch is taken from debian's glibc package (generate-supported.mk). -It install the localedata/SUPPORTED file of the glibc. This file lists -all the supported locales of the glibc. - -diff --git a/localedata/Makefile b/localedata/Makefile -index 65079f9eb8..14818f84e0 100644 ---- a/localedata/Makefile -+++ b/localedata/Makefile -@@ -169,7 +169,8 @@ endif - # Files to install. - install-others := $(addprefix $(inst_i18ndir)/, \ - $(addsuffix .gz, $(charmaps)) \ -- $(locales)) -+ $(locales)) \ -+ $(inst_i18ndir)/SUPPORTED - - tests: $(objdir)/iconvdata/gconv-modules - -@@ -380,6 +381,14 @@ endif - - include SUPPORTED - -+$(inst_i18ndir)/SUPPORTED: SUPPORTED $(+force) -+ for locale in $(SUPPORTED-LOCALES); do \ -+ [ $$locale = true ] && continue; \ -+ echo $$locale | sed 's,/, ,' >> LOCALES; \ -+ done -+ $(make-target-directory) -+ $(INSTALL_DATA) LOCALES $@ -+ - INSTALL-SUPPORTED-LOCALE-ARCHIVE=$(addprefix install-archive-, $(SUPPORTED-LOCALES)) - INSTALL-SUPPORTED-LOCALE-FILES=$(addprefix install-files-, $(SUPPORTED-LOCALES)) -
\ No newline at end of file diff --git a/gnu/packages/patches/glibc-2.31-hurd-clock_gettime_monotonic.patch b/gnu/packages/patches/glibc-2.31-hurd-clock_gettime_monotonic.patch deleted file mode 100644 index 1c3fe427f9..0000000000 --- a/gnu/packages/patches/glibc-2.31-hurd-clock_gettime_monotonic.patch +++ /dev/null @@ -1,84 +0,0 @@ -This is needed to run Python on the Hurd, especially during the build of -python-boot0. - -Adapted from https://salsa.debian.org/glibc-team/glibc/-/blob/glibc-2.31/debian/patches/hurd-i386/unsubmitted-clock_t_centiseconds.diff - -Use the realtime clock for the monotonic clock. This is of course not a proper -implementation (which is being done in Mach), but will permit to fix at least -the iceweasel stack. - -vlc however doesn't build when _POSIX_CLOCK_SELECTION is enabled but -_POSIX_TIMERS is not, and they refuse to fix that (see #765578), so disable the -former. - -From 0aa1dfd580cf9ad7b812c307b128decb782b825f Mon Sep 17 00:00:00 2001 -From: Jan Nieuwenhuizen <janneke@gnu.org> -Date: Mon, 2 Mar 2020 18:59:04 +0100 -Subject: [PATCH 2/2] Use realtime clock for the monotonic clock. - ---- - sysdeps/mach/clock_gettime.c | 2 +- - sysdeps/mach/hurd/bits/posix_opt.h | 6 +++--- - sysdeps/posix/clock_getres.c | 1 + - sysdeps/pthread/timer_create.c | 2 +- - 4 files changed, 6 insertions(+), 5 deletions(-) - -diff --git a/sysdeps/mach/clock_gettime.c b/sysdeps/mach/clock_gettime.c -index ac3547df3c..af8681ba4e 100644 ---- a/sysdeps/mach/clock_gettime.c -+++ b/sysdeps/mach/clock_gettime.c -@@ -25,7 +25,7 @@ - int - __clock_gettime (clockid_t clock_id, struct timespec *ts) - { -- if (clock_id != CLOCK_REALTIME) -+ if (clock_id != CLOCK_MONOTONIC && clock_id != CLOCK_REALTIME) - { - errno = EINVAL; - return -1; -diff --git a/sysdeps/mach/hurd/bits/posix_opt.h b/sysdeps/mach/hurd/bits/posix_opt.h -index 0050151332..27b3a28ab7 100644 ---- a/sysdeps/mach/hurd/bits/posix_opt.h -+++ b/sysdeps/mach/hurd/bits/posix_opt.h -@@ -163,10 +163,10 @@ - #define _POSIX_THREAD_PROCESS_SHARED -1 - - /* The monotonic clock might be available. */ --#define _POSIX_MONOTONIC_CLOCK 0 -+#define _POSIX_MONOTONIC_CLOCK 200809L - --/* The clock selection interfaces are available. */ --#define _POSIX_CLOCK_SELECTION 200809L -+/* The clock selection interfaces are not really available yet. */ -+#define _POSIX_CLOCK_SELECTION -1 - - /* Advisory information interfaces could be available in future. */ - #define _POSIX_ADVISORY_INFO 0 -diff --git a/sysdeps/posix/clock_getres.c b/sysdeps/posix/clock_getres.c -index fcd79fd554..1dd02aa449 100644 ---- a/sysdeps/posix/clock_getres.c -+++ b/sysdeps/posix/clock_getres.c -@@ -52,6 +52,7 @@ __clock_getres (clockid_t clock_id, struct timespec *res) - switch (clock_id) - { - case CLOCK_REALTIME: -+ case CLOCK_MONOTONIC: - retval = realtime_getres (res); - break; - -diff --git a/sysdeps/pthread/timer_create.c b/sysdeps/pthread/timer_create.c -index 9d8a9ea8ae..3430582c09 100644 ---- a/sysdeps/pthread/timer_create.c -+++ b/sysdeps/pthread/timer_create.c -@@ -48,7 +48,7 @@ timer_create (clockid_t clock_id, struct sigevent *evp, timer_t *timerid) - return -1; - } - -- if (clock_id != CLOCK_REALTIME) -+ if (clock_id != CLOCK_REALTIME && clock_id != CLOCK_MONOTONIC) - { - __set_errno (EINVAL); - return -1; --- -2.24.0 - diff --git a/gnu/packages/patches/glibc-CVE-2019-19126.patch b/gnu/packages/patches/glibc-CVE-2019-19126.patch deleted file mode 100644 index 5b9ac58ab7..0000000000 --- a/gnu/packages/patches/glibc-CVE-2019-19126.patch +++ /dev/null @@ -1,22 +0,0 @@ -Fix CVE-2019-19126: - -https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2019-19126 -https://sourceware.org/bugzilla/show_bug.cgi?id=25204 - -Taken from upstream: -https://sourceware.org/git/?p=glibc.git;a=commit;h=37c90e117310728a4ad1eb998c0bbe7d79c4a398 - -diff --git a/sysdeps/unix/sysv/linux/x86_64/64/dl-librecon.h b/sysdeps/unix/sysv/linux/x86_64/64/dl-librecon.h -index 975cbe2..df2cdfd 100644 ---- a/sysdeps/unix/sysv/linux/x86_64/64/dl-librecon.h -+++ b/sysdeps/unix/sysv/linux/x86_64/64/dl-librecon.h -@@ -31,7 +31,8 @@ - environment variable, LD_PREFER_MAP_32BIT_EXEC. */ - #define EXTRA_LD_ENVVARS \ - case 21: \ -- if (memcmp (envline, "PREFER_MAP_32BIT_EXEC", 21) == 0) \ -+ if (!__libc_enable_secure \ -+ && memcmp (envline, "PREFER_MAP_32BIT_EXEC", 21) == 0) \ - GLRO(dl_x86_cpu_features).feature[index_arch_Prefer_MAP_32BIT_EXEC] \ - |= bit_arch_Prefer_MAP_32BIT_EXEC; \ - break; diff --git a/gnu/packages/patches/glibc-CVE-2019-7309.patch b/gnu/packages/patches/glibc-CVE-2019-7309.patch deleted file mode 100644 index f9f623830a..0000000000 --- a/gnu/packages/patches/glibc-CVE-2019-7309.patch +++ /dev/null @@ -1,76 +0,0 @@ -Fix <https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2019-7309>. - -Taken from this upstream commit, sans ChangeLog updates and tests: -<https://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=3f635fb43389b54f682fc9ed2acc0b2aaf4a923d>. - -diff --git a/sysdeps/x86_64/memcmp.S b/sysdeps/x86_64/memcmp.S -index 1fc487caa5..1322bb3b92 100644 ---- a/sysdeps/x86_64/memcmp.S -+++ b/sysdeps/x86_64/memcmp.S -@@ -21,14 +21,18 @@ - - .text - ENTRY (memcmp) -- test %rdx, %rdx -+#ifdef __ILP32__ -+ /* Clear the upper 32 bits. */ -+ movl %edx, %edx -+#endif -+ test %RDX_LP, %RDX_LP - jz L(finz) - cmpq $1, %rdx -- jle L(finr1b) -+ jbe L(finr1b) - subq %rdi, %rsi - movq %rdx, %r10 - cmpq $32, %r10 -- jge L(gt32) -+ jae L(gt32) - /* Handle small chunks and last block of less than 32 bytes. */ - L(small): - testq $1, %r10 -@@ -156,7 +160,7 @@ L(A32): - movq %r11, %r10 - andq $-32, %r10 - cmpq %r10, %rdi -- jge L(mt16) -+ jae L(mt16) - /* Pre-unroll to be ready for unrolled 64B loop. */ - testq $32, %rdi - jz L(A64) -@@ -178,7 +182,7 @@ L(A64): - movq %r11, %r10 - andq $-64, %r10 - cmpq %r10, %rdi -- jge L(mt32) -+ jae L(mt32) - - L(A64main): - movdqu (%rdi,%rsi), %xmm0 -@@ -216,7 +220,7 @@ L(mt32): - movq %r11, %r10 - andq $-32, %r10 - cmpq %r10, %rdi -- jge L(mt16) -+ jae L(mt16) - - L(A32main): - movdqu (%rdi,%rsi), %xmm0 -@@ -254,7 +258,7 @@ L(ATR): - movq %r11, %r10 - andq $-32, %r10 - cmpq %r10, %rdi -- jge L(mt16) -+ jae L(mt16) - testq $16, %rdi - jz L(ATR32) - -@@ -325,7 +329,7 @@ L(ATR64main): - movq %r11, %r10 - andq $-32, %r10 - cmpq %r10, %rdi -- jge L(mt16) -+ jae L(mt16) - - L(ATR32res): - movdqa (%rdi,%rsi), %xmm0 diff --git a/gnu/packages/patches/glibc-CVE-2019-9169.patch b/gnu/packages/patches/glibc-CVE-2019-9169.patch deleted file mode 100644 index 029b4ddbd7..0000000000 --- a/gnu/packages/patches/glibc-CVE-2019-9169.patch +++ /dev/null @@ -1,22 +0,0 @@ -Fix <https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2019-9169>. - -Taken from this upstream commit, sans ChangeLog updates: -https://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=583dd860d5b833037175247230a328f0050dbfe9 - -diff --git a/posix/regexec.c b/posix/regexec.c -index 91d5a797b8..084b1222d9 100644 ---- a/posix/regexec.c -+++ b/posix/regexec.c -@@ -1293,8 +1293,10 @@ proceed_next_node (const re_match_context_t *mctx, Idx nregs, regmatch_t *regs, - else if (naccepted) - { - char *buf = (char *) re_string_get_buffer (&mctx->input); -- if (memcmp (buf + regs[subexp_idx].rm_so, buf + *pidx, -- naccepted) != 0) -+ if (mctx->input.valid_len - *pidx < naccepted -+ || (memcmp (buf + regs[subexp_idx].rm_so, buf + *pidx, -+ naccepted) -+ != 0)) - return -1; - } - } diff --git a/gnu/packages/patches/glibc-locales-2.28.patch b/gnu/packages/patches/glibc-locales-2.28.patch deleted file mode 100644 index 31ee6c1ff3..0000000000 --- a/gnu/packages/patches/glibc-locales-2.28.patch +++ /dev/null @@ -1,31 +0,0 @@ -This patch allows us to use glibc's build system to build locales -in a package separate from glibc. - - 1. Use 'localedef' from $PATH since we are not rebuilding it. - 2. Use '--no-archive' to avoid building the big locale archive, and - because the already-built 'localedef' would want to write it - to '/run/current-system/locale', which is not possible. - 3. Pass $(inst_complocaledir)/$$locale to install files in the right - place, and because otherwise, 'localedef' fails with: - "cannot write output files to `(null)'". - ---- glibc-2.27/localedata/Makefile -+++ glibc-2.27/localedata/Makefile -@@ -199,7 +199,7 @@ INSTALL-SUPPORTED-LOCALES=$(addprefix install-, $(SUPPORTED-LOCALES)) - - # Sometimes the whole collection of locale files should be installed. - LOCALEDEF=I18NPATH=. GCONV_PATH=$(common-objpfx)iconvdata LC_ALL=C \ --$(rtld-prefix) $(common-objpfx)locale/localedef -+ localedef --no-archive - install-locales: $(INSTALL-SUPPORTED-LOCALES) - - install-locales-dir: -@@ -224,7 +224,7 @@ $(INSTALL-SUPPORTED-LOCALES): install-locales-dir - input=`echo $$locale | sed 's/\([^.]*\)[^@]*\(.*\)/\1\2/'`; \ - $(LOCALEDEF) $$flags --alias-file=../intl/locale.alias \ - -i locales/$$input -f charmaps/$$charset \ -- $(addprefix --prefix=,$(install_root)) $$locale \ -+ $(addprefix --prefix=,$(install_root)) $(inst_complocaledir)/$$locale \ - && echo ' done'; \ - - tst-setlocale-ENV = LC_ALL=ja_JP.EUC-JP diff --git a/gnu/packages/patches/glibc-skip-c++.patch b/gnu/packages/patches/glibc-skip-c++.patch deleted file mode 100644 index b2cbe76d3b..0000000000 --- a/gnu/packages/patches/glibc-skip-c++.patch +++ /dev/null @@ -1,31 +0,0 @@ -When building, say, glibc 2.31 using a compiler that's itself linked -against 2.33, linking fails with: - - gcc -Wl,-rpath-link=/tmp/guix-build-glibc-2.31.drv-0/build:/tmp/guix-build-glibc-2.31.drv-0/build/math:/tmp/guix-build-glibc-2.31.drv-0/build/elf:/tmp/guix-build-glibc-2.31.drv-0/build/dlfcn:/tmp/guix-build-glibc-2.31.drv-0/build/nss:/tmp/guix-build-glibc-2.31.drv-0/build/nis:/tmp/guix-build-glibc-2.31.drv-0/build/rt:/tmp/guix-build-glibc-2.31.drv-0/build/resolv:/tmp/guix-build-glibc-2.31.drv-0/build/mathvec:/tmp/guix-build-glibc-2.31.drv-0/build/support:/tmp/guix-build-glibc-2.31.drv-0/build/crypt:/tmp/guix-build-glibc-2.31.drv-0/build/nptl -nostdlib -nostartfiles -o /tmp/guix-build-glibc-2.31.drv-0/build/support/links-dso-program -Wl,-z,combreloc -Wl,-z,relro -Wl,--hash-style=both /tmp/guix-build-glibc-2.31.drv-0/build/csu/crt1.o /tmp/guix-build-glibc-2.31.drv-0/build/csu/crti.o `gcc --print-file-name=crtbegin.o` /tmp/guix-build-glibc-2.31.drv-0/build/support/links-dso-program.o -lstdc++ -lgcc -lgcc_s -Wl,-dynamic-linker=/gnu/store/...-glibc-2.31/lib/ld-linux-x86-64.so.2 /tmp/guix-build-glibc-2.31.drv-0/build/libc.so.6 /tmp/guix-build-glibc-2.31.drv-0/build/libc_nonshared.a -Wl,--as-needed /tmp/guix-build-glibc-2.31.drv-0/build/elf/ld.so -Wl,--no-as-needed -lgcc `gcc --print-file-name=crtend.o` /tmp/guix-build-glibc-2.31.drv-0/build/csu/crtn.o - ld: /gnu/store/...-gcc-10.3.0-lib/lib/gcc/x86_64-unknown-linux-gnu/10.3.0/../../../libstdc++.so: undefined reference to `fstat64@GLIBC_2.33' - ld: /gnu/store/...-gcc-10.3.0-lib/lib/gcc/x86_64-unknown-linux-gnu/10.3.0/../../../libstdc++.so: undefined reference to `lstat@GLIBC_2.33' - ld: /gnu/store/...-gcc-10.3.0-lib/lib/gcc/x86_64-unknown-linux-gnu/10.3.0/../../../libstdc++.so: undefined reference to `stat@GLIBC_2.33' - collect2: error: ld returned 1 exit status - -This is unsurprising given that libstdc++.so here is linked against 2.33, -whereas libc.so.6 here is 2.31. - -This patch works around it by not building the offending program. - -diff --git a/support/Makefile b/support/Makefile -index bb9889ef..6614943b 100644 ---- a/support/Makefile -+++ b/support/Makefile -@@ -210,12 +210,7 @@ CFLAGS-support_paths.c = \ - # -fexcess-precision=standard. - CFLAGS-timespec.c += -fexcess-precision=standard - --ifeq (,$(CXX)) - LINKS_DSO_PROGRAM = links-dso-program-c --else --LINKS_DSO_PROGRAM = links-dso-program --LDLIBS-links-dso-program = -lstdc++ -lgcc -lgcc_s $(libunwind) --endif - - ifeq (yes,$(have-selinux)) - LDLIBS-$(LINKS_DSO_PROGRAM) += -lselinux diff --git a/gnu/packages/patches/htslib-for-stringtie.patch b/gnu/packages/patches/htslib-for-stringtie.patch deleted file mode 100644 index 3e6cd5bb63..0000000000 --- a/gnu/packages/patches/htslib-for-stringtie.patch +++ /dev/null @@ -1,26 +0,0 @@ -These changes are commits d7e357946ead219b81cc1becbe0de8a99d96ca84 and -8ed0daa39bc662defa99507f926815431056543a in -https://github.com/samtools/htscodecs. The stringtie package expects these -changes to have been applied. - -diff -ru htslib-1.12/htscodecs/htscodecs/tokenise_name3.c stringtie-2.2.0/htslib/htscodecs/htscodecs/tokenise_name3.c ---- a/htscodecs/htscodecs/tokenise_name3.c 2021-02-22 13:07:06.000000000 +0100 -+++ b/htscodecs/htscodecs/tokenise_name3.c 2021-12-04 19:27:39.000000000 +0100 -@@ -211,7 +211,7 @@ - if (!ctx) return NULL; - ctx->max_names = max_names; - pthread_setspecific(tok_key, ctx); -- } else if (ctx->max_names < max_names) { -+ } else if (ctx->max_names < max_names+1) { - ctx = realloc(ctx, sizeof(*ctx) + ++max_names*sizeof(*ctx->lc)); - if (!ctx) return NULL; - ctx->max_names = max_names; -@@ -1058,6 +1058,8 @@ - tok = decode_token_type(ctx, ntok); - //fprintf(stderr, "Tok %d = %d\n", ntok, tok); - -+ ctx->lc[cnum].last_ntok = 0; -+ - switch (tok) { - case N_CHAR: - if (len+1 >= name_len) return -1;
\ No newline at end of file diff --git a/gnu/packages/patches/xlispstat-fix-compilation-with-modern-gcc.patch b/gnu/packages/patches/xlispstat-fix-compilation-with-modern-gcc.patch new file mode 100644 index 0000000000..46825d1132 --- /dev/null +++ b/gnu/packages/patches/xlispstat-fix-compilation-with-modern-gcc.patch @@ -0,0 +1,213 @@ +From 29d14d78a17f2d85bc9e37f380e71221c2055dd8 Mon Sep 17 00:00:00 2001 +From: "Artyom V. Poptsov" <poptsov.artyom@gmail.com> +Date: Thu, 23 Oct 2025 22:13:53 +0300 +Subject: [PATCH] src: Fix compilation with GCC version 14 or newer + +GCC version 14 now treats some deprecation warnings as errors, namely +it is not allowed to use implicit "int" types, implicit function +declarations (see <https://gcc.gnu.org/gcc-14/porting_to.html>.) In +this patch, deprecated code updated to match the new requirements of +GCC. + +* src/c/ddists.c, src/c/objects.c, src/include/sysvr4-foreign.h, +src/c/iviewdat.c, src/c/postscript.c: Explicitly specify variable +types and procedure return value types to satisfy requirements of +GCC version 14 or newer. +* src/c/X11graph.c: Likewise. +(StBlockForInput): Modernize "select" call. +* src/c/X11BSDstuff.c (line_available): Modernize "select" call. +--- + src/c/X11BSDstuff.c | 4 +++- + src/c/X11graph.c | 10 +++++++--- + src/c/ddists.c | 4 +++- + src/c/iviewdat.c | 2 +- + src/c/objects.c | 6 ++++-- + src/c/postscript.c | 7 ++++--- + src/include/sysvr4-foreign.h | 2 +- + 7 files changed, 23 insertions(+), 12 deletions(-) + +diff --git a/src/c/X11BSDstuff.c b/src/c/X11BSDstuff.c +index 5bb7144..4a9b91b 100644 +--- a/src/c/X11BSDstuff.c ++++ b/src/c/X11BSDstuff.c +@@ -3,6 +3,8 @@ + /* Additions to Xlisp 2.1, Copyright (c) 1989 by David Michael Betz */ + /* You may give out copies of this software; for conditions see the */ + /* file COPYING included with this distribution. */ ++/* Additions to XLISP-STAT 2.1, Copyright (c) 2025, */ ++/* by Artyom V. Poptsov <poptsov.artyom@gmail.com> */ + /* */ + /* Some modifications included from WINTERP */ + /* WINTERP 1.0 Copyright 1989 Hewlett-Packard Company (by Niels Mayer).*/ +@@ -549,7 +551,7 @@ LOCAL int line_available() + FD_ZERO(&readmask); + FD_SET(fileno(stdin), &readmask); + +- result = select(ndfs, (int *) &readmask, NULL, NULL, &tv); ++ result = select(ndfs, &readmask, NULL, NULL, &tv); + if (result > 0) return(TRUE); + /* *** should merge the select here with the one for blocking ***/ + else return(StBlockForInput()); +diff --git a/src/c/X11graph.c b/src/c/X11graph.c +index 70dff08..920957c 100644 +--- a/src/c/X11graph.c ++++ b/src/c/X11graph.c +@@ -1,6 +1,8 @@ + /* X11graph - X11 support for XLISP-STAT */ + /* XLISP-STAT 2.1 Copyright (c) 1990, by Luke Tierney */ + /* Additions to Xlisp 2.1, Copyright (c) 1989 by David Michael Betz */ ++/* Additions to XLISP-STAT 2.1, Copyright (c) 2025, */ ++/* by Artyom V. Poptsov <poptsov.artyom@gmail.com> */ + /* You may give out copies of this software; for conditions see the */ + /* file COPYING included with this distribution. */ + +@@ -23,8 +25,8 @@ extern VOID InstallMenuButton P2H(Window, LVAL); + extern VOID DeleteMenuButton P1H(Window); + extern VOID StX11FinishMenus(V); + extern VOID StX11FinishDialogs(V); +-extern StX11InitMenus(V); +-extern StX11InitDialogs(V); ++extern void StX11InitMenus(V); ++extern void StX11InitDialogs(V); + + extern char *getenv(); + +@@ -316,7 +318,7 @@ int StBlockForInput() + if (tmp > maxfd) maxfd = tmp; + FD_SET(maxfd, &readmask); + } +- result = select(maxfd+1, (int *) &readmask, NULL, NULL, NULL); ++ result = select(maxfd+1, &readmask, NULL, NULL, NULL); + return((FD_ISSET(fileno(stdin), &readmask)) ? TRUE : FALSE); + } + else return(FALSE); +@@ -1221,6 +1223,7 @@ VOID StWGetLocation(w, left, top, frame) + VOID StWSetSize(w, width, height, frame) + Window w; + int width, height; ++ int frame; + { + Display *dpy = StX11Display(); + StGWWinInfo *gwinfo; +@@ -1286,6 +1289,7 @@ VOID StWGetSize(w, pwidth, pheight, frame) + VOID StGWSetSize(gwinfo, width, height, frame) + StGWWinInfo *gwinfo; + int width, height; ++ int frame; + { + Window w; + if (gwinfo == NULL || (w = gwinfo->window) == NullWindow) return; +diff --git a/src/c/ddists.c b/src/c/ddists.c +index e6abeaa..dcefa23 100644 +--- a/src/c/ddists.c ++++ b/src/c/ddists.c +@@ -3,6 +3,8 @@ + /* Additions to Xlisp 2.1, Copyright (c) 1989 by David Michael Betz */ + /* You may give out copies of this software; for conditions see the */ + /* file COPYING included with this distribution. */ ++/* Additions to XLISP-STAT 2.1, Copyright (c) 2025, */ ++/* by Artyom V. Poptsov <poptsov.artyom@gmail.com> */ + + #include "xlisp.h" + #include "xlstat.h" +@@ -29,7 +31,7 @@ LOCAL VOID getpoisarg P1H(double *); + LOCAL double poisson_cdf P2H(int, double); + LOCAL int binomial_quant P3H(double, int, double); + LOCAL int poisson_quant P2H(double, double); +-LOCAL poisson_rand P1H(double); ++LOCAL int poisson_rand P1H(double); + LOCAL int binomial_rand P2H(int, double); + + /* numerical distribution function */ +diff --git a/src/c/iviewdat.c b/src/c/iviewdat.c +index 0b35e05..28fd2df 100644 +--- a/src/c/iviewdat.c ++++ b/src/c/iviewdat.c +@@ -237,7 +237,7 @@ static VOID IViewBasicPointsSetTransformation P2C(IViewBasicPoints, p, double ** + static VOID IViewBasicPointsApplyTransformation P3C(IViewBasicPoints, p, + double **, a, int *, inbasis) + { +- static maxvars = 0; ++ static int maxvars = 0; + static Fixed **b, *x, **screen_data, *screen_location; + int vars, n, i, j; + double *scale = p->scale, *location = p->location; +diff --git a/src/c/objects.c b/src/c/objects.c +index d9c61f2..1084b47 100644 +--- a/src/c/objects.c ++++ b/src/c/objects.c +@@ -3,7 +3,9 @@ + /* Additions to Xlisp 2.1, Copyright (c) 1989 by David Michael Betz */ + /* You may give out copies of this software; for conditions see the */ + /* file COPYING included with this distribution. */ +- ++/* Additions to XLISP-STAT 2.1, Copyright (c) 2025, */ ++/* by Artyom V. Poptsov <poptsov.artyom@gmail.com> */ ++ + #include "xlisp.h" + #include "xlstat.h" + +@@ -1260,7 +1262,7 @@ LVAL xsobject_isnew(V) + VOID xsaddmsg P2C(LVAL, object, char *, str) + { + LVAL fcn; +- static offset = FIRST_METHOD_OFFSET; ++ static int offset = FIRST_METHOD_OFFSET; + + xlsave1(fcn); + fcn = cvsubr(funtab[offset].fd_subr,funtab[offset].fd_type,offset); +diff --git a/src/c/postscript.c b/src/c/postscript.c +index 6ddbfb9..ea57351 100644 +--- a/src/c/postscript.c ++++ b/src/c/postscript.c +@@ -9,6 +9,7 @@ + /* pbmtops.c - read a portable bitmap and produce a PostScript bitmap file + ** + ** Copyright (C) 1988 by Jef Poskanzer. ++** Copyright (C) 2025 by Artyom V. Poptsov <poptsov.artyom@gmail.com> + ** + ** Permission to use, copy, modify, and distribute this software and its + ** documentation for any purpose and without fee is hereby granted, provided +@@ -60,7 +61,7 @@ static FILE *fp; + /**************************************************************************/ + + /* set up global variables and print the postscript preamble */ +-psputinit(file, cols, rows, scale ) ++void psputinit(file, cols, rows, scale ) + FILEP file; + int cols, rows; + double scale; +@@ -120,7 +121,7 @@ psputinit(file, cols, rows, scale ) + } + + /* enter a bit into the image */ +-psputbit(b) ++void psputbit(b) + int b; + { + if ( bitsperitem == 8 ) { +@@ -133,7 +134,7 @@ psputbit(b) + } + + /* clean up and print the showpage command */ +-psputrest( ) ++void psputrest( ) + { + if ( bitsperitem > 0 ) + putitem( ); +diff --git a/src/include/sysvr4-foreign.h b/src/include/sysvr4-foreign.h +index f40acc8..709fc6c 100644 +--- a/src/include/sysvr4-foreign.h ++++ b/src/include/sysvr4-foreign.h +@@ -16,7 +16,7 @@ LOCAL VOID link_and_load(fname, libs, fort) + char *fname, *libs; + int fort; + { +- static initialized = FALSE; ++ static int initialized = FALSE; + void *handle; + + if (! initialized) { +-- +2.51.0 + |
