aboutsummaryrefslogtreecommitdiff
path: root/www/mod_accounting
diff options
context:
space:
mode:
authorOliver Lehmann <oliver@FreeBSD.org>2003-07-24 19:28:51 +0000
committerOliver Lehmann <oliver@FreeBSD.org>2003-07-24 19:28:51 +0000
commit99482e8806a449168613201aa8fad66e66879dfd (patch)
tree9f87de8a02970b492d3312f1bebcc21dc7db080d /www/mod_accounting
parent0e0818a386ca3559343077b5091c1a93efdaf98b (diff)
downloadports-99482e8806a449168613201aa8fad66e66879dfd.tar.gz
ports-99482e8806a449168613201aa8fad66e66879dfd.zip
Add mod_accounting 0.5,
an Apache module that records traffic statistics into a database. PR: 45502 Submitted by: Clément Laforêt <sheepkiller@cultdeadsheep.org>
Notes
Notes: svn path=/head/; revision=85545
Diffstat (limited to 'www/mod_accounting')
-rw-r--r--www/mod_accounting/Makefile53
-rw-r--r--www/mod_accounting/distinfo1
-rw-r--r--www/mod_accounting/files/patch-Makefile32
-rw-r--r--www/mod_accounting/pkg-descr5
-rw-r--r--www/mod_accounting/pkg-message10
-rw-r--r--www/mod_accounting/pkg-plist8
6 files changed, 109 insertions, 0 deletions
diff --git a/www/mod_accounting/Makefile b/www/mod_accounting/Makefile
new file mode 100644
index 000000000000..f15ddf6da446
--- /dev/null
+++ b/www/mod_accounting/Makefile
@@ -0,0 +1,53 @@
+# New ports collection makefile for: mod_accounting
+# Date created: 15 November 2002
+# Whom: Clément Laforêt <sheepkiller@cultdeadsheep.org>
+#
+# $FreeBSD$
+#
+
+PORTNAME= mod_accounting
+PORTVERSION= 0.5
+CATEGORIES= www
+MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
+MASTER_SITE_SUBDIR= mod-acct
+
+MAINTAINER= sheepkiller@cultdeadsheep.org
+COMMENT= An Apache module that records traffic statistics into a database
+
+BUILD_DEPENDS+= ${LOCALBASE}/sbin/apxs:${PORTSDIR}/www/apache13
+
+MAKE_ARGS+= APXS="${APXS}"
+APXS?= ${LOCALBASE}/sbin/apxs
+
+.if defined(WITHOUT_PGSQL)
+MAKE_ARGS+= WITHOUT_PGSQL=YES
+.else
+LIB_DEPENDS+= pq.3:${PORTSDIR}/databases/postgresql7
+.endif
+
+.if defined(WITHOUT_MYSQL)
+MAKE_ARGS+= WITHOUT_MYSQL=YES
+.else
+LIB_DEPENDS+= mysqlclient.10:${PORTSDIR}/databases/mysql323-client
+.endif
+
+pre-everything:
+ @${ECHO} "*-----------------------------------------*"
+ @${ECHO} "To disable MySQL support just define :"
+ @${ECHO} " WITHOUT_MYSQL=YES"
+ @${ECHO} "To disable PostgreSQL support just define :"
+ @${ECHO} " WITHOUT_PGSQL=YES"
+ @${ECHO} "*-----------------------------------------*"
+
+post-install:
+ @${MKDIR} ${PREFIX}/share/${PORTNAME}
+ ${INSTALL_DATA} ${WRKSRC}/schema.sql ${PREFIX}/share/${PORTNAME}
+.if !defined(NOPORTDOCS)
+ @${MKDIR} ${DOCSDIR}
+ ${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}/README
+ ${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}/FAQ.txt
+ ${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}/LICENSE
+.endif
+ @${CAT} ${PKGMESSAGE}
+
+.include <bsd.port.mk>
diff --git a/www/mod_accounting/distinfo b/www/mod_accounting/distinfo
new file mode 100644
index 000000000000..34b0432586fb
--- /dev/null
+++ b/www/mod_accounting/distinfo
@@ -0,0 +1 @@
+MD5 (mod_accounting-0.5.tar.gz) = fc045bbdc5ae32241765fea2967a63fb
diff --git a/www/mod_accounting/files/patch-Makefile b/www/mod_accounting/files/patch-Makefile
new file mode 100644
index 000000000000..7a341994cd56
--- /dev/null
+++ b/www/mod_accounting/files/patch-Makefile
@@ -0,0 +1,32 @@
+--- Makefile.orig Sun Dec 30 14:11:43 2001
++++ Makefile Tue Nov 19 21:07:22 2002
+@@ -5,13 +5,24 @@
+ ##
+
+ # the used tools
+-APXS=apxs
++#APXS=apxs
+ APACHECTL=apachectl
+
+-# here's what you may need to change
+-DEF=-DNEED_POSTGRES -DNEED_MYSQL
+-INC=-I/usr/local/pgsql/include/ -I/usr/local/mysql/include/
+-LIB=-L/usr/local/pgsql/lib -lpq -L/usr/local/mysql/lib/mysql/ -lmysqlclient
++.if !defined(WITHOUT_PGSQL)
++DEF_PGSQL= -DNEED_POSTGRES
++INC_PGSQL= -I${LOCALBASE}/include
++LIB_PGSQL= -L${LOCALBASE}/lib -lpq
++.endif
++
++.if !defined(WITHOUT_MYSQL)
++DEF_MYSQL= -DNEED_MYSQL
++INC_MYSQL= -I${LOCALBASE}/include
++LIB_MYSQL= -L${LOCALBASE}/lib/mysql -lmysqlclient
++.endif
++
++DEF=${DEF_MYSQL} ${DEF_PGSQL}
++INC=${INC_MYSQL} ${INC_PGSQL}
++LIB=${LIB_MYSQL} ${LIB_PGSQL}
+
+ # the default target
+ all: mod_accounting.so
diff --git a/www/mod_accounting/pkg-descr b/www/mod_accounting/pkg-descr
new file mode 100644
index 000000000000..3c0137f48aee
--- /dev/null
+++ b/www/mod_accounting/pkg-descr
@@ -0,0 +1,5 @@
+mod_accounting is a simple Apache module that can record
+traffic statistics (bytes in/out per http request) into
+SQL database (MySQL or PostgreSQL)
+
+WWW: http://mod-acct.sourceforge.net
diff --git a/www/mod_accounting/pkg-message b/www/mod_accounting/pkg-message
new file mode 100644
index 000000000000..601e93302c65
--- /dev/null
+++ b/www/mod_accounting/pkg-message
@@ -0,0 +1,10 @@
+----------------------------------------------------------------
+mod_accounting is now installed on your system
+You can find a SQL example schema to use mod_accounting here :
+${PREFIX}/share/mod_accounting/schema.sql
+
+To install it with MySQL use the following command:
+ mysql <database> < schema.sql
+For PostgreSQL:
+ psql <database> < schema.sql
+----------------------------------------------------------------
diff --git a/www/mod_accounting/pkg-plist b/www/mod_accounting/pkg-plist
new file mode 100644
index 000000000000..7483bdbd9235
--- /dev/null
+++ b/www/mod_accounting/pkg-plist
@@ -0,0 +1,8 @@
+libexec/apache/mod_accounting.so
+@exec %D/sbin/apxs -e -a -n accounting %D/%f
+@unexec echo "===> If you do not plan on reinstalling mod_accounting, you must manually remove"; echo "===> references to it in httpd.conf."
+share/mod_accounting/schema.sql
+%%PORTDOCS%%%%DOCSDIR%%/README
+%%PORTDOCS%%%%DOCSDIR%%/FAQ.txt
+%%PORTDOCS%%%%DOCSDIR%%/LICENSE
+%%PORTDOCS%%@dirrm %%DOCSDIR%%