aboutsummaryrefslogtreecommitdiffstats
path: root/lang
diff options
context:
space:
mode:
authorpi <pi@FreeBSD.org>2016-05-09 01:50:04 +0800
committerpi <pi@FreeBSD.org>2016-05-09 01:50:04 +0800
commit5d7038380ab789cba7d474a13770391fe95dd9a4 (patch)
tree0428f7b1c0494fa6753c9516c8f3b5d7be57757c /lang
parent5350a075ff8deac179e0dbe000a8364aad4afaa5 (diff)
downloadfreebsd-ports-gnome-5d7038380ab789cba7d474a13770391fe95dd9a4.tar.gz
freebsd-ports-gnome-5d7038380ab789cba7d474a13770391fe95dd9a4.tar.zst
freebsd-ports-gnome-5d7038380ab789cba7d474a13770391fe95dd9a4.zip
lang/rexx-regutil: several patches
- additional MASTER_SITE (there was only one) - tidied Makefile considerably - fixed failure to build under different PREFIX - added DOC option - added EXAMPLES option, and now can have examples (there were none before) - eliminated numerous compilation warnings - REMOVED pkg-plist (only two files in it) - REMOVED pkg-message (now redundant) - ADDED new patches in files/ PR: 209379 Submitted by: bob@eager.cx (maintainer)
Diffstat (limited to 'lang')
-rw-r--r--lang/rexx-regutil/Makefile35
-rw-r--r--lang/rexx-regutil/files/patch-Makefile.inc12
-rw-r--r--lang/rexx-regutil/files/patch-inifile.c31
-rw-r--r--lang/rexx-regutil/files/patch-regfilesys.c65
-rw-r--r--lang/rexx-regutil/files/patch-regini.c11
-rw-r--r--lang/rexx-regutil/files/patch-regstem.c11
-rw-r--r--lang/rexx-regutil/files/patch-regunicode.c28
-rw-r--r--lang/rexx-regutil/files/patch-regutil.c11
-rw-r--r--lang/rexx-regutil/files/patch-rxproto.h11
-rw-r--r--lang/rexx-regutil/files/patch-rxsupport.c11
-rw-r--r--lang/rexx-regutil/files/pkg-message.in5
-rw-r--r--lang/rexx-regutil/files/regutil.1.in6
-rw-r--r--lang/rexx-regutil/pkg-plist4
13 files changed, 215 insertions, 26 deletions
diff --git a/lang/rexx-regutil/Makefile b/lang/rexx-regutil/Makefile
index c9f43dca40ab..b021df95e46b 100644
--- a/lang/rexx-regutil/Makefile
+++ b/lang/rexx-regutil/Makefile
@@ -3,14 +3,18 @@
PORTNAME= regutil
PORTVERSION= 1.26
+PORTREVISION= 1
CATEGORIES= lang
-MASTER_SITES= http://home.interlog.com/~ptjm/ http://www.tavi.co.uk/distfiles/
+MASTER_SITES= http://home.interlog.com/~ptjm/ \
+ http://www.ancientgeek.org.uk/distfiles/
PKGNAMEPREFIX= rexx-
-DISTNAME= regutil126
+DISTNAME= ${PORTNAME}${PORTVERSION:S/.//}
MAINTAINER= bob@eager.cx
COMMENT= Implementation of IBM's RexxUtil function library for Regina
+LICENSE= MPL
+
BUILD_DEPENDS= ${LOCALBASE}/include/rexxsaa.h:lang/rexx-regina
USES= ncurses zip
@@ -20,19 +24,28 @@ USE_LDCONFIG= yes
MAKEFILE= Makefile.bsd
MAKE_ARGS+= PLIBS="${LDFLAGS:M-L*} -lncurses"
-SUB_FILES= regutil.1 pkg-message
+SUB_FILES= regutil.1
+
+PLIST_FILES= lib/librexxutil.so \
+ man/man1/regutil.1.gz
-PKGMESSAGE= ${WRKDIR}/pkg-message
+PORTDOCS= regutil.pdf
+PORTEXAMPLES= *.rex
-.include <bsd.port.pre.mk>
+OPTIONS_DEFINE= DOCS EXAMPLES
+
+#include <bsd.options.mk>
do-install:
- ${INSTALL_LIB} ${WRKSRC}/librexxutil.so ${STAGEDIR}${PREFIX}/lib
- ${INSTALL_MAN} ${WRKDIR}/regutil.1 ${STAGEDIR}${PREFIX}/man/man1/regutil.1.gz
- ${INSTALL_MAN} ${WRKDIR}/regutil.1 ${STAGEDIR}${PREFIX}/man/man1/rexxutil.1.gz
+ ${INSTALL_LIB} ${WRKSRC}/librexxutil.so ${STAGEDIR}${PREFIX}/lib/
+ ${INSTALL_MAN} ${WRKDIR}/regutil.1 ${STAGEDIR}${PREFIX}/man/man1/
-post-install:
+do-install-DOCS-on:
${MKDIR} ${STAGEDIR}${DOCSDIR}
- ${INSTALL_MAN} ${WRKSRC}/regutil.pdf ${STAGEDIR}${DOCSDIR}
+ ${INSTALL_MAN} ${WRKSRC}/regutil.pdf ${STAGEDIR}${DOCSDIR}/
+
+do-install-EXAMPLES-on:
+ ${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
+ ${INSTALL_MAN} ${WRKSRC}/*.rex ${STAGEDIR}${EXAMPLESDIR}
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>
diff --git a/lang/rexx-regutil/files/patch-Makefile.inc b/lang/rexx-regutil/files/patch-Makefile.inc
index 147ad6cf0d9d..70e884fc3e33 100644
--- a/lang/rexx-regutil/files/patch-Makefile.inc
+++ b/lang/rexx-regutil/files/patch-Makefile.inc
@@ -1,11 +1,13 @@
---- Makefile.inc.orig 2010-08-30 23:27:33.000000000 +0100
-+++ Makefile.inc 2010-08-30 23:27:53.000000000 +0100
-@@ -26,7 +26,7 @@
+--- Makefile.inc.orig 2003-03-04 20:14:28 UTC
++++ Makefile.inc
+@@ -26,8 +26,8 @@
DEBUG=-g $(PDEBUG)
OPT=
-REXX_INCLUDE=$(HOME)/regina
-+REXX_INCLUDE=$(PREFIX)/include
- CFLAGS=$(DEBUG) $(OPT) $(PCFLAGS) $(PCDEFS) -I $(REXX_INCLUDE)
+-CFLAGS=$(DEBUG) $(OPT) $(PCFLAGS) $(PCDEFS) -I $(REXX_INCLUDE)
++REXX_INCLUDE=/usr/local/include
++CFLAGS+=$(DEBUG) $(OPT) $(PCFLAGS) $(PCDEFS) -I $(REXX_INCLUDE)
LDFLAGS=$(PLDFLAGS)
LIBS=$(PLIBS)
+ LIBFILE=librexxutil
diff --git a/lang/rexx-regutil/files/patch-inifile.c b/lang/rexx-regutil/files/patch-inifile.c
new file mode 100644
index 000000000000..e92d8a7aaab8
--- /dev/null
+++ b/lang/rexx-regutil/files/patch-inifile.c
@@ -0,0 +1,31 @@
+--- inifile.c.orig 2003-02-20 00:04:42 UTC
++++ inifile.c
+@@ -194,7 +194,7 @@ static int read_ini_raw(inif_t fit)
+ fseek(fit->fp, 0, SEEK_SET);
+
+ while ((oldoff = ftell(fit->fp)),
+- fgets(buf, sizeof(buf), fit->fp) != NULL) {
++ fgets((char *) buf, sizeof(buf), fit->fp) != NULL) {
+
+ /* skip leading whitespace */
+ for (i = 0; !pt[buf[i]]; i++)
+@@ -204,8 +204,8 @@ static int read_ini_raw(inif_t fit)
+ * line */
+ switch (pt[buf[i]]) {
+ /* errors */
+- case CV_RBRACK: n = "closing bracket"; goto oops;
+- case CV_EQUALS: n = "equals sign"; goto oops;
++ case CV_RBRACK: n = (unsigned char *) "closing bracket"; goto oops;
++ case CV_EQUALS: n = (unsigned char *) "equals sign"; goto oops;
+
+ oops:
+ fprintf(stderr, "oops: line starts with %s: %s\n", n, buf);
+@@ -284,7 +284,7 @@ static int read_ini_raw(inif_t fit)
+ * write anything before the first section */
+ case CV_EOS:
+ case CV_COMMENT:
+- i = strlen(buf);
++ i = strlen((char *) buf);
+ if (lvt) {
+ lvt->comment = realloc(lvt->comment, cl + i + 1);
+ memcpy(lvt->comment+cl, buf, i+1);
diff --git a/lang/rexx-regutil/files/patch-regfilesys.c b/lang/rexx-regutil/files/patch-regfilesys.c
new file mode 100644
index 000000000000..3999bb6355a9
--- /dev/null
+++ b/lang/rexx-regutil/files/patch-regfilesys.c
@@ -0,0 +1,65 @@
+--- regfilesys.c.orig 2003-11-03 20:24:14 UTC
++++ regfilesys.c
+@@ -114,7 +114,8 @@ int unmapfile(char *buf, int size);
+ /* SysFileSearch(target,file,stem, [options]) */
+ rxfunc(sysfilesearch)
+ {
+- unsigned char *buf, * dptr, *bol, *eol, *eof, *filename, *options,
++ char *filename, *options;
++ unsigned char *buf, * dptr, *bol, *eol, *eof,
+ *lbuf = NULL;
+ PRXSTRING stem;
+ RXSTRING target;
+@@ -141,7 +142,7 @@ rxfunc(sysfilesearch)
+
+ /* map the file into memory. Note that if the OS doesn't support memory-
+ * mapped I/O, this allocates a buffer and reads the file into it. */
+- if (!(buf = mapfile(filename, &len))) {
++ if (!(buf = (unsigned char *) mapfile((char *) filename, &len))) {
+ rc = 3;
+ }
+ else {
+@@ -195,7 +196,7 @@ rxfunc(sysfilesearch)
+ i = eol - bol;
+ if (i && bol[i-1] == '\r')
+ i--;
+- if (cha_adddummy(array, bol, i))
++ if (cha_adddummy(array, (char *) bol, i))
+ rc = 2;
+ }
+ else {
+@@ -203,12 +204,12 @@ rxfunc(sysfilesearch)
+ if (!lbuf)
+ rc = 2;
+ else {
+- i = sprintf(lbuf, "%d:", lines);
++ i = sprintf((char *) lbuf, "%d:", lines);
+ memcpy(lbuf+i, bol, eol-bol);
+ i += eol - bol;
+ if (lbuf[i-1] == '\r')
+ i--;
+- if (cha_addstr(array, lbuf, i))
++ if (cha_addstr(array, (char *) lbuf, i))
+ rc = 2;
+ }
+ }
+@@ -222,7 +223,7 @@ rxfunc(sysfilesearch)
+ if (lbuf)
+ free(lbuf);
+
+- unmapfile(buf, len);
++ unmapfile((char *) buf, len);
+ }
+
+ result->strlength = sprintf(result->strptr, "%d", rc);
+@@ -730,8 +731,8 @@ rxfunc(sysfiletree)
+ rc = 2;
+
+ else {
+- /* break the list into directory & pattern, so the input can be of
+- * the form /usr/home/ptjm/*.c */
++// break the list into directory & pattern, so the input can be of
++// the form /usr/home/ptjm/*.c
+
+ dir = pattern;
+ pattern = strrchr(dir, '/');
diff --git a/lang/rexx-regutil/files/patch-regini.c b/lang/rexx-regutil/files/patch-regini.c
new file mode 100644
index 000000000000..ace11aedcf6a
--- /dev/null
+++ b/lang/rexx-regutil/files/patch-regini.c
@@ -0,0 +1,11 @@
+--- regini.c.orig 2004-07-19 00:09:52 UTC
++++ regini.c
+@@ -1002,7 +1002,7 @@ rxfunc(sysgeterrortext)
+ result->strlength = 0;
+ }
+ #else
+- if (rcs = strerror(rc)) {
++ if ((rcs = strerror(rc))) {
+ result->strlength = strlen(rcs);
+ memcpy(result->strptr, rcs, result->strlength);
+ }
diff --git a/lang/rexx-regutil/files/patch-regstem.c b/lang/rexx-regutil/files/patch-regstem.c
new file mode 100644
index 000000000000..e9afff180cf6
--- /dev/null
+++ b/lang/rexx-regutil/files/patch-regstem.c
@@ -0,0 +1,11 @@
+--- regstem.c.orig 2004-06-15 19:15:06 UTC
++++ regstem.c
+@@ -53,7 +53,7 @@ static int rxstrcasecmp(const PRXSTRING
+ {
+ register int len = min(l->strlength, r->strlength),
+ d = l->strlength - r->strlength,
+- c = casecmp(l->strptr, r->strptr, len);
++ c = casecmp((unsigned char *) l->strptr, (unsigned char *) r->strptr, len);
+
+ return (len && c) ? c : d;
+ }
diff --git a/lang/rexx-regutil/files/patch-regunicode.c b/lang/rexx-regutil/files/patch-regunicode.c
new file mode 100644
index 000000000000..6f800a83be50
--- /dev/null
+++ b/lang/rexx-regutil/files/patch-regunicode.c
@@ -0,0 +1,28 @@
+--- regunicode.c.orig 2003-04-01 20:08:34 UTC
++++ regunicode.c
+@@ -542,10 +542,10 @@ rxfunc(systounicode)
+ /* for the same reason, perform utf-7 and utf-8 conversions here, rather
+ * than using iconv() */
+ else if (cp == CP_UTF7) {
+- outs.strlength = u7tou((unsigned short *)outs.strptr, argv[0].strptr, argv[0].strlength);
++ outs.strlength = u7tou((unsigned short *)outs.strptr, (unsigned char *) argv[0].strptr, argv[0].strlength);
+ }
+ else if (cp == CP_UTF8) {
+- outs.strlength = u8tou((unsigned short *) outs.strptr, argv[0].strptr, argv[0].strlength);
++ outs.strlength = u8tou((unsigned short *) outs.strptr, (unsigned char *) argv[0].strptr, argv[0].strlength);
+ }
+
+ /* if requesting a specific code page, we need iconv, or we return an
+@@ -719,10 +719,10 @@ rxfunc(sysfromunicode)
+ /* for the same reason, perform utf-7 and utf-8 conversions here, rather
+ * than using iconv() */
+ else if (cp == CP_UTF7) {
+- outs.strlength = utou7(outs.strptr, (unsigned short *)argv[0].strptr, argv[0].strlength/2);
++ outs.strlength = utou7((unsigned char *) outs.strptr, (unsigned short *)argv[0].strptr, argv[0].strlength/2);
+ }
+ else if (cp == CP_UTF8) {
+- outs.strlength = utou8(outs.strptr, (unsigned short *)argv[0].strptr, argv[0].strlength/2);
++ outs.strlength = utou8((unsigned char *) outs.strptr, (unsigned short *)argv[0].strptr, argv[0].strlength/2);
+ }
+
+ /* if requesting a specific code page, we need iconv, or we return an
diff --git a/lang/rexx-regutil/files/patch-regutil.c b/lang/rexx-regutil/files/patch-regutil.c
new file mode 100644
index 000000000000..b2a8f680c353
--- /dev/null
+++ b/lang/rexx-regutil/files/patch-regutil.c
@@ -0,0 +1,11 @@
+--- regutil.c.orig 2004-01-16 14:57:12 UTC
++++ regutil.c
+@@ -52,7 +52,7 @@ static void gettimeofday(struct timeval
+
+ struct {
+ char * name;
+- APIRET (APIENTRY*funcptr)(PUCHAR fname, ULONG argc, PRXSTRING argv, PSZ pSomething, PRXSTRING result);
++ APIRET (APIENTRY*funcptr)(PCSZ fname, ULONG argc, PRXSTRING argv, PCSZ pSomething, PRXSTRING result);
+ } funclist[] = {
+ {"SYSADDREXXMACRO", sysaddrexxmacro},
+ {"SYSCLEARREXXMACROSPACE", sysclearrexxmacrospace},
diff --git a/lang/rexx-regutil/files/patch-rxproto.h b/lang/rexx-regutil/files/patch-rxproto.h
new file mode 100644
index 000000000000..0ddaba75fdf9
--- /dev/null
+++ b/lang/rexx-regutil/files/patch-rxproto.h
@@ -0,0 +1,11 @@
+--- rxproto.h.orig 2003-05-23 11:05:50 UTC
++++ rxproto.h
+@@ -53,7 +53,7 @@
+ * to something else, and a pointer to the result string.
+ * It returns 0 for success, and some other value for failure */
+
+-#define rxfunc(x) APIRET APIENTRY x(PUCHAR fname, ULONG argc, PRXSTRING argv, PSZ pSomething, PRXSTRING result)
++#define rxfunc(x) APIRET APIENTRY x(PCSZ fname, ULONG argc, PRXSTRING argv, PCSZ pSomething, PRXSTRING result)
+
+ /* return codes. 22 is rc for invalid call */
+ #define NOMEMORY 5
diff --git a/lang/rexx-regutil/files/patch-rxsupport.c b/lang/rexx-regutil/files/patch-rxsupport.c
new file mode 100644
index 000000000000..f6cd121edc0c
--- /dev/null
+++ b/lang/rexx-regutil/files/patch-rxsupport.c
@@ -0,0 +1,11 @@
+--- rxsupport.c.orig 2003-09-10 21:09:44 UTC
++++ rxsupport.c
+@@ -612,7 +612,7 @@ int cha_adddummy(chararray *ca, const ch
+ }
+
+ ca->array[ca->count].strlength = len;
+- ca->array[ca->count++].strptr = (unsigned char *)str;
++ ca->array[ca->count++].strptr = (char *)str;
+
+ return 0;
+ }
diff --git a/lang/rexx-regutil/files/pkg-message.in b/lang/rexx-regutil/files/pkg-message.in
deleted file mode 100644
index 7f368ec5195c..000000000000
--- a/lang/rexx-regutil/files/pkg-message.in
+++ /dev/null
@@ -1,5 +0,0 @@
-================================================================================
-
-Documentation can be found in %%DOCSDIR%%/regutil.pdf
-
-================================================================================
diff --git a/lang/rexx-regutil/files/regutil.1.in b/lang/rexx-regutil/files/regutil.1.in
index 40ae3dd95410..5cadb66e3e48 100644
--- a/lang/rexx-regutil/files/regutil.1.in
+++ b/lang/rexx-regutil/files/regutil.1.in
@@ -1,4 +1,4 @@
-.Dd September 3, 2010
+.Dd May 8, 2016
.Dt REGUTIL 1 CON
.Os
.Sh NAME
@@ -11,10 +11,14 @@ These closely mirror the functions contained in the
.Em RexxUtil
library provided
on IBM systems (e.g. OS/2).
+As it stands,
+.Nm
+will not work with another REXX interpreter.
.Pp
Details of usage are in the full manual, which is normally found at:
.br
.Pa %%DOCSDIR%%/regutil.pdf
+(if installed).
.Sh SEE ALSO
The original author's web site at
.Em http://pages.interlog.com/~pjtm/
diff --git a/lang/rexx-regutil/pkg-plist b/lang/rexx-regutil/pkg-plist
deleted file mode 100644
index 825973cb21f1..000000000000
--- a/lang/rexx-regutil/pkg-plist
+++ /dev/null
@@ -1,4 +0,0 @@
-lib/librexxutil.so
-man/man1/regutil.1.gz
-man/man1/rexxutil.1.gz
-%%PORTDOCS%%%%DOCSDIR%%/regutil.pdf