aboutsummaryrefslogtreecommitdiffstats
path: root/misc/patanjali/Makefile
blob: 130872c07b5d661f44d2dced47e8bcdd4fd3b0cc (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
# New ports collection makefile for:    patanjali
# Date created:             2002-01-09
# Whom:                 trevor
#
# $FreeBSD$
#

PORTNAME=   patanjali
PORTVERSION=    1.0
CATEGORIES= misc
MASTER_SITES=   http://www.linux.edu/download/
EXTRACT_SUFX=   .src.tar.gz

MAINTAINER= ports@FreeBSD.org
COMMENT=    Displays a verse from Yoga Sutras of Patanjali

PLIST=      ${WRKDIR}/pkg-plist
PLIST_DIRS= share/patanjali
SUTRAS=     patanjali-sutras-english.txt

do-patch:
    @${MV} ${WRKSRC}/${SUTRAS} ${WRKSRC}/${SUTRAS}.orig
    @${SED} -e 's:internet:Internet:g' \
        < ${WRKSRC}/${SUTRAS}.orig > ${WRKSRC}/${SUTRAS}

pre-build:
    ${RM} -f ${WRKSRC}/patanjali

do-build:
    ${CC} -DDPPATHNAME=\"${DATADIR}/${SUTRAS}\" \
        -DVERSION=\"1.0\" ${WRKSRC}/patanjali.c -o ${WRKSRC}/patanjali

pre-install:
    ${ECHO_CMD} bin/patanjali > ${PLIST}
    ${ECHO_CMD} share/patanjali/${SUTRAS} >> ${PLIST}
.if !defined(NOPORTDOCS)
    ${ECHO_CMD} share/doc/patanjali/display-sutras-patanjali-0.99.lsm >> ${PLIST}
    ${ECHO_CMD} @dirrm share/doc/patanjali/ >> ${PLIST}
.endif

do-install:
    ${MKDIR} ${DATADIR}
    ${INSTALL_DATA} ${WRKSRC}/${SUTRAS} ${DATADIR}/
    ${INSTALL_PROGRAM} ${WRKSRC}/patanjali ${PREFIX}/bin
.if !defined(NOPORTDOCS)
    ${MKDIR} ${DOCSDIR}
    ${INSTALL_DATA} ${WRKSRC}/display-sutras-patanjali-0.99.lsm ${DOCSDIR}/
.endif

.include <bsd.port.mk>