aboutsummaryrefslogtreecommitdiff
path: root/math/hexcalc
diff options
context:
space:
mode:
authorWen Heping <wen@FreeBSD.org>2011-05-13 08:23:23 +0000
committerWen Heping <wen@FreeBSD.org>2011-05-13 08:23:23 +0000
commitf7dbb25491e6081010ef7a36cfccb8fb00a9dbd7 (patch)
treeb288733e8121dc2d5067aee1a0bb3861ae7aaf3f /math/hexcalc
parent15659866c62f9e381fb5e7e8e2e666dc07f77eca (diff)
downloadports-f7dbb25491e6081010ef7a36cfccb8fb00a9dbd7.tar.gz
ports-f7dbb25491e6081010ef7a36cfccb8fb00a9dbd7.zip
- Apply a patch from Gentoo to fix run error:
http://bugs.gentoo.org/show_bug.cgi?id=140987 PR: ports/156985 Submitted by: Tim Zingelman <zingelman@fnal.gov>
Notes
Notes: svn path=/head/; revision=274042
Diffstat (limited to 'math/hexcalc')
-rw-r--r--math/hexcalc/Makefile2
-rw-r--r--math/hexcalc/files/patch-hexcalc.c51
2 files changed, 52 insertions, 1 deletions
diff --git a/math/hexcalc/Makefile b/math/hexcalc/Makefile
index 57b31e8c078a..8eb729d7e8a7 100644
--- a/math/hexcalc/Makefile
+++ b/math/hexcalc/Makefile
@@ -7,7 +7,7 @@
PORTNAME= hexcalc
PORTVERSION= 1.11
-PORTREVISION= 2
+PORTREVISION= 3
CATEGORIES= math
MASTER_SITES= ftp://aixpdslib.seas.ucla.edu/pub/hexcalc/RISC/3.2/src/
DISTNAME= ${PORTNAME}
diff --git a/math/hexcalc/files/patch-hexcalc.c b/math/hexcalc/files/patch-hexcalc.c
new file mode 100644
index 000000000000..c071859b659f
--- /dev/null
+++ b/math/hexcalc/files/patch-hexcalc.c
@@ -0,0 +1,51 @@
+--- hexcalc.c.orig 2011-05-13 08:28:24.000000000 +0800
++++ hexcalc.c 2011-05-13 08:32:09.000000000 +0800
+@@ -37,6 +37,7 @@
+ #endif
+
+ #include <stdio.h>
++#include <stdlib.h>
+ #include <ctype.h>
+ #include <X11/IntrinsicP.h>
+ #include <X11/StringDefs.h>
+@@ -509,14 +510,16 @@
+
+ switch(topOp) {
+ case '+' :
+- ac = PopArg() + PopArg();
++ temp = PopArg();
++ ac = PopArg() + temp;
+ break;
+ case '-' :
+ temp = PopArg();
+ ac = PopArg() - temp;
+ break;
+ case '*' :
+- ac = PopArg() * PopArg();
++ temp = PopArg();
++ ac = temp * PopArg();
+ break;
+ case '/' :
+ temp = PopArg();
+@@ -528,15 +531,18 @@
+ break;
+
+ case '|' :
+- ac = PopArg() | PopArg();
++ temp = PopArg();
++ ac = temp | PopArg();
+ break;
+
+ case '&' :
+- ac = PopArg() & PopArg();
++ temp = PopArg();
++ ac = temp & PopArg();
+ break;
+
+ case '^' :
+- ac = PopArg() ^ PopArg();
++ temp = PopArg();
++ ac = temp ^ PopArg();
+ break;
+
+ case '<' :