aboutsummaryrefslogtreecommitdiffstats
path: root/devel/hptools
diff options
context:
space:
mode:
authoredwin <edwin@FreeBSD.org>2007-10-03 21:46:06 +0800
committeredwin <edwin@FreeBSD.org>2007-10-03 21:46:06 +0800
commit3941f18d545b014464ff7be583f530e01bafbe68 (patch)
tree1a70f4d07ac1ab02f5e944a60a89298bb9084746 /devel/hptools
parentb57218ae0552dc99085ab8a34b1715fe8f98dd74 (diff)
downloadfreebsd-ports-gnome-3941f18d545b014464ff7be583f530e01bafbe68.tar.gz
freebsd-ports-gnome-3941f18d545b014464ff7be583f530e01bafbe68.tar.zst
freebsd-ports-gnome-3941f18d545b014464ff7be583f530e01bafbe68.zip
[PATCH] devel/hptools: fix GCC 4.2 builds
Fix build breakage under gcc 4.2 PR: ports/115798 Submitted by: Hung-Yi Chen <gaod@hychen.org> Approved by: maintainer timeout
Diffstat (limited to 'devel/hptools')
-rw-r--r--devel/hptools/Makefile8
-rw-r--r--devel/hptools/files/p-common_getopt.c11
-rw-r--r--devel/hptools/files/p-sload_symb.c11
3 files changed, 30 insertions, 0 deletions
diff --git a/devel/hptools/Makefile b/devel/hptools/Makefile
index f446f238cf1e..175f59e50ebc 100644
--- a/devel/hptools/Makefile
+++ b/devel/hptools/Makefile
@@ -7,6 +7,7 @@
PORTNAME= hptools
PORTVERSION= 3.0.8
+PORTREVISION= 1
CATEGORIES= devel
MASTER_SITES= http://www.hpcalc.org/hp48/pc/programming/
DISTNAME= ${PORTNAME}-src-${PORTVERSION}
@@ -18,6 +19,8 @@ WRKSRC= ${WRKDIR}/Hptools/${CONFIGURE_TARGET}
GNU_CONFIGURE= yes
CONFIGURE_SCRIPT= ../support/configure
+PATCH_ARGS= -E ${PATCH_STRIP}
+
NO_CDROM= 'Commercial use is Prohibited'
@@ -26,6 +29,11 @@ pre-patch:
${WRKDIR}/Hptools/common/envfile.c \
${WRKDIR}/Hptools/rplcomp/defer.c \
${WRKDIR}/Hptools/rplcomp/masd.c
+ cd ${WRKDIR}/Hptools && \
+ ${PATCH} ${PATCH_ARGS} < ${FILESDIR}/p-common_getopt.c
+ cd ${WRKDIR}/Hptools && \
+ ${PATCH} ${PATCH_ARGS} < ${FILESDIR}/p-sload_symb.c
+
pre-configure:
@(${MKDIR} ${WRKSRC})
diff --git a/devel/hptools/files/p-common_getopt.c b/devel/hptools/files/p-common_getopt.c
new file mode 100644
index 000000000000..87a1592c3f8f
--- /dev/null
+++ b/devel/hptools/files/p-common_getopt.c
@@ -0,0 +1,11 @@
+--- common/getopt.c.orig Wed Oct 3 23:28:45 2007
++++ common/getopt.c Wed Oct 3 23:29:03 2007
+@@ -21,7 +21,7 @@
+ int optopt, opterr = TRUE, optind = 1;
+ char *optarg;
+
+-static int sp = 1;
++int sp = 1;
+
+ int getopt( int argc, char * const argv[], const char *opts )
+ {
diff --git a/devel/hptools/files/p-sload_symb.c b/devel/hptools/files/p-sload_symb.c
new file mode 100644
index 000000000000..f1fec8d83738
--- /dev/null
+++ b/devel/hptools/files/p-sload_symb.c
@@ -0,0 +1,11 @@
+--- sload/symb.c.orig Wed Oct 3 23:28:21 2007
++++ sload/symb.c Wed Oct 3 23:28:31 2007
+@@ -8,7 +8,7 @@
+ #include "sptree.h"
+
+
+-static SYMBOLPTR symtree;
++SYMBOLPTR symtree;
+ int lookups=0, lkcmps=0, adds=0;
+
+ b_16 symbols;