aboutsummaryrefslogtreecommitdiff
path: root/lang
diff options
context:
space:
mode:
authorVanilla I. Shu <vanilla@FreeBSD.org>2014-09-26 03:33:04 +0000
committerVanilla I. Shu <vanilla@FreeBSD.org>2014-09-26 03:33:04 +0000
commit89ce9f982ca1cc51e06eed1ff330dbe1d912420f (patch)
tree47e6182510bc0cae22c2f32b7512e97ce6ff4f41 /lang
parentc15f81bd7cb5ee2575849fd819c6c8d2c2b14684 (diff)
downloadports-89ce9f982ca1cc51e06eed1ff330dbe1d912420f.tar.gz
ports-89ce9f982ca1cc51e06eed1ff330dbe1d912420f.zip
Notes
Diffstat (limited to 'lang')
-rw-r--r--lang/gcl/Makefile71
-rw-r--r--lang/gcl/distinfo4
-rw-r--r--lang/gcl/files/patch-configure45
-rw-r--r--lang/gcl/files/patch-gcl-tk__tkMain.c72
-rw-r--r--lang/gcl/files/patch-h_FreeBSD.h25
-rw-r--r--lang/gcl/files/patch-info_makefile61
-rw-r--r--lang/gcl/files/patch-o-gcl_readline.d20
-rw-r--r--lang/gcl/files/patch-o__nsocket.c11
-rw-r--r--lang/gcl/files/patch-o_file.d2
-rw-r--r--lang/gcl/files/patch-unixport_makefile20
10 files changed, 101 insertions, 230 deletions
diff --git a/lang/gcl/Makefile b/lang/gcl/Makefile
index 3b71ffc71490..ae8d92e578d5 100644
--- a/lang/gcl/Makefile
+++ b/lang/gcl/Makefile
@@ -2,8 +2,7 @@
# $FreeBSD$
PORTNAME= gcl
-PORTVERSION= 2.6.10
-PORTREVISION= 3
+PORTVERSION= 2.6.11
CATEGORIES= lang tcl tk
MASTER_SITES= GNU
@@ -13,19 +12,16 @@ COMMENT= GNU Common Lisp
LICENSE= GPLv2 LGPL21
LICENSE_COMB= multi
+BUILD_DEPENDS= gawk:${PORTSDIR}/lang/gawk
LIB_DEPENDS= libgmp.so:${PORTSDIR}/math/gmp
-OPTIONS_DEFINE= EMACS X11 DOCS
-OPTIONS_DEFAULT=EMACS X11
-EMACS_DESC= Install Emacs syntax files
-
-ONLY_FOR_ARCHS= amd64 i386
-
WRKSRC= ${WRKDIR}/${PORTNAME}
-USES= gmake makeinfo readline
+USES= gmake readline
USE_GCC= yes
GNU_CONFIGURE= yes
+CONFIGURE_ENV= ac_cv_prog_AWK="${LOCALBASE}/bin/gawk" \
+ C_INCLUDE_PATH="${PREFIX}/include" LIBRARY_PATH="${PREFIX}/lib"
CONFIGURE_ARGS= --enable-ansi \
--enable-machine=${OPSYS} \
--enable-emacsdir=${PREFIX}/share/emacs/site-lisp/gcl \
@@ -34,7 +30,6 @@ CONFIGURE_ARGS= --enable-ansi \
--disable-dynsysbfd \
--disable-statsysbfd \
--enable-custreloc
-CONFIGURE_ENV= C_INCLUDE_PATH="${PREFIX}/include" LIBRARY_PATH="${PREFIX}/lib"
MAKEFILE= makefile
INSTALL_TARGET= install-command
LATE_INSTALL_ARGS=\
@@ -65,6 +60,29 @@ PLIST_DIRS= lib/${DISTNAME}/unixport \
lib/${DISTNAME}/clcs \
lib/${DISTNAME}
+ONLY_FOR_ARCHS= amd64 i386
+
+OPTIONS_DEFINE= DOCS EMACS X11
+OPTIONS_DEFAULT= EMACS X11
+
+EMACS_DESC= Install Emacs syntax files
+EMACS_USE= emacs=yes
+EMACS_PLIST_FILES= ${FILES_ELISP:S|^|%%EMACS_SITE_LISPDIR%%/gcl/|}
+EMACS_PLIST_DIRS= %%EMACS_SITE_LISPDIR%%/gcl
+X11_USES= tk
+X11_USE= xorg=x11
+X11_CONFIGURE_ON= --enable-tclconfig=${TCL_LIBDIR} \
+ --enable-tkconfig=${TK_LIBDIR} \
+ --with-x
+X11_CONFIGURE_OFF= --disable-xgcl
+X11_LDFLAGS= -lX11
+X11_PLIST_FILES= ${FILES_GCLTK:S|^|lib/gcl-${PORTVERSION}/gcl-tk/|} \
+ ${FILES_GCLTK_DEMOS:S|^|lib/gcl-${PORTVERSION}/gcl-tk/demos/|} \
+ ${FILES_XGCL2:S|^|lib/gcl-${PORTVERSION}/xgcl-2/|}
+X11_PLIST_DIRS= lib/${DISTNAME}/xgcl-2 \
+ lib/${DISTNAME}/gcl-tk/demos \
+ lib/${DISTNAME}/gcl-tk
+
FILES_CLCS= sys-proclaim.lisp
FILES_CMPNEW= gcl_cmpmain.lsp gcl_cmpopt.lsp gcl_collectfn.lsp \
gcl_collectfn.o gcl_lfun_list.lsp sys-proclaim.lisp
@@ -93,27 +111,7 @@ FILES_XGCL2= gcl_dwtest.lsp gcl_dwtestcases.lsp sysdef.lisp
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MEMACS}
-USE_EMACS= yes
EMACS_NO_BUILD_DEPENDS=yes
-PLIST_FILES+= ${FILES_ELISP:S|^|%%EMACS_SITE_LISPDIR%%/gcl/|}
-PLIST_DIRS+= %%EMACS_SITE_LISPDIR%%/gcl
-.endif
-
-.if ${PORT_OPTIONS:MX11}
-USES+= tk
-USE_XORG= x11
-CONFIGURE_ARGS+=--enable-tclconfig=${TCL_LIBDIR} \
- --enable-tkconfig=${TK_LIBDIR} \
- --with-x
-LDFLAGS+= -lX11
-PLIST_FILES+= ${FILES_GCLTK:S|^|lib/gcl-${PORTVERSION}/gcl-tk/|} \
- ${FILES_GCLTK_DEMOS:S|^|lib/gcl-${PORTVERSION}/gcl-tk/demos/|} \
- ${FILES_XGCL2:S|^|lib/gcl-${PORTVERSION}/xgcl-2/|}
-PLIST_DIRS+= lib/${DISTNAME}/xgcl-2 \
- lib/${DISTNAME}/gcl-tk/demos \
- lib/${DISTNAME}/gcl-tk
-.else
-CONFIGURE_ARGS+=--disable-xgcl
.endif
post-patch:
@@ -155,11 +153,14 @@ post-install:
${STAGEDIR}${PREFIX}/lib/${DISTNAME}/pcl)
.endfor
@${MKDIR} ${STAGEDIR}${PREFIX}/lib/${DISTNAME}/unixport
-.for i in ${FILES_UNIXPORT}
+.for i in saved_ansi_gcl
+ (cd ${WRKSRC}/unixport && ${INSTALL_PROGRAM} ${i} \
+ ${STAGEDIR}${PREFIX}/lib/${DISTNAME}/unixport)
+.endfor
+.for i in ${FILES_UNIXPORT:Nsaved_ansi_gcl}
(cd ${WRKSRC}/unixport && ${INSTALL_DATA} ${i} \
${STAGEDIR}${PREFIX}/lib/${DISTNAME}/unixport)
.endfor
- @${CHMOD} a+x ${STAGEDIR}${PREFIX}/lib/${DISTNAME}/unixport/saved_ansi_gcl
.if ${PORT_OPTIONS:MEMACS}
@${MKDIR} ${STAGEDIR}${PREFIX}/${EMACS_SITE_LISPDIR}/gcl
.for i in ${FILES_ELISP}
@@ -169,7 +170,11 @@ post-install:
.endif
.if ${PORT_OPTIONS:MX11}
@${MKDIR} ${STAGEDIR}${PREFIX}/lib/${DISTNAME}/gcl-tk
-.for i in ${FILES_GCLTK}
+.for i in gcltkaux
+ (cd ${WRKSRC}/gcl-tk && ${INSTALL_LIB} ${i} \
+ ${STAGEDIR}${PREFIX}/lib/${DISTNAME}/gcl-tk)
+.endfor
+.for i in ${FILES_GCLTK:Ngcltkaux}
(cd ${WRKSRC}/gcl-tk && ${INSTALL_DATA} ${i} \
${STAGEDIR}${PREFIX}/lib/${DISTNAME}/gcl-tk)
.endfor
diff --git a/lang/gcl/distinfo b/lang/gcl/distinfo
index 331f4d78cf43..30540e41bcf0 100644
--- a/lang/gcl/distinfo
+++ b/lang/gcl/distinfo
@@ -1,2 +1,2 @@
-SHA256 (gcl-2.6.10.tar.gz) = 79a1fb2f92b5e86f24988448db3e34116ab6ef7c93ad839848edd01ad06651ef
-SIZE (gcl-2.6.10.tar.gz) = 5490689
+SHA256 (gcl-2.6.11.tar.gz) = 44058f029a631e8ebae38c6c5a25e2f986b5bfdd8e6283b32d7e56723efafb9c
+SIZE (gcl-2.6.11.tar.gz) = 7047082
diff --git a/lang/gcl/files/patch-configure b/lang/gcl/files/patch-configure
index f6f2bdbf07e6..d50dd788a977 100644
--- a/lang/gcl/files/patch-configure
+++ b/lang/gcl/files/patch-configure
@@ -1,31 +1,32 @@
--- configure 2005-01-15 11:17:17.000000000 -0800
+++ configure 2007-09-22 18:17:38.000000000 -0700
-@@ -4998,7 +4998,7 @@
+@@ -5087,7 +5087,7 @@
TLIBS="$TLIBS -lgmp"
echo "#include \"gmp.h\"" >foo.c
echo "int main() {return 0;}" >>foo.c
-- MP_INCLUDE=`cpp foo.c | grep /gmp.h | head -n 1 | $AWK '{print $3}' | tr -d '"'`
-+ MP_INCLUDE=`$CPP $CPPFLAGS foo.c | grep /gmp.h | head -n 1 | $AWK '{print $3}' | tr -d '"'`
+- MP_INCLUDE=`cpp foo.c | $AWK '/(\/|\\\\)gmp.h/ {if (!i) print $3;i=1}' | tr -d '"'`
++ MP_INCLUDE=`$CPP $CPPFLAGS foo.c | $AWK '/(\/|\\\\)gmp.h/ {if (!i) print $3;i=1}' | tr -d '"'`
rm -f foo.c
else
echo "Cannot use dynamic gmp lib"
-@@ -8399,15 +8399,15 @@
- if test -f ${TK_CONFIG_PREFIX}/../include/tk.h ; then
- TK_INCLUDE=-I${TK_CONFIG_PREFIX}/../include
- else
-- if test -f /usr/include/tcl${TCL_VERSION}/tk.h ; then
-- TK_INCLUDE=-I/usr/include/tcl${TCL_VERSION}
-+ if test -f ${TK_CONFIG_PREFIX}/../../include/tk${TCL_VERSION}/tk.h ; then
-+ TK_INCLUDE=-I${TK_CONFIG_PREFIX}/../../include/tk${TCL_VERSION}
- fi
- fi
- if test -f ${TCL_CONFIG_PREFIX}/../include/tcl.h ; then
- TCL_INCLUDE=-I${TCL_CONFIG_PREFIX}/../include
- else
-- if test -f /usr/include/tcl${TCL_VERSION}/tcl.h ; then
-- TCL_INCLUDE=-I/usr/include/tcl${TCL_VERSION}
-+ if test -f ${TK_CONFIG_PREFIX}/../../include/tcl${TCL_VERSION}/tcl.h ; then
-+ TCL_INCLUDE=-I${TK_CONFIG_PREFIX}/../../include/tcl${TCL_VERSION}
- fi
- fi
+@@ -9043,16 +9043,16 @@
+ if test -f ${TCL_CONFIG_PREFIX}/../include/tcl.h ; then
+ TCL_INCLUDE=-I${TCL_CONFIG_PREFIX}/../include
+ else
+- if test -f /usr/include/tcl${TCL_VERSION}/tcl.h ; then
+- TCL_INCLUDE=-I/usr/include/tcl${TCL_VERSION}
++ if test -f ${TCL_CONFIG_PREFIX}/../../include/tcl${TCL_VERSION}/tcl.h ; then
++ TCL_INCLUDE=-I${TCL_CONFIG_PREFIX}/../../include/tcl${TCL_VERSION}
+ fi
+ fi
+
+ if test -f ${TK_CONFIG_PREFIX}/../include/tk.h ; then
+ TK_INCLUDE=-I${TK_CONFIG_PREFIX}/../include
+ else
+- if test -f /usr/include/tcl${TCL_VERSION}/tk.h ; then
+- TK_INCLUDE=-I/usr/include/tcl${TCL_VERSION}
++ if test -f ${TK_CONFIG_PREFIX}/../../include/tk${TCL_VERSION}/tk.h ; then
++ TK_INCLUDE=-I${TK_CONFIG_PREFIX}/../../include/tk${TCL_VERSION}
+ fi
+ fi
diff --git a/lang/gcl/files/patch-gcl-tk__tkMain.c b/lang/gcl/files/patch-gcl-tk__tkMain.c
deleted file mode 100644
index 69c369c2bc47..000000000000
--- a/lang/gcl/files/patch-gcl-tk__tkMain.c
+++ /dev/null
@@ -1,72 +0,0 @@
---- gcl-tk/tkMain.c.orig
-+++ gcl-tk/tkMain.c
-@@ -206,7 +206,7 @@
-
- if (Tk_ParseArgv(interp, (Tk_Window) NULL, &argc, (const char **)argv, argTable, 0)
- != TCL_OK) {
-- fprintf(stderr, "%s\n", interp->result);
-+ fprintf(stderr, "%s\n", Tcl_GetStringResult(interp));
- exit(1);
- }
- if (name == NULL) {
-@@ -290,7 +290,7 @@
- */
-
- if (Tcl_AppInit(interp) != TCL_OK) {
-- fprintf(stderr, "Tcl_AppInit failed: %s\n", interp->result);
-+ fprintf(stderr, "Tcl_AppInit failed: %s\n", Tcl_GetStringResult(interp));
- }
-
- /*
-@@ -300,7 +300,7 @@
- if (geometry != NULL) {
- code = Tcl_VarEval(interp, "wm geometry . ", geometry, (char *) NULL);
- if (code != TCL_OK) {
-- fprintf(stderr, "%s\n", interp->result);
-+ fprintf(stderr, "%s\n", Tcl_GetStringResult(interp));
- }
- }
-
-@@ -330,13 +330,13 @@
-
- fullName = Tcl_TildeSubst(interp, tcl_RcFileName, &buffer);
- if (fullName == NULL) {
-- fprintf(stderr, "%s\n", interp->result);
-+ fprintf(stderr, "%s\n", Tcl_GetStringResult(interp));
- } else {
- f = fopen(fullName, "r");
- if (f != NULL) {
- code = Tcl_EvalFile(interp, fullName);
- if (code != TCL_OK) {
-- fprintf(stderr, "%s\n", interp->result);
-+ fprintf(stderr, "%s\n", Tcl_GetStringResult(interp));
- }
- fclose(f);
- }
-@@ -371,7 +371,7 @@
- error:
- msg = Tcl_GetVar(interp, "errorInfo", TCL_GLOBAL_ONLY);
- if (msg == NULL) {
-- msg = interp->result;
-+ msg = Tcl_GetStringResult(interp);
- }
- dfprintf(stderr, "%s\n", msg);
- Tcl_Eval(interp, errorExitCmd);
-@@ -502,7 +502,7 @@
- bcopy(msg->msg_id,p,3);
- /* end header */
- if(sock_write_str2(dsfd, m_reply, buf, 4 ,
-- interp->result, strlen(interp->result))
-+ Tcl_GetStringResult(interp), strlen(Tcl_GetStringResult(interp)))
- < 0)
- { /* what do we want to do if the write failed */}
-
-@@ -686,7 +686,7 @@
- code = Tcl_Eval(interp, szCmd);
- if (code != TCL_OK)
- {
-- dfprintf(stderr, "TCL Error int bind : %s\n", interp->result);
-+ dfprintf(stderr, "TCL Error int bind : %s\n", Tcl_GetStringResult(interp));
-
- }
- return code;
diff --git a/lang/gcl/files/patch-h_FreeBSD.h b/lang/gcl/files/patch-h_FreeBSD.h
index 0717c5605c65..1dd4c50c2094 100644
--- a/lang/gcl/files/patch-h_FreeBSD.h
+++ b/lang/gcl/files/patch-h_FreeBSD.h
@@ -28,6 +28,15 @@
#define I386
#endif
+@@ -48,7 +56,7 @@
+ int c = 0; \
+ \
+ if ( \
+- (fp)->_r <= 0 && \
++ ((FILE *)fp)->_r <= 0 && \
+ (ioctl(((FILE *)fp)->_file, FIONREAD, &c), c <= 0) \
+ ) \
+ return(FALSE); \
@@ -68,7 +76,11 @@
#ifdef CLOCKS_PER_SEC
#define HZ CLOCKS_PER_SEC
@@ -41,19 +50,3 @@
#endif
/* #define ss_base ss_sp */
-@@ -79,6 +91,7 @@
- #define HAVE_SIGPROCMASK
- #define SIG_STACK_SIZE (SIGSTKSZ/sizeof(double))
-
-+/*
- #undef SETUP_SIG_STACK
- #define SETUP_SIG_STACK { \
- static struct sigaltstack estack; \
-@@ -90,6 +103,7 @@
- if (sigaltstack(&estack, 0) < 0) \
- perror("sigaltstack"); \
- }
-+ */
-
- #undef INSTALL_SEGMENTATION_CATCHER
- #define INSTALL_SEGMENTATION_CATCHER \
diff --git a/lang/gcl/files/patch-info_makefile b/lang/gcl/files/patch-info_makefile
index 4a5819e97097..19eb318ed280 100644
--- a/lang/gcl/files/patch-info_makefile
+++ b/lang/gcl/files/patch-info_makefile
@@ -5,68 +5,21 @@ retrieving revision 1.23.6.4.2.1
diff -u -d -r1.23.6.4.2.1 makefile
--- info/makefile 25 Jun 2004 22:40:25 -0000 1.23.6.4.2.1
+++ info/makefile 18 Aug 2004 16:29:48 -0000
-@@ -11,12 +11,12 @@
+@@ -12,12 +12,11 @@
-include ../makedefs
--all: gcl-tk.info gcl-si.info $(GCL_DVI) $(GCL_HTML) #gcl.info
+-all: gcl-tk.info gcl-si.info $(GCL_PDF) $(GCL_HTML) #gcl.info
+all: gcl-tk.info gcl-si.info
.texi.info:
-- rm -f $*.*gz
-- -$(MAKEINFO) $*.texi
+ rm -f $*.*gz
+ -$(MAKEINFO) $*.texi
- - gzip $*.info-*
-+ rm -f $*gz
-+ rm -f $*.info
-+ -$(MAKEINFO) --no-split $*.texi
GCL_SI= number.texi sequence.texi character.texi list.texi io.texi \
form.texi compile.texi symbol.texi system.texi structure.texi \
-@@ -34,19 +34,16 @@
- TEXINPUTS=.:$$TEXINPUTS tex --interaction nonstopmode gcl-si.texi || true
-
- gcl-si.info: ${GCL_SI} gcl-si.texi
-- -$(MAKEINFO) gcl-si.texi
-
- gcl-tk.dvi: ${GCL_TK} gcl-tk.texi
- TEXINPUTS=.:$$TEXINPUTS tex --interaction nonstopmode gcl-tk.texi || true
-
- gcl-tk.info: ${GCL_TK} gcl-tk.texi
-- -$(MAKEINFO) gcl-tk.texi
-
- gcl.dvi: ${GCL_MAN} gcl.texi
- TEXINPUTS=.:$$TEXINPUTS tex --interaction nonstopmode gcl.texi || true
-
- gcl.info: ${GCL_MAN} gcl.texi
-- -$(MAKEINFO) gcl.texi
-
- #gcl-si_toc.html: ${GCL_SI} gcl-si.texi
- # $(HTML_CMD) gcl-si.texi
-@@ -69,15 +66,15 @@
- install-html: gcl-tk_toc.html gcl-si_toc.html gcl_toc.html
- cp *.html /d/www/gcl
-
--install: $(GCL_DVI) $(GCL_HTML)
-+install:
- mkdir -p $(DESTDIR)${INFO_DIR}
-- [ -f $(DESTDIR)$(INFO_DIR)dir ] || touch $(DESTDIR)$(INFO_DIR)dir
-- grep gcl-si $(DESTDIR)${INFO_DIR}dir >/dev/null 2>&1 || \
-- echo "* GCL Doc: (gcl-si.info). GNU Common Lisp specific Documentation." >> $(DESTDIR)${INFO_DIR}dir
-- grep gcl-tk $(DESTDIR)${INFO_DIR}dir >/dev/null 2>&1 || \
-- echo "* GCL TK Doc: (gcl-tk.info). TK window GCL interface." >> $(DESTDIR)${INFO_DIR}dir
-- grep gcl.info $(DESTDIR)${INFO_DIR}dir >/dev/null 2>&1 || \
-- echo "* GCL Ansi Doc: (gcl.info). Ansi Common Lisp Specification." >> $(DESTDIR)${INFO_DIR}dir
-+ [ -f $(DESTDIR)$(INFO_DIR)/dir ] || touch $(DESTDIR)$(INFO_DIR)/dir
-+ grep gcl-si $(DESTDIR)${INFO_DIR}/dir >/dev/null 2>&1 || \
-+ echo "* GCL Doc: (gcl-si.info). GNU Common Lisp specific Documentation." >> $(DESTDIR)${INFO_DIR}/dir
-+ grep gcl-tk $(DESTDIR)${INFO_DIR}/dir >/dev/null 2>&1 || \
-+ echo "* GCL TK Doc: (gcl-tk.info). TK window GCL interface." >> $(DESTDIR)${INFO_DIR}/dir
-+ grep gcl.info $(DESTDIR)${INFO_DIR}/dir >/dev/null 2>&1 || \
-+ echo "* GCL Ansi Doc: (gcl.info). Ansi Common Lisp Specification." >> $(DESTDIR)${INFO_DIR}/dir
- -cp *.info* $(DESTDIR)${INFO_DIR}
- # -mkdir -p $(DESTDIR)$(INFO_DIR)../doc/gcl-doc/gcl.html
- # -mkdir -p $(DESTDIR)$(INFO_DIR)../doc/gcl-doc/gcl-si.html
-@@ -88,10 +85,10 @@
+@@ -98,10 +97,10 @@
# -cp gcl/* $(DESTDIR)$(INFO_DIR)../doc/gcl-doc/gcl.html
# -cp gcl-si/* $(DESTDIR)$(INFO_DIR)../doc/gcl-doc/gcl-si.html
# -cp gcl-tk/* $(DESTDIR)$(INFO_DIR)../doc/gcl-doc/gcl-tk.html
@@ -74,9 +27,9 @@ diff -u -d -r1.23.6.4.2.1 makefile
+# -mkdir -p $(DESTDIR)$(INFO_DIR)../doc
# -cp -r gcl-si gcl gcl-tk $(DESTDIR)$(INFO_DIR)../doc
- -cp -r gcl-si gcl-tk $(DESTDIR)$(INFO_DIR)../doc
-- -cp *dvi $(DESTDIR)$(INFO_DIR)../doc
+- -cp *pdf $(DESTDIR)$(INFO_DIR)../doc
+# -cp -r gcl-si gcl-tk $(DESTDIR)$(INFO_DIR)../doc
-+# -cp *dvi $(DESTDIR)$(INFO_DIR)../doc
++# -cp *pdf $(DESTDIR)$(INFO_DIR)../doc
FILE=gcl-si.texi
srcs:
diff --git a/lang/gcl/files/patch-o-gcl_readline.d b/lang/gcl/files/patch-o-gcl_readline.d
deleted file mode 100644
index d4bded9a6c3d..000000000000
--- a/lang/gcl/files/patch-o-gcl_readline.d
+++ /dev/null
@@ -1,20 +0,0 @@
---- o/gcl_readline.d.orig
-+++ o/gcl_readline.d
-@@ -221,7 +221,7 @@
- in case we want to do some simple parsing. Return the array of matches,
- or NULL if there aren't any. */
- /* extern char **rl_completion_matches(char *,char *(*)(char *,int)); */
--static char **rl_completion(char *text, int start, int end) {
-+static char **rl_completion(const char *text, int start, int end) {
- return rl_completion_matches(text, (rl_compentry_func_t *)rl_completion_words_new);
- }
- #endif
-@@ -469,7 +469,7 @@
- char *pn="GCL",*cp=getenv("TERM");
- rl_readline_name=pn;
- #ifdef RL_COMPLETION
-- rl_attempted_completion_function = (CPPFunction *)rl_completion;
-+ rl_attempted_completion_function = rl_completion;
- #endif
- if (isatty(0) && (!cp || strcmp(cp,"dumb")))
- readline_on=1;
diff --git a/lang/gcl/files/patch-o__nsocket.c b/lang/gcl/files/patch-o__nsocket.c
new file mode 100644
index 000000000000..483ef5c38a38
--- /dev/null
+++ b/lang/gcl/files/patch-o__nsocket.c
@@ -0,0 +1,11 @@
+--- o/nsocket.c.orig
++++ o/nsocket.c
+@@ -328,7 +328,7 @@
+
+
+
+-#define SOCKET_FD(strm) ((strm)->sm.sm_fp ? fileno((strm)->sm.sm_fp) : -1)
++#define SOCKET_FD(strm) ((strm)->sm.sm_fp ? fileno((FILE *)(strm)->sm.sm_fp) : -1)
+
+ static void
+ check_socket(object x)
diff --git a/lang/gcl/files/patch-o_file.d b/lang/gcl/files/patch-o_file.d
index 66fc312d3f2a..14255443549d 100644
--- a/lang/gcl/files/patch-o_file.d
+++ b/lang/gcl/files/patch-o_file.d
@@ -5,7 +5,7 @@
#include <signal.h>
-#if defined(DARWIN)
-+#if defined(BSD)
++#if defined(DARWIN) || defined(__FreeBSD__)
#define on_exit(a,b)
#else
static void
diff --git a/lang/gcl/files/patch-unixport_makefile b/lang/gcl/files/patch-unixport_makefile
index 2eb4a531c881..25b1ca65148b 100644
--- a/lang/gcl/files/patch-unixport_makefile
+++ b/lang/gcl/files/patch-unixport_makefile
@@ -1,15 +1,15 @@
--- unixport/makefile 2005-01-15 11:34:45.000000000 -0500
+++ unixport/makefile 2009-12-07 12:35:23.000000000 -0500
-@@ -18,7 +18,7 @@
-
- LD_FLAGS=$(LDFLAGS) $(FIRST_FILE)
- LD_LIBS_PRE=$(addprefix -u ,$(PATCHED_SYMBOLS))
--LD_LIBS_POST=$(LIBS) $(LIBC) -lgclp $(LAST_FILE)
-+LD_LIBS_POST=-lgclp $(LIBS) $(LAST_FILE)
-
- ifeq ($(ARRS),)
- ARRS:=ar rs
-@@ -127,7 +127,7 @@
+@@ -21,7 +21,7 @@
+ LD_FLAGS:=$(LD_FLAGS) $(ODIR)/$(FIRST_FILE)
+ endif
+ LD_LIBS_PRE:=$(addprefix -u ,$(PATCHED_SYMBOLS))
+-LD_LIBS_POST:=$(LIBS) $(LIBC) -lgclp
++LD_LIBS_POST:=-lgclp $(LIBS) $(LIBC)
+ ifneq ($(LAST_FILE),)
+ LD_LIBS_POST:=$(LD_LIBS_POST) $(ODIR)/$(LAST_FILE)
+ endif
+@@ -139,7 +139,7 @@
$(CC) $(LD_FLAGS) $(CFLAGS) -I$(HDIR) -I$(ODIR) -o $(RSYM) $(SPECIAL_RSYM)
msys: msys.c