aboutsummaryrefslogtreecommitdiff
path: root/www/lessc/Makefile
blob: f4a98f9c4e5717b197be49905ce1a127044d023e (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
# Created by: Rodrigo Osorio <rodrigo@freebsd.org>
# $FreeBSD$

PORTNAME=	lessc
PORTVERSION=	2.5.1
DISTVERSIONPREFIX=	v
PORTREVISION=	1
CATEGORIES=	www devel

MAINTAINER=	rodrigo@FreeBSD.org
COMMENT=	Javascript CSS pre-processor

LICENSE=	APACHE20

BROKEN=		fails to package
DEPRECATED=	Broken for more than 6 months
EXPIRATION_DATE=	2018-01-27

BUILD_DEPENDS=	npm>=0:www/npm
RUN_DEPENDS=	npm>=0:www/npm

USE_GITHUB=	yes
GH_ACCOUNT=	less
GH_PROJECT=	less.js

# npm install both builds and installs.  To avoid building in the stage phase,
# allow npm to install in a temporary directory and move from there.
# Moreover, only a fraction of what is installed by npm needs to be packaged
do-build:
	${MKDIR} ${WRKDIR}/build-lib
	(cd ${WRKDIR}/build-lib && \
		${SETENV} HOME=${WRKDIR} npm install ${WRKSRC})

do-install:
	${MKDIR} ${STAGEDIR}${PREFIX}/bin \
		${STAGEDIR}${PREFIX}/lib/node_modules/.bin
	${MV} ${WRKDIR}/build-lib/node_modules/less \
		${STAGEDIR}${PREFIX}/lib/node_modules
	${MV} ${WRKDIR}/build-lib/node_modules/.bin/lessc \
		${STAGEDIR}${PREFIX}/lib/node_modules/.bin
	(cd ${STAGEDIR}${PREFIX}/bin && \
		${LN} -s ../lib/node_modules/.bin/lessc lessc)

.include <bsd.port.mk>