summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Knoblich <stkn@gentoo.org>2003-12-18 00:54:14 +0000
committerStefan Knoblich <stkn@gentoo.org>2003-12-18 00:54:14 +0000
commit2148f9fc1c7e8fb00de20a2334b6821face2cb4a (patch)
tree8d37baf1877772bab2d0af4c5c8de56c35a1c0cb /app-admin/modlogan
parentNew release (diff)
downloadgentoo-2-2148f9fc1c7e8fb00de20a2334b6821face2cb4a.tar.gz
gentoo-2-2148f9fc1c7e8fb00de20a2334b6821face2cb4a.tar.bz2
gentoo-2-2148f9fc1c7e8fb00de20a2334b6821face2cb4a.zip
sample config updates, added the themes package for template output plugin
Diffstat (limited to 'app-admin/modlogan')
-rw-r--r--app-admin/modlogan/ChangeLog9
-rw-r--r--app-admin/modlogan/Manifest7
-rw-r--r--app-admin/modlogan/files/0.8/modlogan.conf10
-rw-r--r--app-admin/modlogan/files/0.8/sample.conf113
-rw-r--r--app-admin/modlogan/files/0.8/sample.def.conf439
-rw-r--r--app-admin/modlogan/files/digest-modlogan-0.8.10-r13
-rw-r--r--app-admin/modlogan/modlogan-0.8.10-r1.ebuild122
7 files changed, 701 insertions, 2 deletions
diff --git a/app-admin/modlogan/ChangeLog b/app-admin/modlogan/ChangeLog
index 2aae70a4b8e1..cd12b0d3ce2e 100644
--- a/app-admin/modlogan/ChangeLog
+++ b/app-admin/modlogan/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for app-admin/modlogan
# Copyright 2002-2003 Gentoo Technologies, Inc.; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-admin/modlogan/ChangeLog,v 1.9 2003/09/24 22:37:56 seemant Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-admin/modlogan/ChangeLog,v 1.10 2003/12/18 00:54:03 stkn Exp $
+
+*modlogan-0.8.10-r1 (18 Dec 2003)
+
+ 18 Dec 2003; Stefan Knoblich <stkn@gentoo.org> modlogan-0.8.10-r1.ebuild,
+ files/0.8/modlogan.conf, files/0.8/sample.conf, files/0.8/sample.def.conf:
+ updated sample config, stats are put into /var/www..., themes get installed
+ (added examples to config file)
*modlogan-0.8.10 (24 Sep 2003)
diff --git a/app-admin/modlogan/Manifest b/app-admin/modlogan/Manifest
index d6ab00ce322a..3b51429e4555 100644
--- a/app-admin/modlogan/Manifest
+++ b/app-admin/modlogan/Manifest
@@ -1,10 +1,15 @@
-MD5 cd399a05e66c9808b0062613fb030361 ChangeLog 1648
+MD5 13fe7762200fb80ebd6ad280ad5eedbe ChangeLog 1947
MD5 f48ecda6f2ca1cf9041571da9865f355 modlogan-0.7.18.ebuild 2351
MD5 2d749926e7adbaf63b926f332854c3db modlogan-0.7.4-r1.ebuild 2458
MD5 c721bb5782586d87b19eebcb32eef178 modlogan-0.8.10.ebuild 2391
+MD5 46625ed77808d1b0c28216c646b634b1 modlogan-0.8.10-r1.ebuild 3013
MD5 543b8b188066fad85df5b30c2c7adbbf files/digest-modlogan-0.7.18 128
MD5 d471e4d2f40dd27ed20334729d7de263 files/digest-modlogan-0.7.4-r1 126
MD5 1dfe057138bc6b37bc313b7bafce15e0 files/digest-modlogan-0.8.10 127
MD5 1508bf93ccc2d4b8d381ae0094bdaeba files/modlogan.conf 228
MD5 61162d9bfcbe972114996bf4cc47c3ef files/sample.conf 1844
MD5 aaae54e619fac1ead5fb9b904775db55 files/sample.def.conf 12786
+MD5 eff845321cd889ffb7be6eaabc38205d files/digest-modlogan-0.8.10-r1 199
+MD5 cd845b930a3a89ad0e76c33a95ba385d files/0.8/sample.conf 2913
+MD5 8215abd50a0724bf4042c01821cd5dff files/0.8/sample.def.conf 11586
+MD5 c95a2f59d42ca578ae23355f467743ba files/0.8/modlogan.conf 189
diff --git a/app-admin/modlogan/files/0.8/modlogan.conf b/app-admin/modlogan/files/0.8/modlogan.conf
new file mode 100644
index 000000000000..5087842e0dbd
--- /dev/null
+++ b/app-admin/modlogan/files/0.8/modlogan.conf
@@ -0,0 +1,10 @@
+#
+# This is the config file for modlogan-statistics
+#
+<Directory "/var/www/localhost/htdocs/modlogan">
+ Options None
+ AllowOverride None
+
+ Order allow,deny
+ Allow from all
+</Directory>
diff --git a/app-admin/modlogan/files/0.8/sample.conf b/app-admin/modlogan/files/0.8/sample.conf
new file mode 100644
index 000000000000..1e12b61598e6
--- /dev/null
+++ b/app-admin/modlogan/files/0.8/sample.conf
@@ -0,0 +1,113 @@
+# ModLogAn configuration file
+#
+# 1. Format:
+# - lines starting with '#' are comments
+# - empty lines are ignored
+# - every other line has consist of a key-value pair
+# - a key-value pair has to be seperated by an equal-sign '='
+#
+# 2. Whitespaces:
+# - whitespaces at the end of key are ignored
+# - whitespaces at the end of value are ignored
+# - whitespaces at the beginning of value are ignored
+# example:
+# inputplugin=clf
+# and
+# inputplugin = clf
+# are the same.
+#
+# 3. Wildcardmatching:
+# every key that starts with
+# - hide
+# - group
+# - match
+# has support for wildcard matching. the wildcard is the '*' and is allowed
+# at the beginning and at the end of the value
+#
+# 4. sections
+# The configuration file is seperated into three parts
+# - [global]
+# - [input]
+# - [output]
+# - [processor]
+# the 'global'-section has to be at the top if the config-file.
+# the keys for the input and the output section are plugin specific
+
+# for the avaible options and if they can be overwritten, look at
+# ./doc/plugin-options.txt
+# for a description and examples of the options take a look at the
+# sample default-configfile ./doc/sample.def.conf
+
+# how include works:
+# include=<path to config file>,<name of section to include>
+#
+# to use the default options of the input_clf section from the default
+# configuration, one would use this:
+# include=/etc/modlogan/modlogan.def.conf,input_clf
+#
+# you can still overwrite options after the include line:
+# include=/etc/modlogan/modlogan.def.conf,input_clf
+# readaheadlimit=25
+
+#
+# global configuration section
+#
+[global]
+includepath=/etc/modlogan
+# include configuration from default config into this section
+include=modlogan.def.conf,global
+# load plugins
+loadplugin=input_clf
+loadplugin=output_modlogan
+loadplugin=processor_web
+
+# where to store statefiles ?
+statedir=/var/www/localhost/htdocs/modlogan/
+incremental=1
+
+# uncomment this, to get a list of supported options
+#show_available_config_options=1
+
+#
+# configuration for web processor plugin
+#
+[processor_web]
+include=modlogan.def.conf,processor_web
+hidereferrer="^http://##HOST2##"
+#splitby=srvhost,"(.*)",$1
+debug_searchengines=1
+
+
+#
+# configuration for modlogan output plugin
+#
+[output_modlogan]
+include=modlogan.def.conf,output_modlogan
+hostname=##HOST##
+outputdir=/var/www/localhost/htdocs/modlogan/
+
+#
+# configuration for template output plugin
+# (use loadplugin = output_template
+# instead of output_modlogan to use this)
+#
+[output_template]
+include=modlogan.def.conf,output_template
+include=modlogan.def.conf,output_template_reports_web
+include=modlogan.def.conf,output_template_menu_web
+hostname=##HOST##
+outputdir=/var/www/localhost/htdocs/modlogan/
+
+# to use another theme, see /usr/share/modlogan/themes/
+# for names (basic is default)
+#template_name = basic
+
+
+#
+# configuration for clf format input plugin
+#
+[input_clf]
+include=modlogan.def.conf,input_clf
+# read from stdin
+inputfile=-
+
diff --git a/app-admin/modlogan/files/0.8/sample.def.conf b/app-admin/modlogan/files/0.8/sample.def.conf
new file mode 100644
index 000000000000..eb72a2277c9c
--- /dev/null
+++ b/app-admin/modlogan/files/0.8/sample.def.conf
@@ -0,0 +1,439 @@
+# $Id: sample.def.conf,v 1.1 2003/12/18 00:54:03 stkn Exp $
+
+[global]
+# Compress XML state files with max gzip compression
+compress_mode=9
+
+## let modlogan decide what a read-ahead-limit might be the best
+read_ahead_limit = 0
+
+########## WEB Processor Section
+[processor_web]
+include = /etc/modlogan/modlogan/group.ua.conf,groupua
+include = /etc/modlogan/modlogan/group.os.conf,groupos
+# Host grouping has been split into some groups to allow
+# for detailed reports if you have lot's of visitors from germany etc.
+include = /etc/modlogan/modlogan/group.host.conf,grouphosts_germany
+include = /etc/modlogan/modlogan/group.host.conf,grouphosts_austria
+include = /etc/modlogan/modlogan/group.host.conf,grouphosts_us
+include = /etc/modlogan/modlogan/group.host.conf,grouphosts_misc
+# these two groupings should reasonably group most hosts
+include = /etc/modlogan/modlogan/group.host.conf,grouphosts_generic
+include = /etc/modlogan/modlogan/group.host.conf,grouphosts_ip
+include = /etc/modlogan/modlogan/group.extension.conf,groupext
+include = /etc/modlogan/modlogan/group.url.conf,groupurl
+
+include = /etc/modlogan/modlogan/group.searchengines.conf,group_searchengines
+include = /etc/modlogan/modlogan/ignore.searchengines.conf,ignore_searchengines
+include = /etc/modlogan/modlogan/match.searchengines.conf,match_searchengines
+
+
+
+maxhostcacheentries = 100
+
+## max count of hits per visit
+# kill endless visits
+max_hits_per_visit = 1000
+
+debug_searchengines = 0
+visit_timeout = 1800
+debug_visits = 0
+
+# log ungrouped searchengines
+log_ungrouped_searchengines = 0
+log_ungrouped_searchengines_file = ungrouped_searchengines.txt
+
+# decode searchstring
+decode_searchstrings = 1
+
+# Hide supplementary files such as images
+hideurl="\.(?i:gif|png|jpe?g|css|js|class|mid|swf)(?:\?|$)"
+# Hide Robots / Bookmarks from main Report
+hideurl="^/(?:robots.txt|favicon.ico)$"
+
+# Direct Accesses (no known referrer)
+groupreferrer="^-$",(Direct Access / no known referrer)
+
+groupsearchstrings="cache:.*? ",(Google Cache)
+# group lowercase
+groupsearchstrings="^(.*)$",$_1
+
+# Some special common broken links
+groupbrokenlinks="favicon\.ico$",Bookmarking Icons for MSIE 5.0, Galeon
+groupbrokenlinks="robots\.txt$",Robot control file /robots.txt
+
+# url that should be counted as pages
+## pages that end with a '/' are index-pages
+pagetype="/$"
+## default page names - single expression for speed
+pagetype="\.(?i:php[34]?|html?|phtml|shtml|asp|cgi|pl|jsp)(?:\?|$)"
+
+# To hide downloads such as Postscript, include this via
+# include = modlogan.def.conf,hide_downloads
+[hide_downloads]
+hideurl="\.(?i:mp3|mpg|pdf|ps|ps\.gz|zip|tgz|deb|rpm|rar|tar\.gz|bz3)$"
+
+########## OUTPUT Section
+[output_modlogan]
+## < 0 for all, 0 for none
+maxrequrls = 30
+maxrefurls = 30
+maxos = 50
+maxhosts = 30
+maxentrypages = 10
+maxexitpages = 10
+maxindexedpages = 20
+maxua = 30
+maxreqprot = 10
+maxreqmeth = 10
+maxstatuscodes = 10
+maxrobots = 20
+maxbookmarks = 20
+maxbrokenlinks = 20
+maxsearchengines= 20
+maxsearchstrings= 30
+maxinteralerrors= 20
+maxcountries = 20
+maxextensions = 20
+maxvisitpaths = 20
+maxvisitdurations = 20
+maxvisitpathlengths = 20
+maxviewdurations = 20
+maxvhosts = 100
+maxgraphedmonths = 13
+
+showdailygraph = 1
+showmonthlygraph = 1
+showhourlygraph = 1
+showcountrygraph = 1
+showvhostgraph = 1
+
+showmonthinmenu = 1
+showmonthlymaxima = 1
+
+showmonthlygraphgrid = 1
+grid = #000000
+
+showvalidationlinks = 1
+
+assumedprotocol = http
+
+pagestyle = seppage
+
+## Template names
+#htmlheader = header.ihtml
+#htmlfooter = footer.ihtml
+# this is NOT how the file in the output will be called!
+# this is the file name of the source file.
+cssfile = /etc/modlogan/modlogan/modlogan.css
+
+# HTML colors are in the CSS file, these colors are for
+# generating the graphics only.
+background = #ffffff
+foreground = #000000
+border = #000000
+shadow = #999999
+pages = #00c0ff
+files = #0080ff
+visits = #ffff00
+xfer = #ff0000
+hits = #00C030
+
+country_circle = #AF0000
+country_circle = #FF0000
+country_circle = #FF6400
+country_circle = #FFB900
+country_circle = #8CFF00
+country_circle = #00C800
+country_circle = #007B00
+country_circle = #0058FF
+country_circle = #009EFF
+country_circle = #0000FF
+country_circle = #000082
+
+# Vhost chart colors
+# added by sysman@sysman.net
+vhost_circle = #CC9933
+vhost_circle = #FF0066
+vhost_circle = #FF6600
+vhost_circle = #FFBB00
+vhost_circle = #CCFF00
+vhost_circle = #00CC00
+vhost_circle = #008800
+vhost_circle = #0066FF
+vhost_circle = #00CCFF
+vhost_circle = #0000FF
+vhost_circle = #000099
+
+########## Webalizer-Lookalike output section
+[output_webalizer]
+maxrequrls = 30
+maxrefurls = 30
+maxos = 50
+maxhosts = 30
+maxentrypages = 10
+maxexitpages = 10
+maxindexedpages = 20
+maxua = 30
+maxreqprot = 10
+maxreqmeth = 10
+maxstatuscodes = 10
+maxrobots = 20
+maxbookmarks = 20
+maxbrokenlinks = 20
+maxsearchengines= 20
+maxsearchstrings= 30
+maxinteralerrors= 20
+maxcountries = 20
+
+# colors
+# the notation is #RRGGBB (HTML-color-tripple)
+background = #c0c0c0
+shadow = #808080
+pages = #00c0ff
+files = #0080ff
+visits = #ffff00
+xfer = #ff0000
+hosts = #ff8000
+hits = #00C030
+grouping = #D0D0E0
+body = #FFFFFF
+
+########## TEXT Output Section
+[output_text]
+
+########## TKControl Output
+[output_tkcontrol]
+maxcallednumbers = 20
+maxcallingnumbers = 20
+
+background = #c0c0c0
+shadow = #808080
+outgoing = #00c0ff
+incoming = #00C030
+grouping = #D0D0E0
+body = #FFFFFF
+calls = #00ffff
+
+########## COMMON LOGFILE FORMAT input section
+[input_clf]
+include = /etc/modlogan/modlogan/match.useragents.conf,match_useragents
+
+# Default input is stdin
+inputfile = -
+
+########## Microsoft IIS input section
+[input_msiis]
+include = /etc/modlogan/modlogan/match.os.conf,matchos
+include = /etc/modlogan/modlogan/match.ua.conf,matchua
+
+# Default input is stdin
+inputfile = -
+
+[input_wuftpd]
+# Default input is stdin
+inputfile = -
+
+[input_realserver]
+# Default input is stdin
+inputfile = -
+
+[input_squid]
+# Default input is stdin
+inputfile = -
+
+[output_template]
+# {NAME} and {DATE} will be replaced. The rest of the filename is yours
+filename_pattern = mla-{NAME}-{DATE}.html
+index_filename = index.html
+template_path = /usr/share/modlogan/themes/
+template_name = basic
+
+assumedprotocol = http
+
+[output_template_reports_web]
+# enabling all available reports for the web-logs
+report = web_request_url
+report = web_request_url_traffic
+report = web_request_protocol
+report = web_request_method
+report = web_request_status
+report = web_request_extensions
+report = web_request_extensions_traffic
+report = web_user_users
+report = web_user_users_traffic
+
+report = web_user_referer
+report = web_user_os
+report = web_user_os_visits
+report = web_user_host
+report = web_user_host_visits
+report = web_user_useragent
+report = web_user_useragent_visits
+report = web_user_bookmarks
+report = web_user_countries
+report = web_user_countries_visits
+report = web_user_view_duration
+report = web_user_view_duration_visits
+report = web_user_view_duration_average
+
+report = web_visit_entry_pages
+report = web_visit_exit_pages
+report = web_visit_path
+report = web_visit_path_length
+report = web_visit_duration
+
+report = web_robot_indexed_pages
+report = web_robot_names
+report = web_robot_searchengine
+report = web_robot_seachstrings
+
+report = web_server_broken_links
+report = web_server_internal_errors
+report = web_server_vhosts
+
+report = web_generic_summary
+report = web_generic_hourly
+report = web_generic_daily
+
+[output_template_menu_web]
+## create a menu for the reports
+
+## with menuentry you can build menu-tree
+## menuentry = <parent>,<child>
+##
+## The first used parent is the root node, here: start
+##
+## if <child> is the name of a report, the specified report is assigned
+## to this menuentry
+
+menuentry = start,web_generic_summary
+menuentry = start,web_generic_hourly
+menuentry = start,web_generic_daily
+
+menuentry = start, req
+menuentry = start, user
+menuentry = start, visits
+menuentry = start, robots
+menuentry = start, server
+
+## declare a title for the pages which are not assigned to a report
+
+menutitle = start, Top
+menutitle = req, Requests
+menutitle = user, Users
+menutitle = robots, Robots
+menutitle = server, Server
+menutitle = visits, Visits
+
+menuentry = req,web_request_url
+menuentry = req,web_request_url_traffic
+menuentry = req,web_request_protocol
+menuentry = req,web_request_method
+menuentry = req,web_request_status
+menuentry = req,web_request_extensions
+menuentry = req,web_request_extensions_traffic
+menuentry = req,web_user_users
+menuentry = req,web_user_users_traffic
+
+menuentry = user,web_user_referer
+menuentry = user,web_user_os
+menuentry = user,web_user_os_visits
+menuentry = user,web_user_host
+menuentry = user,web_user_host_visits
+menuentry = user,web_user_useragent
+menuentry = user,web_user_useragent_visits
+menuentry = user,web_user_bookmarks
+menuentry = user,web_user_countries
+menuentry = user,web_user_countries_visits
+menuentry = user,web_user_view_duration
+menuentry = user,web_user_view_duration_visits
+menuentry = user,web_user_view_duration_average
+
+menuentry = visits,web_visit_entry_pages
+menuentry = visits,web_visit_exit_pages
+menuentry = visits,web_visit_path
+menuentry = visits,web_visit_path_length
+menuentry = visits,web_visit_duration
+
+menuentry = robots,web_robot_indexed_pages
+menuentry = robots,web_robot_names
+menuentry = robots,web_robot_searchengine
+menuentry = robots,web_robot_seachstrings
+
+menuentry = server,web_server_broken_links
+menuentry = server,web_server_internal_errors
+menuentry = server,web_server_vhosts
+
+[output_template_menu_web_german_titles]
+menutitle = start, Start
+menutitle = req, Anfragen
+menutitle = user, Nutzer
+menutitle = robots, Roboter
+menutitle = server, Server
+menutitle = visits, Besuche
+
+[output_template_reports_mail]
+report = mail_daily
+report = mail_hourly
+report = mail_sender
+report = mail_sender_traffic
+report = mail_receipient
+report = mail_receipient_traffic
+report = mail_incoming_domains
+report = mail_incoming_domains_traffic
+report = mail_outgoing_domains
+report = mail_outgoing_domains_traffic
+
+[output_template_reports_mail_qmail]
+report = mail_qmail_queue_pollution
+
+[output_template_reports_mail_virus]
+report = mail_virus
+report = mail_scanner
+report = mail_subject
+
+[output_template_menu_mail]
+menuentry = start, mail_daily
+menuentry = start, mail_hourly
+menuentry = start, email
+menuentry = start, domains
+menuentry = email, mail_sender
+menuentry = email, mail_sender_traffic
+menuentry = email, mail_receipient
+menuentry = email, mail_receipient_traffic
+menuentry = domains, mail_incoming_domains
+menuentry = domains, mail_incoming_domains_traffic
+menuentry = domains, mail_outgoing_domains
+menuentry = domains, mail_outgoing_domains_traffic
+
+menutitle = start, Top
+menutitle = email, Mail-Adresses
+menutitle = domains, Domains
+
+[output_template_menu_mail_german_titles]
+menutitle = start, Hier gehts los
+menutitle = email, Email-Adressen
+menutitle = domains, Domains
+
+[output_template_menu_mail_qmail]
+menuentry = start, qmail
+menuentry = qmail, mail_qmail_queue_pollution
+menutitle = qmail, Qmail
+
+[output_template_menu_mail_virus]
+menuentry = start, virus
+menuentry = virus, mail_virus
+menuentry = virus, mail_scanner
+menuentry = virus, mail_subject
+menutitle = virus, Virus Information
+
+[output_template_localizer]
+report = web_user_location_cities
+report = web_user_location_provinces
+report = web_user_location_countries
+report = web_user_location_provider
+menuentry = user,web_user_location_cities
+menuentry = user,web_user_location_provinces
+menuentry = user,web_user_location_countries
+menuentry = user,web_user_location_provider
diff --git a/app-admin/modlogan/files/digest-modlogan-0.8.10-r1 b/app-admin/modlogan/files/digest-modlogan-0.8.10-r1
new file mode 100644
index 000000000000..f02ded306a44
--- /dev/null
+++ b/app-admin/modlogan/files/digest-modlogan-0.8.10-r1
@@ -0,0 +1,3 @@
+MD5 caf689da199b0c4b01b29aeefcbe6171 modlogan-0.8.10.tar.gz 988443
+MD5 9ad1232612f9555352375e42eca298f5 modlogan-themes-0.0.5.tar.gz 47369
+MD5 46768d1d4af9f3f503f7f32ac4127c7a gd-1.8.1.tar.gz 260967
diff --git a/app-admin/modlogan/modlogan-0.8.10-r1.ebuild b/app-admin/modlogan/modlogan-0.8.10-r1.ebuild
new file mode 100644
index 000000000000..d7c5bc4f2582
--- /dev/null
+++ b/app-admin/modlogan/modlogan-0.8.10-r1.ebuild
@@ -0,0 +1,122 @@
+# Copyright 1999-2003 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-admin/modlogan/modlogan-0.8.10-r1.ebuild,v 1.1 2003/12/18 00:54:03 stkn Exp $
+
+IUSE="nls mysql X"
+
+THEMES_VERSION="0.0.5"
+
+DESCRIPTION="Logfile Analyzer"
+SRC_URI="http://jan.kneschke.de/projects/modlogan/download/${P}.tar.gz
+ http://jan.kneschke.de/projects/modlogan/download/modlogan-themes-${THEMES_VERSION}.tar.gz
+ http://www.kneschke.de/projekte/modlogan/download/gd-1.8.1.tar.gz"
+
+HOMEPAGE="http://jan.kneschke.de/projects/modlogan/"
+
+MY_FILESDIR="${FILESDIR}/${PV%.*}"
+
+SLOT="0"
+LICENSE="GPL-2"
+KEYWORDS="~x86 ~ia64 ~amd64 ~ppc ~sparc ~alpha ~hppa ~mips ~arm"
+
+DEPEND="dev-libs/libxml
+ dev-libs/libxml2
+ media-libs/jpeg
+ media-libs/libpng
+ =media-libs/freetype-1.3*
+ >=dev-libs/libpcre-3.2
+ >=net-libs/adns-1.0
+ X? ( virtual/x11 )
+ mysql? ( >=dev-db/mysql-3.23.26 )"
+
+RDEPEND="nls? ( sys-devel/gettext )"
+
+src_compile() {
+ local myconf
+
+ use X \
+ && myconf="${myconf} --with-x" \
+ || myconf="${myconf} --without-x"
+
+ cd ${S}/../gd-1.8.1
+ export CFLAGS="$CFLAGS -I/usr/include/freetype"
+
+ ./configure ${myconf} || die
+ make || die
+
+ cp .libs/libgd.so.0.0.0 libgd.so.0.0.0
+ ln -s libgd.so.0.0.0 libgd.so
+
+ use mysql \
+ && myconf="--with-mysql=/usr" \
+ || myconf="--without-mysql"
+
+ use nls || myconf="${myconf} --disable-nls"
+
+ cd ${S}
+ econf \
+ --enable-plugins \
+ --sysconfdir=/etc/modlogan \
+ --libdir=/usr/lib/modlogan \
+ --with-gd=${WORKDIR}/gd-1.8.1/ \
+ --disable-check-dynamic \
+ ${myconf} || die
+
+ make || die
+}
+
+src_install() {
+ cd ${S}/../gd-1.8.1
+ into /usr
+ dolib libgd.so.0.0.0
+
+ cd ${S}
+ einstall \
+ sysconfdir=${D}/etc/modlogan \
+ libdir=${D}/usr/lib/modlogan || die
+
+ insinto /etc/modlogan
+ newins ${MY_FILESDIR}/sample.conf modlogan.conf.sample
+ newins ${MY_FILESDIR}/sample.def.conf modlogan.def.conf.sample
+ insinto /etc/modlogan/modlogan
+ newins doc/modlogan.css-dist modlogan.css
+ doins doc/output.tmpl
+ doins doc/modlogan.searchengines
+### needs some fixing
+# insinto /etc/httpd
+# newins ${MY_FILESDIR}/modlogan.conf httpd.modlogan
+###
+ keepdir /var/www/localhost/htdocs/modlogan
+ preplib /usr
+ dodoc AUTHORS COPYING ChangeLog README NEWS TODO
+ dodoc doc/*.txt doc/*.conf doc/*-dist doc/glosar doc/stats
+ dohtml -r html
+
+ # install themes
+ cd ${S}/../modlogan-themes-${THEMES_VERSION}
+ dodir /usr/share/modlogan/themes
+ for i in `ls -1`; do
+ einfo "installing theme $i"
+ cp -Rf $i ${D}/usr/share/modlogan/themes/
+ done
+}
+
+pkg_postinst() {
+ if [ ! -a ${ROOT}etc/modlogan/modlogan.conf ]
+ then
+ cd ${ROOT}/etc/modlogan
+ sed -e "s:##HOST##:${HOSTNAME}:g" \
+ -e "s:##HOST2##:${HOSTNAME/./\\.}:g" \
+ modlogan.conf.sample > modlogan.conf
+ rm modlogan.conf.sample
+ fi
+
+ if [ ! -a ${ROOT}etc/modlogan/modlogan.def.conf ]
+ then
+ cd ${ROOT}/etc/modlogan
+ sed -e "s:##HOST##:${HOSTNAME}:g" \
+ -e "s:##HOST2##:${HOSTNAME/./\\.}:g" \
+ modlogan.def.conf.sample > modlogan.def.conf
+ rm modlogan.def.conf.sample
+ fi
+}