Lines 1-18
Link Here
|
1 |
# New ports collection makefile for: mecab |
1 |
# Created by: Akinori MUSHA aka knu <knu@idaemons.org> |
2 |
# Date created: 2 April 2003 |
|
|
3 |
# Whom: Akinori MUSHA aka knu <knu@idaemons.org> |
4 |
# |
5 |
# $FreeBSD$ |
2 |
# $FreeBSD$ |
6 |
# |
|
|
7 |
|
3 |
|
8 |
PORTNAME= mecab |
4 |
PORTNAME= mecab |
9 |
PORTVERSION= 0.994 |
5 |
PORTVERSION= 0.995 |
10 |
CATEGORIES= japanese textproc |
6 |
CATEGORIES= japanese textproc |
11 |
MASTER_SITES= ${MASTER_SITE_GOOGLE_CODE} |
7 |
MASTER_SITES= GOOGLE_CODE |
12 |
|
8 |
|
13 |
MAINTAINER= clsung@FreeBSD.org |
9 |
MAINTAINER= clsung@FreeBSD.org |
14 |
COMMENT= Yet Another Part-of-Speech and Morphological Analyzer |
10 |
COMMENT= Yet Another Part-of-Speech and Morphological Analyzer |
15 |
|
11 |
|
|
|
12 |
LICENSE= BSD GPLv2 LGPL21 |
13 |
LICENSE_COMB= dual |
14 |
LICENSE_FILE_BSD= ${WRKSRC}/BSD |
15 |
LICENSE_FILE_GPLv2= ${WRKSRC}/GPL |
16 |
LICENSE_FILE_LGPL21= ${WRKSRC}/LGPL |
17 |
|
16 |
USE_AUTOTOOLS= libtool |
18 |
USE_AUTOTOOLS= libtool |
17 |
USE_ICONV= yes |
19 |
USE_ICONV= yes |
18 |
USE_PERL5_BUILD= yes |
20 |
USE_PERL5_BUILD= yes |
Lines 22-38
Link Here
|
22 |
CPPFLAGS+= ${PTHREAD_CFLAGS} -I ${LOCALBASE}/include |
24 |
CPPFLAGS+= ${PTHREAD_CFLAGS} -I ${LOCALBASE}/include |
23 |
LDFLAGS+= -L${LOCALBASE}/lib |
25 |
LDFLAGS+= -L${LOCALBASE}/lib |
24 |
|
26 |
|
25 |
# Default charset (euc-jp/shift_jis/utf-8) |
|
|
26 |
.if defined(WITH_CHARSET) |
27 |
CONFIGURE_ARGS+= --with-charset=${WITH_CHARSET} |
28 |
.endif |
29 |
|
30 |
MAN1= mecab.1 |
27 |
MAN1= mecab.1 |
31 |
|
28 |
|
32 |
DOCS= AUTHORS README doc/*.html |
29 |
PORTDOCS= AUTHORS README *.html |
33 |
|
30 |
|
34 |
.include <bsd.port.pre.mk> |
31 |
OPTIONS_DEFINE= DOCS |
35 |
|
32 |
|
|
|
33 |
OPTIONS_RADIO= CHARSET |
34 |
OPTIONS_RADIO_CHARSET= EUCJP SHIFTJIS UTF8 |
35 |
|
36 |
EUCJP_DESC= Use EUC-JP as default charset. |
37 |
SHIFTJIS_DESC= Use SHIFT-JIS as default charset. |
38 |
UTF8_DESC= Use UTF-8 as default charset. |
39 |
|
40 |
OPTIONS_DEFAULT= EUCJP |
41 |
|
42 |
.include <bsd.port.options.mk> |
43 |
|
44 |
.if ${PORT_OPTIONS:MEUCJP} |
45 |
CONFIGURE_ARGS+= --with-charset=euc-jp |
46 |
.elif ${PORT_OPTIONS:MSHIFTJIS} |
47 |
CONFIGURE_ARGS+= --with-charset=shift_jis |
48 |
.elif ${PORT_OPTIONS:MUTF8} |
49 |
CONFIGURE_ARGS+= --with-charset=utf-8 |
50 |
.endif |
51 |
|
36 |
post-patch: |
52 |
post-patch: |
37 |
${REINPLACE_CMD} -e 's/-lpthread/${PTHREAD_LIBS}/g' \ |
53 |
${REINPLACE_CMD} -e 's/-lpthread/${PTHREAD_LIBS}/g' \ |
38 |
-e 's/-O3/${CFLAGS}/' ${WRKSRC}/${CONFIGURE_SCRIPT} |
54 |
-e 's/-O3/${CFLAGS}/' ${WRKSRC}/${CONFIGURE_SCRIPT} |
Lines 48-59
Link Here
|
48 |
@if [ ! -f ${PREFIX}/etc/mecabrc ]; then \ |
64 |
@if [ ! -f ${PREFIX}/etc/mecabrc ]; then \ |
49 |
${INSTALL_DATA} ${PREFIX}/etc/mecabrc.dist ${PREFIX}/etc/mecabrc; \ |
65 |
${INSTALL_DATA} ${PREFIX}/etc/mecabrc.dist ${PREFIX}/etc/mecabrc; \ |
50 |
fi |
66 |
fi |
51 |
.if !defined(NOPORTDOCS) |
67 |
.if ${PORT_OPTIONS:MDOCS} |
52 |
${MKDIR} ${DOCSDIR} |
68 |
${MKDIR} ${DOCSDIR} |
53 |
.for f in ${DOCS} |
69 |
.for f in ${PORTDOCS:N*.html} |
54 |
${INSTALL_DATA} ${WRKSRC}/${f} ${DOCSDIR}/ |
70 |
${INSTALL_DATA} ${WRKSRC}/${f} ${DOCSDIR}/ |
55 |
.endfor |
71 |
.endfor |
|
|
72 |
${INSTALL_DATA} ${WRKSRC}/doc/*.html ${DOCSDIR}/ |
56 |
.endif |
73 |
.endif |
57 |
@${CAT} ${PKGMESSAGE} |
74 |
@${CAT} ${PKGMESSAGE} |
58 |
|
75 |
|
59 |
.include <bsd.port.post.mk> |
76 |
.include <bsd.port.mk> |