aboutsummaryrefslogtreecommitdiffstats
path: root/games/freebsd-games/Makefile
blob: b42c67c5ca3ab866200500b8db0d7726c392ab06 (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
71
72
73
74
75
76
77
78
79
80
81
82
83
# Ports collection makefile for:  games
# Date created:           20 Nov 2002
# Whom:               Mark Murray <markm@FreeBSD.org>
#
# $FreeBSD$
#

PORTNAME=   freebsd-games
PORTVERSION=    5.1.1
PORTREVISION=   7
CATEGORIES= games
MASTER_SITES=   ${MASTER_SITE_LOCAL}
MASTER_SITE_SUBDIR=markm

MAINTAINER= ports@FreeBSD.org
COMMENT=    FreeBSD-modified "Standard" BSD games

USE_BZIP2=  yes

MAN6=   \
    adventure.6 \
    arithmetic.6 \
    atc.6 \
    backgammon.6 \
    battlestar.6 \
    bs.6 \
    canfield.6 \
    cfscores.6 \
    cribbage.6 \
    fish.6 \
    hack.6 \
    hangman.6 \
    larn.6 \
    mille.6 \
    phantasia.6 \
    piano.6 \
    pig.6 \
    quiz.6 \
    robots.6 \
    rogue.6 \
    sail.6 \
    snake.6 \
    snscore.6 \
    trek.6 \
    worm.6 \
    wump.6

MANCOMPRESSED=  maybe

PATHNAME_FILES= atc/atc.6 \
        atc/pathnames.h \
        cribbage/pathnames.h \
        fish/pathnames.h \
        larn/pathnames.h \
        quiz/datfiles/index \
        quiz/pathnames.h \
        quiz/quiz.6 \
        wump/pathnames.h

.include <bsd.port.pre.mk>

.if ${OSVERSION} >= 700042
BROKEN=     Broken with gcc 4.2
.endif

post-extract:
    @(cd ${BUILD_WRKSRC}; ${SETENV} ${MAKE_ENV} \
        ${MAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} extract)

post-patch:
    @${FIND} ${WRKSRC} -name '*.c' -or -name '*.h' -or -name '*.6' -or \
        -name 'index' | ${XARGS} ${REINPLACE_CMD} -e \
        's|share/games|local/share/games|g'
    @${FIND} ${WRKSRC} -name 'Makefile' | \
        ${XARGS} ${REINPLACE_CMD}  's|$${LIBCOMPAT}||g;;s|-lcompat||g'
    @for f in ${PATHNAME_FILES}; do \
        ${REINPLACE_CMD} -e 's|/usr/local/local/local|${PREFIX}|g' \
            ${WRKSRC}/$${f}; \
    done
    @${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|' \
        "${WRKSRC}/hack/hack.unix.c"

.include <bsd.port.post.mk>