ports/86921: [Maintainer Update] databases/gauche-gdbm link fix, build improvements
Erik Greenwald
erik at smluc.org
Wed Oct 5 04:40:17 UTC 2005
>Number: 86921
>Category: ports
>Synopsis: [Maintainer Update] databases/gauche-gdbm link fix, build improvements
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: maintainer-update
>Submitter-Id: current-users
>Arrival-Date: Wed Oct 05 04:40:16 GMT 2005
>Closed-Date:
>Last-Modified:
>Originator: Erik Greenwald
>Release: FreeBSD 5.4-RELEASE-p6 i386
>Organization:
>Environment:
System: FreeBSD fenris 5.4-RELEASE-p6 FreeBSD 5.4-RELEASE-p6 #3: Thu Aug 11 00:13:25 EDT 2005 root at fenris:/usr/obj/usr/src/sys/FENRIS i386
>Description:
greatly simplify and speed the build process by doing the steps
manually instead of building the lang/gauche wrkdir before starting
the module compile.
pkg-plist is no longer necessary, using PLIST_FILES in the makefile
instead of having two PLIST_SUB lines in the makefile to handle the
two files in pkg-plist.
forces a link against libgdbm, which SHOULD fix the problem noted in
ports/86293 if the issue I was able to replicate was indeed the same
one reported...
tested on i386 5.4 and 7, using athlons.... assuming the link flags
aren't different for other arch's... additional testing/reports
greatly welcomed
Thanks
>How-To-Repeat:
>Fix:
--- databases_gauche-gdbm.patch begins here ---
Index: databases/gauche-gdbm/Makefile
===================================================================
RCS file: /home/ncvs/ports/databases/gauche-gdbm/Makefile,v
retrieving revision 1.30
diff -u -r1.30 Makefile
--- databases/gauche-gdbm/Makefile 26 Jul 2005 08:05:10 -0000 1.30
+++ databases/gauche-gdbm/Makefile 5 Oct 2005 04:22:54 -0000
@@ -7,6 +7,7 @@
PORTNAME= gdbm
PORTVERSION= 0.8.5 # Keep this in sync with lang/gauche
+PORTREVISION= 1
CATEGORIES= databases scheme
MASTER_SITES= # none
PKGNAMEPREFIX= gauche-
@@ -16,7 +17,7 @@
COMMENT= GDBM interface for Gauche
BUILD_DEPENDS= gosh:${PORTSDIR}/${GAUCHE_PORT} \
- ${NONEXISTENT}:${PORTSDIR}/${GAUCHE_PORT}:build
+ ${NONEXISTENT}:${PORTSDIR}/${GAUCHE_PORT}:patch
LIB_DEPENDS= gdbm.3:${PORTSDIR}/databases/gdbm
RUN_DEPENDS= gosh:${PORTSDIR}/${GAUCHE_PORT}
@@ -25,9 +26,9 @@
WRKSRC= ${WRKDIR}/dbm
MAKE_ARGS= GOSH=gosh \
OPTFLAGS="${CFLAGS} -I${LOCALBASE}/include"
-PLIST_SUB= VERSION="${PORTVERSION}" \
- TARGET="${CONFIGURE_TARGET}"
USE_REINPLACE= yes
+PLIST_FILES= lib/gauche/$(PORTVERSION)/${CONFIGURE_TARGET}/gdbm.so \
+ share/gauche/$(PORTVERSION)/lib/dbm/gdbm.scm
GUACHE_BUILDDIR=`cd ${PORTSDIR}/${GAUCHE_PORT} && ${MAKE} -V WRKSRC`
@@ -35,10 +36,21 @@
${MKDIR} ${WRKDIR}
${LN} -sf ${GUACHE_BUILDDIR}/ext/dbm ${WRKDIR}/
-do-configure:
- cd ${WRKSRC} && make clean && ${REINPLACE_CMD} -e 's/^LIBFILES.*/LIBFILES = gdbm.so/' -e 's/^SCMFILES.*/SCMFILES = gdbm.scm/' Makefile
+do-build:
+ cd ${WRKSRC} && ${LOCALBASE}/bin/gauche-config --fixup-extension gdbm
+ cd ${WRKSRC} && ${LOCALBASE}/bin/gosh genstub gdbm.stub
+ cd ${WRKSRC} && $(CC) $(CFLAGS) -c gdbm_head.c
+ cd ${WRKSRC} && $(CC) $(CFLAGS) -c gdbm_tail.c
+ cd ${WRKSRC} && $(CC) $(CFLAGS) -c -I${LOCALBASE}/include \
+ -I'${LOCALBASE}/lib/gauche/${PORTVERSION}/include' gdbm.c
+ cd ${WRKSRC} && $(CC) $(CFLAGS) $(LDFLAGS) -shared -Wl,-x -o gdbm.so \
+ -Wl,-soname,gdbm.so gdbm.o gdbm_head.o gdbm_tail.o \
+ -L${LOCALBASE}/lib -lgdbm
do-install:
- cd ${WRKSRC} && make install-std
+ ${INSTALL_PROGRAM} ${WRKSRC}/gdbm.so \
+ ${LOCALBASE}/lib/gauche/$(PORTVERSION)/${CONFIGURE_TARGET}/gdbm.so
+ ${INSTALL_DATA} ${WRKSRC}/gdbm.scm \
+ ${LOCALBASE}/share/gauche/$(PORTVERSION)/lib/dbm/gdbm.scm
.include <bsd.port.mk>
Index: databases/gauche-gdbm/pkg-plist
===================================================================
RCS file: databases/gauche-gdbm/pkg-plist
diff -N databases/gauche-gdbm/pkg-plist
--- databases/gauche-gdbm/pkg-plist 21 Aug 2003 09:28:55 -0000 1.3
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,2 +0,0 @@
-lib/gauche/%%VERSION%%/%%TARGET%%/gdbm.so
-share/gauche/%%VERSION%%/lib/dbm/gdbm.scm
--- databases_gauche-gdbm.patch ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list