aboutsummaryrefslogtreecommitdiffstats
path: root/games/fretsonfire/Makefile
blob: 7821e463133d6204a6d312d6b5dd7fd53b075e1e (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
# New ports collection makefile for:    fretsonfire
# Date created:     2006-09-01
# Whom:         Jose Alonso Cardenas Marquez <acm@FreeBSD.org>
#
# $FreeBSD$
#

PORTNAME=   fretsonfire
PORTVERSION=    1.3.110
PORTREVISION=   2
CATEGORIES= games python
MASTER_SITES=   SF
DISTNAME=   ${PORTNAME:S/f/F/g:S/o/O/}-${PORTVERSION}
DIST_SUBDIR=    ${PORTNAME}

MAINTAINER= acm@FreeBSD.org
COMMENT=    A game of musical skill and fast fingers

RUN_DEPENDS=    ${PYTHON_SITELIBDIR}/numpy:${PORTSDIR}/math/py-numpy \
        ${PYTHON_SITELIBDIR}/pygame/__init__.py:${PORTSDIR}/devel/py-game \
        ${PYTHON_SITELIBDIR}/OpenGL/__init__.py:${PORTSDIR}/graphics/py-opengl \
        ${PYTHON_SITELIBDIR}/PIL/__init__.py:${PORTSDIR}/graphics/py-imaging \
        ${LOCALBASE}/share/${PORTNAME}/default.ttf:${PORTSDIR}/games/fretsonfire-data

USE_PYTHON= yes
USE_DOS2UNIX=   *.txt
NO_BUILD=   yes

BROKEN=     does not build

DATADIR=    share/${PORTNAME}
EXTRACT_AFTER_ARGS= | ${TAR} -xf - --exclude 'data'
SUB_FILES=  pkg-message FretsOnFire
SUB_LIST=   PROGRAM_DIR="${FOF_DIR}/${PORTNAME:S/f/F/g:S/o/O/}"
WRKSRC=     "${WRKDIR}/Frets on Fire-${PORTVERSION}"

FOF_DIR=    ${PREFIX}/lib/${PORTNAME}

.include <bsd.port.pre.mk>

.if ${ARCH} != "i386"
WITHOUT_PSYCO=  yes
.endif

.if !defined(WITHOUT_PSYCO)
RUN_DEPENDS+=   ${PYTHON_SITELIBDIR}/psyco/_psyco.so:${PORTSDIR}/devel/py-psyco
.endif

do-install:
    ${MKDIR} ${FOF_DIR}/${PORTNAME:S/f/F/g:S/o/O/}
    @cd ${WRKSRC}/src && \
        ${FIND} * -type d -exec ${MKDIR} "${FOF_DIR}/${PORTNAME:S/f/F/g:S/o/O/}/{}" \; && \
            ${FIND} -E * -type f -iregex ".*\.(py)" -exec ${INSTALL_DATA} "{}" "${FOF_DIR}/${PORTNAME:S/f/F/g:S/o/O/}/{}" \;

    ${MKDIR} ${FOF_DIR}/data
    ${LN} -s ${LOCALBASE}/${DATADIR}/* ${FOF_DIR}/data
    ${INSTALL_SCRIPT} ${WRKDIR}/${PORTNAME:S/f/F/g:S/o/O/} ${PREFIX}/bin

.if !defined(NOPORTDOCS)
    ${MKDIR} ${DOCSDIR}
    ${INSTALL_DATA} ${WRKSRC}/readme.txt ${DOCSDIR}/README
    ${INSTALL_DATA} ${WRKSRC}/install.txt ${DOCSDIR}/INSTALL
.endif

post-install:
    @${CAT} ${PKGMESSAGE}

.include <bsd.port.post.mk>