aboutsummaryrefslogtreecommitdiffstats
path: root/www/limesurvey/Makefile
blob: 5abea3807d9ed641638600859fadfeae9c692ff7 (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
# New ports collection makefile for:    phpsurveyor
# Date created:     21 March 2005
# Whom:             janos.mohacsi@bsd.hu
#
# $FreeBSD$
#

PORTNAME=   phpsurveyor
PORTVERSION=    0.98
CATEGORIES= www
MASTER_SITES=   ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}
DISTNAME=   ${PORTNAME}-0_98_final

MAINTAINER= janos.mohacsi@bsd.hu
COMMENT=    A PHP-based survey building and runing system

USE_PHP=    mysql session
WRKSRC=     ${WRKDIR}
USE_ZIP=    yes

#User-configurable variables
WWWDOCROOT?=    www/data
PHPSURVEYORURL?=    phpsurveyor
WWWOWN?=    www
WWWGRP?=    www
#
# End of user-configurable variables.

# Set/override/append to variables from bsd.port.mk:
#
NO_BUILD=   yes
USE_REINPLACE=  yes
PKGMESSAGE= ${WRKDIR}/pkg-message
PLIST_SUB+= PHPSURVEYORDIR=${PHPSURVEYORDIR} WWWOWN=${WWWOWN} WWWGRP=${WWWGRP}

# Set custom variables:
#
PHPSURVEYORDIR= ${WWWDOCROOT}/${PHPSURVEYORURL}

post-configure:
    @ ${SED} \
    -e 's#%%PREFIX%%#${PREFIX}#g' \
    -e 's#%%PHPSURVEYORURL%%#${PHPSURVEYORURL}#g' \
    -e 's#%%PHPSURVEYORDIR%%#${PHPSURVEYORDIR}#g' \
    pkg-message > ${PKGMESSAGE}

do-install:
    ${MKDIR} -m 0755 ${PREFIX}/${PHPSURVEYORDIR}
    cd ${WRKSRC} && ${FIND} * \( -name tmp -a -prune \) -o -print \
      | ${TAR} cTf - - | ${TAR} xUCf ${PREFIX}/${PHPSURVEYORDIR} -
    ${MKDIR} ${PREFIX}/${PHPSURVEYORDIR}/tmp
    ${CHOWN} -R ${WWWOWN}:${WWWGRP} ${PREFIX}/${PHPSURVEYORDIR}
    ${CHMOD} 755 ${PREFIX}/${PHPSURVEYORDIR}/tmp

post-install:
.if !defined(BATCH)
    @ ${CAT} ${PKGMESSAGE}
.endif

.include <bsd.port.mk>