aboutsummaryrefslogtreecommitdiff
path: root/mail/mew3/Makefile
blob: 15cb86d1fa397320a5d623e6397a4885452357dd (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
# New ports collection makefile for: Mew
# Date created:		21 November 1997
# Whom:			Kiriyama Kazuhiko <kiri@kiri.toba-cmt.ac.jp>
#
# $FreeBSD$
#

PORTNAME=	mew
PORTVERSION=	${MEW_VER}
PORTREVISION=	4
CATEGORIES=	mail elisp
MASTER_SITES=	http://www.mew.org/Release/
PKGNAMESUFFIX=	-${EMACS_PORT_NAME}

MAINTAINER?=	ports@FreeBSD.org
COMMENT?=	Message interface to Emacs Window (version 3) for emacs21

LATEST_LINK?=	mew3

# Mew major version
MEW_MAJOR_VER=	3

# distfile version
MEW_VER=	${MEW_MAJOR_VER}.3

# document install directory by install-doc target
DOCSDIR=	share/doc/${PORTNAME}${MEW_MAJOR_VER}

# emacs port setup
USE_EMACS=	yes
EMACS_PORT_NAME?=	emacs21

# target name for make build and install
ALL_TARGET?=	all info jinfo
INSTALL_TARGET?=	install install-info install-jinfo install-etc

# environments
REINPLACE_ARGS=
MAKE_ENV+=	EMACS_LIBDIR=${EMACS_LIBDIR} MEW_MAJOR_VER=${MEW_MAJOR_VER}
PLIST_SUB+=	MEW_MAJOR_VER=${MEW_MAJOR_VER}
INFO?=		mew${MEW_MAJOR_VER} mew${MEW_MAJOR_VER}.jis

# manuals
MAN1=		mewcat.1 mewdecode.1 mewencode.1 mewls.1 incm.1

.include <bsd.port.pre.mk>

.if ${ARCH} == "ia64"
BROKEN=		"Does not build on ia64"
.endif

post-patch:
	for f in mew-key.el info/mew.texi; do \
		${REINPLACE_CMD} -i "" -E \
			-e 's,%%MEW_MAJOR_VER%%,${MEW_MAJOR_VER},g' \
			${WRKSRC}/$${f}; \
	done

post-install:
.if !defined(NOPORTDOCS)
	${MKDIR} ${PREFIX}/${DOCSDIR}
	(cd ${WRKSRC} ; \
		${INSTALL_DATA} 00* ${PREFIX}/${DOCSDIR}/ ; \
		for dir in contrib; do \
			${CP} -R $${dir} ${PREFIX}/${DOCSDIR}/ ; \
		done)
	${CHOWN} -R ${SHAREOWN}:${SHAREGRP} ${PREFIX}/${DOCSDIR}
.endif

.include <bsd.port.post.mk>