ports/97960: [PATCH] chinese/libtabe: update to 0.2.6
Rong-En Fan
rafan at infor.org
Fri May 26 16:10:33 UTC 2006
>Number: 97960
>Category: ports
>Synopsis: [PATCH] chinese/libtabe: update to 0.2.6
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: update
>Submitter-Id: current-users
>Arrival-Date: Fri May 26 16:10:19 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator: Rong-En Fan
>Release: FreeBSD 7.0-CURRENT i386
>Organization:
NTU CSIE
>Environment:
System: FreeBSD woodstock.rafan.org 7.0-CURRENT FreeBSD 7.0-CURRENT #3: Wed May 17 00:28:05 EDT 2006
>Description:
- Update to 0.2.6
Some patches were merged into upstream. configure is also slightly changed
to support all BDB versions.
It seems libtabe can be used on amd64, tested by yinjieh at csie.nctu.edu.tw
with xcin25. Remove amd64 from arch exclude list.
- Shared library version bumped. Bump comsumers's (xcin25 and p5-Lingua-ZH-TaBE)
PORTREVISION.
For p5-Lingua-ZH-TaBE, warning messages are shown if WITH_BDB_VERSION is
defined.
- s/ECHO/ECHO_CMD/ for xcin25.
Removed file(s):
- files/patch-aa
- files/patch-ab
Port maintainer (kcwu at csie.org) is cc'd.
Port maintainer (clsung at FreeBSD.org) is cc'd.
Generated with FreeBSD Port Tools 0.77
>How-To-Repeat:
>Fix:
--- libtabe-0.2.6.patch begins here ---
diff -ruN --exclude=CVS /usr/ports/chinese/libtabe/Makefile /home/rafan/tmp/ports/b/0.2.6/libtabe/Makefile
--- /usr/ports/chinese/libtabe/Makefile Mon May 22 21:13:40 2006
+++ /home/rafan/tmp/ports/b/0.2.6/libtabe/Makefile Thu May 25 22:07:22 2006
@@ -6,21 +6,18 @@
#
PORTNAME= libtabe
-PORTVERSION= 0.2.5
-PORTREVISION= 3
+PORTVERSION= 0.2.6
CATEGORIES= chinese
-MASTER_SITES= ftp://ftp.linux.org.tw/pub/xcin/libtabe/devel/
+MASTER_SITES= ftp://cle.linux.org.tw/pub/xcin/cvs/
MAINTAINER= kcwu at csie.org
COMMENT= Unified library for Chinese text processing
-WRKSRC= ${WRKDIR}/libtabe
INSTALLS_SHLIB= yes
HAS_CONFIGURE= yes
USE_GMAKE= yes
USE_BDB= yes
OBSOLETE_BDB_VAR= USE_DB2
-NOT_FOR_ARCHS= amd64
DATADIR= ${PREFIX}/share/tabe
DOCSDIR= ${PREFIX}/share/doc/tabe
CONFIGURE_ARGS= --prefix=${PREFIX} \
@@ -31,6 +28,8 @@
--with-db-bin=${LOCALBASE}/bin \
--enable-shared
+.include <bsd.port.pre.mk>
+
.if !defined(WITHOUT_X11)
USE_XLIB= yes
PLIST_SUB+= X11=""
@@ -39,16 +38,15 @@
PLIST_SUB+= X11="@comment "
.endif
-.include <bsd.port.pre.mk>
-
pre-everything::
.if defined(WITH_BDB_VER)
- @${ECHO} ""
- @${ECHO} "WARNING:"
- @${ECHO} " You have defined WITH_BDB_VER. Make sure you use the same"
- @${ECHO} " db version for all ports that use libtabe, such as xcin."
- @${ECHO} " Otherwise, ports that use libtabe may not work correctly."
- @${ECHO} ""
+pre-everything::
+ @${ECHO_CMD} ""
+ @${ECHO_CMD} "WARNING:"
+ @${ECHO_CMD} " You have defined WITH_BDB_VER. Make sure you use the same"
+ @${ECHO_CMD} " db version for all ports that use libtabe, such as xcin."
+ @${ECHO_CMD} " Otherwise, ports that use libtabe may not work correctly."
+ @${ECHO_CMD} ""
.endif
post-patch:
@@ -68,7 +66,5 @@
${INSTALL_DATA} ${WRKSRC}/doc/${DOC} ${DOCSDIR}
.endfor
.endif
- ${MKDIR} ${DATADIR}
- ${TOUCH} ${DATADIR}/${PORTNAME}-${PORTVERSION}
.include <bsd.port.post.mk>
diff -ruN --exclude=CVS /usr/ports/chinese/libtabe/distinfo /home/rafan/tmp/ports/b/0.2.6/libtabe/distinfo
--- /usr/ports/chinese/libtabe/distinfo Sun Jan 22 03:21:03 2006
+++ /home/rafan/tmp/ports/b/0.2.6/libtabe/distinfo Sat May 20 15:38:21 2006
@@ -1,3 +1,3 @@
-MD5 (libtabe-0.2.5.tar.gz) = 8b03826b2858ae999b18d41099eb73c9
-SHA256 (libtabe-0.2.5.tar.gz) = 2223f81502a418a7fe6ea98217fe59cd54e7a308da7be38729b46120db0b7038
-SIZE (libtabe-0.2.5.tar.gz) = 1615825
+MD5 (libtabe-0.2.6.tar.gz) = 9e388ce6c13dacfe595bf31c54c2aaf9
+SHA256 (libtabe-0.2.6.tar.gz) = 02b3f2e39958978dd6a1ffd95f892b7b9a087622dac409f2dbf8f325668714b6
+SIZE (libtabe-0.2.6.tar.gz) = 1788455
diff -ruN --exclude=CVS /usr/ports/chinese/libtabe/files/patch-aa /home/rafan/tmp/ports/b/0.2.6/libtabe/files/patch-aa
--- /usr/ports/chinese/libtabe/files/patch-aa Wed Apr 17 06:51:53 2002
+++ /home/rafan/tmp/ports/b/0.2.6/libtabe/files/patch-aa Wed Dec 31 19:00:00 1969
@@ -1,12 +0,0 @@
---- src/Makefile.in.orig Wed Dec 5 13:56:10 2001
-+++ src/Makefile.in Wed Dec 5 13:56:23 2001
-@@ -55,8 +55,7 @@
-
- $(LIBNAME): $(LIBOBJS)
- $(LIBTOOL) --mode=link $(CC) -o $@ $(LIBOBJS) -rpath $(libdir) \
-- -version-info $(CURRENT_VER):$(REVISION_VER):$(AGE_VER) \
-- -release $(RELEASE_VER)
-+ -version-info $(CURRENT_VER):$(REVISION_VER):$(AGE_VER)
-
- bims:
- (cd supports/bims; $(MAKE))
diff -ruN --exclude=CVS /usr/ports/chinese/libtabe/files/patch-ab /home/rafan/tmp/ports/b/0.2.6/libtabe/files/patch-ab
--- /usr/ports/chinese/libtabe/files/patch-ab Wed Apr 17 06:51:53 2002
+++ /home/rafan/tmp/ports/b/0.2.6/libtabe/files/patch-ab Wed Dec 31 19:00:00 1969
@@ -1,12 +0,0 @@
---- src/supports/bims/Makefile.in.orig Wed Dec 5 13:56:40 2001
-+++ src/supports/bims/Makefile.in Wed Dec 5 13:56:47 2001
-@@ -45,8 +45,7 @@
-
- $(LIBNAME): $(LIBOBJS)
- $(LIBTOOL) --mode=link $(CC) -o $@ $(LIBOBJS) -rpath $(libdir) \
-- -version-info $(CURRENT_VER):$(REVISION_VER):$(AGE_VER) \
-- -release $(RELEASE_VER)
-+ -version-info $(CURRENT_VER):$(REVISION_VER):$(AGE_VER)
-
- bims.lo: bims.c bims.h
- $(LIBTOOL) --mode=compile $(CC) -c $(CFLAGS) $(DEFS) $(INC) -o $@ bims.c
diff -ruN --exclude=CVS /usr/ports/chinese/libtabe/files/patch-configure /home/rafan/tmp/ports/b/0.2.6/libtabe/files/patch-configure
--- /usr/ports/chinese/libtabe/files/patch-configure Mon May 22 21:13:40 2006
+++ /home/rafan/tmp/ports/b/0.2.6/libtabe/files/patch-configure Sat May 20 15:30:57 2006
@@ -1,69 +1,46 @@
---- configure.orig Sat Oct 20 07:03:29 2001
-+++ configure Mon May 1 10:53:24 2006
-@@ -22,6 +22,8 @@
- ac_help="$ac_help
- --with-db-bin=PATH set the binary dir of Berkeley DB2/3."
- ac_help="$ac_help
-+ --with-db-name=NAME set the library name of Berkeley DB."
-+ac_help="$ac_help
- --enable-shared[=PKGS] build shared libraries [default=yes]"
- ac_help="$ac_help
- --enable-static[=PKGS] build static libraries [default=yes]"
-@@ -790,6 +792,14 @@
- :
- fi
-
-+# Check whether --with-db_name or --without-db_name was given.
-+if test "${with_db_name+set}" = set; then
-+ withval="$with_db_name"
-+ test x$withval != x && with_db_name="$withval"
-+else
-+ with_db_name='db'
-+fi;
-+
-
- if test "$program_prefix" != NONE; then
- program_prefix="$program_prefix/"
-@@ -5315,18 +5325,22 @@
- cat conftest.$ac_ext >&5
- fi
- rm -f conftest*
--test "$ac_cv_search_db_create" = "no" && for i in db db3; do
-+test "$ac_cv_search_db_create" = "no" && for i in $with_db_name; do
- LIBS="-l$i $ac_func_search_save_LIBS"
+--- configure.orig Mon Sep 20 01:16:48 2004
++++ configure Sat Apr 22 01:18:43 2006
+@@ -18984,6 +18984,10 @@
+ else
+ ac_check_lib_save_LIBS=$LIBS
+ LIBS="-l$dbname $LIBS"
+__db_create="db_create"
-+if [ "$i" = "db-4.2" ]; then
++if [ "$dbname" = "db-4.2" ]; then
+ __db_create="db_create_4002"
+fi
- cat > conftest.$ac_ext <<EOF
- #line 5322 "configure"
- #include "confdefs.h"
- /* Override any gcc2 internal prototype to avoid an error. */
+ cat >conftest.$ac_ext <<_ACEOF
+ /* confdefs.h. */
+ _ACEOF
+@@ -18997,11 +19001,11 @@
+ #endif
/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
--char db_create();
-+char $__db_create();
+ builtin and then its argument prototype would still apply. */
+-char db_create ();
++char $__db_create ();
+ int
+ main ()
+ {
+-db_create ();
++$__db_create ();
+ ;
+ return 0;
+ }
+@@ -19253,7 +19257,9 @@
+ #endif
+ if(errno) return errno;
- int main() {
--db_create()
-+$__db_create()
- ; return 0; }
- EOF
- if { (eval echo configure:5333: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-@@ -5385,7 +5399,7 @@
- cat conftest.$ac_ext >&5
- fi
- rm -f conftest*
--test "$ac_cv_search_db_open" = "no" && for i in db db2; do
-+test "$ac_cv_search_db_open" = "no" && for i in $with_db_name; do
- LIBS="-l$i $ac_func_search_save_LIBS"
- cat > conftest.$ac_ext <<EOF
- #line 5392 "configure"
-@@ -6219,6 +6233,7 @@
- s%@with_db_inc@%$with_db_inc%g
- s%@with_db_lib@%$with_db_lib%g
- s%@with_db_bin@%$with_db_bin%g
-+s%@with_db_name@%$with_db_name%g
- s%@USE_DB@%$USE_DB%g
- s%@x_includes@%$x_includes%g
- s%@x_libraries@%$x_libraries%g
+-#if DB_VERSION >= 303011
++#if DB_VERSION >= 403000
++errno = dbp->stat(dbp, NULL, &sp, 0);
++#elif DB_VERSION >= 303011
+ errno = dbp->stat(dbp, &sp, 0);
+ #else
+ errno = dbp->stat(dbp, &sp, NULL, 0);
+@@ -20833,6 +20839,7 @@
+ s, at with_db_inc@,$with_db_inc,;t t
+ s, at with_db_lib@,$with_db_lib,;t t
+ s, at with_db_bin@,$with_db_bin,;t t
++s, at with_db_name@,$with_db_name,;t t
+ s, at x_includes@,$x_includes,;t t
+ s, at x_libraries@,$x_libraries,;t t
+ s, at build_supports@,$build_supports,;t t
diff -ruN --exclude=CVS /usr/ports/chinese/libtabe/files/patch-src::tabe_tsidbint.c /home/rafan/tmp/ports/b/0.2.6/libtabe/files/patch-src::tabe_tsidbint.c
--- /usr/ports/chinese/libtabe/files/patch-src::tabe_tsidbint.c Mon May 22 21:13:40 2006
+++ /home/rafan/tmp/ports/b/0.2.6/libtabe/files/patch-src::tabe_tsidbint.c Sat May 20 15:30:58 2006
@@ -1,113 +1,13 @@
---- src/tabe_tsidbint.c.orig Sun Nov 11 07:33:07 2001
-+++ src/tabe_tsidbint.c Mon May 1 00:47:55 2006
-@@ -27,6 +27,7 @@
- #endif
-
- #include "tabe.h"
-+#define DB_VERSION (DB_VERSION_MAJOR*100000+DB_VERSION_MINOR*1000+DB_VERSION_PATCH)
-
- static void tabeTsiDBClose(struct TsiDB *tsidb);
- static int tabeTsiDBRecordNumber(struct TsiDB *tsidb);
-@@ -69,7 +70,7 @@
- {
- DB *dbp=NULL;
-
--#ifdef HAVE_DB3
-+#if DB_VERSION >= 300000
- /* create a db handler */
- if ((errno = db_create(&dbp, NULL, 0)) != 0) {
- fprintf(stderr, "db_create: %s\n", db_strerror(errno));
-@@ -82,26 +83,32 @@
- return(NULL);
- }
- else {
--#ifndef HAVE_DB3
-- errno = db_open(db_name, DB_BTREE, DB_CREATE, 0644, NULL, NULL, &dbp);
--#else
-+#if DB_VERSION >= 401025
-+ errno = dbp->open(dbp, NULL, db_name, NULL, DB_BTREE, DB_CREATE, 0644);
-+#elif DB_VERSION >= 300000
- errno = dbp->open(dbp, db_name, NULL, DB_BTREE, DB_CREATE, 0644);
-+#else
-+ errno = db_open(db_name, DB_BTREE, DB_CREATE, 0644, NULL, NULL, &dbp);
- #endif
- }
- }
- else {
- if (flags & DB_FLAG_READONLY) {
--#ifndef HAVE_DB3
-- errno = db_open(db_name, DB_BTREE, DB_RDONLY, 0444, NULL, NULL, &dbp);
--#else
-+#if DB_VERSION >= 401025
-+ errno = dbp->open(dbp, NULL, db_name, NULL, DB_BTREE, DB_RDONLY, 0444);
-+#elif DB_VERSION >= 300000
- errno = dbp->open(dbp, db_name, NULL, DB_BTREE, DB_RDONLY, 0444);
-+#else
-+ errno = db_open(db_name, DB_BTREE, DB_RDONLY, 0444, NULL, NULL, &dbp);
- #endif
- }
- else {
--#ifndef HAVE_DB3
-- errno = db_open(db_name, DB_BTREE, 0, 0644, NULL, NULL, &dbp);
--#else
-+#if DB_VERSION >= 401025
-+ errno = dbp->open(dbp, NULL, db_name, NULL, DB_BTREE, 0, 0644);
-+#elif DB_VERSION >= 300000
- errno = dbp->open(dbp, db_name, NULL, DB_BTREE, 0, 0644);
-+#else
-+ errno = db_open(db_name, DB_BTREE, 0, 0644, NULL, NULL, &dbp);
- #endif
- }
- }
-@@ -112,10 +119,10 @@
- }
- if (errno < 0) {
- /* DB specific errno */
--#ifndef HAVE_DB3
-- fprintf(stderr, "tabeTsiDBOpen(): DB error opening DB File %s.\n", db_name);
--#else
-+#if DB_VERSION >= 300000
- fprintf(stderr, "tabeTsiDBOpen(): %s.\n", db_strerror(errno));
-+#else
-+ fprintf(stderr, "tabeTsiDBOpen(): DB error opening DB File %s.\n", db_name);
- #endif
- return(NULL);
- }
-@@ -265,12 +272,18 @@
+--- src/tabe_tsidbint.c.orig Fri Apr 21 23:04:10 2006
++++ src/tabe_tsidbint.c Fri Apr 21 23:04:33 2006
+@@ -272,7 +272,9 @@
switch(tsidb->type) {
case DB_TYPE_DB:
dbp = (DB *)tsidb->dbp;
+-#if DB_VERSION >= 303011
+#if DB_VERSION >= 403000
-+ errno = dbp->stat(dbp, NULL, &sp, 0);
++errno = dbp->stat(dbp, NULL, &sp, 0);
+#elif DB_VERSION >= 303011
-+ errno = dbp->stat(dbp, &sp, 0);
-+#else
- errno = dbp->stat(dbp, &sp, NULL, 0);
-+#endif
- if (!errno) {
--#ifndef HAVE_DB3
-- return(sp->bt_nrecs);
--#else
-+#if DB_VERSION >= 300000
- return(sp->bt_ndata); /* or sp->bt_nkeys? */
-+#else
-+ return(sp->bt_nrecs);
- #endif
- }
- break;
-@@ -502,14 +515,10 @@
- dbcp->c_close(dbcp);
- }
-
--#ifndef HAVE_DB3
--#if DB_VERSION_MINOR > 6 || (DB_VERSION_MINOR == 6 && DB_VERSION_PATCH > 4)
-+#if DB_VERSION >= 206004
- dbp->cursor(dbp, NULL, &dbcp, 0);
+ errno = dbp->stat(dbp, &sp, 0);
#else
- dbp->cursor(dbp, NULL, &dbcp);
--#endif
--#else
-- dbp->cursor(dbp, NULL, &dbcp, 0);
- #endif
- tsidb->dbcp = dbcp;
-
+ errno = dbp->stat(dbp, &sp, NULL, 0);
diff -ruN --exclude=CVS /usr/ports/chinese/libtabe/files/patch-src::tabe_tsiyindbint.c /home/rafan/tmp/ports/b/0.2.6/libtabe/files/patch-src::tabe_tsiyindbint.c
--- /usr/ports/chinese/libtabe/files/patch-src::tabe_tsiyindbint.c Mon May 22 21:13:40 2006
+++ /home/rafan/tmp/ports/b/0.2.6/libtabe/files/patch-src::tabe_tsiyindbint.c Sat May 20 15:30:58 2006
@@ -1,114 +1,13 @@
---- src/tabe_tsiyindbint.c.orig Mon May 1 00:49:54 2006
-+++ src/tabe_tsiyindbint.c Mon May 1 00:50:03 2006
-@@ -27,6 +27,7 @@
- #endif
-
- #include "tabe.h"
-+#define DB_VERSION (DB_VERSION_MAJOR*100000+DB_VERSION_MINOR*1000+DB_VERSION_PATCH)
-
- static void tabeTsiYinDBClose(struct TsiYinDB *tsiyindb);
- static int tabeTsiYinDBRecordNumber(struct TsiYinDB *tsiyindb);
-@@ -72,7 +73,7 @@
- {
- DB *dbp=NULL;
-
--#ifdef HAVE_DB3
-+#if DB_VERSION >= 300000
- /* create a db handler */
- if ((errno = db_create(&dbp, NULL, 0)) != 0) {
- fprintf(stderr, "db_create: %s\n", db_strerror(errno));
-@@ -85,26 +86,32 @@
- return(NULL);
- }
- else {
--#ifndef HAVE_DB3
-- errno = db_open(db_name, DB_BTREE, DB_CREATE, 0644, NULL, NULL, &dbp);
--#else
-+#if DB_VERSION >= 401025
-+ errno = dbp->open(dbp, NULL, db_name, NULL, DB_BTREE, DB_CREATE, 0644);
-+#elif DB_VERSION >= 300000
- errno = dbp->open(dbp, db_name, NULL, DB_BTREE, DB_CREATE, 0644);
-+#else
-+ errno = db_open(db_name, DB_BTREE, DB_CREATE, 0644, NULL, NULL, &dbp);
- #endif
- }
- }
- else {
- if (flags & DB_FLAG_READONLY) {
--#ifndef HAVE_DB3
-- errno = db_open(db_name, DB_BTREE, DB_RDONLY, 0444, NULL, NULL, &dbp);
--#else
-+#if DB_VERSION >= 401025
-+ errno = dbp->open(dbp, NULL, db_name, NULL, DB_BTREE, DB_RDONLY, 0444);
-+#elif DB_VERSION >= 300000
- errno = dbp->open(dbp, db_name, NULL, DB_BTREE, DB_RDONLY, 0444);
-+#else
-+ errno = db_open(db_name, DB_BTREE, DB_RDONLY, 0444, NULL, NULL, &dbp);
- #endif
- }
- else {
--#ifndef HAVE_DB3
-- errno = db_open(db_name, DB_BTREE, 0, 0644, NULL, NULL, &dbp);
--#else
-+#if DB_VERSION >= 401025
-+ errno = dbp->open(dbp, NULL, db_name, NULL, DB_BTREE, 0, 0644);
-+#elif DB_VERSION >= 300000
- errno = dbp->open(dbp, db_name, NULL, DB_BTREE, 0, 0644);
-+#else
-+ errno = db_open(db_name, DB_BTREE, 0, 0644, NULL, NULL, &dbp);
- #endif
- }
- }
-@@ -115,11 +122,11 @@
- }
- if (errno < 0) {
- /* DB specific errno */
--#ifndef HAVE_DB3
-+#if DB_VERSION >= 300000
-+ fprintf(stderr, "tabeTsiYinDBOpen(): %s.\n", db_strerror(errno));
-+#else
- fprintf(stderr, "tabeTsiYinDBOpen(): DB error opening DB File %s.\n",
- db_name);
--#else
-- fprintf(stderr, "tabeTsiYinDBOpen(): %s.\n", db_strerror(errno));
- #endif
- return(NULL);
- }
-@@ -268,12 +275,18 @@
+--- src/tabe_tsiyindbint.c.orig Fri Apr 21 23:04:40 2006
++++ src/tabe_tsiyindbint.c Fri Apr 21 23:04:55 2006
+@@ -275,7 +275,9 @@
switch(tsiyindb->type) {
case DB_TYPE_DB:
dbp = (DB *)tsiyindb->dbp;
+-#if DB_VERSION >= 303011
+#if DB_VERSION >= 403000
-+ errno = dbp->stat(dbp, NULL, &sp, 0);
++errno = dbp->stat(dbp, NULL, &sp, 0);
+#elif DB_VERSION >= 303011
-+ errno = dbp->stat(dbp, &sp, 0);
-+#else
- errno = dbp->stat(dbp, &sp, NULL, 0);
-+#endif
- if (!errno) {
--#ifndef HAVE_DB3
-- return(sp->bt_nrecs);
--#else
-+#if DB_VERSION >= 300000
- return(sp->bt_ndata); /* or sp->bt_nkeys? */
-+#else
-+ return(sp->bt_nrecs);
- #endif
- }
- break;
-@@ -481,14 +494,10 @@
- dbcp->c_close(dbcp);
- }
-
--#ifndef HAVE_DB3
--#if DB_VERSION_MINOR > 6 || (DB_VERSION_MINOR == 6 && DB_VERSION_PATCH > 4)
-+#if DB_VERSION >= 206004
- dbp->cursor(dbp, NULL, &dbcp, 0);
+ errno = dbp->stat(dbp, &sp, 0);
#else
- dbp->cursor(dbp, NULL, &dbcp);
--#endif
--#else
-- dbp->cursor(dbp, NULL, &dbcp, 0);
- #endif
- tsiyindb->dbcp = dbcp;
-
+ errno = dbp->stat(dbp, &sp, NULL, 0);
diff -ruN --exclude=CVS /usr/ports/chinese/libtabe/files/patch-util-tsipackdb.in /home/rafan/tmp/ports/b/0.2.6/libtabe/files/patch-util-tsipackdb.in
--- /usr/ports/chinese/libtabe/files/patch-util-tsipackdb.in Mon May 22 21:13:40 2006
+++ /home/rafan/tmp/ports/b/0.2.6/libtabe/files/patch-util-tsipackdb.in Sat May 20 15:30:58 2006
@@ -1,24 +1,11 @@
---- util/tsipackdb.in.orig Sun Nov 11 07:33:09 2001
-+++ util/tsipackdb.in Mon May 1 10:19:51 2006
-@@ -29,31 +29,37 @@
+--- util/tsipackdb.in.orig Sun Sep 19 22:25:51 2004
++++ util/tsipackdb.in Fri Apr 21 23:31:23 2006
+@@ -26,14 +26,26 @@
}
pack_db_file () {
-- db_stat=`mywhich ${1}_stat`
- db_dump=`mywhich ${1}_dump`
- db_load=`mywhich ${1}_load`
-- test x$db_stat != x && test x$db_dump != x && test x$db_load != x && \
-- $db_stat -d $2 2>&1 | (
-- read line
-- read line
-- test "$line" = "$3" && \
-- echo "Using $db_dump and $db_load to pack $2 ...." && \
-- ${1}_dump $2 | ${1}_load $2.new && \
-- mv $2.new $2 && \
-- return 0
-- return -1 \
-- )
--}
+ case "${1}" in
+ db|db3|db4|db41)
+ db_dump=`mywhich ${1}_dump`
@@ -33,31 +20,26 @@
+ echo "unsupportted Berkyley version: ${1}"
+ return 1
+ esac
-+ if [ -x "$db_dump" ] && [ -x "$db_load" ]; then
-+
-+ echo "Try using $db_dump and $db_load to pack $2 ...."
+ if [ -x "$db_dump" ] && [ -x "$db_load" ]; then
+ echo "Try using $db_dump and $db_load to pack $2 ...."
+
+- ${1}_dump $2 > $2.tmp && \
+- ${1}_load $2.new < $2.tmp && \
+ $db_dump $2 > $2.tmp && \
+ $db_load $2.new < $2.tmp && \
-+ mv $2.new $2 && \
-+ return 0
+ mv $2.new $2 && \
+ return 0
--if [ "$USE_DB" = "DB2" ]; then
-- pack_db_file db $1 "$DB2_VER" && exit 0
-- pack_db_file db2 $1 "$DB2_VER" && exit 0
--fi
-+ fi
-+
-+ return 1
-+}
+@@ -42,9 +54,9 @@
+ return 1
+ }
--if [ "$USE_DB" = "DB3" ]; then
-- pack_db_file db $1 "$DB3_VER" && exit 0
-- pack_db_file db3 $1 "$DB3_VER" && exit 0
--fi
+-for dbprefix in db db2 db3 db4
+for dbname in @with_db_name@ db db2 db3 db4
-+do
+ do
+- pack_db_file $dbprefix $1 && exit 0
+ pack_db_file $dbname $1 && exit 0
-+done
+ done
exit 0
diff -ruN --exclude=CVS /usr/ports/chinese/libtabe/pkg-plist /home/rafan/tmp/ports/b/0.2.6/libtabe/pkg-plist
--- /usr/ports/chinese/libtabe/pkg-plist Sat Apr 8 14:31:48 2006
+++ /home/rafan/tmp/ports/b/0.2.6/libtabe/pkg-plist Sat May 20 15:30:58 2006
@@ -1,18 +1,17 @@
bin/tsiadd
bin/tsidel
bin/tsidump
+bin/tsiguess
bin/tsiyincheck
bin/tsiyindump
%%X11%%include/tabe/bims.h
include/tabe/tabe.h
%%X11%%lib/libbims.a
-%%X11%%lib/libbims.la
%%X11%%lib/libbims.so
-%%X11%%lib/libbims.so.2
+%%X11%%lib/libbims.so.3
lib/libtabe.a
-lib/libtabe.la
lib/libtabe.so
-lib/libtabe.so.2
+lib/libtabe.so.3
lib/tabe/tsi.db
lib/tabe/yin.db
%%PORTDOCS%%%%DOCSDIR%%/BoPoMoFo.shtml
@@ -24,8 +23,6 @@
%%PORTDOCS%%%%DOCSDIR%%/ZuYinCode.txt
%%PORTDOCS%%%%DOCSDIR%%/et26.txt
%%PORTDOCS%%%%DOCSDIR%%/libtabe.sgml
-%%DATADIR%%/libtabe-0.2.5
@dirrm include/tabe
@dirrm lib/tabe
%%PORTDOCS%%@dirrm %%DOCSDIR%%
- at dirrm %%DATADIR%%
--- libtabe-0.2.6.patch ends here ---
xcin25 and p5-Lingua-ZH-Tabe patch begins here
diff -ruN /usr/ports/chinese/xcin25/Makefile xcin25/Makefile
--- /usr/ports/chinese/xcin25/Makefile Thu May 25 21:37:50 2006
+++ xcin25/Makefile Fri May 26 11:32:34 2006
@@ -18,8 +18,7 @@
MAINTAINER= kcwu at csie.org
COMMENT= Chinese input method server under X
-LIB_DEPENDS= tabe.2:${PORTSDIR}/chinese/libtabe
-
+LIB_DEPENDS= tabe.3:${PORTSDIR}/chinese/libtabe
RUN_DEPENDS= ${X11BASE}/lib/X11/fonts/local/kc15f.pcf.gz:${PORTSDIR}/chinese/kcfonts
WRKSRC= ${WRKDIR}/xcin
@@ -51,9 +50,9 @@
.if defined(WITH_BDB_VER)
@${ECHO_CMD} ""
@${ECHO_CMD} "WARNING:"
- @${ECHO_CMD} " You have defined WITH_BDB_VER. Make sure you use the same"
- @${ECHO_CMD} " db version that libtabe uses. Otherwise, this port may"
- @${ECHO_CMD} " not work correctly."
+ @${ECHO_CMD} " You have defined WITH_BDB_VER. Make sure you use the same"
+ @${ECHO_CMD} " db version that libtabe uses. Otherwise, this port may"
+ @${ECHO_CMD} " not work correctly."
@${ECHO_CMD} ""
.endif
diff -ruN /usr/ports/chinese/p5-Lingua-ZH-TaBE/Makefile p5-Lingua-ZH-TaBE/Makefile
--- /usr/ports/chinese/p5-Lingua-ZH-TaBE/Makefile Sat Apr 8 22:51:29 2006
+++ p5-Lingua-ZH-TaBE/Makefile Fri May 26 11:37:42 2006
@@ -8,6 +8,7 @@
PORTNAME= Lingua-ZH-TaBE
PORTVERSION= 0.07
+PORTREVISION= 1
CATEGORIES= chinese perl5
MASTER_SITES= ${MASTER_SITE_PERL_CPAN}
MASTER_SITE_SUBDIR= Lingua
@@ -16,7 +17,7 @@
MAINTAINER= clsung at FreeBSD.org
COMMENT= Chinese processing via libtabe
-LIB_DEPENDS= tabe.2:${PORTSDIR}/chinese/libtabe
+LIB_DEPENDS= tabe.3:${PORTSDIR}/chinese/libtabe
PERL_CONFIGURE= yes
@@ -27,11 +28,18 @@
MAN3= Lingua::ZH::TaBE.3
-pre-fetch:
- @${ECHO} ""
- @${ECHO} "You may specify db version to use:"
- @${ECHO} ""
- @${ECHO} " WITH_DB_VER=version (Default 41)"
- @${ECHO} ""
+pre-everything::
+ @${ECHO_CMD} ""
+ @${ECHO_CMD} "You may specify db version to use:"
+ @${ECHO_CMD} ""
+ @${ECHO_CMD} " WITH_BDB_VER=version (Default 41)"
+.if defined(WITH_BDB_VER)
+ @${ECHO_CMD} ""
+ @${ECHO_CMD} "WARNING:"
+ @${ECHO_CMD} " You have defined WITH_BDB_VER. Make sure you use the same"
+ @${ECHO_CMD} " db version that libtabe uses. Otherwise, this port may"
+ @${ECHO_CMD} " not work correctly."
+.endif
+ @${ECHO_CMD} ""
.include <bsd.port.mk>
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list