aboutsummaryrefslogtreecommitdiffstats
path: root/devel/lua-pty/Makefile
blob: 9ae1cd8e746fc32e4780eed3bd0ac3a0edfb3895 (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
# New ports collection makefile for:   lua50-pty
# Date created:        17 April 2006
# Whom:                Andrew Turner <andrew+ports@fubar.geek.nz>
#
# $FreeBSD$
#

PORTNAME=   pty
PORTVERSION=    1.25
CATEGORIES= devel
MASTER_SITES=   ${MASTER_SITE_LOCAL}
MASTER_SITE_SUBDIR= philip
PKGNAMEPREFIX=  ${LUA_PKGNAMEPREFIX}
DISTFILES=  pty.lua?rev=1.2 pty.c?rev=1.25

MAINTAINER= andrew+ports@fubar.geek.nz
COMMENT=    Pty (pseudo-terminal) bindings for Lua 5

USE_LUA?=   5.1

.if ${USE_LUA} == 5.0
LUA_COMPS=  compat51 lua
BUILD_DEPENDS+= ${NONEXISTENT}:${PORTSDIR}/devel/lua50-compat51:extract
COMPAT_SRC= `(cd ${PORTSDIR}/devel/lua50-compat51 && ${MAKE} -V WRKSRC)`
MAKE_ENV=   COMPATDIR="${COMPAT_SRC}"
.endif

PLIST_FILES=    %%LUA_MODSHAREDIR%%/pty.lua \
        %%LUA_MODLIBDIR%%/lpty.so

do-extract:
    @${MKDIR} ${WRKSRC}
.for file in ${DISTFILES}
    @${CP} ${DISTDIR}/${file} ${WRKSRC}/${file:C/\?.*$//}
.endfor
    @${CP} ${FILESDIR}/Makefile ${WRKSRC}

do-install:
    ${INSTALL_PROGRAM} ${WRKSRC}/lpty.so ${LUA_MODLIBDIR}
    ${INSTALL_DATA} ${WRKSRC}/pty.lua ${LUA_MODSHAREDIR}

.include <bsd.port.mk>