diff options
author | demon <demon@FreeBSD.org> | 2004-07-26 02:54:55 +0800 |
---|---|---|
committer | demon <demon@FreeBSD.org> | 2004-07-26 02:54:55 +0800 |
commit | 9aa90e8d8dc6aadacd95e4934ff52d99f2953d95 (patch) | |
tree | dea2ed6b3b8633207e141898f097d27ab776bb0f /www/rt34/Makefile | |
parent | 605d1dce1f3ae6182840de6ec3433c56931fd642 (diff) | |
download | freebsd-ports-gnome-9aa90e8d8dc6aadacd95e4934ff52d99f2953d95.tar.gz freebsd-ports-gnome-9aa90e8d8dc6aadacd95e4934ff52d99f2953d95.tar.zst freebsd-ports-gnome-9aa90e8d8dc6aadacd95e4934ff52d99f2953d95.zip |
Upgrade to RT version 3.2.1 after a repo-copy from rt3 (thanks marcus!).
Submitted by: autrijus@autrijus.org (maintainer)
Diffstat (limited to 'www/rt34/Makefile')
-rw-r--r-- | www/rt34/Makefile | 60 |
1 files changed, 49 insertions, 11 deletions
diff --git a/www/rt34/Makefile b/www/rt34/Makefile index 7ba0241f7fe7..aaae45555d5c 100644 --- a/www/rt34/Makefile +++ b/www/rt34/Makefile @@ -1,12 +1,12 @@ -# New ports collection makefile for: rt3 -# Date created: 28 November 2002 -# Whom: autrijus +# New ports collection makefile for: rt3 +# Date created: 28 November 2002 +# Whom: autrijus # # $FreeBSD$ # PORTNAME= rt -PORTVERSION?= 3.0.11 +PORTVERSION?= 3.2.1 CATEGORIES= www MASTER_SITES?= http://download.bestpractical.com/pub/rt/release/ \ http://download.bestpractical.com/pub/rt/devel/ \ @@ -30,6 +30,7 @@ BUILD_DEPENDS+= ${APXS}:${PORTSDIR}/${APACHE_PORT} \ ${SITE_PERL}/Getopt/Long.pm:${PORTSDIR}/devel/p5-Getopt-Long \ ${SITE_PERL}/${PERL_ARCH}/HTML/Entities.pm:${PORTSDIR}/www/p5-HTML-Parser \ ${SITE_PERL}/HTML/FormatText.pm:${PORTSDIR}/textproc/p5-HTML-Format \ + ${SITE_PERL}/HTML/Scrubber.pm:${PORTSDIR}/www/p5-HTML-Scrubber \ ${SITE_PERL}/HTML/TreeBuilder.pm:${PORTSDIR}/www/p5-HTML-Tree \ ${SITE_PERL}/Locale/Maketext.pm:${PORTSDIR}/devel/p5-Locale-Maketext \ ${SITE_PERL}/Locale/Maketext/Fuzzy.pm:${PORTSDIR}/devel/p5-Locale-Maketext-Fuzzy \ @@ -37,6 +38,7 @@ BUILD_DEPENDS+= ${APXS}:${PORTSDIR}/${APACHE_PORT} \ ${SITE_PERL}/Log/Dispatch.pm:${PORTSDIR}/devel/p5-Log-Dispatch \ ${SITE_PERL}/Mail/Mailer.pm:${PORTSDIR}/mail/p5-Mail-Tools \ ${SITE_PERL}/MIME/Entity.pm:${PORTSDIR}/mail/p5-MIME-Tools \ + ${SITE_PERL}/Module/Versions/Report.pm:${PORTSDIR}/devel/p5-Module-Versions-Report \ ${SITE_PERL}/MLDBM.pm:${PORTSDIR}/databases/p5-MLDBM \ ${SITE_PERL}/Net/SMTP.pm:${PORTSDIR}/net/p5-Net \ ${SITE_PERL}/${PERL_ARCH}/Params/Validate.pm:${PORTSDIR}/devel/p5-Params-Validate \ @@ -49,6 +51,7 @@ BUILD_DEPENDS+= ${APXS}:${PORTSDIR}/${APACHE_PORT} \ ${SITE_PERL}/Text/Wrapper.pm:${PORTSDIR}/textproc/p5-Text-Wrapper \ ${SITE_PERL}/${PERL_ARCH}/Time/HiRes.pm:${PORTSDIR}/devel/p5-Time-HiRes \ ${SITE_PERL}/Time/ParseDate.pm:${PORTSDIR}/devel/p5-Time-modules \ + ${SITE_PERL}/Tree/Simple.pm:${PORTSDIR}/devel/p5-Tree-Simple \ ${SITE_PERL}/WWW/Mechanize.pm:${PORTSDIR}/www/p5-WWW-Mechanize RUN_DEPENDS= ${BUILD_DEPENDS} @@ -64,6 +67,9 @@ CONFIGURE_ARGS= --prefix=${RT_PATH} \ --with-db-host=${DB_HOST} \ --with-db-port=${DB_PORT} \ --with-db-type=${DB_TYPE} \ + --with-db-rt-user=${DB_USER} \ + --with-db-rt-pass=${DB_PASSWORD} \ + --with-db-database=${DB_DATABASE} \ --with-db-dba=${DB_DBA_USER} .if defined(WITH_FASTCGI) @@ -81,6 +87,7 @@ BUILD_DEPENDS+= ${LOCALBASE}/libexec/apache2/mod_perl.so:${PORTSDIR}/www/mod_per DEPENDS_ARGS+= WITHOUT_MODPERL=yes DEPENDS_ARGS+= WITH_MODPERL2=yes .else +# XXX - probe for static mod_perl using `httpd -l | grep perl` BUILD_DEPENDS+= ${LOCALBASE}/libexec/apache/libperl.so:${PORTSDIR}/www/mod_perl .endif .endif @@ -107,7 +114,10 @@ RT_PATH?= ${PREFIX}/rt3 LAYOUT?= RT3 DB_DBA_USER?= root +DB_USER?= rt_user +DB_PASSWORD?= rt_pass DB_HOST?= localhost +DB_DATABASE?= rt3 DB_DBA_PASSWORD?= WEB_USER?= www @@ -118,15 +128,21 @@ pre-fetch: @${ECHO} "" @${ECHO} "You may use the following build options:" @${ECHO} "" + @${ECHO} " UPGRADE_RT30 Upgrading from a RT 3.0 installation" + @${ECHO} " INITIAL_INSTALL Do initialize DB (for initial install only)" + @${ECHO} " WITH_FASTCGI Use FastCGI instead of mod_perl" + @${ECHO} " WITH_APACHE2 Use Apache2 as the web server" + @${ECHO} "" @${ECHO} " DB_TYPE=type mysql, Oracle, Pg or SQLite (mysql)" @${ECHO} " DB_HOST=hostname The database host (localhost)" @${ECHO} " DB_PORT=port The database port" + @${ECHO} " DB_DATABASE=port The database name (rt3)" + @${ECHO} " DB_DBA_USER=username Name of database administrator (root)" @${ECHO} " DB_DBA_PASSWORD=password Password of database administrator" - @${ECHO} " WITH_FASTCGI Use FastCGI instead of mod_perl" - @${ECHO} " WITH_APACHE2 Use Apache2 as the web server" - @${ECHO} " INITIAL_INSTALL Do initialize DB (for initial install only)" - @${ECHO} "" + @${ECHO} " DB_USER=username Name of database user for RT (rt_user)" + @${ECHO} " DB_PASSWORD=password Name of database password for RT (rt_pass)" + @sleep 3 pre-install: PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} \ @@ -135,10 +151,32 @@ pre-install: post-install: @${INSTALL_DATA} ${WRKSRC}/README ${RT_PATH}/README .if !defined(INITIAL_INSTALL) - @echo Upgrade of RT3 complete. +.if defined(UPGRADE_RT30) +.for version in 3.1.0 3.1.15 3.1.17 + -@${PERL} $(RT_PATH)/sbin/rt-setup-database --action schema --datadir ${WRKSRC}/etc/upgrade/${version} + -@${PERL} $(RT_PATH)/sbin/rt-setup-database --action acl --datadir ${WRKSRC}/etc/upgrade/${version} + -@${PERL} $(RT_PATH)/sbin/rt-setup-database --action insert --datadir ${WRKSRC}/etc/upgrade/${version} +.endfor + @${ECHO} "" + @${ECHO} "Upgrade of RT3 complete." +.else + @${ECHO} "" + @${ECHO} "Installation of RT3 complete. You may safely ignore the" + @${ECHO} "'make initialize-database' instruction above. Instead," + @${ECHO} "if you are upgrading from RT 3.0, please enter this now:" + @${ECHO} " make post-install -DUPGRADE_RT30" + @${ECHO} "" + @${ECHO} "If you are initializing a new installation, please do this:" + @${ECHO} " make post-install -DINITIAL_INSTALL" + @${ECHO} "" + @${ECHO} "Note that for both commands above, you will still need to" + @${ECHO} "supply the same build flags as passed to 'make install'," + @${ECHO} "in particular DB_DBA_USER and DB_DBA_PASSWORD." + @${ECHO} "" +.endif .else - -@${PERL} $(RT_PATH)/sbin/rt-setup-database --force --action drop --dba ${DB_DBA_USER} --dba-password ${DB_DBA_PASSWORD} - -@${PERL} $(RT_PATH)/sbin/rt-setup-database --force --action init --dba ${DB_DBA_USER} --dba-password ${DB_DBA_PASSWORD} + -@${PERL} $(RT_PATH)/sbin/rt-setup-database --force --action drop --dba '${DB_DBA_USER}' --dba-password '${DB_DBA_PASSWORD}' + -@${PERL} $(RT_PATH)/sbin/rt-setup-database --force --action init --dba '${DB_DBA_USER}' --dba-password '${DB_DBA_PASSWORD}' @${SED} s!%%RT_PATH%%!${RT_PATH}!g ${PKGMESSAGE} .endif |