aboutsummaryrefslogtreecommitdiffstats
path: root/www/node04/Makefile
blob: c245653801f5c022feadf46295b6b4f5396daa62 (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
# New ports collection makefile for:        node
# Date created:                 2010-04-12
# Whom:                     Jin-Sih Lin <linpct@gmail.com>
#
# $FreeBSD$
#

PORTNAME=   node
PORTVERSION=    0.4.10
CATEGORIES= www
MASTER_SITES=   http://nodejs.org/dist/
DISTNAME=   ${PORTNAME}-v${PORTVERSION}

MAINTAINER= linpct@gmail.com
COMMENT=    V8 javascript for client and server

LIB_DEPENDS=    execinfo.1:${PORTSDIR}/devel/libexecinfo

MAN1=       node.1

HAS_CONFIGURE=  yes
USE_LDCONFIG=   yes
USE_PYTHON= yes
USE_GNOME=  pkgconfig

ONLY_FOR_ARCHS= i386 amd64
MAKE_JOBS_SAFE= yes
CONFIGURE_ARGS= --prefix=${PREFIX_RELDEST}
PREFIX_RELDEST= ${PREFIX:S,^${DESTDIR},,}

.include <bsd.port.pre.mk>

.if ${ARCH} == amd64
LIB_DEPENDS+=   v8.1:${PORTSDIR}/lang/v8
CONFIGURE_ARGS+=    --shared-v8-includes=${LOCALBASE}/include --shared-v8-libpath=${LOCALBASE}/lib
PLIST_SUB+= SHAREDV8="@comment "
.else
PLIST_SUB+= SHAREDV8=""
.endif

.if !defined(DISABLE_MAKE_JOBS)
WAF_ARGS=   --jobs=${MAKE_JOBS_NUMBER}
.endif

do-build:
    @(cd ${WRKSRC}; ${SETENV} ${MAKE_ENV} ${PYTHON_CMD} tools/waf-light ${WAF_ARGS} build)

do-install:
    @(cd ${WRKSRC}; ${SETENV} ${MAKE_ENV} ${PYTHON_CMD} tools/waf-light ${WAF_ARGS} install)

post-install:
    @${INSTALL_MAN}  ${WRKSRC}/doc/node.1 ${MANPREFIX}/man/man1/

.include <bsd.port.post.mk>