- Added EPrints version make configuration variable.
- Removed redundant code.
1 parent 02bfc60 commit 189b12522dab27177c19143f2b3a8be3f8baa4a3
nstanger authored on 23 Jan 2008
Showing 3 changed files
View
4
Repositories/statistics/Makefile
GENERATED_FILES:=config/inc.vars.es.php scripts/eprints-usage.php \
scripts/fix-countries.php scripts/fix-titles.php vhost/apache.conf
 
CONFIG_SUBS:=EPRINTSSTATS EPRINTS_HOST EPRINTS_PORT EPRINTS_ADMIN_EMAIL
USAGE_SUBS:=GEOIP_DATABASE APACHE_LOG_LOCATION APACHE_LOG_NAME_1 APACHE_LOG_NAME_2
USAGE_SUBS:=EPRINTS_VERSION GEOIP_DATABASE APACHE_LOG_LOCATION APACHE_LOG_NAME_1 APACHE_LOG_NAME_2
FIX_SUBS:=GEOIP_DATABASE
VHOST_SUBS:=EPRINTSSTATS PHP_LIB
 
 
 
 
scripts/fix-titles.php: scripts/fix-titles_src.php environment_config.make
@announce "Generating $@"
perl -p $(foreach SUB,$(FIX_SUBS),-e "s|##$(SUB)##|$($(SUB))|g;") $< > $@
perl -p $(foreach SUB,$(USAGE_SUBS),-e "s|##$(SUB)##|$($(SUB))|g;") $< > $@
 
 
vhost/apache.conf: vhost/apache_src.conf environment_config.make
@announce "Generating $@"
View
2
■■■
Repositories/statistics/scripts/eprints-usage_src.php
EPrints, so we now need to check the major version number and alter
the queries appropriately. Use only the MAJOR version number (i.e.,
2 or 3, don't include the release number).
*/
$eprints_version = 3;
$eprints_version = ##EPRINTS_VERSION##;
 
/* NJS 2006-04-28
In earlier versions of this script, which eprints to count was
determined by comparing the request date of the eprint against the
View
10
Repositories/statistics/scripts/fix-titles_src.php
EPrints, so we now need to check the major version number and alter
the queries appropriately. Use only the MAJOR version number (i.e.,
2 or 3, don't include the release number).
*/
$eprints_version = 2;
$eprints_version = ##EPRINTS_VERSION##;
 
/*
 
Apache log for ePrints uses this format:
date YYYY MM DD
archive ID
 
*/
 
// Web server log files
$log_dir = '##APACHE_LOG_LOCATION##';
$log_file = array(
'otago_eprints' => '##APACHE_LOG_NAME_1##',
'cardrona' => '##APACHE_LOG_NAME_2##',
);
 
 
// eprintstats db
$sqlserver = 'localhost';
$sqluser = 'eprintstatspriv';