math/xspread: include errno.h for errno

errno must be accessed by a macro from errno.h.
This commit is contained in:
Brooks Davis 2024-09-30 16:56:09 +01:00
parent c115a19758
commit bb1a2c2c42
2 changed files with 12 additions and 3 deletions

View file

@ -1,6 +1,6 @@
PORTNAME= xspread
PORTVERSION= 3.1.1c
PORTREVISION= 5
PORTREVISION= 6
CATEGORIES= math
MASTER_SITES= http://archive.debian.org/%SUBDIR%/ \
http://mirror.safehostnet.com/debian-archive/%SUBDIR%/ \

View file

@ -1,6 +1,15 @@
--- interp.c.orig 1995-11-07 02:17:26 UTC
--- interp.c.orig
+++ interp.c
@@ -516,7 +516,7 @@ int mo, day, yr;
@@ -33,7 +33,7 @@
#include <setjmp.h>
#include <ctype.h>
-extern int errno; /* set by math functions */
+#include <errno.h>
#include "sc.h"
@@ -516,7 +516,7 @@
mdays[1] = 28 + (yr%4 == 0);
if (mo < 1 || mo > 12 || day < 1 || day > mdays[--mo] ||