Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 26 Mar 2016 11:42:56 +0000 (UTC)
From:      TAKATSU Tomonari <tota@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r411923 - in head/japanese: . mecab-ipadic mecab-ipadic-eucjp mecab-ipadic-sjis mecab-ipadic-utf8
Message-ID:  <201603261142.u2QBgutI066034@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: tota
Date: Sat Mar 26 11:42:55 2016
New Revision: 411923
URL: https://svnweb.freebsd.org/changeset/ports/411923

Log:
  - Separate japanese/mecab-ipadic into three slave ports
    to identify character set by means of package name
    * japanese/mecab-ipadic-eucjp
    * japanese/mecab-ipadic-sjis
    * japanese/mecab-ipadic-utf8 (default)
  - Set default character set to UTF-8
  - Unbreak mecab-ipadic-sjis
  - Bump PORTREVISION
  
  PR:		200325
  Submitted by:	Koichiro IWAO (meta+ports_AT_vmeta_DOT_jp)
  Approved by:	maintainer timeout (> 8 weeks)

Added:
  head/japanese/mecab-ipadic-eucjp/
  head/japanese/mecab-ipadic-eucjp/Makefile   (contents, props changed)
  head/japanese/mecab-ipadic-sjis/
  head/japanese/mecab-ipadic-sjis/Makefile   (contents, props changed)
  head/japanese/mecab-ipadic-utf8/
  head/japanese/mecab-ipadic-utf8/Makefile   (contents, props changed)
Deleted:
  head/japanese/mecab-ipadic/pkg-plist
Modified:
  head/japanese/Makefile   (contents, props changed)
  head/japanese/mecab-ipadic/Makefile   (contents, props changed)

Modified: head/japanese/Makefile
==============================================================================
--- head/japanese/Makefile	Sat Mar 26 11:33:30 2016	(r411922)
+++ head/japanese/Makefile	Sat Mar 26 11:42:55 2016	(r411923)
@@ -161,6 +161,9 @@
     SUBDIR += man-doc
     SUBDIR += mecab
     SUBDIR += mecab-ipadic
+    SUBDIR += mecab-ipadic-eucjp
+    SUBDIR += mecab-ipadic-sjis
+    SUBDIR += mecab-ipadic-utf8
     SUBDIR += mg
     SUBDIR += mh
     SUBDIR += migemo

Added: head/japanese/mecab-ipadic-eucjp/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/japanese/mecab-ipadic-eucjp/Makefile	Sat Mar 26 11:42:55 2016	(r411923)
@@ -0,0 +1,10 @@
+# Created by: Koichiro IWAO <meta+ports@vmeta.jp>
+# $FreeBSD$
+
+PKGNAMESUFFIX=	-eucjp
+
+COMMENT=	Japanese Morphological Dictionary for MeCab (EUC-JP)
+
+MASTERDIR=	${.CURDIR}/../mecab-ipadic
+
+.include "${MASTERDIR}/Makefile"

Added: head/japanese/mecab-ipadic-sjis/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/japanese/mecab-ipadic-sjis/Makefile	Sat Mar 26 11:42:55 2016	(r411923)
@@ -0,0 +1,10 @@
+# Created by: Koichiro IWAO <meta+ports@vmeta.jp>
+# $FreeBSD$
+
+PKGNAMESUFFIX=	-sjis
+
+COMMENT=	Japanese Morphological Dictionary for MeCab (Shift JIS)
+
+MASTERDIR=	${.CURDIR}/../mecab-ipadic
+
+.include "${MASTERDIR}/Makefile"

Added: head/japanese/mecab-ipadic-utf8/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/japanese/mecab-ipadic-utf8/Makefile	Sat Mar 26 11:42:55 2016	(r411923)
@@ -0,0 +1,10 @@
+# Created by: Koichiro IWAO <meta+ports@vmeta.jp>
+# $FreeBSD$
+
+PKGNAMESUFFIX=	-utf8
+
+COMMENT=	Japanese Morphological Dictionary for MeCab (UTF-8)
+
+MASTERDIR=	${.CURDIR}/../mecab-ipadic
+
+.include "${MASTERDIR}/Makefile"

Modified: head/japanese/mecab-ipadic/Makefile
==============================================================================
--- head/japanese/mecab-ipadic/Makefile	Sat Mar 26 11:33:30 2016	(r411922)
+++ head/japanese/mecab-ipadic/Makefile	Sat Mar 26 11:42:55 2016	(r411923)
@@ -3,13 +3,29 @@
 
 PORTNAME=	mecab-ipadic
 DISTVERSION=	2.7.0-20070801
+PORTREVISION=	1
 CATEGORIES=	japanese textproc
 MASTER_SITES=	GOOGLE_CODE
 PROJECTHOST=	mecab
 
 MAINTAINER=	yasu@utahime.org
-COMMENT=	Japanese Morphological Dictionary for MeCab
+COMMENT?=	MeCab IPA dictionary meta-port
 
+.if empty(PKGNAMESUFFIX)
+USES=	metaport
+OPTIONS_RADIO=	CHARSET
+OPTIONS_RADIO_CHARSET=	EUCJP SHIFTJIS UTF8
+OPTIONS_DEFAULT=	UTF8
+
+EUCJP_DESC=	Use EUC-JP as dictionary charset.
+SHIFTJIS_DESC=	Use SHIFT-JIS as dictionary charset.
+UTF8_DESC=	Use UTF-8 as dictionary charset.
+EUCJP_RUN_DEPENDS=	${LOCALBASE}/lib/mecab/dic/ipadic/char.bin:${PORTSDIR}/japanese/mecab-ipadic-eucjp
+SHIFTJIS_RUN_DEPENDS=	${LOCALBASE}/lib/mecab/dic/ipadic/char.bin:${PORTSDIR}/japanese/mecab-ipadic-sjis
+UTF8_RUN_DEPENDS=	${LOCALBASE}/lib/mecab/dic/ipadic/char.bin:${PORTSDIR}/japanese/mecab-ipadic-utf8
+.endif
+
+.if !empty(PKGNAMESUFFIX)
 LICENSE=	NAIST ICOT
 LICENSE_COMB=	multi
 LICENSE_NAME_NAIST=	NAIST
@@ -26,21 +42,30 @@ USE_PERL5=		build
 GNU_CONFIGURE=		yes
 CONFIGURE_ARGS+=	--with-dicdir=${PREFIX}/lib/mecab/dic/ipadic
 
-OPTIONS_RADIO=	CHARSET
-OPTIONS_RADIO_CHARSET=	EUCJP SHIFTJIS UTF8
-
-EUCJP_DESC=	Use EUC-JP as dictionary charset.
-SHIFTJIS_DESC=	Use SHIFT-JIS as dictionary charset.
-UTF8_DESC=	Use UTF-8 as dictionary charset.
-
-.include <bsd.port.options.mk>
-
-.if ${PORT_OPTIONS:MEUCJP}
+.if ${PKGNAMESUFFIX:S,-,,} == "eucjp"
 CONFIGURE_ARGS+=	--with-charset=euc-jp
-.elif ${PORT_OPTIONS:MSHIFTJIS}
-CONFIGURE_ARGS+=	--with-charset=shift_jis
-.elif ${PORT_OPTIONS:MUTF8}
+CONFLICTS=	ja-mecab-ipadic-utf8-[0-9]* ja-mecab-ipadic-sjis-[0-9]*
+.elif ${PKGNAMESUFFIX:S,-,,} == "sjis"
+CONFIGURE_ARGS+=	--with-charset=shiftjis
+CONFLICTS=	ja-mecab-ipadic-eucjp-[0-9]* ja-mecab-ipadic-utf8-[0-9]*
+.elif ${PKGNAMESUFFIX:S,-,,} == "utf8"
 CONFIGURE_ARGS+=	--with-charset=utf-8
+CONFLICTS=	ja-mecab-ipadic-eucjp-[0-9]* ja-mecab-ipadic-sjis-[0-9]*
 .endif
 
+WRKSRC=	${WRKDIR}/${PORTNAME}-${DISTVERSION}
+
+PLIST_FILES=	\
+	lib/mecab/dic/ipadic/char.bin \
+	lib/mecab/dic/ipadic/dicrc \
+	lib/mecab/dic/ipadic/left-id.def \
+	lib/mecab/dic/ipadic/matrix.bin \
+	lib/mecab/dic/ipadic/pos-id.def \
+	lib/mecab/dic/ipadic/rewrite.def \
+	lib/mecab/dic/ipadic/right-id.def \
+	lib/mecab/dic/ipadic/sys.dic \
+	lib/mecab/dic/ipadic/unk.dic
+
+.endif # !empty(PKGNAMESUFFIX)
+
 .include <bsd.port.mk>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201603261142.u2QBgutI066034>