${LINKXX} -o $@ $@.o ${LIB} ${TEST_LIBS}
clean:
- rm -rvf *.o *.lo .libs lib* *.c *.cpp *.h
- rm -rvf log.xml project rpmbuild RPMS tgz
+ rm -rvf *.o *.lo .libs/ lib* *.c *.cpp *.h
+ rm -vf base64_test base64_test.xml
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
install: ${LIB}
mkdir -p ${PREFIX}/${libdir}
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.ws-interface' => [],
'lb.ws-test' => [ qw/gsoap:B/ ],
'lb.types' => [ qw// ],
- 'lb.harvester' => [ qw/postgresql:R/ ],
- 'lb.yaim' => [ qw/glite-yaim-core:R/ ],
+ 'lb.harvester' => [ qw// ],
+ 'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
- 'lbjp-common.jp-interface' => [ qw/cppunit:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
jpclient => 'jp.client',
);
+%obsoletes = (
+ 'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
+);
+
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_version=>'glite-version',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
+ yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
- 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema/],
+ vdt=>[qw/globus globus_essentials myproxy/],
+ 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
+ );
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
);
};
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
+};
+ for (@{$obsoletes{"$subsys.$module"}}) {
+ print C "package.obsoletes = $_\n";
+ print C "package.replaces = $_\n";
+ }
-[Platform-default:DynamicDependency]
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+ print C qq{
+[Platform-default:DynamicDependency]
};
for (@{$need_externs{"$subsys.$module"}},@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
- Generic lbdir settings in the Makefile
- Fixed package description and summary
+1.0.3-1
+- Fix library versioning
+
+1.0.4-1
+- Fixed libtool version numbering
+
+1.0.5-1
+- Fixed target 'clean' in the Makefile
+
+1.0.6-1
+- Support for IPv6 literal addresses
+- Fixed notification ID parsing
+
# : /cvs/jra1mw/org.glite.jobid.api-c/project/version.properties,v 1.1 2009/01/16 08:48:52 zsustr Exp $
-module.version=1.0.2
+module.version=1.0.6
module.age=1
return EINVAL;
out->BShost = strdup(bkserver);
- portbeg = strchr(out->BShost, ':');
+ portbeg = strrchr(out->BShost, ':');
if (portbeg) {
*portbeg = 0;
/* try to get port number */
pom = strdup(idString + sizeof(GLITE_JOBID_PROTO_PREFIX) - 1);
pom1 = strchr(pom, '/');
- pom2 = strchr(pom, ':');
if (!pom1) { free(pom); free(out); return EINVAL; }
+ pom1[0] = '\0';
- if ( pom2 && (pom1 > pom2)) {
+ pom2 = strrchr(pom, ':');
+ if (pom2 && strchr(pom2,']')) pom2 = NULL;
+
+ if ( pom2 ) {
pom[pom2-pom] = '\0';
out->BShost = strdup(pom);
pom[pom1-pom] = '\0';
clean:
rm -rvf *.o *.lo .libs lib* *.c *.cpp *.h
- rm -rvf log.xml project rpmbuild RPMS tgz
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
install:
mkdir -p ${PREFIX}/include/${globalprefix}/${jobidprefix}
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.ws-interface' => [],
'lb.ws-test' => [ qw/gsoap:B/ ],
'lb.types' => [ qw// ],
- 'lb.harvester' => [ qw/postgresql:R/ ],
- 'lb.yaim' => [ qw/glite-yaim-core:R/ ],
+ 'lb.harvester' => [ qw// ],
+ 'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
- 'lbjp-common.jp-interface' => [ qw/cppunit:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
jpclient => 'jp.client',
);
+%obsoletes = (
+ 'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
+);
+
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_version=>'glite-version',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
+ yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
- 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema/],
+ vdt=>[qw/globus globus_essentials myproxy/],
+ 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
+ );
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
);
};
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
+};
+ for (@{$obsoletes{"$subsys.$module"}}) {
+ print C "package.obsoletes = $_\n";
+ print C "package.replaces = $_\n";
+ }
-[Platform-default:DynamicDependency]
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+ print C qq{
+[Platform-default:DynamicDependency]
};
for (@{$need_externs{"$subsys.$module"}},@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
1.0.0-5
- module rebuilt
+1.0.0-6
+- module rebuilt
+
+1.0.1-1
+- Fixed target 'clean' in the Makefile
+
+1.0.1-2
+- Module rebuilt
+
# : /cvs/glite/org.glite.jobid.api-cpp/project/version.properties,v 1.1 2009/01/16 08:48:52 zsustr Exp $
-module.version=1.0.0
-module.age=5
+module.version=1.0.1
+module.age=2
-include Makefile.inc
all compile:
- ${ant_prefix}/bin/ant -Dfile.reference.commons-codec.jar=${commons-codec_jar}
+ ${ant_prefix}/bin/ant -Dfile.reference.commons-codec.jar=${jakarta-commons-codec_jar}
install:
mkdir -p ${PREFIX}/share/java
check:
clean:
- echo TODO
+ ${ant_prefix}/bin/ant clean
+ rm -rvf log.xml project/glite-jobid-api-java.spec rpmbuild/ RPMS/ tgz/ debian/
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.ws-interface' => [],
'lb.ws-test' => [ qw/gsoap:B/ ],
'lb.types' => [ qw// ],
- 'lb.harvester' => [ qw/postgresql:R/ ],
- 'lb.yaim' => [ qw/glite-yaim-core:R/ ],
+ 'lb.harvester' => [ qw// ],
+ 'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
- 'lbjp-common.jp-interface' => [ qw/cppunit:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
jpclient => 'jp.client',
);
+%obsoletes = (
+ 'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
+);
+
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_version=>'glite-version',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
+ yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
- 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema/],
+ vdt=>[qw/globus globus_essentials myproxy/],
+ 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
+ );
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
);
};
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
+};
+ for (@{$obsoletes{"$subsys.$module"}}) {
+ print C "package.obsoletes = $_\n";
+ print C "package.replaces = $_\n";
+ }
-[Platform-default:DynamicDependency]
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+ print C qq{
+[Platform-default:DynamicDependency]
};
for (@{$need_externs{"$subsys.$module"}},@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
1.0.1-1
- Initial release of the api-java module
+1.0.2-1
+- Fixed target 'clean' in the Makefile
+
+1.0.3-1
+- Target 'clean' fixed to handle debian builds as well
+
+1.0.3-2
+- Module rebuilt
+
# : /cvs/glite/org.glite.jobid.api-java/project/version.properties,v 1.5 2009/01/20 17:25:13 akrenek Exp $
-module.version=1.0.1
-module.age=1
+module.version=1.0.3
+module.age=2
# : /cvs/jra1mw/org.glite.jobid.api-c/project/version.properties,v 1.1 2009/01/16 08:48:52 zsustr Exp $
-module.version=1.0.2
+module.version=1.0.6
module.age=1
compile-java:
${JAVAC} \
- -classpath ${commons-lang_jar}:${stagedir}/share/java/jobid-api-java.jar:${trustmanager_classpath}:${utiljava_prefix}/share/java/glite-security-util-java.jar:${axis_classpath} \
+ -classpath ${jakarta-commons-lang_jar}:${stagedir}/share/java/jobid-api-java.jar:${trustmanager_classpath}:${utiljava_prefix}/share/java/glite-security-util-java.jar:${axis_classpath} \
-d build \
src/org/glite/lb/*.java \
build/gen/*.java \
${JAVAH} -classpath build -jni -d build org.glite.lb.ContextIL
-mkdir -p build/c
-ln -s ../../src_c/Makefile build/c
- cd build/c && make PREFIX=${PREFIX} JAVA_HOME=${jdk_prefix} topdir=../..
+ cd build/c && $(MAKE) PREFIX=${PREFIX} JAVA_HOME=${jdk_prefix} topdir=../..
examples: build/examples
mkdir -p ${PREFIX}/share/java
cp build/lb-client-java.jar ${PREFIX}/share/java
cp build/examples/lb-client-java-examples.jar ${PREFIX}/share/java
- cd build/c && make install PREFIX=${PREFIX}
+ cd build/c && $(MAKE) install PREFIX=${PREFIX}
clean:
rm -rf build
- cd src_c && make clean
+ cd src_c && $(MAKE) clean
+ rm -rvf log.xml project/org.glite.lb.client-java.spec rpmbuild/ RPMS/ tgz/ debian/
.PHONY: all compile compile-java build-jar build-c examples genevents genws check install clean
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.harvester' => [ qw// ],
'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
%obsoletes = (
'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
);
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
+ vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
+ );
};
sub mode_etics {
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
};
for (@{$obsoletes{"$subsys.$module"}}) {
print C "package.obsoletes = $_\n";
print C "package.replaces = $_\n";
}
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+
print C qq{
[Platform-default:DynamicDependency]
};
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
1.0.2-1
- Fixed time zone in UTC times in events
+
+1.0.3-1
+- Improved portability
+
+1.0.4-1
+- Fixed target 'clean' in the Makefile to handle debian builds
+- Fixed format of the package description file
+
+1.0.4-2
+- Module rebuilt
+
-JAVA implemantation of the L&B service client. Supports producing (logging)
-events into L&B, event and job status queries, and receiving notifications.
-
-
+JAVA implemantation of the L&B service client. Supports producing (logging) events into L&B, event and job status queries, and receiving notifications.
# $Header$
-module.version=1.0.2
-module.age=1
+module.version=1.0.4
+module.age=2
CC=gcc
PATH_TO_JAVA=${JAVA_HOME}
+OS=$(shell uname | tr '[:upper:]' '[:lower:]')
+
LIB=libglite_lb_sendviasocket.la
OBJ=send_via_socket.lo
libtool --mode=link ${CC} -rpath ${PREFIX}/${libdir} -o $@ ${OBJ}
%.lo: %.c
- libtool --mode=compile ${CC} -I.. -I${PATH_TO_JAVA}/include -I${PATH_TO_JAVA}/include/linux -c $<
+ libtool --mode=compile ${CC} -I.. -I${PATH_TO_JAVA}/include -I${PATH_TO_JAVA}/include/$(OS) -c $<
install: compile
-mkdir -p ${PREFIX}/${libdir}
COMMON_LIB_THR:=-lglite_lb_common_${thrflavour}
TRIO_LIB:=-lglite_lbu_trio
-CFLAGS:=${DEBUG} \
+CFLAGS:=${CFLAGS} ${DEBUG} \
-I. \
-I${top_srcdir}/src -I${top_srcdir}/interface \
-I${stagedir}/include \
TEST_LIBS:=-L${cppunit_prefix}/${libdir} -lcppunit
TEST_INC:=-I${cppunit_prefix}/include
-LDFLAGS:=-L${stagedir}/${libdir} ${COVERAGE_FLAGS}
+LDFLAGS:=${LDFLAGS} -L${stagedir}/${libdir} ${COVERAGE_FLAGS}
COMPILE:=libtool --mode=compile ${CC} ${CFLAGS}
CXXCOMPILE:=libtool --mode=compile ${CXX} ${CXXFLAGS}
THRPLUSLIB:=libglite_lb_clientpp_${thrflavour}.la
TOOLS:=${LB_PERF_TOOLS}
-EXAMPLES_SRC:=log_usertag_proxy.c job_log.c job_reg.c feed_shark.c query_ext.c query_seq_code.c stats.c abort_job.c change_acl.c stresslog.c flood_proxy.c dagids.c stress_context.c parse_eventsfile.c test_changed_jdl.c done_failed_events.c
+EXAMPLES_SRC:=log_usertag_proxy.c job_log.c job_reg.c feed_shark.c query_ext.c query_seq_code.c stats.c stats-duration-fromto.c abort_job.c change_acl.c stresslog.c flood_proxy.c dagids.c stress_context.c parse_eventsfile.c test_changed_jdl.c done_failed_events.c
EXAMPLES:=${EXAMPLES_SRC:.c=}
# TODO: migrate them here from branch_RC31_3
${INSTALL} -m 755 ${top_srcdir}/examples/sandbox_transfers.sh ${PREFIX}/examples/glite-lb-sandbox_transfers.sh
${INSTALL} -m 644 ${MAN_GZ} ${PREFIX}/share/man/man1
${INSTALL} -m 644 ${MAN8_GZ} ${PREFIX}/share/man/man8
- sed "s/%LIBDIR%/${libdir}/" ${top_srcdir}/m4/glite_lb_client.m4 > glite_lb_client.m4
- ${INSTALL} -m 644 glite_lb_client.m4 ${PREFIX}/share/build/m4/
+ ${INSTALL} -m 644 ${top_srcdir}/m4/glite_lb.m4 ${PREFIX}/share/build/m4/
clean:
rm -rvf *.o *.lo .libs lib* *.c *.cpp *.h *.dox producer_test notify C/ CPP/
rm -rvf ${LIB} ${THRLIB} ${TOOLS} logevent register_sandbox ${PLUSLIB} ${THRPLUSLIB} ${MAN_GZ} ${MAN8_GZ}
rm -rvf ${EXAMPLES} ${EXAMPLES_CL} ${EXAMPLES_CL_THR} ${sh_PROGS}
rm -f EventAttrNames.pl
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
check_version:
${CHECK_VERSION} ${stagedir}/include/glite/lb/common_version.h
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.ws-interface' => [],
'lb.ws-test' => [ qw/gsoap:B/ ],
'lb.types' => [ qw// ],
- 'lb.harvester' => [ qw/postgresql:R/ ],
- 'lb.yaim' => [ qw/glite-yaim-core:R/ ],
+ 'lb.harvester' => [ qw// ],
+ 'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
- 'lbjp-common.jp-interface' => [ qw/cppunit:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
jpclient => 'jp.client',
);
+%obsoletes = (
+ 'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
+);
+
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_version=>'glite-version',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
+ yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
- 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema/],
+ vdt=>[qw/globus globus_essentials myproxy/],
+ 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
+ );
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
);
};
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
+};
+ for (@{$obsoletes{"$subsys.$module"}}) {
+ print C "package.obsoletes = $_\n";
+ print C "package.replaces = $_\n";
+ }
-[Platform-default:DynamicDependency]
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+ print C qq{
+[Platform-default:DynamicDependency]
};
for (@{$need_externs{"$subsys.$module"}},@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
-#
+#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
-#
+
if test ! -z "$FAKE"; then
SUFFIX="_fake"
static void usage(char *me)
{
- fprintf(stderr,"usage: %s [-m bkserver] [-x|-X non-default_sock_path] [-j dg_jobid] [-s source_id] [-n num_subjobs [-S][-C]] [-P] [-l jdl_file] [-e seed]\n", me);
+ fprintf(stderr,"usage: %s [-m bkserver] [-x|-X non-default_sock_path] [-j dg_jobid] [-s source_id] [-n num_subjobs [-S][-C]] [-P] [-l jdl_file] [-e seed] [-E]\n", me);
}
int main(int argc, char *argv[])
{
char *src = NULL,*job = NULL,*server = NULL,*seq,*jdl = NULL, *seed = NULL;
int lbproxy = 0;
- int done = 0,num_subjobs = 0,reg_subjobs = 0,i, collection = 0, pbs=0, cream=0, type;
+ int done = 0,num_subjobs = 0,reg_subjobs = 0,i, collection = 0, pbs=0, cream=0, type, flags=0;
edg_wll_Context ctx;
edg_wlc_JobId jobid,*subjobs;
opterr = 0;
do {
- switch (getopt(argc,argv,"xX:s:j:m:n:SCl:e:Pc")) {
+ switch (getopt(argc,argv,"xX:s:j:m:n:SCl:e:PcE")) {
case 'x': lbproxy = 1; break;
case 'X': lbproxy = 1;
edg_wll_SetParam(ctx, EDG_WLL_PARAM_LBPROXY_STORE_SOCK, optarg);
case 'c': cream = 1; break;
case 'l': jdl = (char *) strdup(optarg); break;
case 'e': seed = strdup(optarg); break;
+ case 'E': flags = flags | EDG_WLL_LOGLFLAG_EXCL; break;
case '?': usage(argv[0]); exit(EINVAL);
case -1: done = 1; break;
}
exit(1);
}
} else {
+
+ if (flags) {
+ //printf("Registering with edg_wll_RegisterJobExt(). Flags = %d\n", flags);
+ if (edg_wll_RegisterJobExt(ctx,jobid,type,
+ jdl ? jdl : "blabla", "NS",
+ num_subjobs,seed,&subjobs,NULL,flags))
+ {
+ char *et,*ed;
+ edg_wll_Error(ctx,&et,&ed);
+ fprintf(stderr,"edg_wll_RegisterJobExt(%s): %s (%s)\n",job,et,ed);
+ exit(1);
+ }
+ } else {
if (edg_wll_RegisterJobSync(ctx,jobid,type,
jdl ? jdl : "blabla", "NS",
num_subjobs,seed,&subjobs))
fprintf(stderr,"edg_wll_RegisterJobSync(%s): %s (%s)\n",job,et,ed);
exit(1);
}
+ }
}
seq = edg_wll_GetSequenceCode(ctx);
--- /dev/null
+/*
+Copyright (c) Members of the EGEE Collaboration. 2004-2010.
+See http://www.eu-egee.org/partners for details on the copyright holders.
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+*/
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <time.h>
+#include <string.h>
+
+#ifdef BUILDING_LB_CLIENT
+#include "statistics.h"
+#else
+#include "glite/lb/statistics.h"
+#endif
+
+
+int main(int argc,char **argv)
+{
+ edg_wll_Context ctx;
+ edg_wll_QueryRec group[2];
+ time_t now,from,to;
+ char *cfrom,*cto;
+ int from_res,to_res;
+ float *durations, *dispersions;
+ char **groups;
+ int i;
+
+ edg_wll_InitContext(&ctx);
+
+ if (argc < 3) {
+ fprintf(stderr,"usage: %s CE state_from state_to\n",argv[0]);
+ return 1;
+ }
+
+/* the only supported grouping for now */
+ group[0].attr = EDG_WLL_QUERY_ATTR_DESTINATION;
+ group[0].op = EDG_WLL_QUERY_OP_EQUAL;
+ if (strcmp(argv[1], "ALL"))
+ group[0].value.c = argv[1];
+ else
+ group[0].value.c = NULL;
+ group[1].attr = EDG_WLL_QUERY_ATTR_UNDEF;
+
+
+ time(&now);
+ to = now;
+ from = now - 600;
+
+ if (edg_wll_StateDurationsFromTo(ctx,group,atoi(argv[2]),atoi(argv[3]),
+ argc >=5 ? atoi(argv[4]) : 0, &from,&to,&durations,&dispersions,
+ &groups,&from_res,&to_res))
+ {
+ char *et,*ed;
+ edg_wll_Error(ctx,&et,&ed);
+ fprintf(stderr,"edg_wll_StateRate(): %s, %s\n",et,ed);
+ return 1;
+ }
+
+ cfrom = strdup(ctime(&from));
+ cto = strdup(ctime(&to));
+ cfrom[strlen(cfrom)-1] = 0;
+ cto[strlen(cto)-1] = 0;
+
+ for (i = 0; groups[i]; i++)
+ printf("Average duration at \"%s\": %f s\n"
+ "Dispersion index: %f\n"
+ " Measuered from %s to %s\n"
+ " With resolution from %d to %d s\n",
+ /*argv[1]*/groups[i],durations[i],dispersions[i],cfrom,
+ cto,from_res,to_res);
+
+ free(durations);
+ free(dispersions);
+ for (i = 0; groups[i]; i++)
+ free(groups[i]);
+ free(groups);
+
+ return 0;
+}
+
time_t now,from,to;
char *cfrom,*cto;
int from_res,to_res,argOK = 3, era = 60;
- float val;
int CEidx = 1, MAJidx = 2, MINidx = 3;
+ float *vals;
+ char **groups;
+ int i;
edg_wll_InitContext(&ctx);
/* the only supported grouping for now */
group[0].attr = EDG_WLL_QUERY_ATTR_DESTINATION;
group[0].op = EDG_WLL_QUERY_OP_EQUAL;
- group[0].value.c = argv[CEidx];
+ if (strcmp(argv[CEidx], "ALL"))
+ group[0].value.c = argv[CEidx];
+ else
+ group[0].value.c = NULL;
group[1].attr = EDG_WLL_QUERY_ATTR_UNDEF;
to = now;
from = now - 60;
- if (edg_wll_StateRate(ctx,group,atoi(argv[MAJidx]),argc >= (argOK+1) ? atoi(argv[MINidx]) : 0,
- &from,&to,&val,&from_res,&to_res))
+ if (edg_wll_StateRates(ctx,group,atoi(argv[MAJidx]),argc >= (argOK+1) ? atoi(argv[MINidx]) : 0,
+ &from,&to,&vals,&groups,&from_res,&to_res))
{
char *et,*ed;
edg_wll_Error(ctx,&et,&ed);
cfrom[strlen(cfrom)-1] = 0;
cto[strlen(cto)-1] = 0;
- printf("Average failure rate at \"%s\": %f jobs/s\n"
- " Measuered from %s to %s\n"
- " With resolution from %d to %d s\n",
- argv[CEidx],val,cfrom,cto,from_res,to_res);
+ for (i = 0; groups[i]; i++)
+ printf("Average failure rate at \"%s\": %f jobs/s\n"
+ " Measuered from %s to %s\n"
+ " With resolution from %d to %d s\n",
+ /*argv[1]*/groups[i],vals[i],cfrom,cto,from_res,to_res);
+ free(vals);
+ for (i = 0; groups[i]; i++)
+ free(groups[i]);
+ free(groups);
return 0;
}
int minor,
time_t *from,
time_t *to,
- float *rate,
+ float *rates,
int *res_from,
int *res_to
);
+int edg_wll_StateRates(
+ edg_wll_Context context,
+ const edg_wll_QueryRec *group,
+ edg_wll_JobStatCode major,
+ int minor,
+ time_t *from,
+ time_t *to,
+ float **rates,
+ char ***groups,
+ int *res_from,
+ int *res_to
+);
/** Compute average time for which jobs stay in the specified state.
* \see edg_wll_StateRate for description of parameters.
*/
int edg_wll_StateDuration(
+ edg_wll_Context context,
+ const edg_wll_QueryRec *group,
+ edg_wll_JobStatCode major,
+ int minor,
+ time_t *from,
+ time_t *to,
+ float *duration,
+ int *res_from,
+ int *res_to
+);
+
+int edg_wll_StateDurations(
edg_wll_Context context,
const edg_wll_QueryRec *group,
edg_wll_JobStatCode major,
int minor,
time_t *from,
time_t *to,
- float *duration,
+ float **durations,
+ char ***groups,
int *res_from,
int *res_to
);
+int edg_wll_StateDurationFromTo(
+ edg_wll_Context ctx,
+ const edg_wll_QueryRec *group,
+ edg_wll_JobStatCode base,
+ edg_wll_JobStatCode final,
+ int minor,
+ time_t *from,
+ time_t *to,
+ float *durations,
+ float *dispersions,
+ int *res_from,
+ int *res_to
+);
+
+int edg_wll_StateDurationsFromTo(
+ edg_wll_Context ctx,
+ const edg_wll_QueryRec *group,
+ edg_wll_JobStatCode base,
+ edg_wll_JobStatCode final,
+ int minor,
+ time_t *from,
+ time_t *to,
+ float **durations,
+ float **dispersions,
+ char ***groups,
+ int *res_from,
+ int *res_to
+);
#ifdef __cplusplus
}
AC_DEFUN([AC_GLITE_LB],
[
+ AC_REQUIRE([AC_GLITE])
ac_glite_lb_prefix=$GLITE_LOCATION
AC_SEC_GSOAP_PLUGIN
- if test -n "ac_glite_lb_prefix" ; then
+ case $GLITE_LDFLAGS in
+ *lib64* )
+ ac_glite_lb_libdir=lib64
+ ;;
+
+ *lib32* )
+ ac_glite_lb_libdir=lib32
+ ;;
+
+ * )
+ ac_glite_lb_libdir=lib
+ ;;
+ esac
+
+
+ if test -n "$ac_glite_lb_prefix" ; then
dnl
dnl
dnl
- ac_glite_lb_lib="-L$ac_glite_lb_prefix/lib"
+ ac_glite_lb_lib="-L$ac_glite_lb_prefix/$ac_glite_lb_libdir"
GLITE_LB_THR_CLIENT_LIBS="$ac_glite_lb_lib -lglite_lb_client_$GLOBUS_THR_FLAVOR"
GLITE_LB_THR_CLIENTPP_LIBS="$ac_glite_lb_lib -lglite_lb_clientpp_$GLOBUS_THR_FLAVOR"
GLITE_LB_THR_COMMON_LIBS="$ac_glite_lb_lib -lglite_lb_common_$GLOBUS_THR_FLAVOR $SEC_GSOAP_PLUGIN_GSS_THR_LIBS"
GLITE_LB_NOTHR_CLIENT_LIBS="$ac_glite_lb_lib -lglite_lb_client_$GLOBUS_NOTHR_FLAVOR"
GLITE_LB_NOTHR_CLIENTPP_LIBS="$ac_glite_lb_lib -lglite_lb_clientpp_$GLOBUS_NOTHR_FLAVOR"
GLITE_LB_NOTHR_COMMON_LIBS="$ac_glite_lb_lib -lglite_lb_common_$GLOBUS_NOTHR_FLAVOR $SEC_GSOAP_PLUGIN_GSS_NOTHR_LIBS"
- GLITE_STATIC_LB_NOTHR_CLIENT_LIBS="$ac_glite_lb_prefix/lib/libglite_lb_client_$GLOBUS_NOTHR_FLAVOR.a"
- GLITE_STATIC_LB_NOTHR_COMMON_LIBS="$ac_glite_lb_prefix/lib/libglite_lb_common_$GLOBUS_NOTHR_FLAVOR.a $SEC_GSOAP_PLUGIN_GSS_STATIC_NOTHR_LIBS"
+ GLITE_STATIC_LB_NOTHR_CLIENT_LIBS="$ac_glite_lb_prefix/$ac_glite_lb_libdir/libglite_lb_client_$GLOBUS_NOTHR_FLAVOR.a"
+ GLITE_STATIC_LB_NOTHR_COMMON_LIBS="$ac_glite_lb_prefix/$ac_glite_lb_libdir/libglite_lb_common_$GLOBUS_NOTHR_FLAVOR.a $SEC_GSOAP_PLUGIN_GSS_STATIC_NOTHR_LIBS"
ifelse([$2], , :, [$2])
else
GLITE_LB_THR_CLIENT_LIBS=""
+++ /dev/null
-dnl Usage:
-dnl AC_GLITE_LB
-dnl - GLITE_LB_THR_CLIENT_LIBS
-dnl - GLITE_LB_THR_CLIENTPP_LIBS
-dnl - GLITE_LB_THR_COMMON_LIBS
-dnl - GLITE_LB_NOTHR_CLIENT_LIBS
-dnl - GLITE_LB_NOTHR_CLIENTPP_LIBS
-dnl - GLITE_LB_NOTHR_COMMON_LIBS
-dnl - GLITE_STATIC_LB_NOTHR_CLIENT_LIBS
-dnl - GLITE_STATIC_LB_NOTHR_COMMON_LIBS
-
-AC_DEFUN([AC_GLITE_LB],
-[
- ac_glite_lb_prefix=$GLITE_LOCATION
-
- AC_SEC_GSOAP_PLUGIN
-
- if test -n "ac_glite_lb_prefix" ; then
- dnl
- dnl
- dnl
- ac_glite_lb_lib="-L$ac_glite_lb_prefix/%LIBDIR%"
- GLITE_LB_THR_CLIENT_LIBS="$ac_glite_lb_lib -lglite_lb_client_$GLOBUS_THR_FLAVOR"
- GLITE_LB_THR_CLIENTPP_LIBS="$ac_glite_lb_lib -lglite_lb_clientpp_$GLOBUS_THR_FLAVOR"
- GLITE_LB_THR_COMMON_LIBS="$ac_glite_lb_lib -lglite_lb_common_$GLOBUS_THR_FLAVOR $SEC_GSOAP_PLUGIN_GSS_THR_LIBS"
- GLITE_LB_NOTHR_CLIENT_LIBS="$ac_glite_lb_lib -lglite_lb_client_$GLOBUS_NOTHR_FLAVOR"
- GLITE_LB_NOTHR_CLIENTPP_LIBS="$ac_glite_lb_lib -lglite_lb_clientpp_$GLOBUS_NOTHR_FLAVOR"
- GLITE_LB_NOTHR_COMMON_LIBS="$ac_glite_lb_lib -lglite_lb_common_$GLOBUS_NOTHR_FLAVOR $SEC_GSOAP_PLUGIN_GSS_NOTHR_LIBS"
- GLITE_STATIC_LB_NOTHR_CLIENT_LIBS="$ac_glite_lb_prefix/%LIBDIR%/libglite_lb_client_$GLOBUS_NOTHR_FLAVOR.a"
- GLITE_STATIC_LB_NOTHR_COMMON_LIBS="$ac_glite_lb_prefix/%LIBDIR%/libglite_lb_common_$GLOBUS_NOTHR_FLAVOR.a $SEC_GSOAP_PLUGIN_GSS_STATIC_NOTHR_LIBS"
- ifelse([$2], , :, [$2])
- else
- GLITE_LB_THR_CLIENT_LIBS=""
- GLITE_LB_THR_CLIENTPP_LIBS=""
- GLITE_LB_THR_COMMON_LIBS=""
- GLITE_LB_NOTHR_CLIENT_LIBS=""
- GLITE_LB_NOTHR_CLIENTPP_LIBS=""
- GLITE_LB_NOTHR_COMMON_LIBS=""
- GLITE_STATIC_LB_NOTHR_CLIENT_LIBS=""
- GLITE_STATIC_LB_NOTHR_COMMON_LIBS=""
- ifelse([$3], , :, [$3])
- fi
-
- AC_SUBST(GLITE_LB_THR_CLIENT_LIBS)
- AC_SUBST(GLITE_LB_THR_CLIENTPP_LIBS)
- AC_SUBST(GLITE_LB_THR_COMMON_LIBS)
- AC_SUBST(GLITE_LB_NOTHR_CLIENT_LIBS)
- AC_SUBST(GLITE_LB_NOTHR_CLIENTPP_LIBS)
- AC_SUBST(GLITE_LB_NOTHR_COMMON_LIBS)
- AC_SUBST(GLITE_STATIC_LB_NOTHR_CLIENT_LIBS)
- AC_SUBST(GLITE_STATIC_LB_NOTHR_COMMON_LIBS)
-])
-
-AC_DEFUN([GLITE_CHECK_LB_CLIENT],
-[AC_MSG_CHECKING([for org.glite.lb.client])
-save_CPPFLAGS=$CPPFLAGS
-CPPFLAGS="$CPPFLAGS $GLITE_CPPFLAGS"
-save_LDFLAGS=$LDFLAGS
-LDFLAGS="$LDFLAGS $GLITE_LDFLAGS -L$GLOBUS_LOCATION/lib"
-save_LIBS=$LIBS
-
-AC_LANG_PUSH([C])
-
-# prepare the test program, to link against the different combinations
-# of globus flavours
-
-AC_LANG_CONFTEST(
- [AC_LANG_PROGRAM(
- [@%:@include "glite/lb/consumer.h"],
- [edg_wll_QueryEvents(
- (edg_wll_Context)0,
- (const edg_wll_QueryRec*)0,
- (const edg_wll_QueryRec*)0,
- (edg_wll_Event**)0
- );]
- )]
-)
-
-LIBS="-lglite_lb_client_$GLOBUS_THR_FLAVOR $LIBS"
-AC_LINK_IFELSE([],
- [AC_SUBST([GLITE_LB_CLIENT_THR_LIBS], [-lglite_lb_client_$GLOBUS_THR_FLAVOR])],
- [AC_MSG_ERROR([cannot find org.glite.lb.client ($GLOBUS_THR_FLAVOR)])]
-)
-LIBS=$save_LIBS
-
-LIBS="-lglite_lb_client_$GLOBUS_NOTHR_FLAVOR $LIBS"
-AC_LINK_IFELSE([],
- [AC_SUBST([GLITE_LB_CLIENT_NOTHR_LIBS], [-lglite_lb_client_$GLOBUS_NOTHR_FLAVOR])],
- [AC_MSG_ERROR([cannot find org.glite.lb.client ($GLOBUS_NOTHR_FLAVOR)])]
-)
-LIBS=$save_LIBS
-
-AC_LANG_POP([C])
-
-AC_LANG_PUSH([C++])
-
-# prepare the test program, to link against the different combinations
-# of globus flavours
-
-AC_LANG_CONFTEST(
- [AC_LANG_PROGRAM(
- [@%:@include "glite/lb/Job.h"],
- [glite::lb::Job job;]
- )]
-)
-
-save_LIBS=$LIBS
-LIBS="-lglite_lb_clientpp_$GLOBUS_THR_FLAVOR $LIBS"
-AC_LINK_IFELSE([],
- [AC_SUBST([GLITE_LB_CLIENTPP_THR_LIBS], [-lglite_lb_clientpp_$GLOBUS_THR_FLAVOR])],
- [AC_MSG_ERROR([cannot find org.glite.lb.client (C++ - $GLOBUS_THR_FLAVOR)])]
-)
-LIBS=$save_LIBS
-
-LIBS="-lglite_lb_clientpp_$GLOBUS_NOTHR_FLAVOR $LIBS"
-AC_LINK_IFELSE([],
- [AC_SUBST([GLITE_LB_CLIENTPP_NOTHR_LIBS], [-lglite_lb_clientpp_$GLOBUS_NOTHR_FLAVOR])],
- [AC_MSG_ERROR([cannot find org.glite.lb.client (C++ - $GLOBUS_NOTHR_FLAVOR)])]
-)
-LIBS=$save_LIBS
-
-AC_LANG_POP([C++])
-
-LDFLAGS="$save_LDFLAGS"
-CPPFLAGS=$save_CPPFLAGS
-
-AC_MSG_RESULT([yes])
-
-])
4.0.3-2
- install libraries into $libdir
+4.0.4-1
+- Connection pool lock optimization and fixes
+- Rare crash fixes in notify example
+
+4.0.5-1
+- Compatibility with IPv6 compliant clients
+
+4.0.6-1
+- Install glite_lb.m4 rather than glite_lb_client.m4
+
+4.0.7-1
+- hard-coded 'lib' fixed in glite_lb.m4
+
4.1.0-1
- Support for CREAM jobs
- Support for logging sandbox transfers as jobs of a specific type
- Connection Pool locking fixed (Savannah bug #37081)
- Extended with WMS DNs and other flags (producer API cleanup)
+4.1.1-1
+- Job registration example supports the 'exclusive' flag
+- Notification client can read server address from JobID
+
+4.1.2-1
+- Fixed target 'clean' in the Makefile
+- Extended job state transition statistics
+- Extended statistics example
+- More automation in m4 macros
+- Fixed propagation of error codes received from server
+
+4.1.3-1
+- Hostname parsing adjusted to handle IPv6 addresses
+
# $Header$
-module.version=4.1.0
+module.version=4.1.3
module.age=1
{"state", required_argument, 0, 'S'},
{0, 0, 0, 0}};
int option_index = 0;
- char *single, *statelist;
+ char *single, *statelist, *notif_server;
edg_wll_JobStatCode single_code;
int statno, stdelims, sti;
+ unsigned int notif_server_port;
#define MAX_NEW_CONDS 7
conditions = (edg_wll_QueryRec **)calloc(MAX_NEW_CONDS + 1,sizeof(edg_wll_QueryRec *));
}
conditions[i][0].value.j = jid;
i++;
+ edg_wll_GetParam(ctx, EDG_WLL_PARAM_NOTIF_SERVER, ¬if_server);
+ if (!notif_server) {
+ glite_jobid_getServerParts(jid, ¬if_server, ¬if_server_port);
+ edg_wll_SetParam(ctx, EDG_WLL_PARAM_NOTIF_SERVER, notif_server);
+ edg_wll_SetParamInt(ctx, EDG_WLL_PARAM_NOTIF_SERVER_PORT, notif_server_port);
+ }
+ free(notif_server);
break;
case 'o':
if (excl) { usage("new"); return EX_USAGE; } else excl = 1;
valid);
edg_wll_NotifIdFree(id_out);
if (attr == EDG_WLL_QUERY_ATTR_JOBID) edg_wlc_JobIdFree(jid);
+ if (edg_wll_Error(ctx,&errt,&errd)) {
+ fprintf(stderr, "%s: %s (%s)\n", me, errt, errd);
+ return EX_IOERR;
+ }
}
else if ( !strcmp(argv[1], "bind") )
{
if ( !edg_wll_NotifBind(ctx, nid, sock, fake_addr, &valid) )
printf("valid until: %s (%ld)\n", TimeToStr(valid), valid);
edg_wll_NotifIdFree(nid);
+ if (edg_wll_Error(ctx,&errt,&errd)) {
+ fprintf(stderr, "%s: %s (%s)\n", me, errt, errd);
+ return EX_IOERR;
+ }
}
else if ( !strcmp(argv[1], "receive") )
{
if (tout.tv_sec < 0) tout.tv_sec = 0;
tout.tv_usec = 0;
- edg_wll_FreeStatus(&stat);
- stat.state = EDG_WLL_JOB_UNDEF;
-
if ( (err = edg_wll_NotifReceive(ctx, sock, &tout, &stat, &recv_nid)) ) {
edg_wll_NotifIdFree(recv_nid);
recv_nid = NULL;
if (err != ETIMEDOUT) goto receive_err;
}
- else glite_lb_print_stat_fields(fields,&stat);
+ else {
+ glite_lb_print_stat_fields(fields,&stat);
+ edg_wll_FreeStatus(&stat);
+ stat.state = EDG_WLL_JOB_UNDEF;
+ }
- if ((now = time(NULL)) >= client_tout) return 0;
+ if ((now = time(NULL)) >= client_tout) goto cleanup;
if (refresh && now >= do_refresh) {
valid = now + opt_valid;
free(conditions);
}
- edg_wll_NotifCloseFd(ctx);
-
if (edg_wll_Error(ctx,&errt,&errd))
fprintf(stderr, "%s: %s (%s)\n", me, errt, errd);
+ edg_wll_NotifCloseFd(ctx);
edg_wll_FreeContext(ctx);
+ edg_wll_poolFree();
-
return 0;
}
dprintf(("generating jobids..."));
{
char *name=server?server:strdup(PROXY_SERVER);
- char *p = strchr(name,':');
+ char *p = strrchr(name,':');
int port;
if (p) { *p=0; port = atoi(p+1); }
if ((ret = edg_wll_log_direct_connect(ctx,&con_bkserver))) {
edg_wll_UpdateError(ctx,EAGAIN,"edg_wll_DoLogEventServer(): edg_wll_log_direct_connect error");
goto edg_wll_DoLogEventServer_end;
- goto inc_seq_code;
}
count++;
}
case 0: /* timeout */
edg_wll_UpdateError(ctx,EAGAIN,"edg_wll_DoLogEventServer(): select() timeouted");
count = 0;
- goto inc_seq_code;
+ goto edg_wll_DoLogEventServer_end;
break;
case -1: /* error */
switch(errno) {
continue;
default:
edg_wll_UpdateError(ctx,errno,"edg_wll_DoLogEventServer(): select() error");
- goto inc_seq_code;
+ goto edg_wll_DoLogEventServer_end;
}
default:
break;
/* read answer from lbproxy */
if ((ret = edg_wll_log_proxy_read(ctx,&con_lbproxy)) == -1) {
edg_wll_UpdateError(ctx,EAGAIN,"edg_wll_DoLogEventServer(): edg_wll_log_proxy_read error");
- goto inc_seq_code;
+ goto edg_wll_DoLogEventServer_end;
}
count -= 1;
}
/* read answer from bkserver */
if ((ret = edg_wll_log_direct_read(ctx,&con_bkserver)) == -1) {
edg_wll_UpdateError(ctx,EAGAIN,"edg_wll_DoLogEventServer(): edg_wll_log_direct_read error");
- goto inc_seq_code;
+ goto edg_wll_DoLogEventServer_end;
}
count -= 1;
}
}
-inc_seq_code:
- edg_wll_IncSequenceCode(ctx); /* XXX: should not fail, called second time */
-
edg_wll_DoLogEventServer_end:
edg_wll_log_proxy_close(ctx,&con_lbproxy);
edg_wll_log_direct_close(ctx,&con_bkserver);
// va_list fmt_args;
int ret = 0;
edg_wll_LogLine in = NULL, out = NULL;
+ int err_store;
+ char *err_desc_store = NULL;
if ((flags & (EDG_WLL_LOGFLAG_LOCAL|EDG_WLL_LOGFLAG_PROXY|EDG_WLL_LOGFLAG_DIRECT)) == 0) {
return edg_wll_SetError(ctx,ret = EINVAL,"edg_wll_LogEventMaster(): no known flag specified");
if (in) free(in);
if (out) free(out);
- if (!ret) if(edg_wll_IncSequenceCode(ctx)) {
+ if (ctx->errCode) {
+ err_store = ctx->errCode;
+ err_desc_store = strdup(ctx->errDesc); }
+
+ if(edg_wll_IncSequenceCode(ctx)) {
edg_wll_SetError(ctx,ret = EINVAL,"edg_wll_LogEventMaster(): edg_wll_IncSequenceCode failed");
}
+ if (err_desc_store) {
+ edg_wll_SetError(ctx, err_store, err_desc_store);
+ free(err_desc_store); }
+
if (ret) edg_wll_UpdateError(ctx,0,"Logging library ERROR: ");
return edg_wll_Error(ctx,NULL,NULL);
*/
int edg_wll_StateRate(
+ edg_wll_Context ctx,
+ const edg_wll_QueryRec *group,
+ edg_wll_JobStatCode major,
+ int minor,
+ time_t *from,
+ time_t *to,
+ float *rate,
+ int *res_from,
+ int *res_to)
+
+{
+ float *rates = NULL;
+ char **groups = NULL;
+ int i;
+
+ edg_wll_StateRates(ctx, group, major, minor, from, to, &rates, &groups, res_from, res_to);
+ if (groups && groups[0]){
+ *rate = rates[0];
+ free(rates);
+ for (i = 0; groups[i]; i++)
+ free(groups[i]);
+ free(groups);
+ }
+ return edg_wll_Error(ctx, NULL, NULL);
+}
+
+int edg_wll_StateRates(
edg_wll_Context ctx,
const edg_wll_QueryRec *group,
edg_wll_JobStatCode major,
int minor,
time_t *from,
time_t *to,
- float *rate,
+ float **rates,
+ char ***groups,
int *res_from,
int *res_to)
{
char *response = NULL, *send_mess = NULL, *message = NULL;
- float not_returned;
+ float *not_returned;
edg_wll_ResetError(ctx);
if (http_check_status(ctx,response))
goto err;
- edg_wll_ParseStatsResult(ctx,message, from, to, rate,
- ¬_returned, res_from, res_to);
+ edg_wll_ParseStatsResultFull(ctx,message, from, to, rates,
+ ¬_returned, ¬_returned, groups, res_from, res_to);
err:
free(response);
*/
int edg_wll_StateDuration(
+ edg_wll_Context ctx,
+ const edg_wll_QueryRec *group,
+ edg_wll_JobStatCode major,
+ int minor,
+ time_t *from,
+ time_t *to,
+ float *duration,
+ int *res_from,
+ int *res_to)
+{
+ float *durations;
+ char **groups;
+ int i;
+
+ edg_wll_StateDurations(ctx, group, major, minor, from, to, &durations, &groups, res_from, res_to);
+ if (groups && groups[0]){
+ *duration = durations[0];
+ free(durations);
+ for (i = 0; groups[i]; i++)
+ free(groups[i]);
+ free(groups);
+ }
+
+ return edg_wll_Error(ctx, NULL, NULL);
+}
+
+int edg_wll_StateDurations(
edg_wll_Context ctx,
const edg_wll_QueryRec *group,
edg_wll_JobStatCode major,
int minor,
time_t *from,
time_t *to,
- float *duration,
+ float **durations,
+ char ***groups,
int *res_from,
int *res_to)
{
char *response = NULL, *send_mess = NULL, *message = NULL;
- float not_returned;
+ float *not_returned;
edg_wll_ResetError(ctx);
if (http_check_status(ctx,response))
goto err;
- edg_wll_ParseStatsResult(ctx,message, from, to, ¬_returned,
- duration, res_from, res_to);
+ edg_wll_ParseStatsResultFull(ctx,message, from, to, ¬_returned,
+ durations, ¬_returned, groups, res_from, res_to);
err:
free(response);
+/** Compute average time for which jobs moves from one to second specified state.
+ */
+
+int edg_wll_StateDurationFromTo(
+ edg_wll_Context ctx,
+ const edg_wll_QueryRec *group,
+ edg_wll_JobStatCode base,
+ edg_wll_JobStatCode final,
+ int minor,
+ time_t *from,
+ time_t *to,
+ float *duration,
+ float *dispersion,
+ int *res_from,
+ int *res_to
+)
+{
+ float *durations;
+ float *dispersions;
+ char **groups;
+ int i;
+
+ edg_wll_StateDurationsFromTo(ctx, group, base, final, minor, from, to,
+ &durations, &dispersions, &groups, res_from, res_to);
+ if (groups && groups[0]){
+ *duration = durations[0];
+ *dispersion = dispersions[0];
+ free(durations);
+ free(dispersions);
+ for (i = 0; groups[i]; i++)
+ free(groups[i]);
+ free(groups);
+ }
+
+ return edg_wll_Error(ctx, NULL, NULL);
+}
+
+int edg_wll_StateDurationsFromTo(
+ edg_wll_Context ctx,
+ const edg_wll_QueryRec *group,
+ edg_wll_JobStatCode base,
+ edg_wll_JobStatCode final,
+ int minor,
+ time_t *from,
+ time_t *to,
+ float **durations,
+ float **dispersions,
+ char ***groups,
+ int *res_from,
+ int *res_to
+)
+{
+ char *response = NULL, *send_mess = NULL, *message = NULL;
+ float *not_returned;
+
+
+ edg_wll_ResetError(ctx);
+
+ edg_wll_StatsDurationFTRequestToXML(ctx, "DurationFromTo", group, base, final, minor, from, to, &send_mess);
+
+ if (set_server_name_and_port(ctx, NULL))
+ goto err;
+
+ ctx->p_tmp_timeout = ctx->p_query_timeout;
+
+ if (edg_wll_http_send_recv(ctx, "POST /statsRequest HTTP/1.1",request_headers, send_mess,
+ &response,NULL,&message))
+ goto err;
+
+ if (http_check_status(ctx,response))
+ goto err;
+
+ edg_wll_ParseStatsResultFull(ctx,message, from, to, ¬_returned,
+ durations, dispersions, groups, res_from, res_to);
+
+err:
+ free(response);
+ free(message);
+
+ return edg_wll_Error(ctx,NULL,NULL);
+}
+
+
+
static int set_server_name_and_port(edg_wll_Context ctx, const edg_wll_QueryRec **job_conditions)
{
int i = 0, j,
PERF_HDRS:=lb_perftest.h
PERF_OBJS:=lb_perftest.o
-CFLAGS:=${DEBUG} -I${top_srcdir}/src -I${top_srcdir}/interface \
+CFLAGS:=${CFLAGS} ${DEBUG} -I${top_srcdir}/src -I${top_srcdir}/interface \
-I. \
-I${top_srcdir}/test \
-I${stagedir}/include \
classadslib := ${classadslib} -lclassad
-LDFLAGS:=-L${stagedir}/${libdir} -L${stagedir}/lib \
+LDFLAGS:=${LDFLAGS} -L${stagedir}/${libdir} -L${stagedir}/lib \
${COVERAGE_FLAGS}
EXT_LIBS:= ${EXPAT_LIBS} ${JOBID_LIB} ${TRIO_LIB} ${classadslib}
${INSTALL} -m 644 glite/wmsutils/jobid/*.h ${PREFIX}/include/glite/wmsutils/jobid/ ; \
fi ;
${STAGE_PERFTEST} ;
- mkdir -p ${PREFIX}/share/build/m4
- ${INSTALL} -m 644 ${top_srcdir}/m4/*.m4 ${PREFIX}/share/build/m4
clean:
rm -rvf *.o *.lo .libs lib* *.c *.h *.dox C/ CPP/ test_parse il_test parse.cpp events.tex status.tex
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
%.o: %.c
${COMPILE} ${CFLAGS} -c $<
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.harvester' => [ qw// ],
'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
%obsoletes = (
'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
);
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
+ vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
+ );
};
sub mode_etics {
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
};
for (@{$obsoletes{"$subsys.$module"}}) {
print C "package.obsoletes = $_\n";
print C "package.replaces = $_\n";
}
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+
print C qq{
[Platform-default:DynamicDependency]
};
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
time_t rssTime;
_edg_wll_authz_policy authz_policy;
+
+ int exclusive_zombies;
)
/* to be used internally: set, update and and clear the error information in
time_t notifValidity;
char *statsFunction;
edg_wll_QueryRec **statsConditions;
- edg_wll_JobStatCode statsMajor;
+ edg_wll_JobStatCode statsBaseState;
+ edg_wll_JobStatCode statsFinalState;
int statsMinor;
time_t statsFrom, statsTo;
- float statsRate, statsDuration;
+ float *statsRate, *statsDuration, *statsDispersion;
+ char **statsGroup;
int statsResFrom, statsResTo;
glite_jobid_t jobId;
char *source;
extern int edg_wll_QuerySequenceCodeToXML(edg_wll_Context ctx, glite_jobid_const_t jobId, char **message);
extern int edg_wll_StatsRequestToXML(edg_wll_Context,const char *,const edg_wll_QueryRec *,edg_wll_JobStatCode,int,time_t *,time_t *,char **);
+
+extern int edg_wll_StatsDurationFTRequestToXML(edg_wll_Context,const char *,const edg_wll_QueryRec *,edg_wll_JobStatCode,edg_wll_JobStatCode,int,time_t *,time_t *,char **);
extern edg_wll_ErrorCode edg_wll_ParseStatsResult(edg_wll_Context ctx, char *messageBody, time_t *from, time_t *to, float *rate, float *duration, int *res_from, int *res_to);
+extern edg_wll_ErrorCode edg_wll_ParseStatsResultFull(edg_wll_Context ctx, char *messageBody, time_t *from, time_t *to, float **rate, float **duration, float **dispersion, char ***group, int *res_from, int *res_to);
+
#ifdef __cplusplus
}
#endif
7.0.4-2
- Buildtime dependency on c-ares
+7.0.5-1
+- Comments for common event fields
+- Locking in connPool initiation
+
+7.0.6-1
+- Remove glite_lb_common.m4 (replaced by glite_lb.m4 from lb.client)
+
7.1.0-1
- Advanced Autorization
7.1.1-1
- Broader authorization policy format
+
+7.1.2-1
+- A new property included in context
+
+7.1.3-1
+- Fixed target 'clean' in the Makefile to handle debian builds
+- Extended job state transition statistics
+
+7.1.4-1
+- Hostname parsing adjusted to handle IPv6 addresses
+
# $Header$
-module.version=7.1.1
+module.version=7.1.4
module.age=1
{
char *p;
- p = strchr(host, ':');
+ p = strrchr(host, ':');
if(p)
*p = 0;
dest_host = strdup(host);
{
char *p = NULL,*s = mygetenv(param);
- if (s) p = strchr(s,':');
+ if (s) p = strrchr(s,':');
return p ? atoi(p+1) : dflt;
}
s = mygetenv(param);
if (!s && !dflt) return NULL;
s = strdup(s?s:dflt),
- p = strchr(s,':');
+ p = strrchr(s,':');
if (p) *p = 0;
return s;
}
c->bound = 0;
c->statsFunction = NULL;
c->statsConditions = NULL;
- c->statsMajor = EDG_WLL_JOB_UNDEF;
+ c->statsBaseState = EDG_WLL_JOB_UNDEF;
+ c->statsFinalState = EDG_WLL_JOB_UNDEF;
c->statsMinor = 0;
- c->statsRate = 0;
- c->statsDuration = 0;
+ c->statsRate = NULL;
+ c->statsDuration = NULL;
+ c->statsDispersion = NULL;
+ c->statsGroup = NULL;
c->statsFrom = 0;
c->statsTo = 0;
c->statsResFrom = 0;
void edg_wll_freeXMLCtx(edg_wll_XML_ctx *c) {
+ int i;
if (c->char_buf) free(c->char_buf);
if (c->errtxt) free(c->errtxt);
if (c->warntxt) free(c->warntxt);
if (c->XML_tag) free(c->XML_tag);
if (c->XML_tag2) free(c->XML_tag2);
+ if (c->statsRate) free(c->statsRate);
+ if (c->statsDuration) free(c->statsDuration);
+ if (c->statsDispersion) free(c->statsDispersion);
+ if (c->statsGroup){
+ for (i = 0; c->statsGroup[i]; i++)
+ free(c->statsGroup[i]);
+ free(c->statsGroup);
+ }
}
else if (!strcmp(attr[i],"desc"))
XMLCtx->errDesc = strdup(attr[i+1]);
else { unexpError() }
- }
+ }
+ XMLCtx->statsGroup = (char**)malloc(1*sizeof(char*));
+ XMLCtx->statsGroup[0] = NULL;
+ XMLCtx->position = -1;
+
break;
- case 1: if (strcasecmp(el,"from") && strcasecmp(el,"to") &&
- strcasecmp(el,"rate") && strcasecmp(el,"duration") &&
- strcasecmp(el,"res_from") && strcasecmp(el,"res_to"))
- unexpWarning()
- break;
+ case 1: if (strcasecmp(el,"from") && strcasecmp(el,"to") &&
+ strcasecmp(el,"res_from") && strcasecmp(el,"res_to") &&
+ strcasecmp(el, "stat"))
+ unexpWarning()
+ if (strcasecmp(el, "stat") == 0){
+ XMLCtx->position++;
+ XMLCtx->statsGroup = (char**)realloc(XMLCtx->statsGroup, (XMLCtx->position+2)*sizeof(char*));
+ XMLCtx->statsGroup[XMLCtx->position+1] = NULL;
+ XMLCtx->statsRate = (float*)realloc(XMLCtx->statsRate, (XMLCtx->position+1)*sizeof(float));
+ XMLCtx->statsDuration = (float*)realloc(XMLCtx->statsDuration, (XMLCtx->position+1)*sizeof(float));
+ XMLCtx->statsDispersion = (float*)realloc(XMLCtx->statsDispersion, (XMLCtx->position+1)*sizeof(float));
+ }
+ break;
+ case 2: if (strcasecmp(el,"rate") && strcasecmp(el,"duration")
+ && strcasecmp(el,"dispersion") && strcasecmp(el,"group"))
+ unexpWarning()
+ break;
default: unexpWarning()
break;
}
XMLCtx->statsFrom = edg_wll_from_string_to_time_t(XMLCtx);
else if (!strcmp(XMLCtx->element,"to"))
XMLCtx->statsTo = edg_wll_from_string_to_time_t(XMLCtx);
- else if (!strcmp(XMLCtx->element,"rate"))
- XMLCtx->statsRate = edg_wll_from_string_to_float(XMLCtx);
- else if (!strcmp(XMLCtx->element,"duration"))
- XMLCtx->statsDuration = edg_wll_from_string_to_float(XMLCtx);
else if (!strcmp(XMLCtx->element,"res_from"))
XMLCtx->statsResFrom = edg_wll_from_string_to_int(XMLCtx);
else if (!strcmp(XMLCtx->element,"res_to"))
XMLCtx->statsResTo = edg_wll_from_string_to_int(XMLCtx);
}
+ else if (XMLCtx->level == 3){
+ if (!strcmp(XMLCtx->element,"rate"))
+ XMLCtx->statsRate[XMLCtx->position] =
+ edg_wll_from_string_to_float(XMLCtx);
+ else if (!strcmp(XMLCtx->element,"duration"))
+ XMLCtx->statsDuration[XMLCtx->position] =
+ edg_wll_from_string_to_float(XMLCtx);
+ else if (!strcmp(XMLCtx->element,"dispersion"))
+ XMLCtx->statsDispersion[XMLCtx->position] =
+ edg_wll_from_string_to_float(XMLCtx);
+ else if (!strcmp(XMLCtx->element,"group"))
+ XMLCtx->statsGroup[XMLCtx->position] =
+ edg_wll_from_string_to_string(XMLCtx);
+ }
edg_wll_freeBuf(XMLCtx);
XMLCtx->level--;
edg_wll_ErrorCode errorCode;
XML_Char *encoding = "ISO-8859-1";
+ if (!messageBody)
+ return edg_wll_SetError(ctx, EDG_WLL_ERROR_XML_PARSE, "Parse error: empty response");
+
errno = 0;
edg_wll_ResetError(ctx);
edg_wll_initXMLCtx(&XMLCtx);
edg_wll_ErrorCode errorCode;
XML_Char *encoding = "ISO-8859-1";
+ if (!messageBody)
+ return edg_wll_SetError(ctx, EDG_WLL_ERROR_XML_PARSE, "Parse error: empty response");
+
errno = 0;
edg_wll_ResetError(ctx);
edg_wll_initXMLCtx(&XMLCtx);
edg_wll_ErrorCode errorCode;
XML_Char *encoding = "ISO-8859-1";
+ if (!messageBody)
+ return edg_wll_SetError(ctx, EDG_WLL_ERROR_XML_PARSE, "Parse error: empty response");
+
errno = 0;
edg_wll_ResetError(ctx);
edg_wll_initXMLCtx(&XMLCtx);
edg_wll_ErrorCode errorCode;
XML_Char *encoding = "ISO-8859-1";
+ if (!messageBody)
+ return edg_wll_SetError(ctx, EDG_WLL_ERROR_XML_PARSE, "Parse error: empty response");
+
errno = 0;
edg_wll_ResetError(ctx);
edg_wll_initXMLCtx(&XMLCtx);
edg_wll_ErrorCode errorCode;
XML_Char *encoding = "ISO-8859-1";
+ if (!messageBody)
+ return edg_wll_SetError(ctx, EDG_WLL_ERROR_XML_PARSE, "Parse error: empty response");
+
errno = 0;
edg_wll_ResetError(ctx);
edg_wll_initXMLCtx(&XMLCtx);
/* parse statistics result from client */
+
+/* this is backward-compatible version, edg_wll_ParseStatsResultFull is prefered*/
edg_wll_ErrorCode edg_wll_ParseStatsResult(edg_wll_Context ctx, char *messageBody, time_t *from, time_t *to, float *rate, float *duration, int *res_from, int *res_to)
{
+ float *rates, *durations, *dispersions;
+ char **groups;
+ edg_wll_ErrorCode ret;
+ int i;
+
+ ret = edg_wll_ParseStatsResultFull(ctx, messageBody, from, to, &rates, &durations, &dispersions, &groups, res_from, res_to);
+
+ if (groups && groups[0]){
+ if (rates) {
+ *rate = rates[0];
+ free(rates);
+ }
+ if (durations) {
+ *duration = durations[0];
+ free(durations);
+ }
+ if (dispersions)
+ free(dispersions);
+ for(i = 0; groups[i]; i++)
+ free(groups[i]);
+ }
+ if (groups)
+ free(groups);
+
+ return ret;
+}
+
+edg_wll_ErrorCode edg_wll_ParseStatsResultFull(edg_wll_Context ctx, char *messageBody, time_t *from, time_t *to, float **rate, float **duration, float **dispersion, char ***group, int *res_from, int *res_to)
+{
edg_wll_XML_ctx XMLCtx;
edg_wll_ErrorCode errorCode;
XML_Char *encoding = "ISO-8859-1";
+ int i;
+
+ if (!messageBody)
+ return edg_wll_SetError(ctx, EDG_WLL_ERROR_XML_PARSE, "Parse error: empty response");
errno = 0;
edg_wll_ResetError(ctx);
if ((errorCode = edg_wll_Error(ctx,NULL,NULL))) {
*from = -1;
*to = -1;
- *rate = 0;
- *duration = 0;
+ *rate = NULL;
+ *duration = NULL;
+ *dispersion = NULL;
+ *group = NULL;
*res_from = -1;
*res_to = -1;
} else {
*from = XMLCtx.statsFrom;
*to = XMLCtx.statsTo;
- *rate = XMLCtx.statsRate;
- *duration = XMLCtx.statsDuration;
+ *rate = NULL;
+ *duration = NULL;
+ *dispersion = NULL;
+ *group = NULL;
+ for (i = 0; XMLCtx.statsGroup[i]; i++){
+ *rate = (float*)realloc(*rate, (i+1)*sizeof(float));
+ (*rate)[i] = XMLCtx.statsRate[i];
+ *duration = (float*)realloc(*duration, (i+1)*sizeof(float));
+ (*duration)[i] = XMLCtx.statsDuration[i];
+ *dispersion = (float*)realloc(*dispersion, (i+1)*sizeof(float));
+ (*dispersion)[i] = XMLCtx.statsDispersion[i];
+ *group = (char**)realloc(*group, (i+2)*sizeof(char*));
+ (*group)[i] = strdup(XMLCtx.statsGroup[i]);
+ (*group)[i+1] = NULL;
+ }
*res_from = XMLCtx.statsResFrom;
*res_to = XMLCtx.statsResTo;
}
edg_wll_add_string_to_XMLBody(&pomValue, conditions[row][i].value.c, "location", NULL);
break;
case EDG_WLL_QUERY_ATTR_DESTINATION:
- edg_wll_add_string_to_XMLBody(&pomValue, conditions[row][i].value.c, "destination", NULL);
+ conditions[row][i].value.c ?
+ edg_wll_add_string_to_XMLBody(&pomValue, conditions[row][i].value.c, "destination", NULL) :
+ edg_wll_add_string_to_XMLBody(&pomValue, "", "destination", NULL);
break;
case EDG_WLL_QUERY_ATTR_NETWORK_SERVER:
edg_wll_add_string_to_XMLBody(&pomValue, conditions[row][i].value.c, "networkserver", NULL);
/* construct Message-Body of Request-Line for edg_wll_StateRate function */
int edg_wll_StatsRequestToXML(
+ edg_wll_Context ctx,
+ const char *function,
+ const edg_wll_QueryRec *cond,
+ edg_wll_JobStatCode major,
+ int minor,
+ time_t *from,
+ time_t *to,
+ char **message)
+{
+ return edg_wll_StatsDurationFTRequestToXML(ctx, function, cond, major, EDG_WLL_JOB_UNDEF, minor, from, to, message);
+}
+
+int edg_wll_StatsDurationFTRequestToXML(
edg_wll_Context ctx,
const char *function,
const edg_wll_QueryRec *cond,
- edg_wll_JobStatCode major,
+ edg_wll_JobStatCode base_state,
+ edg_wll_JobStatCode final_state,
int minor,
time_t *from,
time_t *to,
- char **message)
+ char **message)
{
char *pomA=NULL, *pomB=NULL, *pomC=NULL;
const edg_wll_QueryRec **conditions;
pomA = strdup("");
- edg_wll_add_edg_wll_JobStatCode_to_XMLBody(&pomA, major, "major", EDG_WLL_JOB_UNDEF);
+ edg_wll_add_edg_wll_JobStatCode_to_XMLBody(&pomA, base_state, "base_state", EDG_WLL_JOB_UNDEF);
+ edg_wll_add_edg_wll_JobStatCode_to_XMLBody(&pomA, final_state, "final_state", EDG_WLL_JOB_UNDEF);
edg_wll_add_int_to_XMLBody(&pomA, minor, "minor", -1);
edg_wll_add_time_t_to_XMLBody(&pomA, *from, "from", 0);
edg_wll_add_time_t_to_XMLBody(&pomA, *to, "to", 0);
clean:
rm -rvf LBUG* LBAG* LBDG* LBTP* events.tex status.tex ver.tex comment*
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
# dependencies:
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.harvester' => [ qw// ],
'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
%obsoletes = (
'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
);
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
+ vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
+ );
};
sub mode_etics {
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
};
for (@{$obsoletes{"$subsys.$module"}}) {
print C "package.obsoletes = $_\n";
print C "package.replaces = $_\n";
}
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+
print C qq{
[Platform-default:DynamicDependency]
};
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
1.0.3-1
- Updates to the User Guide, Admin Guide and Test Plan Test Suite Documentation
+1.0.4-1
+- Admin Guide updates - installation and migration
+- Test Plan updates
+
1.1.0-1
- Documentation updated to follow development
1.1.6-1
- Documented new authorization functions
+
+1.1.7-1
+- More docs for authorization functions
+
+1.1.8-1
+- Minor updates in the Admin Guide and Test Plan
+
+1.1.9-1
+- Fixed target 'clean' in the Makefile to handle debian builds
+- Updated references to L&B versions
+- General grammar and typo fixes
+- A new shared FAQ section prepared
+- Documentation for new TestPlan tests
+
+1.1.9-2
+- Module rebuilt
+
# $Header$
-module.version=1.1.6
-module.age=1
+module.version=1.1.9
+module.age=2
glite-lb-common & common files \\
glite-lb-client & client library and CLI tools\\
glite-lb-client-interface & client library interface (header files) \\
-glite-lb-harvester & enhanced \LB notification client (since \LBver{1.10}) \\
+%glite-lb-harvester & enhanced \LB notification client (since \LBver{1.10}) \\
glite-lb-logger & local-logger and inter-logger \\
glite-lb-proxy & proxy (restricted server used by WMS)\\
glite-lb-server & server \\
glite-security-gsoap-plugin & GSS wrapper and GSS plugin for gSoap
\end{tabularx}
-In \LBver{2.0}, the code has been restructured quite a lot, especially the dependencies were lightened,
+Starting with \LBver{2.0}, the code has been restructured quite a lot, especially the dependencies were lightened,
and the new list of packages is now the following:
\begin{tabularx}{\textwidth}{>{\tt}lX}
glite-lb-doc & documentation \\
glite-lb-common & common files \\
glite-lb-client & client library and CLI tools\\
-glite-lb-harvester & enhanced \LB notification client \\
+glite-lb-client-java & Java implementation of the client (since \LBver{2.1})\\
+glite-lb-harvester & enhanced \LB notification client (since \LBver{2.1})\\
glite-lb-logger & local-logger and inter-logger \\
glite-lb-server & server, including merged proxy functionality \\
glite-lb-state-machine & state machine and LB plugin for Job Provenance \\
glite-lb-utils & auxiliary utilities \\
glite-lb-ws-interface & web service interface \\
+glite-lb-yaim & YAIM initialization scripts for \LB (since \LBver{2.1}) \\
\end{tabularx}
More detailed description together with the dependencies can be read directly from each package,
\item \texttt{MYSQL\_PASSWORD} -- root password of MySQL server (mandatory)
\item \texttt{GLITE\_WMS\_LCGMON\_FILE} -- pathname of file where job state
export data are written for use by lgcmon/R-GMA
-(default: \texttt{/var/glite/logging/status.log}
+(default: \texttt{/var/glite/logging/status.log}). \emph{Note: This feature is now obsolete and only available in \LBver{1.x}.}
\item \texttt{GLITE\_LB\_EXPORT\_PURGE\_ARGS} -- purge timeouts (default: \texttt{--cleared 2d --aborted 15d --cancelled 15d --other 60d})
According to local retention policy you may want to use different purge timeouts (for example WLCG would need \texttt{--cleared 90d --aborted 90d --cancelled 90d --other 90d}).
\item \texttt{GLITE\_LB\_RTM\_DN} -- DNs using to get notifications from \LB server\\
(default: \texttt{heppc24.hep.ph.ic.ac.uk} machine certificate)
\item \texttt{GLITE\_LB\_SUPER\_USERS} -- additional super-users (default: empty)
-\item \texttt{GLITE\_LB\_TYPE} -- type of the \LB service: server, proxy, both (default: server)
+\item \texttt{GLITE\_LB\_TYPE} -- type of the \LB service: server, proxy, both (default: autodetect, \LB node only: 'server', WMS node only: proxy, \LB and WMS: 'both')
\item \texttt{GLITE\_LB\_HARVESTER\_ENABLED} -- set to \texttt{true} for sending notification, used mainly for export to MSG publish system (default: \texttt{false})
\item \texttt{GLITE\_LB\_HARVESTER\_MSG\_OPTIONS} -- additional options for MSG publish (default: \texttt{--wlcg})
\item \texttt{GLITE\_LB\_INDEX\_OWNER} -- when specified, add (\texttt{true}) or drop (\texttt{false}) 'owner' index (default: 'owner' index not created or dropped)
\item \emph{Move data.} Just stop the MySQL server and move
\verb'/var/lib/mysql' data directory directly to the target machine.
\item \emph{(optional) Restore file contexts.} You may need to restore file
- contexts in case of enabled SELinux. For example, commands on the target
- machine:
+ contexts in case of enabled SELinux.
+\end{itemize}
+For example, commands on the target machine:
\begin{verbatim}
service mysqld stop
cd /var/lib
restorecond -R mysql
service mysqld start
\end{verbatim}
-\end{itemize}
\subsubsection{Migration of database to support transactions}
Started from version 1.4.3 of the \texttt{glite-lb-server}
database automatically. For existing LB server database the migration
process is not automatically handled.
-Note: If you want to add transaction when migrating to \LB 2.0 skip
-this section and use \LB 2.0 migration procedure. The migration of
-database to support transactions is included in \LB 2.0 migration procedure.
+Note: If you want to add transaction when migrating to \LB 2.x skip
+this section and use \LB 2.x migration procedure. The migration of
+database to support transactions is included in \LB 2.x migration procedure.
Steps:
\begin{itemize}
\end{itemize}
-\subsubsection{Migration to \LB 2.0}
+\subsubsection{Migration to \LB 2.x}
\label{inst:migrate20}
-The migration process of existing \LB 1.x database to the \LB 2.0 is
+The migration process of existing \LB 1.x database to the \LB 2.x is
not handled automatically. The database schema change is required due
to support of merged \LB server and proxy services using single
database, pointers to purged jobs (``zombies'') and other
Warning: There are two types of \LB database based on the fact that
you can have a \LB server or \LB proxy. For more information about \LB
-proxy please see \ref{inst:LBproxy}.
+proxy please see \ref{inst:LBproxy}
Steps:
\begin{itemize}
- \item \emph{Stop the server and upgrade to \LB 2.0.} Stop both a \LB
+ \item \emph{Stop the server and upgrade to \LB 2.x.} Stop both a \LB
server and a MySQL server. Making a fresh backup copy of database is
- a good idea. Do the upgrade to \LB 2.0, optionally you can move the
+ a good idea. Do the upgrade to \LB 2.x, optionally you can move the
database to new OS in this step (see \ref{inst:OSmigration}).
\item \emph{Before migration some database tuning is
required.} Especially parameter \texttt{innodb\_buffer\_pool\_size}
needs to be increased, to support bigger transactions. For details
- see Section~\ref{inst:db_tuning}.
+ see Section~\ref{inst:db_tuning}
\item \emph{Database type.} Check if you have a \LB server or a \LB
proxy. In the following step you must properly set the switch
\verb'-s' (server) or \verb'-p' (proxy).
\verb'mysql -u lbserver lbserver20 -e "alter table events drop index host"'
\end{quote}
\item \emph{(Optional) Check the \LB indexes.} You may need to add
- LastUpdateTime for monitoring services. See \ref{maintain:index}.
+ LastUpdateTime for monitoring services. See \ref{maintain:index}
\item \emph{Start the servers.} MySQL and \LB. Check logs.
\end{itemize}
\subsubsection{Export to R-GMA}
+\emph{Note: This feature is now obsolete and only available in \LBver{1.x}.}
+
{\sloppy
\LB server can export information on job state changes to R-GMA infrastructure through \verb'lcgmon'
in real time. This export is enabled by YAIM by default and uses \verb'GLITE_WMS_LCGMON_FILE'
data (jobs in Cleared state after two days, Aborted and Cancelled after 15 days, and other jobs
after 60 days of inactivity). It is recommended to run the cron jobs more often (in order to purge less jobs
during single run) if event queue backlogs form in client WMS machines when the purging cron jobs is running.
-For details on setting job purge timeouts, see Sect.~\ref{run:purge}.
+For details on setting job purge timeouts, see Sect.~\ref{run:purge}
\subsubsection{Exploiting parallelism}
\LB server only, not supported by proxy.
-(This functionality should not be confused with per-job dumps, Sect.~\ref{inst:purge} and \ref{run:purge}.)
+(This functionality should not be confused with per-job dumps, Sect.~\ref{inst:purge} and \ref{run:purge})
Besides setting up \LB server database on a~reliable storage or
backing it up directly (Sect.~\ref{inst:backup})
\begin{sloppypar}
In case of emergency (\eg corrupted file) the files can be examined
-with \verb'glite-lb-parse_eventsfile' %
-\footnote{Not fully supported tool, installed by \texttt{glite-lb-client} package among examples.}.
+with \verb'glite-lb-parse_eventsfile'.\footnote{Not fully supported tool, installed
+by \texttt{glite-lb-client} package among examples.}
It is possible to hand-edit the event files in emergency (remove corrupted lines).
However, glite-lb-interlogd must not be running, and the corresponding .ctl file
must be removed.
On the other hand, if it happens,
and an event with such a~jobid is logged,
\eg due to a~third-party job processing software bug,
-glite-lb-interlogd keeps trying to deliver it indefinitely%
-\footnote{Unless event expiration is set, though it is not done for normal events.}.
+glite-lb-interlogd keeps trying to deliver it indefinitely.\footnote{Unless
+event expiration is set, though it is not done for normal events.}
The unsuccessful attempts are reported via syslog.
The only solution is manual
removal of the corresponding files
\newpage
\input{LBAG-Troubleshooting}
+\newpage
+\input{faq}
+
+\newpage
\nocite{jgc}
\bibliographystyle{unsrt}
\bibliography{lbjp}
\hline
{\tt lb-test-logevent.sh} & Implemented & Test if local logger accepts events correctly (i.e. returns 0). \\
\hline
-{\tt lb-test-il-recovery.sh} & Implemented & Tests if iterlogger recovers correctly and processes events logged in between when restarted. \\
+{\tt lb-test-il-recovery.sh} & Implemented & Tests if interlogger recovers correctly and processes events logged in between when restarted. \\
\hline
{\tt lb-test-job-states.sh} & Implemented & Test that job state queries return correctly and that testing jobs are in expected states. \\
\hline
\hline
{\tt lb-test-changeacl.sh} & Implemented & Test proper parsing of \code{ChangeACL} events. \\
\hline
+{\tt lb-test-statistics.sh} & Implemented & Test statistic functions provided by \LB \\
+\hline
\end{tabularx}
\subsubsection{Event logging examples}
\req\ running \path{glite-lb-bkserverd}
\what\ call \code{edg\_wll\_RegisterJob}. Jobids should preferably point
-to a~remote \LB\ server.
+to a~remote \LB\ server. Try re-registration using flag \code{EDG\_WLL\_LOGLFLAG\_EXCL} in various scenarios.
\how\ \ctblb{lb-test-job-registration.sh}
\what\
\begin{enumerate}
\item Register a compute job.
-\item Register input sandbox trasfer.
+\item Register input sandbox transfer.
\item Register output sandbox transfer.
\item Generate events to trigger job state changes in one of the sandbox transfer jobs.
\begin{enumerate}
\what\
\begin{enumerate}
\item Register a job.
-\item Send a \code{CahngeACL} event to add authorized user.
+\item Send a \code{ChangeACL} event to add authorized user.
\item Check job status to see if the event was processed correctly.
\end{enumerate}
\result\ The \emph{test~DN} should be listed in the job's ACL.
+\subsubsection{Statistics}
+
+\req\ All \LB\ services running
+
+\what\
+\begin{enumerate}
+\item Register a series of jobs.
+\item Generate events to push jobs to a given state.
+\item Run statistics to calculate rate of jobs reaching that state.
+\item Query for average time needed by test jobs to go from one state to another.
+\item Check if the statistics returned reasonable results.
+\end{enumerate}
+
+\how\ \ctblb{lb-test-statistics.sh}
+
+\note\ The test includes artificial delays. Takes approx. 30\,s to finish.
+
+\result\ Meaningful values should be returned by both tests.
+
+
\section{LB ``In the Wild''---Real-World WMS Test}
\req\ All \LB services running, working grid infrastructure accessible (including permissions).
In all above cases: Watch the life cycle. Check the resulting state (\emph{Cleared}, \emph{Cancelled} or \emph{Aborted}). Check events received in the course of job execution; events from all relevant components must be present (NS, WM, JC, LM, and LRMS).
-\how\ \ctblb{lb-test-wild.pl}
+\how\ \ctblb{lb-test-wild.sh}
\result\ Jobs were submitted. Cancel operation worked where applicable. Resulting state was as expected (\emph{Cleared}, \emph{Cancelled} or \emph{Aborted}). Events were received from all components as expected.
-\note\ The test runs automatically. Bear in mind that in a real-life grid, even valid jobs may not always finish succesf
-ully. Analyze failures and re-run if necessary.
+\note\ The test runs automatically. Bear in mind that in a real-life grid, even valid jobs may not always finish successfully. Analyze failures and re-run if necessary.
\note\ The number of jobs to generate may be specified using the \texttt{-n} argument
one query but may arrive before a subsequent query is issued),
and (ii)~the dependence on a~remote service to provide vital state information
may block the local service if the remote one is not responding.
-These problems are addressed by providing \emph{local view} on the \LB data,
-see Sect.~\ref{local}.
+These problems are addressed by providing \emph{local view} of the \LB data,
+see Sect.~\ref{local}
Job representing collection or DAG can be used to monitor status of the set, including
information like how many subjobs is already finished etc.
Support for non-gLite jobs, namely for PBS or Condor systems, is described in section
-\ref{sec:nonglite}.
+\ref{sec:nonglite}
\subsubsection{Event ordering}%
the server where events belonging to a~job are gathered from multiple sources,
\LB infrastructure can store the logged events temporarily
on the event source, and perform the processing described
-in Sect.~\ref{evprocess}.
+in Sect.~\ref{evprocess}
In this setup, the logging vs.\ query semantics can be synchronous---it is
guaranteed that a~successfully logged event is reflected in the result of
an immediately following query,
Authorization information is also manipulated in this way.
Description of tools for event submission and ACL manipulation
-can be found in Section \ref{s:lb-tools}.
+can be found in Section \ref{s:lb-tools}
\subsubsection{Querying information}
information, but confortably wait for server to inform the user.
User registers for notifications via notification client \verb'glite-lb-notify', described in Section
-\ref{s:lb-notify}.
+\ref{s:lb-notify}
Conditions under which the notification is sent can be specified. For example - job XY reaches status
DONE. In \LBver{1.x}, one or more JOBID's are required in the condition and only a single occurence
of a specific attribute is allowed among ANDed conditions. In \LBver{2.x}, more complex conditions are allowed.
Thus \LB\ becomes a~data source for various real-tim Grid monitoring tools.
\subsubsection{R-GMA feed}
+\emph{Note: This feature is now obsolete and only available in \LBver{1.x}.}
+
The \LB server also supports streaming the most important data---the job
state changes---to another monitoring system. It works as the
notification service, sending information about job state changes to
the R-GMA infrastructure that is part of the Grid monitoring
infrastructure used in the EGEE Grid.
-Currently, only basic information about job state changes is provided
+Only basic information about job state changes is provided
this way, taking into account the security limitation of the R-GMA.
\subsubsection{\LB Job Statistics}
\subsubsection{CREAM jobs}
-\LB 2.1 implements basic support for CREAM jobs. \LB gathers events from CREAM, performing both the mapping of CREAM attributes to WMS attributes (if possible) and storing CREAM-specific atributes. Thus, the jobs submitted directly to computing elements can be tracked by \LB as well as extended data from WMS. The CREAM job states are mapped to \LB ones according to Appendix \ref{a:creammapping}.
+\LB 2.1 implements basic support for CREAM jobs. \LB gathers events from CREAM, performing both the mapping of CREAM attributes to WMS attributes (if possible) and storing CREAM-specific atributes. Thus, the jobs submitted directly to computing elements can be tracked by \LB as well as extended data from WMS. The CREAM job states are mapped to \LB ones according to Appendix \ref{a:creammapping}
CREAM events are generated by thee CREAM executor and LRMS, the generic \emph{CREAMStatus} event is generated when CREAM notifies that the job status has been changed.
\newpage
\input{LBUG-Troubleshooting}
+\newpage
+\input{faq}
+
\appendix
\newpage
\input{LBUG-Appendix}
Note that \LBver{1.x} supported only using VOMS group names, not full FQANs,
whose support has been introduced in \LBver{2.0}. \LBver{1.x} also did not
-allowed the users to use symbolic names for the values specifying ACL
+allow the users to use symbolic names for the values specifying ACL
setting and integers must be used instead. For example, to grant access
right on a \LBver{1.x} server one has to use following syntax:
and the job state updated
accordingly.
-On the other hand, the server exposes querying interface (Fig.~\ref{f:comp-query}%
-\ifx\insideUG\undefined\relax\else
-, Sect.~\ref{retrieve}
-\fi
-).
+On the other hand, the server exposes querying interface
+(Fig.~\ref{f:comp-query}\ifx\insideUG\undefined\relax\else, Sect.~\ref{retrieve}\fi).
The incoming user queries are transformed into SQL queries on the underlying
database engine.
The query result is filtered, authorization rules applied, and the result
% useful definitions
\def\LB{L\&B\xspace}
-\newcommand\LBver[1]{\textbf{\LB version {#1}\xspace}}
+\newcommand\LBver[1]{\textbf{\LB version {#1}}}
\def\JP{JP\xspace}
%\def\eg{e.\,g.}
\def\eg{for example\xspace}
--- /dev/null
+%
+%% Copyright (c) Members of the EGEE Collaboration. 2004-2010.
+%% See http://www.eu-egee.org/partners for details on the copyright holders.
+%%
+%% Licensed under the Apache License, Version 2.0 (the "License");
+%% you may not use this file except in compliance with the License.
+%% You may obtain a copy of the License at
+%%
+%% http://www.apache.org/licenses/LICENSE-2.0
+%%
+%% Unless required by applicable law or agreed to in writing, software
+%% distributed under the License is distributed on an "AS IS" BASIS,
+%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+%% See the License for the specific language governing permissions and
+%% limitations under the License.
+%
+
+\section{FAQ---Frequently Asked Questions}
+\label{s:faq}
+
+\subsection{Job in State `Running' Despite Having Received the `Done' Event from LRMS}
+
+Jobs stay in state \emph{Running} until a \emph{Done} event is received from the workload management system. \emph{Done} events from local resource managers are not enough since the job in question may have been resubmitted in the meantime.
+
\textbf{The following versions of \LB service are covered by these documents:}
\begin{itemize}
-\item \LBver{2.2}: current development version, available through CVS only,
-\item \LBver{2.1}: currently in certification, to be released in April 2010,
+\item \LBver{2.2}: in development, available through CVS only,
+\item \LBver{2.1}: replacement for \LBver{2.0} in gLite 3.2,
\item \LBver{2.0}: current stable version, in production as part of gLite 3.2,
\item \LBver{1.x}: old stable version, in production as part of gLite 3.1.
\end{itemize}
check:
clean:
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
.PHONY: default all check install stage clean
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.ws-interface' => [],
'lb.ws-test' => [ qw/gsoap:B/ ],
'lb.types' => [ qw// ],
- 'lb.harvester' => [ qw/postgresql:R/ ],
+ 'lb.harvester' => [ qw// ],
'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
jpclient => 'jp.client',
);
+%obsoletes = (
+ 'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
+);
+
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
+ vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
+ );
};
sub mode_etics {
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
+};
+ for (@{$obsoletes{"$subsys.$module"}}) {
+ print C "package.obsoletes = $_\n";
+ print C "package.replaces = $_\n";
+ }
-[Platform-default:DynamicDependency]
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+ print C qq{
+[Platform-default:DynamicDependency]
};
for (@{$need_externs{"$subsys.$module"}},@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
- glite-LB Metapackage module now CVS-based
- compile and build by make rather than inline commands
+3.2.11-1
+- Fixed handling of target 'clean' in Makefile
+
+3.2.12-1
+- Fixed target 'clean' in the Makefile to handle debian builds
+
+3.2.12-2
+- Module rebuilt
+
# $Header
-module.version=3.2.10
-module.age=1
+module.version=3.2.12
+module.age=2
clean:
rm -rfv *.o *.lo *.loT .libs/ manpage.links manpage.refs
rm -rvf harvester harvester-dbg glite-lb-harvester.*
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
harvester: harvester.o
${LINK} -o $@ $+ ${LIBS}
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.harvester' => [ qw// ],
'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
%obsoletes = (
'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
);
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
+ vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
+ );
};
sub mode_etics {
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
};
for (@{$obsoletes{"$subsys.$module"}}) {
print C "package.obsoletes = $_\n";
print C "package.replaces = $_\n";
}
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+
print C qq{
[Platform-default:DynamicDependency]
};
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
- Resource Broker from JDL for CREAM jobs
- For CE stripping protocol from destination
- Test script updates
+
+1.0.6-2
+- Module rebuilt
+
+1.0.7-1
+- Fixed target 'clean' in the Makefile to handle debian builds
+- Removed log4c calls in code rune manually
+
+1.0.8-1
+- IPv6-compliant implementation
+- Array boundary fix
+
+1.0.8-2
+- Module rebuilt
+
-module.version=1.0.6
-module.age=1
+module.version=1.0.8
+module.age=2
* Real time monitor.
*/
-#include <arpa/inet.h>
#include <netinet/in.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
-#ifdef WITH_OLD_LB
+#if defined(WITH_OLD_LB) || !defined(USE_LOG4C)
#include <syslog.h>
#endif
#include <errno.h>
#include <unistd.h>
#include <fcntl.h>
#include <time.h>
+#include <netdb.h>
#include <glite/security/glite_gss.h>
#ifdef WITH_LBU_DB
#include <glite/lbu/trio.h>
#endif
#endif
-// TODO: ipv6? :-)
-
typedef struct {
edg_wll_NotifId id; // notification context (after bootstrap/rebind)
char *id_str; // notification id string
static const char rcsid[] = "@(#)$Id$";
-#ifdef WITH_OLD_LB
+#if defined(WITH_OLD_LB) || !defined(USE_LOG4C)
static int rtm2syslog[] = {
LOG_ERR,
LOG_WARNING,
if (level <= WRN && !config.daemonize) fprintf(stderr, RTM_TTY_RED);
if (config.daemonize) {
-#ifdef WITH_OLD_LB
+#if defined(WITH_OLD_LB) || !defined(USE_LOG4C)
openlog(NULL, LOG_PID | LOG_CONS, LOG_DAEMON);
syslog(rtm2syslog[level], "%s", line);
closelog();
int load_notifs_file() {
FILE *f;
- char *results[5];
+ char *results[RTM_FILE_NOTIF_NUM];
notif_t *new_notif;
int err;
char *notifidstr;
void *notify_thread(void *thread_data) {
- struct sockaddr_in addr;
int i, j, err;
time_t now, bootstrap;
edg_wll_NotifId notifid;
thread_t *t = (thread_t *)thread_data;
edg_wll_Context ctx = NULL;
int flags = 0;
-
+ struct addrinfo *ai = NULL;
+ struct addrinfo hints;
+ char *portstr;
const int one = 1;
lprintf(t, DBG, "thread started");
if (config.cert) edg_wll_SetParam(ctx, EDG_WLL_PARAM_X509_CERT, config.cert);
if (config.key) edg_wll_SetParam(ctx, EDG_WLL_PARAM_X509_KEY, config.key);
- // socket
- if ((sock = socket(PF_INET, SOCK_STREAM, 0)) < 0) {
+ // listen
+ memset(&hints, 0, sizeof hints);
+ hints.ai_flags = AI_NUMERICHOST | AI_NUMERICSERV | AI_PASSIVE | AI_ADDRCONFIG;
+ hints.ai_socktype = SOCK_STREAM;
+ asprintf(&portstr, "%d", listen_port ? (listen_port + t->id) : 0);
+ if (!portstr) {
+ lprintf(t, ERR, "can't convert port number: ENOMEM");
+ goto exit;
+ }
+ err = getaddrinfo(NULL, portstr, &hints, &ai);
+ free(portstr); portstr = NULL;
+ if (err != 0) {
+ lprintf(t, ERR, "getaddrinfo() failed: %s", gai_strerror(err));
+ goto exit;
+ }
+ if (!ai) {
+ lprintf(t, ERR, "no result from getaddrinfo()");
+ goto exit;
+ }
+ if ((sock = socket(ai->ai_family, ai->ai_socktype, ai->ai_protocol)) < 0) {
lprintf(t, ERR, "can't create socket: %s", strerror(errno));
goto exit;
}
setsockopt(sock, SOL_SOCKET, SO_REUSEADDR, &one, sizeof(one));
- memset(&addr, 0, sizeof addr);
- addr.sin_family = AF_INET;
- if (listen_port) addr.sin_port = htons(listen_port + t->id);
- addr.sin_addr.s_addr = INADDR_ANY;
- if (bind(sock, (const struct sockaddr*)&addr, sizeof addr) != 0) {
+ if (bind(sock, ai->ai_addr, ai->ai_addrlen) != 0) {
lprintf(t, ERR, "can't bind socket: %s, port = %d", strerror(errno), listen_port ? listen_port + t->id : -1);
goto exit;
}
lprintf(t, ERR, "can't listen on socket: %s", strerror(errno));
goto exit;
}
+ freeaddrinfo(ai); ai = NULL;
#ifdef WITH_LBU_DB
if (db_init(t, &t->dbctx) == 0)
exit:
if (sock != -1) close(sock);
+ if (ai) freeaddrinfo(ai);
// for (i = 0; conditions[i]; i++) free(conditions[i]);
if (t->nservers && quit != RTM_QUIT_PRESERVE && quit != RTM_QUIT_RELOAD) {
for (i = 0; i < t->nservers; i++) {
if (config.pidfile && !config.guard) {
if (remove(config.pidfile) == -1) lprintf(NULL, WRN, "can't remove pidfile '%s': %s", config.pidfile, strerror(errno));
}
-#ifdef WITH_OLD_LB
+#ifndef WITH_OLD_LB
if (config.daemonize) glite_common_log_fini();
#endif
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.harvester' => [ qw// ],
'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
/ ],
'lb.logger-msg' => [ qw/
lb.logger
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
%obsoletes = (
'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
);
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
undef %aux;
my @m=qw/
lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
-security.gss security.gsoap-plugin
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
+ vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
+ );
};
sub mode_etics {
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
};
for (@{$obsoletes{"$subsys.$module"}}) {
print C "package.obsoletes = $_\n";
print C "package.replaces = $_\n";
}
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+
print C qq{
[Platform-default:DynamicDependency]
};
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
endif
DEBUG:=-g -O0
-CFLAGS:=${DEBUG} \
+CFLAGS:=${CFLAGS} ${DEBUG} \
-I${stagedir}/include -I${top_srcdir}/src -I${top_srcdir}/interface \
-D_GNU_SOURCE \
${COVERAGE_FLAGS} \
${VERSION} ${LB_STANDALONE_FLAGS} ${LB_PERF_FLAGS}
-LDFLAGS:=-L${stagedir}/${libdir} \
+LDFLAGS:=${LDFLAGS} -L${stagedir}/${libdir} \
${COVERAGE_FLAGS}
COMPILE:=libtool --mode=compile ${CC}
${CXX} ${CFLAGS} ${TEST_INC} -c $< -o $@
clean:
- rm -rvf .libs/ *.o *.lo ${LOGD} ${INTERLOGD} ${NOTIF_INTERLOGD} ${MAN_GZ}
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -rvf .libs/ *.o *.lo *.no ${LOGD} ${INTERLOGD} ${NOTIF_INTERLOGD} ${MAN_GZ}
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.harvester' => [ qw// ],
'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
%obsoletes = (
'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
);
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
+ vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
+ );
};
sub mode_etics {
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
};
for (@{$obsoletes{"$subsys.$module"}}) {
print C "package.obsoletes = $_\n";
print C "package.replaces = $_\n";
}
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+
print C qq{
[Platform-default:DynamicDependency]
};
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
.I PREFIX.
.I PREFIX
-defaults to /tmp/dglogd.log.
+defaults to /var/glite/log/dglogd.log.
On startup, interlogger checks all files matching the pattern
.I PREFIX*.
.I PREFIX.
.I PREFIX
-defaults to /tmp/dglogd.log.
+defaults to /var/glite/log/dglogd.log.
The value has to be same as used in the cooperating glite-lb-logd.
2.0.4-2
- install libraries into $libdir
+2.0.6-1
+- Pidfiles support in daemons
+
+2.0.7-1
+- Startup script fixes
+
+2.0.8-1
+- Compatibility with IPv6 compliant clients
+
2.1.0-1
- Compliance with the Common Logging Format
- Fixed startup script (Savannah Bug #29081)
- Introduce a separate logging category for notification interlogger
- Fix problem with dropping unused notoifications
+2.1.5-1
+- Perftest script accepts argument -i to save pidfile in /tmp
+
+2.1.6-1
+- Fixed target 'clean' in the Makefile to handle debian builds
+
+2.1.7-1
+- Hostname parsing adjusted to handle IPv6 addresses
+- Default file locations updated in documentation
+
+2.1.8-1
+- Fixed propagation of error messages
+
# $Header$
-module.version=2.1.4
+module.version=2.1.8
module.age=1
} else {
s = s + 3;
}
- p = strchr(s, ':');
+ p = strrchr(s, ':');
if(p) {
*p++ = 0;
c = ':';
case EDG_WLL_GSS_ERROR_HERRNO:
snprintf(err->msg, IL_ERR_MSG_LEN, "%s: %s", msg, hstrerror(errno));
break;
+
+ default:
+ strncpy(err->msg, msg, IL_ERR_MSG_LEN);
}
+ break;
default:
strncpy(err->msg, msg, IL_ERR_MSG_LEN);
LCAS_CFLAGS=-I${lcas_prefix}/include
-CFLAGS:= \
+CFLAGS:= ${CFLAGS} \
${WS_CFLAGS} ${DEBUG} \
-DVERSION=\"${version}\" \
-I${gsoap_prefix}/include -I${gsoap_prefix}/ \
SRVBONES_LIB:= -L${stagedir}/${libdir} -lglite_lbu_server_bones
LB_COMMON_LIB:=-L${stagedir}/${libdir} -lglite_lb_common_${nothrflavour}
LB_UTILS_DB_LIB:=-L${stagedir}/${libdir} -lglite_lbu_db
- LDFLAGS:= -L${stagedir}/${libdir}
+ LDFLAGS:=${LDFLAGS} -L${stagedir}/${libdir}
endif
# LB_MACHINE_LIB:=${stagedir}/${libdir}/libglite_lb_statemachine.a
clean:
rm -rvf *.c *.h *.ch *.xh *.xml *.nsmap *.o *.lo .libs glite-lb-* ${STATIC_LIB_BK} ${LCAS_PLUGIN_LIB} test* ${MAN_GZ} ${EXAMPLES}
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
%.c: %.c.T
rm -f $@
stop_daemon "glite-lb-notif-interlogd" $NOTIF_IL_PIDFILE
stop_daemon "glite-lb-bkserverd" $BK_PIDFILE
- if test x"$GLITE_LB_EXPORT_ENABLED" = x"true"; then
- stop_daemon "glite-jp-importer" $jp_importer_pidfile
- fi
+ stop_daemon "glite-jp-importer" $jp_importer_pidfile
stop_daemon "glite-lb-interlogd" $PROXY_IL_PIDFILE
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.harvester' => [ qw// ],
'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
%obsoletes = (
'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
);
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
+ vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
+ );
};
sub mode_etics {
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
};
for (@{$obsoletes{"$subsys.$module"}}) {
print C "package.obsoletes = $_\n";
print C "package.replaces = $_\n";
}
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+
print C qq{
[Platform-default:DynamicDependency]
};
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
.BI -G\fR,\fP --proxy-purge
Enable automatic purging of the jobs in terminal state for proxy service (disabled by default, purging cron job installed by YAIM).
+.TP
+.BI -E\fR,\fP --exclusive-zombies-off
+Disable checking of purged jobs when registering jobs with the EDG_WLL_LOGLFLAG_EXCL flag set.
+
.\".SH USAGE
.\" Add any additional description here
2.0.3-2
- Rebuild with lb.state-machine 1.0.2-1
----
-Crystal ball:
+2.0.3-3
+- install libraries into $libdir
+- buildtime dependency pn c-ares
+
2.0.4-1
- Consider arch libdir when linking c-ares
- Checking the c-ares version, fix for c-ares >= 1.5.0.
2.0.5-1
- Reflect updates in the database module
-- Adjusted grey job purges (purge undefined jobs etc.)
+- Adjusted grey job purges
+- Purge undefined or unknown jobs
-2.0.3-3
-- install libraries into $libdir
-- buildtime dependency on c-ares
+2.0.6-1
+- Fixed collection state with cancelled subjobs
+
+2.0.7-1
+- Starting proxy support
+- Fixed collection state with cancelled subjobs
+
+2.0.7-2
+- Rebuild with gridsite 1.5.10.5-3
+
+2.0.8-1
+- Startup script fixes
+
+2.0.9-1
+- Compatibility with IPv6 compliant clients
2.1.0-1
- Advanced Autorization (used by LCAS plugin too, old configuration file not supported anymore)
2.1.4-1
- Broader authorization policy format
+
+2.1.5-1
+- READ_ALL and PURGE authorization
+- Refactoring of WS error handling
+
+2.1.6-1
+- Implemented checking of zombie jobs for JobID exclusivity
+
+2.1.7-1
+- Fixed target 'clean' in the Makefile to handle debian builds
+- More robust reaction to errors while parsing client requests
+- Extended job state transition statistics
+
+2.1.8-1
+- Statistics turned on by default
+- Old implementation of statistics optimized
+- Memory handling bug fixes
+- Two sets of statistic functions implemented for bw compatibility
+
+2.1.9-1
+- Support for IPv6 literal addresses
+- Fixed jobid detection in HTTP GET requests
+- Provisional handling of c-ares name translation bugs
+
+2.1.10-1
+- Fixed precedence in selecting IPv6/IPv4
+
# : /cvs/jra1mw/org.glite.lb.server/project/version.properties,v 1.185 2008/06/25 13:12:58 akrenek Exp $
-module.version=2.1.4
+module.version=2.1.10
module.age=1
int proxy_purge;
struct _edg_wll_authz_policy authz_policy;
char *policy_file = NULL;
+int exclusive_zombies;
static struct option opts[] = {
{ "mysql",1,NULL,'m' },
static int noIndex = 0;
static int strict_locking = 0;
static int greyjobs = 0;
-static int count_statistics = 0;
+static int count_statistics = 1;
static int hardJobsLimit = 0;
static int hardEventsLimit = 0;
static int hardRespSizeLimit = 0;
static time_t rss_time = 60*60;
char * policy_file = NULL;
struct _edg_wll_authz_policy authz_policy = { NULL, 0};
+static int exclusive_zombies = 1;
{"proxy-purge", 0, NULL, 'G'},
{"rss-time", 1, NULL, 'I'},
{"policy", 1, NULL, 'l'},
+ {"exclusive-zombies-off", 0, NULL, 'E'},
{NULL,0,NULL,0}
};
-static const char *get_opt_string = "Ac:k:C:V:p:a:drm:ns:i:S:D:J:jR:F:xOL:N:X:Y:T:t:zb:gPBo:q:W:Z:GI:l:"
+static const char *get_opt_string = "Ac:k:C:V:p:a:drm:ns:i:S:D:J:jR:F:xOL:N:X:Y:T:t:zb:gPBo:q:W:Z:GI:l:E"
#ifdef GLITE_LB_SERVER_WITH_WS
"w:"
#endif
"\t-G,--proxy-purge\t enable automatic purge on proxy service (disabled by default)\n"
"\t-I,--rss-time\t age (in seconds) of job states published via RSS\n"
"\t-l,--policy\tauthorization policy file\n"
+ "\t-E,--exclusive-zombies-off\twith 'exclusive' flag, allow reusing IDs of purged jobs\n"
,me);
}
break;
case 'l': policy_file = strdup(optarg);
break;
+ case 'E': exclusive_zombies = 0;
+ break;
case '?': usage(name); return 1;
}
if (mode & SERVICE_SERVER) {
if ( fake_host )
{
- char *p = strchr(fake_host,':');
+ char *p = strrchr(fake_host,':');
if (p)
{
}
ctx->strict_locking = strict_locking;
ctx->greyjobs = greyjobs;
+ ctx->exclusive_zombies = exclusive_zombies;
return 0;
}
return err;
}
- if (httpErr == HTTP_BADREQ)
+ if (httpErr == HTTP_BADREQ && body)
err = try_accept_ws(conn, timeout, cdata, body, strlen(body) + 1);
if (httpErr != HTTP_BADREQ || err)
edg_wll_DoneHTTP(ctx, resp, hdrOut, bodyOut);
int err = NETDB_INTERNAL;
struct sockaddr_in v4;
-/* start timer */
- gettimeofday(&start_time,0);
-
-/* ares init */
- if ( ares_init(&channel) != ARES_SUCCESS ) return(NETDB_INTERNAL);
- memset((void *) &ar, 0, sizeof(ar));
-
if (addr->sa_family == AF_INET6 && IN6_IS_ADDR_V4MAPPED(&((struct sockaddr_in6 *)addr)->sin6_addr)) {
v4.sin_family = AF_INET;
v4.sin_port = ((struct sockaddr_in6 *)addr)->sin6_port;
len = sizeof(v4);
}
+ if (!numeric && addr->sa_family == AF_INET6) {
+ /* don't bother, c-ares up to version 1.7.3 has fatal bug */
+ return NETDB_INTERNAL;
+ }
+
+/* start timer */
+ gettimeofday(&start_time,0);
+
+/* ares init */
+ if ( ares_init(&channel) != ARES_SUCCESS ) return(NETDB_INTERNAL);
+ memset((void *) &ar, 0, sizeof(ar));
+
/* query DNS server asynchronously */
if (name) flags |= ARES_NI_LOOKUPHOST | ( numeric? ARES_NI_NUMERICHOST : 0);
if (service) flags |= ARES_NI_LOOKUPSERVICE | ( numeric? ARES_NI_NUMERICSERV : 0);
}
if (ar.err == NETDB_SUCCESS) {
- if (name) *name = ar.host;
+ if (name) {
+ if (numeric && addr->sa_family == AF_INET6) {
+ asprintf(name,"[%s]",ar.host);
+ free(ar.host);
+ } else {
+ *name = ar.host;
+ }
+ }
if (service) *service = ar.service;
}
err = ar.err;
long filepos;
char *ulm_data,
*reg_id_s,
- *event_file;
+ *event_file = NULL;
if((ret=notif_create_ulm(context,
reg_id,
ret = 0;
out:
- if(ulm_data) free(ulm_data);
- if(reg_id_s) free(reg_id_s);
+ free(event_file);
+ free(ulm_data);
+ free(reg_id_s);
if(ret) edg_wll_UpdateError(context, ret, "edg_wll_NotifSend()");
return(ret);
}
See the License for the specific language governing permissions and
limitations under the License.
*/
-
+#ident "$Header$"
#include <inttypes.h>
#include <stdio.h>
/* GET /[jobId]: Job Status */
else if (*requestPTR=='/'
- && strncmp(requestPTR, "/RSS", strlen("/RSS"))
- && strncmp(requestPTR, "/NOTIF", strlen("/NOTIF"))
- && *(requestPTR+strlen("/NOTIF")-1) != ':'
- && !isspace(*(requestPTR+strlen("/NOTIF")-1))) {
+ && strncmp(requestPTR, "/RSS:", strlen("/RSS:"))
+ && ( strncmp(requestPTR, "/NOTIF", strlen("/NOTIF"))
+ || *(requestPTR+strlen("/NOTIF")) != ':'
+ && !isspace(*(requestPTR+strlen("/NOTIF"))))
+ ) {
edg_wlc_JobId jobId = NULL;
char *pom1,*fullid = NULL;
edg_wll_JobStat stat;
memset(&request,0,sizeof(request));
memset(&result,0,sizeof(result));
- if ( !parsePurgeRequest(ctx,messageBody,(int (*)()) edg_wll_StringToStat,&request) ) {
+ if (parsePurgeRequest(ctx,messageBody,(int (*)()) edg_wll_StringToStat,&request))
+ ret = HTTP_BADREQ;
+ else {
/* do throttled purge on background if requested */
if ((request.flags & EDG_WLL_PURGE_BACKGROUND)) {
retval = fork();
else if (!strncmp(requestPTR,KEY_STATS_REQUEST,sizeof(KEY_STATS_REQUEST)-1)) {
char *function;
edg_wll_QueryRec **conditions;
- edg_wll_JobStatCode major = EDG_WLL_JOB_UNDEF;
+ edg_wll_JobStatCode base = EDG_WLL_JOB_UNDEF;
+ edg_wll_JobStatCode final = EDG_WLL_JOB_UNDEF;
time_t from, to;
int i, j, minor, res_from, res_to;
- float rate = 0, duration = 0;
-
-
+ float *rates = NULL, *durations = NULL , *dispersions = NULL;
+ char **groups = NULL;
if (parseStatsRequest(ctx, messageBody, &function, &conditions,
- &major, &minor, &from, &to))
+ &base, &final, &minor, &from, &to))
ret = HTTP_BADREQ;
else {
int fatal = 0, err = 0;
// navratove chyby nejsou zname, nutno predelat dle aktualni situace
if (!strcmp(function,"Rate"))
err = edg_wll_StateRateServer(ctx,
- conditions[0], major, minor,
- &from, &to, &rate, &res_from, &res_to);
+ conditions[0], base, minor,
+ &from, &to, &rates, &groups,
+ &res_from, &res_to);
else if (!strcmp(function,"Duration"))
err = edg_wll_StateDurationServer(ctx,
- conditions[0], major, minor,
- &from, &to, &duration, &res_from, &res_to);
+ conditions[0], base, minor,
+ &from, &to, &durations, &groups,
+ &res_from, &res_to);
+ else if (!strcmp(function, "DurationFromTo"))
+ err = edg_wll_StateDurationFromToServer(
+ ctx, conditions[0], base, final,
+ minor, &from, &to, &durations,
+ &dispersions, &groups,
+ &res_from, &res_to);
switch (err) {
case 0: if (html) ret = HTTP_NOTIMPL;
}
/* glue errors (if eny) to XML responce */
if (!html && !fatal)
- if (edg_wll_StatsResultToXML(ctx, from, to, rate,
- duration, res_from, res_to, &message))
+ if (edg_wll_StatsResultToXML(ctx, from,
+ to, rates, durations,
+ dispersions, groups,
+ res_from, res_to, &message))
ret = HTTP_INTERNAL;
+ if (rates) free(rates);
+ if (durations) free(durations);
+ if (dispersions) free(dispersions);
+ if (groups){
+ for(i = 0; groups[i]; i++)
+ free(groups[i]);
+ free(groups);
+ }
}
free(function);
case 1: if (!strcasecmp(el,"and")) {
XMLCtx->jobQueryRec_begin = XML_GetCurrentByteIndex(XMLCtx->p);
}
- else if ( (strcasecmp(el,"major")) && (strcasecmp(el,"minor")) &&
+ else if ( (strcasecmp(el,"base_state")) && (strcasecmp(el,"final_state")) && (strcasecmp(el,"minor")) &&
(strcasecmp(el,"from")) && (strcasecmp(el,"to")) ) unexp()
break;
case 2: /* fall through */
edg_wll_XML_ctx *XMLCtx = data;
if (XMLCtx->level == 2) {
- if (!strcmp(XMLCtx->element,"major")) {
- XMLCtx->statsMajor =
+ if (!strcmp(XMLCtx->element,"base_state")) {
+ XMLCtx->statsBaseState =
edg_wll_from_string_to_edg_wll_JobStatCode(XMLCtx);
}
+ else if (!strcmp(XMLCtx->element,"final_state")) {
+ XMLCtx->statsFinalState =
+ edg_wll_from_string_to_edg_wll_JobStatCode(XMLCtx);
+ }
else if (!strcmp(XMLCtx->element,"minor")) {
XMLCtx->statsMinor = edg_wll_from_string_to_int(XMLCtx);
}
/* parse Stats request from client */
-int parseStatsRequest(edg_wll_Context ctx, char *messageBody, char **function, edg_wll_QueryRec ***conditions, edg_wll_JobStatCode *major, int *minor, time_t *from, time_t *to)
+int parseStatsRequest(edg_wll_Context ctx, char *messageBody, char **function, edg_wll_QueryRec ***conditions, edg_wll_JobStatCode *base_state, edg_wll_JobStatCode *final_state, int *minor, time_t *from, time_t *to)
{
int ret;
edg_wll_XML_ctx XMLCtx;
/* returns emty variables as default; only some variables will be filled in */
/* depending on vaule of XMLCtx.notifFunction */
*function = NULL;
- *major = EDG_WLL_JOB_UNDEF;
+ *base_state = EDG_WLL_JOB_UNDEF;
+ *final_state = EDG_WLL_JOB_UNDEF;
*minor = 0;
*from = 0;
*to = 0;
*function = NULL;
*conditions = NULL;
- *major = EDG_WLL_JOB_UNDEF;
+ *base_state = EDG_WLL_JOB_UNDEF;
+ *final_state = EDG_WLL_JOB_UNDEF;
*minor = 0;
*from = 0;
*to = 0;
else {
*function = XMLCtx.statsFunction;
*conditions = XMLCtx.statsConditions;
- *major = XMLCtx.statsMajor;
+ *base_state = XMLCtx.statsBaseState;
+ *final_state = XMLCtx.statsFinalState;
*minor = XMLCtx.statsMinor;
*from = XMLCtx.statsFrom;
*to = XMLCtx.statsTo;
edg_wll_Context ctx,
time_t from,
time_t to,
- float rate,
- float duration,
+ float *rates,
+ float *durations,
+ float *dispersions,
+ char **groups,
int res_from,
int res_to,
char **message)
{
char *pomA, *pomB;
-
+ int i;
pomA = strdup("");
edg_wll_add_time_t_to_XMLBody(&pomA, from, "from", -1);
edg_wll_add_time_t_to_XMLBody(&pomA, to, "to", -1);
- edg_wll_add_float_to_XMLBody(&pomA, rate, "rate", 0);
- edg_wll_add_float_to_XMLBody(&pomA, duration, "duration", 0);
edg_wll_add_int_to_XMLBody(&pomA, res_from, "res_from", -1);
- edg_wll_add_int_to_XMLBody(&pomA, res_to, "res_to", -1);
+ edg_wll_add_int_to_XMLBody(&pomA, res_to, "res_to", -1);
+
+ if (groups) for (i = 0; groups[i]; i++){
+ asprintf(&pomB, "%s\t\t<stat>\n", pomA);
+ pomA = pomB;
+ edg_wll_add_string_to_XMLBody(&pomA, groups[i], "group", NULL);
+ if (rates)
+ edg_wll_add_float_to_XMLBody(&pomA, rates[i], "rate", -1.0f);
+ if (durations)
+ edg_wll_add_float_to_XMLBody(&pomA, durations[i], "duration", -1.0f);
+ if (dispersions)
+ edg_wll_add_float_to_XMLBody(&pomA, dispersions[i], "dispersion", -1.0f);
+ asprintf(&pomB, "%s\t\t</stat>\n", pomA);
+ pomA = pomB;
+ }
if (ctx->errDesc || ctx->errCode)
trio_asprintf(&pomB,"%s code=\"%d\" desc=\"%|Xs\">\r\n%s%s",
else
trio_asprintf(&pomB,"%s>\r\n%s%s", STATS_RESULT_BEGIN, pomA, STATS_RESULT_END);
free(pomA);
-
+printf("XXX %s XXX\n", pomB);
*message = pomB;
return 0;
}
int edg_wll_NotifResultToXML(edg_wll_Context ctx, time_t validity, char **message);
int edg_wll_QuerySequenceCodeResultToXML(edg_wll_Context ctx, char *source, char **message);
-int edg_wll_StatsResultToXML(edg_wll_Context,time_t,time_t,float,float,int,int,char **);
+int edg_wll_StatsResultToXML(edg_wll_Context,time_t,time_t,float*,float*,float*,char**,int,int,char **);
-int parseStatsRequest(edg_wll_Context,char *,char **,edg_wll_QueryRec ***,edg_wll_JobStatCode *,int *,time_t *,time_t *);
+int parseStatsRequest(edg_wll_Context,char *,char **,edg_wll_QueryRec ***,edg_wll_JobStatCode *,edg_wll_JobStatCode *,int *,time_t *,time_t *);
#ifdef __cplusplus
free(ju); ju = NULL;
dest = strdup(jobc[1]);
- if ( !(aux = strchr(dest, ':')) )
+ if ( !(aux = strrchr(dest, ':')) )
{
edg_wll_SetError(ctx, EINVAL, "Can't parse notification destination");
free(dest);
*/
static int notif_check_acl(edg_wll_Context ctx,const edg_wll_JobStat *stat,const char *recip, int *authz_flags)
{
- edg_wll_Acl acl = calloc(1,sizeof *acl);
int ret;
struct _edg_wll_GssPrincipal_data princ;
+ edg_wll_Acl acl = NULL;
memset(&princ, 0, sizeof(princ));
*authz_flags = 0;
return 1;
if (stat->acl) {
+ acl = calloc(1,sizeof *acl);
ret = edg_wll_DecodeACL(stat->acl,&acl->value);
if (ret) {
edg_wll_FreeAcl(acl);
goto cleanup;
}
if ( !strncmp(address_override, "0.0.0.0", aux-address_override) ||
+ !strncmp(address_override, "[::]", aux-address_override) ||
!strncmp(address_override, "::", aux-address_override) )
trio_asprintf(&addr_s, "%s:%s", ctx->connections->serverConnection->peerName, aux+1);
}
goto rollback;
}
if ( !strncmp(address_override, "0.0.0.0", aux-address_override) ||
+ !strncmp(address_override, "[::]", aux-address_override) ||
!strncmp(address_override, "::", aux-address_override) )
trio_asprintf(&addr_s, "%s:%s", ctx->connections->serverConnection->peerName, aux+1);
}
}
if ( dest )
{
- host = strchr(dest, ':');
+ host = strrchr(dest, ':');
port = atoi(host+1);
if ( !(host = strndup(dest, host-dest)) )
{
#include <stdio.h>
#include <errno.h>
#include <time.h>
+#include <math.h>
#include "glite/lb/events.h"
#include "glite/lb/jobstat.h"
#include "glite/jobid/strmd5.h"
#include "stats.h"
-#include "authz_policy.h"
+
+#define GROUPS_HASHTABLE_SIZE 1000
+
static int stats_inc_counter(edg_wll_Context,const edg_wll_JobStat *,edg_wll_Stats *);
static int stats_record_duration(edg_wll_Context,const edg_wll_JobStat *,const edg_wll_JobStat *,edg_wll_Stats *);
-
-#define dprintf(x) { printf("[%d] ",getpid()); printf x; }
+static int stats_record_duration_fromto(edg_wll_Context ctx, const edg_wll_JobStat *from, const edg_wll_JobStat *to, edg_wll_Stats *stats);
/* XXX: should be configurable at run time */
static struct _edg_wll_StatsArchive default_archives[] = {
};
static edg_wll_Stats default_stats[] = {
- { STATS_COUNT, default_group, EDG_WLL_JOB_READY, 0, default_archives },
- { STATS_COUNT, default_group, EDG_WLL_JOB_SCHEDULED, 0, default_archives },
- { STATS_COUNT, default_group, EDG_WLL_JOB_RUNNING, 0, default_archives },
- { STATS_COUNT, default_group, EDG_WLL_JOB_DONE, EDG_WLL_STAT_OK, default_archives },
- { STATS_COUNT, default_group, EDG_WLL_JOB_DONE, EDG_WLL_STAT_FAILED, default_archives },
- { STATS_DURATION, default_group, EDG_WLL_JOB_SCHEDULED, 0, default_archives },
- { STATS_DURATION, default_group, EDG_WLL_JOB_RUNNING, 0, default_archives },
+ { STATS_COUNT, default_group, EDG_WLL_JOB_READY, 0, 0, default_archives },
+ { STATS_COUNT, default_group, EDG_WLL_JOB_SCHEDULED, 0, 0, default_archives },
+ { STATS_COUNT, default_group, EDG_WLL_JOB_RUNNING, 0, 0, default_archives },
+ { STATS_COUNT, default_group, EDG_WLL_JOB_DONE, 0, EDG_WLL_STAT_OK, default_archives },
+ { STATS_COUNT, default_group, EDG_WLL_JOB_DONE, 0, EDG_WLL_STAT_FAILED, default_archives },
+ { STATS_DURATION, default_group, EDG_WLL_JOB_SCHEDULED, 0, 0, default_archives },
+ { STATS_DURATION, default_group, EDG_WLL_JOB_RUNNING, 0, 0, default_archives },
+ { STATS_DURATION_FROMTO, default_group, EDG_WLL_JOB_SUBMITTED, EDG_WLL_JOB_RUNNING, 0, default_archives },
+ { STATS_DURATION_FROMTO, default_group, EDG_WLL_JOB_SUBMITTED, EDG_WLL_JOB_DONE, EDG_WLL_STAT_OK, default_archives },
+ { STATS_DURATION_FROMTO, default_group, EDG_WLL_JOB_SUBMITTED, EDG_WLL_JOB_DONE, EDG_WLL_STAT_FAILED, default_archives },
+ { STATS_DURATION_FROMTO, default_group, EDG_WLL_JOB_RUNNING, EDG_WLL_JOB_DONE, EDG_WLL_STAT_OK, default_archives },
+ { STATS_DURATION_FROMTO, default_group, EDG_WLL_JOB_RUNNING, EDG_WLL_JOB_DONE, EDG_WLL_STAT_FAILED, default_archives },
{ STATS_UNDEF, }
};
glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
"stats: using %s",fname);
unlink(fname);
+
+ stats[i].htab = (struct hsearch_data*)malloc(sizeof(*(stats[i].htab)));
+ memset(stats[i].htab, 0, sizeof(*(stats[i].htab)));
+ stats[i].htab_size = GROUPS_HASHTABLE_SIZE;
+ if (!hcreate_r(stats[i].htab_size, stats[i].htab)){
+ glite_common_log(LOG_CATEGORY_CONTROL,
+ LOG_PRIORITY_WARN,
+ "Cannot create hash table for stats!");
+ free(stats[i].htab);
+ stats[i].htab = NULL;
+ }
}
return 0;
}
for (i=0; stats[i].type; i++) switch (stats[i].type) {
case STATS_COUNT:
if (!to) continue;
- if (to->state == stats[i].major && (!from || from->state != to->state)) {
+ if (to->state == stats[i].base_state && (!from || from->state != to->state)) {
switch (to->state) {
case EDG_WLL_JOB_DONE:
if (to->done_code != stats[i].minor) continue;
break;
case STATS_DURATION:
if (!to || !from) continue;
- if (from->state == stats[i].major && from->state != to->state)
+ if (from->state == stats[i].base_state && from->state != to->state)
stats_record_duration(ctx,from,to,stats+i);
+ break;
+ case STATS_DURATION_FROMTO:
+ if (!from) continue;
+ if ((to->state == stats[i].final_state) && (from->state != to->state)){
+ switch (to->state) {
+ case EDG_WLL_JOB_DONE:
+ if (to->done_code != stats[i].minor) continue;
+ break;
+ default: break;
+ }
+ stats_record_duration_fromto(ctx, from, to, stats+i);
+ }
+ break;
default: break;
}
return 0;
}
+static int stats_double_htable(edg_wll_Stats *stats){
+ struct edg_wll_stats_group *g;
+ ENTRY search, *found;
+ int i;
+
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_INFO,
+ "Hash table full, refilling.");
+ hdestroy_r(stats->htab);
+ memset(stats->htab, 0, sizeof(*(stats->htab)));
+ stats->htab_size *= 2;
+ if (!hcreate_r(stats->htab_size, stats->htab)){
+ glite_common_log(LOG_CATEGORY_LB_SERVER,
+ LOG_PRIORITY_WARN,
+ "Cannot enlarge hash table for stats! Using linear search instead.");
+ free(stats->htab);
+ stats->htab = NULL;
+ return -1;
+ }
+ for (i=0; i<stats->grpno; i++) {
+ g = (struct edg_wll_stats_group *) (
+ ((char *) stats->map) + stats->grpsize * i
+ );
+ search.key = strdup(g->sig);
+ search.data = (void*)g;
+ if (! hsearch_r(search, ENTER, &found, stats->htab)){
+ glite_common_log(LOG_CATEGORY_LB_SERVER,
+ LOG_PRIORITY_WARN,
+ "Unexpected error in hsearch_r, switching to linear search!");
+ hdestroy_r(stats->htab);
+ free(stats->htab);
+ stats->htab = NULL;
+ return -1;
+ }
+ }
+ return 0;
+}
+
static struct edg_wll_stats_archive *archive_skip(
const struct edg_wll_stats_archive *a,
int len)
static int stats_remap(edg_wll_Stats *stats)
{
+ struct edg_wll_stats_group *g;
+ ENTRY search, *found;
+ int i;
+
int newgrpno = stats->map->grpno;
glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
"stats_remap: size changed (%d != %d), remap",
return -1;
}
assert(stats->map->grpno == newgrpno);
+
+ if (stats->htab){
+ while (newgrpno*100 > stats->htab_size*80)
+ stats_double_htable(stats);
+ for (i = stats->grpno; i < newgrpno; i++){
+ g = (struct edg_wll_stats_group *) (
+ ((char *) stats->map) + stats->grpsize * i );
+ search.key = strdup(g->sig);
+ search.data = (void*)g;
+ if (!hsearch_r(search, ENTER, &found, stats->htab)){
+ /* This should never happen */
+ glite_common_log(LOG_CATEGORY_LB_SERVER,
+ LOG_PRIORITY_ERROR,
+ "Cannot insert new element into stats hash table. Switching to linear search.");
+ hdestroy_r(stats->htab);
+ free(stats->htab);
+ stats->htab = NULL;
+ break;
+ }
+ }
+ }
+
stats->grpno = newgrpno;
return 0;
}
+static void stats_search_existing_group(edg_wll_Stats *stats, struct edg_wll_stats_group **g, char *sig)
+{
+ ENTRY search, *found;
+ int i;
+
+ if (stats->htab){
+ search.key = sig;
+ hsearch_r(search, FIND, &found, stats->htab);
+ if (found && strcmp(sig, found->key) == 0)
+ *g = (struct edg_wll_stats_group*)found->data;
+ else
+ *g = NULL;
+ }
+ else{
+ for (i=0; i<stats->grpno; i++) {
+ *g = (struct edg_wll_stats_group *) (
+ ((char *) stats->map) + stats->grpsize * i
+ );
+ if (!strcmp(sig,(*g)->sig)) break;
+ }
+ if (i == stats->grpno)
+ *g = NULL;
+ }
+}
+
+static int stats_search_group(edg_wll_Context ctx, const edg_wll_JobStat *jobstat,edg_wll_Stats *stats, struct edg_wll_stats_group **g)
+{
+ int i, j;
+ char *sig = NULL;
+ struct edg_wll_stats_archive *a;
+ ENTRY search, *found;
+
+ sig = str2md5base64(jobstat->destination);
+
+ stats_search_existing_group(stats, g, sig);
+
+ /* not found, initialize new */
+ if (*g == NULL) {
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
+ "group %s not found",sig);
+ if (stats->grpno) {
+ char *zero = calloc(1,stats->grpsize);
+ munmap(stats->map,stats->grpno * stats->grpsize);
+ lseek(stats->fd,0,SEEK_END);
+ write(stats->fd,zero,stats->grpsize);
+ free(zero);
+ stats->map = mmap(NULL,(stats->grpno+1) * stats->grpsize,
+ PROT_READ|PROT_WRITE,MAP_SHARED,stats->fd,0);
+
+ if (stats->map == MAP_FAILED) {
+ free(sig);
+ edg_wll_SetError(ctx,errno,"mmap()");
+ return -1;
+ }
+ }
+ stats->grpno++;
+ stats->map->grpno++;
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
+ "allocated");
+
+ *g = (struct edg_wll_stats_group *) (
+ ((char *) stats->map) + stats->grpsize * (stats->grpno-1));
+
+ /* invalidate all cells in all archives */
+ a = (*g)->archive;
+ for (i=0; stats->archives[i].interval; i++) {
+ for (j=0; j<stats->archives[i].length; j++) a->cells[j].cnt = -1;
+ a = archive_skip(a,stats->archives[i].length);
+ }
+
+ strcpy((*g)->sig,sig);
+ strncpy((*g)->destination, jobstat->destination, STATS_DEST_SIZE); // redundant, no string larger than STATS_DEST_SIZE should pass here
+ (*g)->last_update = jobstat->stateEnterTime.tv_sec; //now;
+
+ if (stats->grpno*100 > stats->htab_size*80)
+ stats_double_htable(stats);
+ if (stats->htab){
+ search.key = strdup(sig);
+ search.data = (void*)(*g);
+ if (!hsearch_r(search, ENTER, &found, stats->htab)){
+ /* This should never happen */
+ glite_common_log(LOG_CATEGORY_LB_SERVER,
+ LOG_PRIORITY_ERROR,
+ "Cannot insert new element into stats hash table. Switching to linear search.");
+ hdestroy_r(stats->htab);
+ free(stats->htab);
+ stats->htab = NULL;
+ }
+ }
+ }
+ else
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
+ "group %s found", sig);
+
+ free(sig);
+
+ return 0;
+}
static int stats_inc_counter(edg_wll_Context ctx,const edg_wll_JobStat *jobstat,edg_wll_Stats *stats)
{
int i,j;
- char *sig = NULL;
struct edg_wll_stats_group *g;
struct edg_wll_stats_archive *a;
time_t now = jobstat->stateEnterTime.tv_sec;
/* XXX: we support destination grouping only */
- if (!jobstat->destination) return 0;
+ if (!jobstat->destination){
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_WARN,
+ "Only grouping by destination is supported!");
+ return 0;
+ }
+
+ /* XXX: we support destination length up to STATS_DEST_SIZE only */
+ if (strlen(jobstat->destination) >= STATS_DEST_SIZE){
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_WARN,
+ "Destination %s omitted from statistics (only size smaller that %i characters supported)!", jobstat->destination, STATS_DEST_SIZE);
+ return 0;
+ }
+
edg_wll_ResetError(ctx);
glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
goto cleanup;
}
- sig = str2md5base64(jobstat->destination);
-
- for (i=0; i<stats->grpno; i++) {
- g = (struct edg_wll_stats_group *) (
- ((char *) stats->map) + stats->grpsize * i
- );
- if (!strcmp(sig,g->sig)) break;
- }
-
- /* not found, initialize new */
- if (i == stats->grpno) {
- glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
- "group %s not found",sig);
- if (stats->grpno) {
- char *zero = calloc(1,stats->grpsize);
- munmap(stats->map,stats->grpno * stats->grpsize);
- lseek(stats->fd,0,SEEK_END);
- write(stats->fd,zero,stats->grpsize);
- free(zero);
- stats->map = mmap(NULL,(stats->grpno+1) * stats->grpsize,
- PROT_READ|PROT_WRITE,MAP_SHARED,stats->fd,0);
-
- if (stats->map == MAP_FAILED) {
- edg_wll_SetError(ctx,errno,"mmap()");
- goto cleanup;
- }
- }
- stats->grpno++;
- stats->map->grpno++;
- glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
- "allocated");
-
- g = (struct edg_wll_stats_group *) (
- ((char *) stats->map) + stats->grpsize * i);
-
- /* invalidate all cells in all archives */
- a = g->archive;
- for (i=0; stats->archives[i].interval; i++) {
- for (j=0; j<stats->archives[i].length; j++) a->cells[j].cnt = -1;
- a = archive_skip(a,stats->archives[i].length);
- }
-
- strcpy(g->sig,sig);
- g->last_update = now;
- }
- else
- glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
- "group %s found at %d", sig, i);
-
+ if (stats_search_group(ctx, jobstat, stats, &g))
+ goto cleanup;
+
a = g->archive;
for (i=0; stats->archives[i].interval; i++) {
time_t pt = g->last_update;
cleanup:
- free(sig);
flock(stats->fd,LOCK_UN);
return edg_wll_Error(ctx,NULL,NULL);
}
return 0;
}
-int edg_wll_StateRateServer(
- edg_wll_Context ctx,
- const edg_wll_QueryRec *group,
- edg_wll_JobStatCode major,
- int minor,
- time_t *from,
- time_t *to,
- float *rate,
- int *res_from,
- int *res_to
-)
+static int stats_record_duration_fromto(
+ edg_wll_Context ctx,
+ const edg_wll_JobStat *from,
+ const edg_wll_JobStat *to,
+ edg_wll_Stats *stats)
{
- edg_wll_Stats *stats = default_stats; /* XXX: hardcoded */
- struct edg_wll_stats_group *g;
- struct edg_wll_stats_archive *a;
- int i,j,matchi;
- char *sig = NULL;
- time_t afrom,ato;
- long match;
- struct _edg_wll_GssPrincipal_data princ;
+ struct edg_wll_stats_group *g;
+ struct edg_wll_stats_archive *a;
+ int i, j;
+ time_t now = to->stateEnterTime.tv_sec;
- princ.name = ctx->peerName;
- princ.fqans = ctx->fqans;
+ /* XXX: we support destination grouping only */
+ if (!to->destination) return 0;
- edg_wll_ResetError(ctx);
+ /* XXX: we support destination length up to STATS_DEST_SIZE only */
+ if (strlen(to->destination) >= STATS_DEST_SIZE){
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_WARN,
+ "Destination %s omitted from statistics (only size smaller that %i characters supported)!", to->destination, STATS_DEST_SIZE);
+ return 0;
+ }
- switch (ctx->count_statistics) {
- case 0: return edg_wll_SetError(ctx,ENOSYS,NULL);
- case 1: if (!ctx->noAuth && !check_authz_policy(&ctx->authz_policy, &princ, GET_STATISTICS)) return edg_wll_SetError(ctx,EPERM,NULL);
- break;
- case 2: break;
- default: abort();
- }
+ edg_wll_ResetError(ctx);
- if (group[0].attr != EDG_WLL_QUERY_ATTR_DESTINATION
- || group[1].attr != EDG_WLL_QUERY_ATTR_UNDEF)
- return edg_wll_SetError(ctx,ENOSYS,
- "the only supported grouping is by destination");
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
+ "record_duration_fromto: destination %s, stats %d",
+ to->destination, (int) (stats - (edg_wll_Stats *) default_stats));
- if (*from >= *to) return edg_wll_SetError(ctx,EINVAL,"from >= to");
+ if (flock(stats->fd,LOCK_EX)) return edg_wll_SetError(ctx,errno,"flock()");
- for (;stats->type; stats++) {
- if (stats->type != STATS_COUNT || stats->major != major) continue;
- switch (major) {
- case EDG_WLL_JOB_DONE:
- if (stats->minor != minor) continue;
- break;
- default: break;
- }
- break;
- }
+ /* remap the file if someone changed its size */
+ if (stats->map->grpno != stats->grpno && stats_remap(stats)) {
+ edg_wll_SetError(ctx,errno,"shmem remap failed");
+ goto cleanup;
+ }
- if (!stats->type) return edg_wll_SetError(ctx,ENOENT,"no matching state counter");
+ if (stats_search_group(ctx, to, stats, &g))
+ goto cleanup;
- /* remap the file if someone changed its size */
- if (stats->map->grpno != stats->grpno)
- {
- if (flock(stats->fd,LOCK_EX)) return edg_wll_SetError(ctx,errno,"flock()");
- if (stats_remap(stats)) {
- edg_wll_SetError(ctx,errno,"shmem remap failed");
- goto cleanup;
+ time_t base = to->stateEnterTimes[stats->base_state+1];
+ time_t final = to->stateEnterTimes[stats->final_state+1];
+ time_t timedif = final-base;
+ if (base && final){ /* final should be always not null*/
+ a = g->archive;
+
+ for (i=0; stats->archives[i].interval; i++) {
+ time_t pt = g->last_update;
+
+ pt -= pt % stats->archives[i].interval;
+
+ /* nothing happened longer than is history of this archive */
+ if (now-pt > stats->archives[i].interval * stats->archives[i].length) {
+ for (j=0; j<stats->archives[i].length; j++) a->cells[j].cnt = 0;
+ a->ptr = 0;
+ }
+ /* catch up eventually, cleaning not touched cells */
+ else for (pt += stats->archives[i].interval; pt < now;
+ pt += stats->archives[i].interval)
+ {
+ if (++(a->ptr) == stats->archives[i].length) a->ptr = 0;
+ a->cells[a->ptr].cnt = 0;
+ }
+
+ /* validate an unused cell */
+ if (a->cells[a->ptr].cnt < 0) a->cells[a->ptr].cnt = 0;
+
+ /* now we can do IT */
+ a->cells[a->ptr].cnt++;
+ a->cells[a->ptr].value += (float)timedif;
+ a->cells[a->ptr].value2 += (float)timedif * (float)timedif;
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
+ "update archive %d, cell %d incremented to %f",
+ i, a->ptr, a->cells[a->ptr].value);
+
+ /* go to next archive */
+ a = archive_skip(a,stats->archives[i].length);
}
}
+
+ g->last_update = now;
+
+cleanup:
+ flock(stats->fd,LOCK_UN);
+ return edg_wll_Error(ctx,NULL,NULL);
+}
- if (flock(stats->fd,LOCK_SH)) return edg_wll_SetError(ctx,errno,"flock()");
+static int findStat(
+ edg_wll_Context ctx,
+ const edg_wll_QueryRec *group,
+ edg_wll_JobStatCode base_state,
+ edg_wll_JobStatCode final_state,
+ int minor,
+ time_t *from,
+ time_t *to,
+ edg_wll_Stats **stats
+)
+{
+ edg_wll_JobStatCode later_state;
- /* XXX */
- sig = str2md5base64(group->value.c);
+ switch (ctx->count_statistics) {
+ case 0: return edg_wll_SetError(ctx,ENOSYS,NULL);
+ case 1: if (!ctx->noAuth) return edg_wll_SetError(ctx,EPERM,NULL);
+ break;
+ case 2: break;
+ default: abort();
+ }
+
+ if (group[0].attr != EDG_WLL_QUERY_ATTR_DESTINATION
+ || group[1].attr != EDG_WLL_QUERY_ATTR_UNDEF)
+ return edg_wll_SetError(ctx,ENOSYS,
+ "the only supported grouping is by destination");
+
+ if (*from >= *to) return edg_wll_SetError(ctx,EINVAL,"from >= to");
+
+ for (;(*stats)->type; (*stats)++) {
+ //if ((*stats)->type != STATS_COUNT || (*stats)->base_state != base_state || (*stats)->final_state != final_state) continue;
+ if ((*stats)->type == STATS_COUNT){
+ if ((*stats)->base_state != base_state) continue;
+ else later_state = base_state;
+ }
+ if ((*stats)->type == STATS_DURATION_FROMTO){
+ if((*stats)->base_state != base_state || (*stats)->final_state != final_state) continue;
+ else later_state = final_state;
+ }
+ if ((*stats)->type == STATS_DURATION){
+ continue;
+ }
+ switch (later_state) {
+ case EDG_WLL_JOB_DONE:
+ if ((*stats)->minor != minor) continue;
+ break;
+ default: break;
+ }
+ break;
+ }
+
+ if (!(*stats)->type) return edg_wll_SetError(ctx,ENOENT,"no matching state counter");
+ return 0;
+}
- for (i=0, g=stats->map; i<stats->grpno; i++) {
- if (!strcmp(sig,g->sig)) break;
- g = (struct edg_wll_stats_group *) (((char *) g) + stats->grpsize);
- }
+static int stateRateRequest(
+ edg_wll_Context ctx,
+ edg_wll_Stats *stats,
+ struct edg_wll_stats_group *g,
+ time_t *from,
+ time_t *to,
+ float *rate,
+ int *res_from,
+ int *res_to
+)
+{
+ struct edg_wll_stats_archive *a;
+ int i,j,matchi;
+ time_t afrom,ato;
+ long match, diff;
- if (i == stats->grpno) {
- glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
- "no match: %s\n",sig);
- edg_wll_SetError(ctx,ENOENT,"no matching group");
- goto cleanup;
- }
+ edg_wll_ResetError(ctx);
match = 0;
matchi = -1;
"best match: archive %d, interval %ld", matchi, match);
if (matchi < 0) {
- if (*from > g->last_update) {
- /* special case -- we are sure that nothing arrived */
- *rate = 0;
- *res_from = *res_to = stats->archives[0].interval;
- goto cleanup;
- }
edg_wll_SetError(ctx,ENOENT,"no data available");
goto cleanup;
}
*rate = 0;
match = 0;
-
for (j=0; j<stats->archives[matchi].length; j++,afrom += i) {
struct edg_wll_stats_cell *c = a->cells + ((a->ptr+j+1) % stats->archives[matchi].length);
}
glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
- "search %ld in %ld, %ld", *from, afrom, afrom+i);
+ "search %ld in %ld, %ld", *from, afrom, afrom+i);
+
+ // (from, to) is inside (afrom, afrom+i)
+ if (*from >= afrom && *to < afrom+i) {
+ diff = *to - *from;
+ }
+ // (afrom, afrom+i) is inside (from, to)
+ else if (*from < afrom && *to >= afrom+i) {
+ diff = i;
+ }
+ // from is in (afrom, afrom+i)
+ else if (*from >= afrom && *from < afrom+i) {
+ diff = afrom+i - *from;
+ }
+ // to is in (afrom, afrom+i)
+ else if (*to >= afrom && *to < afrom+i) {
+ diff = afrom+i - *to;
+ }
+ match += diff;
+ *rate += c->cnt * (float)diff/i;
+
+ if (*to >= afrom && *to < afrom+i) {
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG, "matched to: match %d, rate %f", match, *rate);
+ break;
+ }
+ }
- if (*from >= afrom && *from < afrom+i) {
- match += *from - afrom;
- *rate += c->cnt * (1.0 - ((float) *from-afrom)/i);
- glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG, "matched from: match %ld, rate %f", match, *rate);
- }
- else if (*from < afrom && *to >= afrom) {
- match += i;
- *rate += c->cnt;
- glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG, "matched in: match %ld, rate %f", match, *rate);
+ if (match > 0)
+ *rate /= match;
+
+cleanup:
+ return edg_wll_Error(ctx,NULL,NULL);
+}
+
+int edg_wll_StateRateServer(
+ edg_wll_Context ctx,
+ const edg_wll_QueryRec *group,
+ edg_wll_JobStatCode major,
+ int minor,
+ time_t *from,
+ time_t *to,
+ float **rates,
+ char ***groups,
+ int *res_from,
+ int *res_to
+)
+{
+ edg_wll_Stats *stats = default_stats; /* XXX: hardcoded */
+ struct edg_wll_stats_group *g;
+ int i;
+ char *sig = NULL;
+ int err;
+
+ edg_wll_ResetError(ctx);
+ *rates = NULL; *groups = NULL;
+
+ if ((err = findStat(ctx, group, major, EDG_WLL_JOB_UNDEF, minor, from, to, &stats))) return err;
+
+ /* remap the file if someone changed its size */
+ if (stats->map->grpno != stats->grpno)
+ {
+ if (flock(stats->fd,LOCK_EX)) return edg_wll_SetError(ctx,errno,"flock()");
+ if (stats_remap(stats)) {
+ edg_wll_SetError(ctx,errno,"shmem remap failed");
+ goto cleanup;
}
+ }
- if (*to >= afrom && *to < afrom+i) {
- match -= i-(*to-afrom);
- *rate -= c->cnt * (((float) i)-(*to - afrom))/i;
+ if (flock(stats->fd,LOCK_SH)) return edg_wll_SetError(ctx,errno,"flock()");
- glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG, "matched to: match %ld, rate %f", match, *rate);
+ if (group->value.c){
+ /* single group */
+ sig = str2md5base64(group->value.c);
- /* asi blbost
- if (j == stats->archives[matchi].length - 1
- && *to > g->last_update)
- {
- match -= *to - g->last_update;
- *rate -= c->cnt * (((float) *to) - g->last_update)/i;
- dprintf(("corrected wrt. last_update: match %ld, rate %f\n",match,*rate));
- }
- */
+ *rates = (float*)malloc(2*sizeof((*rates)[0]));
+ (*rates)[0] = (*rates)[1] = 0;
+ *groups = (char**)malloc(2*sizeof((*groups)[0]));
+ (*groups)[0] = (*groups)[1] = NULL;
- break;
+ stats_search_existing_group(stats, &g, sig);
+
+ if (g == NULL) {
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
+ "no match: %s\n",sig);
+ edg_wll_SetError(ctx,ENOENT,"no matching group");
+ free(*rates); *rates = NULL;
+ free(*groups); *groups = NULL;
+ goto cleanup;
+ }
+
+ if ((err = stateRateRequest(ctx, stats, g, from, to, &((*rates)[0]), res_from, res_to))){
+ free(*rates);
+ free(*groups);
+ goto cleanup;
+ }
+ (*groups)[0] = strdup(g->destination);
+ }
+ else{
+ /* all groups */
+ *rates = (float*)malloc(stats->grpno * sizeof((*rates)[0]));
+ *groups = (char**)malloc((stats->grpno+1) * sizeof((*groups)[0]));
+ for (i=0, g=stats->map; i<stats->grpno; i++) {
+ (*rates)[i] = 0;
+ (*groups)[i] = NULL;
+ if ((err = stateRateRequest(ctx, stats, g, from, to, &((*rates)[i]), res_from, res_to)))
+ continue; //TODO in fact breaks results here
+ (*groups)[i] = strdup(g->destination);
+ g = (struct edg_wll_stats_group *) (((char *) g) + stats->grpsize);
+ }
+ (*groups)[i] = NULL;
+ if (i == 0){
+ edg_wll_SetError(ctx,ENOENT,"no matching group");
+ free(*rates); *rates = NULL;
+ free(*groups); *groups = NULL;
+ goto cleanup;
}
}
- *rate /= match;
cleanup:
- free(sig);
- flock(stats->fd,LOCK_UN);
- return edg_wll_Error(ctx,NULL,NULL);
+ free(sig);
+ flock(stats->fd,LOCK_UN);
+ return edg_wll_Error(ctx,NULL,NULL);
}
int edg_wll_StateDurationServer(
int minor,
time_t *from,
time_t *to,
- float *duration,
+ float **duration,
+ char ***groups,
int *res_from,
int *res_to
)
return edg_wll_SetError(ctx,ENOSYS,NULL);
}
+static int stateDurationFromToRequest(
+ edg_wll_Context ctx,
+ edg_wll_Stats *stats,
+ struct edg_wll_stats_group *g,
+ time_t *from,
+ time_t *to,
+ float *duration,
+ float *dispersion,
+ int *res_from,
+ int *res_to
+)
+{
+ struct edg_wll_stats_archive *a;
+ int i,j,matchi;
+ time_t afrom,ato;
+ long match, diff;
+ float rate;
+
+ edg_wll_ResetError(ctx);
+
+ match = 0;
+ matchi = -1;
+ /* XXX: assumes decreasing resolution of archives */
+ for (j=0; stats->archives[j].interval; j++) {
+ afrom = ato = g->last_update;
+
+ ato += stats->archives[j].interval - ato % stats->archives[j].interval;
+ afrom -= afrom % stats->archives[j].interval;
+ afrom -= stats->archives[j].interval * (stats->archives[j].length-1);
+
+ /* intersection of [from,to] and [afrom,ato] */
+ if (afrom < *from) afrom = *from;
+ if (ato > *to) ato = *to;
+
+ /* find the best match */
+ if (ato-afrom > match) {
+ match = ato - afrom;
+ matchi = j;
+ }
+ }
+
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
+ "best match: archive %d, interval %ld", matchi, match);
+
+ if (matchi < 0) {
+ edg_wll_SetError(ctx,ENOENT,"no data available");
+ goto cleanup;
+ }
+
+ *res_from = *res_to = stats->archives[matchi].interval;
+
+ a = g->archive;
+ for (j=0; j<matchi; j++) a = archive_skip(a,stats->archives[j].length);
+
+ i = stats->archives[matchi].interval;
+ afrom = g->last_update - g->last_update % i
+ - (stats->archives[matchi].length-1)*i;
+
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
+ "archive from %ld = %s", afrom, ctime(&afrom));
+
+ if (afrom > *from) *from = afrom;
+ if (afrom + stats->archives[matchi].length * i < *to) *to = afrom + stats->archives[matchi].length * i;
+
+ rate = 0.0f;
+ *duration = 0.0f;
+ *dispersion = 0.0f;
+ match = 0;
+
+ for (j=0; j<stats->archives[matchi].length; j++,afrom += i) {
+ struct edg_wll_stats_cell *c = a->cells + ((a->ptr+j+1) % stats->archives[matchi].length);
+
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
+ "cell %d (abs %d): ",
+ j, (a->ptr+j+1) % stats->archives[matchi].length);
+ if (c->cnt < 0) {
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG, "invalid");
+ continue; /* invalid cell */
+ }
+
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
+ "search %ld in %ld, %ld", *from, afrom, afrom+i);
+
+ // (from, to) is inside (afrom, afrom+i)
+ if (*from >= afrom && *to < afrom+i) {
+ diff = *to - *from;
+ }
+ // (afrom, afrom+i) is inside (from, to)
+ else if (*from < afrom && *to >= afrom+i) {
+ diff = i;
+ }
+ // from is in (afrom, afrom+i)
+ else if (*from >= afrom && *from < afrom+i) {
+ diff = afrom+i - *from;
+ }
+ // to is in (afrom, afrom+i)
+ else if (*to >= afrom && *to < afrom+i) {
+ diff = afrom+i - *to;
+ }
+ match += diff;
+ rate += c->cnt * (float)diff;
+ if (c->cnt)
+ *duration += (float)diff * c->value/c->cnt;
+ *dispersion += (float)diff * c->value2;
+
+ if (*to >= afrom && *to < afrom+i) {
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG, "matched to: match %d, duration %f, dispersion %f", match, *duration, *dispersion);
+ break;
+ }
+ }
+ if (match > 0){
+ *duration /= match;
+ *dispersion /= match;
+ rate /= match;
+ if (rate > 1)
+ *dispersion = sqrtf(1/(rate-1) * ((*dispersion) - rate*((*duration)*(*duration))));
+ else
+ *dispersion = 0;
+ }
+
+cleanup:
+ return edg_wll_Error(ctx,NULL,NULL);
+}
+
+int edg_wll_StateDurationFromToServer(
+ edg_wll_Context ctx,
+ const edg_wll_QueryRec *group,
+ edg_wll_JobStatCode base_state,
+ edg_wll_JobStatCode final_state,
+ int minor,
+ time_t *from,
+ time_t *to,
+ float **durations,
+ float **dispersions,
+ char ***groups,
+ int *res_from,
+ int *res_to
+)
+{
+ edg_wll_Stats *stats = default_stats; /* XXX: hardcoded */
+ struct edg_wll_stats_group *g;
+ char *sig = NULL;
+ int err;
+ int i;
+
+ edg_wll_ResetError(ctx);
+ *durations = NULL;
+ *dispersions = NULL;
+ *groups = NULL;
+
+ if ((err = findStat(ctx, group, base_state, final_state, minor, from, to, &stats))) return err;
+
+ /* remap the file if someone changed its size */
+ if (stats->map->grpno != stats->grpno)
+ {
+ if (flock(stats->fd,LOCK_EX)) return edg_wll_SetError(ctx,errno,"flock()");
+ if (stats_remap(stats)) {
+ edg_wll_SetError(ctx,errno,"shmem remap failed");
+ goto cleanup;
+ }
+ }
+
+ if (flock(stats->fd,LOCK_SH)) return edg_wll_SetError(ctx,errno,"flock()");
+
+ if (group->value.c){
+ /* single group */
+ sig = str2md5base64(group->value.c);
+ *durations = (float*)malloc(1*sizeof((*durations)[0]));
+ (*durations)[0] = 0;
+ *dispersions = (float*)malloc(1*sizeof((*dispersions)[0]));
+ (*dispersions)[0] = 0;
+ *groups = (char**)malloc(2*sizeof((*groups)[0]));
+ (*groups)[0] = (*groups)[1] = NULL;
+
+ stats_search_existing_group(stats, &g, sig);
+
+ if (g == NULL) {
+ glite_common_log(LOG_CATEGORY_LB_SERVER, LOG_PRIORITY_DEBUG,
+ "no match: %s\n",sig);
+ edg_wll_SetError(ctx,ENOENT,"no matching group");
+ goto cleanup;
+ }
+
+ if ((err = stateDurationFromToRequest(ctx, stats, g, from, to, &((*durations)[0]), &((*dispersions)[0]), res_from, res_to))){
+ free(*durations);
+ free(*dispersions);
+ free(*groups);
+ goto cleanup;
+ }
+ (*groups)[0] = strdup(g->destination);
+ }
+ else{
+ /* all groups */
+ *durations = (float*)malloc(stats->grpno * sizeof((*durations)[0]));
+ *dispersions = (float*)malloc(stats->grpno * sizeof((*dispersions)[0]));
+ *groups = (char**)malloc((stats->grpno+1) * sizeof((*groups)[0]));
+
+ for (i=0, g=stats->map; i<stats->grpno; i++) {
+ (*durations)[i] = 0;
+ (*dispersions)[i] = 0;
+ (*groups)[i] = NULL;
+ if ((err = stateDurationFromToRequest(ctx, stats, g, from, to, &((*durations)[i]), &((*dispersions)[i]), res_from, res_to)))
+ continue; //TODO in fact breaks results here
+ (*groups)[i] = strdup(g->destination);
+ g = (struct edg_wll_stats_group *) (((char *) g) + stats->grpsize);
+ }
+ (*groups)[i] = NULL;
+ if (i == 0){
+ edg_wll_SetError(ctx,ENOENT,"no matching group");
+ free(*durations); *durations = NULL;
+ free(*dispersions); *dispersions = NULL;
+ free(*groups); *groups = NULL;
+ goto cleanup;
+ }
+ }
+
+cleanup:
+ free(sig);
+ flock(stats->fd,LOCK_UN);
+ return edg_wll_Error(ctx,NULL,NULL);
+}
+
limitations under the License.
*/
+#ifndef _GNU_SOURCE
+#define _GNU_SOURCE
+#endif
+#include<search.h>
#include "glite/lb/context.h"
#include "glite/lb/events.h"
#include "glite/lb/jobstat.h"
#include "glite/lb/query_rec.h"
+#define STATS_DEST_SIZE 256
+
int edg_wll_InitStatistics(edg_wll_Context);
int edg_wll_UpdateStatistics(
struct edg_wll_stats_cell {
int cnt;
float value;
+ float value2;
};
struct edg_wll_stats_archive {
struct edg_wll_stats_group {
int grpno;
char sig[33];
+ char destination[STATS_DEST_SIZE];
time_t last_update;
struct edg_wll_stats_archive archive[1];
};
typedef struct {
- enum { STATS_UNDEF = 0, STATS_COUNT, STATS_DURATION } type;
+ enum { STATS_UNDEF = 0, STATS_COUNT, STATS_DURATION, STATS_DURATION_FROMTO } type;
edg_wll_QueryRec *group;
- edg_wll_JobStatCode major;
+ edg_wll_JobStatCode base_state;
+ edg_wll_JobStatCode final_state;
int minor;
struct _edg_wll_StatsArchive {
int interval,length;
int fd;
struct edg_wll_stats_group *map;
int grpno,grpsize;
+ unsigned htab_size;
+ struct hsearch_data *htab;
} edg_wll_Stats;
int edg_wll_StateRateServer(
int minor,
time_t *from,
time_t *to,
- float *rate,
+ float **rates,
+ char ***groups,
int *res_from,
int *res_to
);
int minor,
time_t *from,
time_t *to,
- float *duration,
+ float **duration,
+ char ***groups,
int *res_from,
int *res_to
);
+int edg_wll_StateDurationFromToServer(
+ edg_wll_Context ctx,
+ const edg_wll_QueryRec *group,
+ edg_wll_JobStatCode base_state,
+ edg_wll_JobStatCode final_state,
+ int minor,
+ time_t *from,
+ time_t *to,
+ float **duration,
+ float **dispersion,
+ char ***groups,
+ int *res_from,
+ int *res_to
+);
+
#endif /* GLITE_LB_STATS_H */
{
char *unique = edg_wlc_JobIdGetUnique(event->any.jobId);
char *q = NULL, *userid = NULL, *subj = NULL, *owner = NULL;
- glite_lbu_Statement stmt = NULL;
+ glite_lbu_Statement stmt = NULL, stmt_zomb = NULL;
int nar, grey = 0;
char *can_peername = NULL;
int local_job = is_job_local(ctx, event->any.jobId);
if (nar < 0) goto err;
else if (nar == 0) {
/* Job not stored yet */
-
if (event->any.type == EDG_WLL_EVENT_REGJOB) {
/* XXX: directness is checked by any.user == peerName. Not perfect but better than event flags. */
goto err;
}
+ if ((event->any.priority & EDG_WLL_LOGLFLAG_EXCL) && ctx->exclusive_zombies) {
+ trio_asprintf(&q,"select jobid from zombie_jobs "
+ "where zombie_jobs.jobid='%|Ss'",unique);
+
+ if (edg_wll_ExecSQL(ctx,q,&stmt_zomb) > 0) {
+ edg_wll_SetError(ctx,EEXIST,"Zombie job with given jobid already exists. Rejecting event.");
+ goto err;
+ }
+ if (stmt_zomb) { glite_lbu_FreeStmt(&stmt_zomb); stmt_zomb = NULL; }
+ free (q); q = NULL;
+ }
+
/* else OK */
}
else {
stat->pub.jobtype = EDG_WLL_STAT_SIMPLE;
stat->pub.stateEnterTimes[1 + EDG_WLL_JOB_SUBMITTED] = (int)e->timestamp.tv_sec;
stat->pub.lastUpdateTime = e->timestamp;
+ stat->pub.stateEnterTime = e->timestamp;
err:
return edg_wll_Error(ctx,NULL,NULL);
DEBUG:=-g -O0 -Wall
-CFLAGS:= \
+CFLAGS:= ${CFLAGS} \
${DEBUG} \
-I${classads_prefix}/include -I${classads_prefix}/include/classad \
-I${stagedir}/include -I${top_srcdir}/src -I. \
clean:
rm -rvf .libs *.o *.lo ${PLUGIN_LIB} ${MACHINE_LIB}
rm -rfv job_attrs.h job_attrs2.h lb-job-attrs2.xsd glite-jpis-config.xml
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
check:
@echo No tests yet
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.harvester' => [ qw// ],
'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
%obsoletes = (
'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
);
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
+ vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
+ );
};
sub mode_etics {
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
};
for (@{$obsoletes{"$subsys.$module"}}) {
print C "package.obsoletes = $_\n";
print C "package.replaces = $_\n";
}
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+
print C qq{
[Platform-default:DynamicDependency]
};
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
1.1.1-1
- JDL status field for CREAM jobs too (for notifications)
+
+1.1.1-2
+- Module rebuilt
+
+1.1.2-1
+- Fixed target 'clean' in the Makefile to handle debian builds
+
+1.1.2-2
+- Module rebuilt
+
# $Header$
-module.version=1.1.1
-module.age=1
+module.version=1.1.2
+module.age=2
clean:
rm -vf at3
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -rvf log.xml project/glite-lb-types.spec rpmbuild/ RPMS/ tgz/ debian/
check:
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.ws-interface' => [],
'lb.ws-test' => [ qw/gsoap:B/ ],
'lb.types' => [ qw// ],
- 'lb.harvester' => [ qw/postgresql:R/ ],
- 'lb.yaim' => [ qw/glite-yaim-core:R/ ],
+ 'lb.harvester' => [ qw// ],
+ 'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
jpclient => 'jp.client',
);
+%obsoletes = (
+ 'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
+);
+
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_version=>'glite-version',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
+ yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
- 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema/],
+ vdt=>[qw/globus globus_essentials myproxy/],
+ 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
+ );
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
);
};
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
+};
+ for (@{$obsoletes{"$subsys.$module"}}) {
+ print C "package.obsoletes = $_\n";
+ print C "package.replaces = $_\n";
+ }
-[Platform-default:DynamicDependency]
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+ print C qq{
+[Platform-default:DynamicDependency]
};
for (@{$need_externs{"$subsys.$module"}},@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
_optional_
@type Suspend Job execution (queuing) was suspended.
- int status_code Classification of the attempt to suspend the job (REQ, REFUSE, DONE or ABORT).
- _code_ REQ The request was acknowledged.
- _code_ REFUSE The request was declined by this component.
- _code_ DONE The request was completed by whole system.
- _code_ ABORT The request was refused by whole system.
string reason Reason for the suspend.
_optional_
@type Resume Job execution (queuing) was resumed.
- int status_code Classification of the attempt to resume the job (REQ, REFUSE, DONE or ABORT).
- _code_ REQ The request was acknowledged.
- _code_ REFUSE The request was declined by this component.
- _code_ DONE The request was completed by whole system.
- _code_ ABORT The request was refused by whole system.
string reason Reason for the resume.
_optional_
string LRMS_jobid jobId from the LRMS
_optional_
+@type CREAMSuspend Job execution (queuing) was suspended.
+ int status_code Classification of the attempt to suspend the job (REQ, REFUSE, DONE or ABORT).
+ _code_ REQ The request was acknowledged.
+ _code_ REFUSE The request was declined by this component.
+ _code_ DONE The request was completed by whole system.
+ _code_ ABORT The request was refused by whole system.
+ string reason Reason for the suspend.
+ _optional_
+
+@type CREAMResume Job execution (queuing) was resumed.
+ int status_code Classification of the attempt to resume the job (REQ, REFUSE, DONE or ABORT).
+ _code_ REQ The request was acknowledged.
+ _code_ REFUSE The request was declined by this component.
+ _code_ DONE The request was completed by whole system.
+ _code_ ABORT The request was refused by whole system.
+ string reason Reason for the resume.
+ _optional_
+
+
@flesh Transfer
@type FileTransferRegister register file transfer
- Support for CREAM jobs
- Type comments made complete
+1.0.2-1
+- Fix build with binary version of this module
+
+1.1.1-1
+- Fixed handling of target 'clean' in the Makefile
+
+1.1.2-1
+- Fixed target 'clean' in the Makefile to handle debian builds
+- Backward compatibility fixes in event types
+
+1.1.2-2
+- Module rebuilt
+
-module.version=1.1.0
-module.age=1
+# $Header$
+module.version=1.1.2
+module.age=2
DEBUG:=-g -O0 -Wall
-CFLAGS:= \
+CFLAGS:= ${CFLAGS} \
${WS_CFLAGS} ${DEBUG} \
-DVERSION=\"${version}\" \
-I${stagedir}/include -I${top_srcdir}/src -I. \
-I${gsoap_prefix}/include -I${gsoap_prefix}/ \
${COVERAGE_FLAGS} \
-D_GNU_SOURCE
-LDFLAGS:=-L${stagedir}/${libdir}
+LDFLAGS:=${LDFLAGS} -L${stagedir}/${libdir}
COMPILE:=libtool --mode=compile ${CC} ${CFLAGS}
LINK:=libtool --mode=link ${CC} -rpath ${stagedir}/${libdir} ${LDFLAGS}
done
clean:
- rm -rfv ${ALLUTILS} ${MAN_GZ} ${MAN8_GZ} *.{lo,o} .libs/
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -rfv ${ALLUTILS} ${MAN_GZ} ${MAN8_GZ} *.lo *.o .libs/
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
%.o: %.c
${COMPILE} -c $<
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.ws-interface' => [],
'lb.ws-test' => [ qw/gsoap:B/ ],
'lb.types' => [ qw// ],
- 'lb.harvester' => [ qw/postgresql:R/ ],
- 'lb.yaim' => [ qw/glite-yaim-core:R/ ],
+ 'lb.harvester' => [ qw// ],
+ 'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
jpclient => 'jp.client',
);
+%obsoletes = (
+ 'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
+);
+
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_version=>'glite-version',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
+ yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
- 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema/],
+ vdt=>[qw/globus globus_essentials myproxy/],
+ 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
+ );
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
);
};
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
+};
+ for (@{$obsoletes{"$subsys.$module"}}) {
+ print C "package.obsoletes = $_\n";
+ print C "package.replaces = $_\n";
+ }
-[Platform-default:DynamicDependency]
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+ print C qq{
+[Platform-default:DynamicDependency]
};
for (@{$need_externs{"$subsys.$module"}},@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
2.0.4-1
- man page update
+2.0.4-2
+- Module rebuilt
+
+2.0.5-1
+- Fixed target 'clean' in the Makefile to handle debian builds and improve portability
+- Handle situations with no jobs while purging
+
+2.0.6-1
+- Hostname parsing adjusted to handle IPv6 addresses
+
# $Header$
-module.version=2.0.4
+module.version=2.0.6
module.age=1
edg_wll_InitContext(&ctx);
if ( server )
{
- char *p = strchr(server, ':');
+ char *p = strrchr(server, ':');
if ( p )
{
edg_wll_SetParam(ctx, EDG_WLL_PARAM_QUERY_SERVER_PORT, atoi(p+1));
edg_wll_InitContext(&ctx);
if ( server )
{
- char *p = strchr(server, ':');
+ char *p = strrchr(server, ':');
if ( p )
{
edg_wll_SetParam(ctx, EDG_WLL_PARAM_QUERY_SERVER_PORT, atoi(p+1));
} else {
dprintf(("yes.\n"));
}
+ if (!jobs) {
+ dprintf(("File empty.\n"));
+ goto main_end;
+ }
+
request->jobs = jobs;
}
if ( server )
{
- char *p = strchr(server, ':');
+ char *p = strrchr(server, ':');
if ( p )
{
edg_wll_SetParam(ctx, EDG_WLL_PARAM_QUERY_SERVER_PORT, atoi(p+1));
}
jobs[cnt++] = strdup(buf);
}
- jobs[cnt] = NULL;
+ if (jobs) jobs[cnt] = NULL;
fclose(jobIds);
*jobs_out = jobs;
# fi
clean:
- rm -rvf *.h *.html *.xml *.wsdl
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -vf *.h *.html *.xml *.wsdl glue2-copy.xsd
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
%.xml: %.xml.T
rm -f $@
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.ws-interface' => [],
'lb.ws-test' => [ qw/gsoap:B/ ],
'lb.types' => [ qw// ],
- 'lb.harvester' => [ qw/postgresql:R/ ],
- 'lb.yaim' => [ qw/glite-yaim-core:R/ ],
+ 'lb.harvester' => [ qw// ],
+ 'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
jpclient => 'jp.client',
);
+%obsoletes = (
+ 'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
+);
+
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_version=>'glite-version',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
+ yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
- 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema/],
+ vdt=>[qw/globus globus_essentials myproxy/],
+ 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
+ );
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
);
};
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
+};
+ for (@{$obsoletes{"$subsys.$module"}}) {
+ print C "package.obsoletes = $_\n";
+ print C "package.replaces = $_\n";
+ }
-[Platform-default:DynamicDependency]
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+ print C qq{
+[Platform-default:DynamicDependency]
};
for (@{$need_externs{"$subsys.$module"}},@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
- Primitive AGU compatibility
- Support for CREAM jobs
+3.1.1-1
+- Fixed handling of target 'clean' in the Makefile
+
+3.1.2-1
+- Fixed target 'clean' in the Makefile to handle debian builds
+
+3.1.2-2
+- Module rebuilt
+
# $Header$
-module.version=3.1.0
-module.age=1
+module.version=3.1.2
+module.age=2
VPATH=${top_srcdir}/examples
CC=gcc
DEBUG:=-g -O0 -Wall
-CFLAGS=-I${gsoap_prefix}/include -I${gsoap_prefix}/ \
+CFLAGS:=${CFLAGS} -I${gsoap_prefix}/include -I${gsoap_prefix}/ \
-I${stagedir}/include -I${top_srcdir}/src -I. \
-I${globus_prefix}/include/${nothrflavour} \
${DEBUG}
done
clean:
- rm -rf .libs LB.xh *.xml ${GSOAP_FILES_PREFIX}* *.o *.lo *.nsmap soap_version.h ${CEXAMPLES}
-
-
+ rm -rvf .libs LB.xh *.xml ${GSOAP_FILES_PREFIX}* *.o *.lo *.nsmap soap_version.h ${CEXAMPLES}
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
LB.xh: ws_typemap.dat ${stagedir}/interface/LB.wsdl
${gsoap_bin_prefix}/wsdl2h -c -t ${top_srcdir}/examples/ws_typemap.dat -I${stagedir}/interface -o $@ ${stagedir}/interface/LB.wsdl
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.ws-interface' => [],
'lb.ws-test' => [ qw/gsoap:B/ ],
'lb.types' => [ qw// ],
- 'lb.harvester' => [ qw/postgresql:R/ ],
- 'lb.yaim' => [ qw/glite-yaim-core:R/ ],
+ 'lb.harvester' => [ qw// ],
+ 'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
jpclient => 'jp.client',
);
+%obsoletes = (
+ 'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
+);
+
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_version=>'glite-version',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
+ yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
- 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema/],
+ vdt=>[qw/globus globus_essentials myproxy/],
+ 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
+ );
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
);
};
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
+};
+ for (@{$obsoletes{"$subsys.$module"}}) {
+ print C "package.obsoletes = $_\n";
+ print C "package.replaces = $_\n";
+ }
-[Platform-default:DynamicDependency]
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+ print C qq{
+[Platform-default:DynamicDependency]
};
for (@{$need_externs{"$subsys.$module"}},@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
1.0.1-3
- Module repacked
+1.0.2-1
+- Flavor libdir in Makefile
+
1.1.0-1
- Primitive AGU compatibility
+1.1.1-1
+- LB 4 AGU fixes
+- Updated WS error handling
+
+1.1.2-1
+- Fixed handling of target 'clean' in the Makefile
+
+1.1.3-1
+- Fixed target 'clean' in the Makefile to handle debian builds
+
+1.1.3-2
+- Module rebuilt
+
# : /cvs/jra1mw/org.glite.lb.ws-test/project/version.properties,v 1.1 2009/01/15 15:49:26 zsustr Exp $
-module.version=1.1.0
-module.age=1
+module.version=1.1.3
+module.age=2
check:
clean:
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
.PHONY: default all check stage clean
### Default values to some glite-LB variables
+
+#
+# system settings
+#
+
# backward compatible default location of GLITE_LOCATION_VAR
GLITE_LOCATION_VAR=/var/glite
+# query timeout
+GLITE_WMS_QUERY_TIMEOUT=300
+# CA certificates directory
+X509_CERT_DIR='/etc/grid-security/certificates'
+# VOMS directory
+X509_VOMS_DIR='/etc/grid-security/vomsdir'
+
+#
+# purge and exports
+#
+
+# purge timeouts
+GLITE_LB_EXPORT_PURGE_ARGS='--cleared 2d --aborted 15d --cancelled 15d --other 60d'
+# enable export of the purged jobs to the Job Provenance
+GLITE_LB_EXPORT_ENABLED='false'
+# Job Provenance server
+GLITE_LB_EXPORT_JPPS=
+# prefix to the Job Provenance installation (if different from $GLITE_LOCATION)
+GLITE_JP_LOCATION=
+
+#
+# L&B configuration
+#
+
+# L&B super users (separated by comma)
+GLITE_LB_SUPER_USERS=
+# L&B service type (server/proxy/both), overrided by YAIM when needed
+GLITE_LB_TYPE=
+# configure glite-LB to be used with Real Time Monitor (harvester)
+GLITE_LB_RTM_ENABLED='false'
+# Real Time Monitoring identities (separated by comma)
+GLITE_LB_RTM_DN='/C=UK/O=eScience/OU=Imperial/L=Physics/CN=heppc24.hep.ph.ic.ac.uk/Email=janusz.martyniak@imperial.ac.uk'
+
+#
+# additional options
+#
+
+# bkserver additional options
+GLITE_LB_SERVER_OTHER_OPTIONS=
+# notification interlogger additional options
+GLITE_LB_NOTIF_IL_OTHER_OPTIONS=
+# proxy interlogger additional options
+GLITE_LB_PROXY_IL_OTHER_OPTIONS=
yaimlog ERROR "The home directory of ${GLITE_USER} doesn't exist. Check whether the user ${GLITE_USER} was properly created"
exit ${YEX_NOSUCHFILE}
fi
- yaimgridenv_set GLITE_JP_LOCATION ${GLITE_JP_LOCATION:-}
- yaimgridenv_set GLITE_WMS_QUERY_TIMEOUT ${GLITE_WMS_QUERY_TIMEOUT:-300}
+ yaimgridenv_set GLITE_WMS_QUERY_TIMEOUT "${GLITE_WMS_QUERY_TIMEOUT}"
yaimgridenv_set GLITE_HOST_CERT ${GLITE_HOME_DIR:-/home/glite}/.certs/hostcert.pem
yaimgridenv_set GLITE_HOST_KEY ${GLITE_HOME_DIR:-/home/glite}/.certs/hostkey.pem
- yaimgridenv_set X509_CERT_DIR /etc/grid-security/certificates
- yaimgridenv_set X509_VOMS_DIR /etc/grid-security/vomsdir
+ yaimgridenv_set X509_CERT_DIR "${X509_CERT_DIR}"
+ yaimgridenv_set X509_VOMS_DIR "${X509_VOMS_DIR}"
yaimgridenv_set GLITE_LB_EXPORT_ENABLED ${GLITE_LB_EXPORT_ENABLED:-false}
- yaimgridenv_set GLITE_LB_EXPORT_PURGE_ARGS "${GLITE_LB_EXPORT_PURGE_ARGS:---cleared 2d --aborted 15d --cancelled 15d --other 60d}"
+ yaimgridenv_set GLITE_LB_EXPORT_PURGE_ARGS "${GLITE_LB_EXPORT_PURGE_ARGS}"
yaimgridenv_set GLITE_LB_EXPORT_JPPS ${GLITE_LB_EXPORT_JPPS:-}
- yaimgridenv_set GLITE_LB_RTM_ENABLED ${GLITE_LB_RTM_ENABLED:-false}
- yaimgridenv_set GLITE_LB_RTM_DN "${GLITE_LB_RTM_DN:-/C=UK/O=eScience/OU=Imperial/L=Physics/CN=heppc24.hep.ph.ic.ac.uk/Email=janusz.martyniak@imperial.ac.uk}"
- yaimgridenv_set GLITE_LB_SUPER_USERS "${GLITE_LB_SUPER_USERS:-}"
- yaimgridenv_set GLITE_LB_HARVESTER_ENABLED ${GLITE_LB_HARVESTER_ENABLED:-false}
- yaimgridenv_set GLITE_LB_HARVESTER_MSG_OPTIONS "${GLITE_LB_HARVESTER_MSG_OPTIONS:---wlcg}"
-
+ yaimgridenv_set GLITE_JP_LOCATION "${GLITE_JP_LOCATION}"
+
+ yaimgridenv_set GLITE_LB_SERVER_OTHER_OPTIONS "${GLITE_LB_SERVER_OTHER_OPTIONS}"
+ yaimgridenv_set GLITE_LB_NOTIF_IL_OTHER_OPTIONS "${GLITE_LB_NOTIF_IL_OTHER_OPTIONS}"
+ yaimgridenv_set GLITE_LB_PROXY_IL_OTHER_OPTIONS "${GLITE_LB_PROXY_IL_OTHER_OPTIONS}"
+
+ #
+ # default L&B mode (proxy/server/both) according to the node list,
+ # admin can specify GLITE_LB_TYPE, the value is overrided as needed
+ #
+ # behaviour:
+ # LB: default 'server', no overriding
+ # WMS: default 'proxy', override to 'both' if needed
+ # WMS & LB: default 'both', override to 'both' if needed
+ #
+ use_proxy=0
+ use_server=0
+ case "$NODE_TYPE_LIST" in
+ *WMS*) use_proxy=1 ;;
+ esac
+ case "$NODE_TYPE_LIST" in
+ *LB*) use_server=1 ;;
+ esac
+ if [ "x${GLITE_LB_TYPE}" = "x" ]; then
+ # default
+ if [ $use_server -eq 1 ]; then
+ if [ $use_proxy -eq 1 ]; then
+ GLITE_LB_TYPE=both
+ else
+ GLITE_LB_TYPE=server
+ fi
+ else
+ if [ $use_proxy -eq 1 ]; then
+ GLITE_LB_TYPE=proxy
+ fi
+ fi
+ else
+ # override if needed
+ if [ $use_proxy -eq 1 ]; then
+ case "$GLITE_LB_TYPE" in
+ *proxy*|*both*)
+ ;;
+ *)
+ yaimlog WARNING "Overriding L&B mode from '$GLITE_LB_TYPE' to 'both'"
+ GLITE_LB_TYPE=both
+ esac
+ fi
+ fi
yaimgridenv_set GLITE_LB_TYPE ${GLITE_LB_TYPE:-server}
cares_prefix=${INSTALL_ROOT:-/opt}/c-ares
$superusers
}
-action "STATUS_FOR_MONITORING" {
+action "READ_ALL" {
$rtm
}
HOSTNAME=`hostname -f`
+ yaimlog INFO "Configuring nodes [$NODE_TYPE_LIST], using L&B mode: $GLITE_LB_TYPE"
+
# Redefine GLITE_HOME_DIR to make sure we retrieve the correct HOME directory of user glite
GLITE_HOME_DIR=`getent passwd ${GLITE_USER} | cut -d: -f6`
if [ "x${GLITE_HOME_DIR}" = "x" ]; then
fi
fi
+ # disable network, restart mysql, if needd
+ grep "skip-networking" /etc/my.cnf > /dev/null
+ if [ ! $? = 0 ]; then
+ mv /etc/my.cnf /etc/my.cnf.orig
+ sed 's/\[mysqld\]/[mysqld]\nskip-networking/' /etc/my.cnf.orig > /etc/my.cnf
+ rm -f /etc/my.cnf.orig
+ ps ax | grep -v grep |grep mysqld_safe > /dev/null 2>&1
+ if [ $? = 0 ] ; then
+ /etc/init.d/mysqld stop
+ fi
+ fi
+
/sbin/chkconfig mysqld on
ps ax | grep -v grep |grep mysqld_safe > /dev/null 2>&1
if [ ! $? = 0 ] ; then
SERVICE_HOST=`hostname -f`
-if [ ! -f ${INFO_SERVICE_CONFIG}/glite-info-service-${SERVICE_LC}.conf.template ]; then
- yaimlog ERROR "The template file for glite-info-service-${SERVICE_LC}.conf.template was not found in ${INFO_SERVICE_CONFIG}."
+if [ ! -f ${INFO_SERVICE_CONFIG}/glite-info-glue2-${SERVICE_LC}.conf.template ]; then
+ yaimlog ERROR "The template file for glite-info-glue2-${SERVICE_LC}.conf.template was not found in ${INFO_SERVICE_CONFIG}."
exit 1
fi
fi
yaimlog DEBUG "Delete a previous version of the glite-info-service-${SERVICE_LC}.conf if it exists"
-rm -rf ${INFO_SERVICE_CONFIG}/glite-info-service-${SERVICE_LC}.conf
+rm -rf ${INFO_SERVICE_CONFIG}/glite-info-glue2-${SERVICE_LC}.conf
-yaimlog DEBUG "Create the glite-info-service-${SERVICE_LC}.conf file out of the template file"
-cp ${INFO_SERVICE_CONFIG}/glite-info-service-${SERVICE_LC}.conf.template ${INFO_SERVICE_CONFIG}/glite-info-service-${SERVICE_LC}.conf
+yaimlog DEBUG "Create the glite-info-glue2-${SERVICE_LC}.conf file out of the template file"
+cp ${INFO_SERVICE_CONFIG}/glite-info-glue2-${SERVICE_LC}.conf.template ${INFO_SERVICE_CONFIG}/glite-info-glue2-${SERVICE_LC}.conf
# Note: the configuration file may need to be altered if non standard values have been used.
#!/bin/sh
export PATH=$PATH:${INFO_SERVICE_SCRIPT}
export ${SERVICE}_HOST=${SERVICE_HOST}
-${INFO_SERVICE_SCRIPT}/glite-info-service ${INFO_SERVICE_CONFIG}/glite-info-service-${SERVICE_LC}.conf $SITE_NAME
-${INFO_SERVICE_SCRIPT}/glite-info-service-glue2 ${INFO_SERVICE_CONFIG}/glite-info-service-${SERVICE_LC}.conf $SITE_NAME
+${INFO_SERVICE_SCRIPT}/glite-info-service ${INFO_SERVICE_CONFIG}/glite-info-glue2-${SERVICE_LC}.conf $SITE_NAME
+${INFO_SERVICE_SCRIPT}/glite-info-glue2-simple ${INFO_SERVICE_CONFIG}/glite-info-glue2-${SERVICE_LC}.conf $SITE_NAME
EOF
chmod +x ${INFO_PROVIDER_PATH}/glite-info-provider-service-${SERVICE_LC}-wrapper
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.harvester' => [ qw// ],
'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
%obsoletes = (
'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
);
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
+ vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
+ );
};
sub mode_etics {
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
};
for (@{$obsoletes{"$subsys.$module"}}) {
print C "package.obsoletes = $_\n";
print C "package.replaces = $_\n";
}
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+
print C qq{
[Platform-default:DynamicDependency]
};
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
4.2.8-1
- Updated autorization policy format
+
+4.2.9-1
+- Fixed handling of target 'clean' in the Makefile
+- Configuration tuned to improve support for collocated WMS/L&B and standalone WMS scenarios
+
+4.2.10-1
+- Makefile modified to fix debian builds
+- DB listens on internal address
+- Publishing L&B service in GLUE 2.0
+
+4.2.11-1
+- Inteligent post-configuration restarting of MySQL
+- Using glue2 template for BDII
+
# $Header$
-module.version=4.2.8
+module.version=4.2.11
module.age=1
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.harvester' => [ qw// ],
'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
'lbjp-common.gss' => [ qw// ],
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
);
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
+);
+
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
+ );
};
sub mode_etics {
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
};
for (@{$obsoletes{"$subsys.$module"}}) {
print C "package.obsoletes = $_\n";
print C "package.replaces = $_\n";
}
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+
print C qq{
[Platform-default:DynamicDependency]
};
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
system("chmod +x \"$TMPDIR/etics-tag-$module.$branch.sh\"");
- printf("\n\n---------\nFinished!\n\nExecution script written in:\t$TMPDIR/etics-tag-$module.$branch.sh\n");
+ printf("\n\n---------\nDone!\n\nExecution script written in:\t$TMPDIR/etics-tag-$module.$branch.sh\n");
printf("Old configuration stored in:\t$TMPDIR/$currentconfig.ini.$$\n") if (defined $opt_g);
printf("New configuration written in:\t$TMPDIR/$newconfig.ini.$$\n\n");
--- /dev/null
+#!/usr/bin/perl
+#
+# Copyright (c) Members of the EGEE Collaboration. 2004-2010.
+# See http://www.eu-egee.org/partners for details on the copyright holders.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+use Getopt::Std;
+use Switch;
+use File::Basename;
+
+$TMPDIR=$ENV{'TMPDIR'};
+$GLITE_LB_LOCATION=dirname $0;
+
+if ($TMPDIR eq "") {$TMPDIR="/tmp";}
+
+getopts('i:c:m:gh');
+
+$module='org.gridsite.core';
+
+$usage = qq{
+usage: $0 -c <new configuration>
+ -c Use this configuration (\d+\.\d+\.\d+-\S+)
+ -h Display this help
+
+};
+
+# **********************************
+# Interpret cmdline options
+# **********************************
+
+if (defined $opt_h) {die $usage};
+die $usage unless $module;
+
+
+if (defined $opt_c) {
+
+ # **********************************
+ # Parse the tag supplied by the user
+ # **********************************
+
+ if ($opt_c=~/(\d+)\.(\d+)\.(\d+)-(\S+?)/) {
+ $major=$1;
+ $minor=$2;
+ $revision=$3;
+ $age=$4;
+ }
+ else {die ("tag not stated properly")};
+}
+else {
+ die $usage;
+}
+
+printf("Tag: $tag\n\tprefix: $prefix\n\t major: $major\n\t minor: $minor\n\t rev: $revision\n\t age: $age\n");
+
+
+# **********************************
+# Create the execution script
+# **********************************
+
+open EXEC, ">", "$TMPDIR/etics-tag-gridsite.$major.$minor.$revision-$age.sh" or die $!;
+
+printf (EXEC "#This script registers tags for the $module module, version $major.$minor.$revision-$age\n#Generated automatically by $0\n\n");
+
+# **********************************
+# Update version.properties
+# **********************************
+
+## printf(EXEC "#Generate new version.properties\ncat >$module/project/version.properties <<EOF\n# generated for LB configure --mode=etics only\nmodule.version=$major.$minor.$revision\nmodule.age=$age\nEOF\n\n");
+
+# **********************************
+# Etics configuration prepare / modify / upload
+# **********************************
+
+$newconfig="$module" . "_R_$major" . "_$minor" . "_$revision" . "_$age";
+$newconfig=~s/^org.//;
+$newconfig=~s/\./-/g;
+
+$module=~/([^\.]+?)\.([^\.]+?)$/;
+$subsysname=$1;
+$modulename=$2;
+
+printf("Module=$module\nname=$modulename\nsubsys=$subsysname\n");
+system("$GLITE_LB_LOCATION/configure --mode=etics --module $subsysname.$modulename --output $TMPDIR/$newconfig.ini.$$ --version $major.$minor.$revision-$age");
+
+printf(EXEC "\n#Add new configuration\netics-configuration add -i $TMPDIR/$newconfig.ini.$$ -c $newconfig $module\n");
+
+$version="${major}_${minor}_${revision}_${age}";
+
+$template = qq{
+[Configuration-gridsite-MODULE_R_$version]
+profile = None
+moduleName = org.gridsite.MODULE
+displayName = gridsite-MODULE_R_$version
+description = gridsite-MODULE_R_$version
+projectName = org.glite
+age = $age
+vcsroot = None
+tag = None
+version = $major.$minor.$revision
+path = \${projectName}/org.gridsite.core/\${version}/\${platformName}/gridsite-core-\${version}-\${age}.tar.gz
+
+[Platform-default:VcsCommand]
+displayName = None
+description = None
+tag = None
+branch = None
+commit = None
+checkout = echo No checkout required
+
+[Platform-default:BuildCommand]
+checkstyle = None
+packaging = echo "building nothing, org.gridsite.core make rpm step will create this"
+displayName = None
+description = None
+doc = None
+publish = None
+postpublish = None
+compile = echo "building nothing, org.gridsite.core make rpm step will create this"
+init = None
+install = None
+prepublish = None
+test = None
+clean = None
+configure = None
+
+[Platform-default:DynamicDependency]
+org.glite|org.gridsite.core = B
+};
+
+
+for $mod (qw/apache commands shared/) {
+ $conf = $template;
+ $conf =~ s/MODULE/$mod/g;
+
+ open CONF,">$TMPDIR/$subsysname-${mod}_R_$version.ini.$$";
+ print CONF $conf;
+ close CONF;
+
+ print EXEC "etics-configuration add -i $TMPDIR/$subsysname-${mod}_R_$version.ini.$$\n";
+}
+
+printf(EXEC "etics-commit\n");
+
+open CONF,">$TMPDIR/${subsysname}_R_$version.ini.$$";
+
+print CONF qq{
+[Configuration-gridsite_R_$version]
+profile = None
+moduleName = org.gridsite
+displayName = gridsite_R_$version
+description = gridsite_R_$version
+projectName = org.glite
+age = $age
+vcsroot = None
+tag = None
+version = $major.$minor.$revision
+path = None
+
+[Hierarchy]
+org.gridsite.apache = gridsite-apache_R_$version
+org.gridsite.shared = gridsite-shared_R_$version
+org.gridsite.commands = gridsite-commands_R_$version
+org.gridsite.core = gridsite-core_R_$version
+};
+
+close CONF;
+
+print EXEC "etics-configuration add -i $TMPDIR/${subsysname}_R_$version.ini.$$\n";
+
+printf(EXEC "etics-commit\n");
+
+
+# **********************************
+# Final bows
+# **********************************
+
+close(EXEC);
+
+system("chmod +x \"$TMPDIR/etics-tag-gridsite.$major.$minor.$revision-$age.sh\"");
+
+printf("\n\n---------\nDone!\n\nExecution script written in:\t$TMPDIR/etics-tag-gridsite.$major.$minor.$revision-$age.sh\n");
+printf("New configuration written in:\t$TMPDIR/${subsysname}_R_$version.ini.$$\n\n");
+
system("chmod +x \"$TMPDIR/etics-tag-with-subsystems-${subsysname}_$branch.sh\"");
- printf("\n\n---------\nFinished!\n\nExecution script written in:\t$TMPDIR/etics-tag-with-subsystems-${subsysname}_$branch.sh\nNew configuration written in:\t$TMPDIR/$newconfig.ini.$$\n\n");
+ printf("\n\n---------\nDone!\n\nExecution script written in:\t$TMPDIR/etics-tag-with-subsystems-${subsysname}_$branch.sh\nNew configuration written in:\t$TMPDIR/$newconfig.ini.$$\n\n");
system("chmod +x \"$TMPDIR/tag-with-subsystems-$module.$major.$minor.$revision-$age.sh\"");
- printf("\n\n---------\nFinished!\n\nExecution script written in:\t$TMPDIR/tag-with-subsystems-$module.$major.$minor.$revision-$age.sh\nNew configuration written in:\t$TMPDIR/$newconfig.ini.$$\n\n");
+ printf("\n\n---------\nDone!\n\nExecution script written in:\t$TMPDIR/tag-with-subsystems-$module.$major.$minor.$revision-$age.sh\nNew configuration written in:\t$TMPDIR/$newconfig.ini.$$\n\n");
system("cp $module/project/ChangeLog $tmpChangeLog");
unless ($increment eq "n") {system("echo $major.$minor.$revision-$age >> $tmpChangeLog");}
+ if ($increment eq "a") {system("echo \"- Module rebuilt\" >> $tmpChangeLog"); system("echo \"\" >> $tmpChangeLog");}
$ChangeLogRet=system("vim $tmpChangeLog");
system("chmod +x \"$TMPDIR/etics-tag-$module.$major.$minor.$revision-$age.sh\"");
- printf("\n\n---------\nFinished!\n\nExecution script written in:\t$TMPDIR/etics-tag-$module.$major.$minor.$revision-$age.sh\nChangeLog candidate written in:\t$tmpChangeLog\n");
+ printf("\n\n---------\nDone!\n\nExecution script written in:\t$TMPDIR/etics-tag-$module.$major.$minor.$revision-$age.sh\nChangeLog candidate written in:\t$tmpChangeLog\n");
printf("Old configuration stored in:\t$TMPDIR/$currentconfig.ini.$$\n") if (defined $opt_g);
printf("New configuration written in:\t$TMPDIR/$newconfig.ini.$$\n\n");
--- /dev/null
+#!/usr/bin/perl
+#
+# Copyright (c) Members of the EGEE Collaboration. 2004-2010.
+# See http://www.eu-egee.org/partners for details on the copyright holders.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+use Getopt::Std;
+use Switch;
+
+$TMPDIR=$ENV{'TMPDIR'};
+
+if ($TMPDIR eq "") {$TMPDIR="/tmp";}
+
+
+
+$usage = qq{
+usage: $0 [-p] -a|module.name [module.name ...]|-c configuration [configuration ...]
+
+ -h Display this help
+ -p Single line output for Etics web interface
+ -a Process all subdirectories in . rather than getting lists
+ -c Download subsystem configurations from Etics and parse hierarchy
+
+};
+
+if ($#ARGV < 0) {die $usage};
+
+getopts('phac');
+
+if (defined $opt_h) {die $usage};
+if (defined $opt_p) {
+ $eq_separator = "=";
+ $pair_separator_back = " ";
+ $pair_separator_front = "-p "; }
+else {
+ $eq_separator = " = ";
+ $pair_separator_back = "\n";
+ $pair_separator_front = ""; }
+
+sub GetDefault {
+ # **********************************
+ # Determine the most recent tag and its components from version.properties
+ # **********************************
+ my($mname) = @_;
+
+ unless (open VP, "$mname/project/version.properties") {
+ unless (defined $opt_a) { die "$mname/project/version.properties: $?\n"; }
+ else { return 1; }
+ }
+
+ while ($_ = <VP>) {
+ chomp;
+
+ if(/module\.version\s*=\s*(\d*)\.(\d*)\.(\d*)/) {
+ $current_major=$1;
+ $current_minor=$2;
+ $current_revision=$3;
+ }
+ if(/module\.age\s*=\s*(\S+)/) {
+ $current_age=$1;
+ }
+ }
+ close (VP);
+
+ $current_prefix=$mname;
+ $current_prefix=~s/^org\.//;
+ $current_prefix=~s/\./-/g;
+ $current_prefix="$current_prefix" . "_R_";
+ $current_tag="$current_prefix" . "$current_major" . "_$current_minor" . "_$current_revision" . "_$current_age";
+
+ printf "$pair_separator_front$mname.DEFAULT$eq_separator$current_tag$pair_separator_back";
+
+}
+
+if (defined $opt_a) { # All subdirectories
+ opendir(LOCAL, ".");
+ @contents = readdir(LOCAL);
+ closedir(LOCAL);
+
+ foreach $f (@contents) {
+ unless ( ($f eq ".") || ($f eq "..") ) {
+ if (-d $f) {
+ GetDefault ($f);
+ }
+ }
+ }
+}
+else {
+if (defined $opt_c) { # Configurations
+ my $output = "";
+ while ($subsys = shift) {
+ $module = $subsys;
+ $module =~ s/_[a-zA-Z]*_.*//;
+ $module =~ s/glite-/glite\./;
+ $module =~ s/gridsite-/gridsite\./;
+ system("etics-configuration prepare -o $TMPDIR/subsys.INI.$$.tmp -c $subsys org.$module");
+ open FILE, "$TMPDIR/subsys.INI.$$.tmp" or die $!;
+ $hierarchy = 0;
+ while (my $line = <FILE>) {
+ if ($line =~ /^\[Hierarchy\]/) { $hierarchy = 1; }
+ else {
+ if ($line =~ /^\[.*\]/) { $hierarchy = 0; }
+ else {
+ if ($hierarchy eq 1) {
+ $line =~ /^(\S*)\s*=\s*(\S*)$/;
+ unless ($1 eq "") {
+ $output = $output . "$pair_separator_front$1.DEFAULT$eq_separator$2$pair_separator_back";
+ }
+ }
+ }
+ }
+ }
+ close FILE,
+ system("rm -f $TMPDIR/subsys.INI.$$.tmp");
+ }
+ print $output;
+}
+else {
+# Listed subsystems
+ while ($module = shift) {
+ chomp($module);
+ #Clean possible trailing '/' (even multiple occurrences :-) from module name
+ $module=~s/\/+$//;
+
+ $module=~/\.([^\.]+?)$/;
+
+ @modules=split(/\s+/, `PATH=\$PATH:./:./org.glite.lb configure --listmodules $1`);
+
+ foreach $m (@modules) {
+ GetDefault ($m);
+ }
+ }
+} }
+
+if (defined $opt_p) { printf "\n"; }
# : /cvs/glite/org.glite.lb/project/version.properties,v 1.164 2008/01/09 15:35:55 mmulac Exp $
-module.version=2.1.7
+module.version=2.1.13
module.age=1
PSQL_CPPFLAGS:=-I${postgresql_prefix}/include -I${postgresql_prefix}/include/postgresql
-CFLAGS:= \
+CFLAGS:= ${CFLAGS} \
${DEBUG} \
-DVERSION=\"${version}\" \
-I${stagedir}/include -I${top_srcdir}/src -I. \
TEST_LIBS:=-L${cppunit_prefix}/${libdir} -lcppunit
TEST_INC:=-I${cppunit_prefix}/include
-LDFLAGS:=-L${stagedir}/${libdir} ${COVERAGE_FLAGS}
+LDFLAGS:=${LDFLAGS} -L${stagedir}/${libdir} ${COVERAGE_FLAGS}
COMPILE:=libtool --mode=compile ${CC} ${CFLAGS}
COMPILEXX:=libtool --mode=compile ${CXX} ${CFLAGS}
compile: libglite_lbu_db.la
check: timezone
- ./timezone
+ LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${log4c_prefix}/${libdir} ./timezone
test_coverage:
-mkdir coverage
clean:
rm -rvf *.o *.lo *.loT .libs lib* *.c *.h *.dox C/ CPP/
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
rm -rvf db_expire db_test db_test_mysql db_test_psql timezone
db-mysql.o db-mysql.lo: db-mysql.c
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.harvester' => [ qw// ],
'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
%obsoletes = (
'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
);
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
+ vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
+ );
};
sub mode_etics {
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
};
for (@{$obsoletes{"$subsys.$module"}}) {
print C "package.obsoletes = $_\n";
print C "package.replaces = $_\n";
}
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+
print C qq{
[Platform-default:DynamicDependency]
};
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
2.0.2-1
- Fixed timezone handling
+2.0.3-1
+- More timezone handling fixes and optimization
+- Unit test
+
+2.0.3-2
+- Module rebuilt
+
+2.0.4-1
+- Fixed target 'clean' in the Makefile
+
+2.0.4-2
+- Module rebuilt
+
: /cvs/jra1mw/org.glite.lbjp-common.db/project/version.properties,v 1.2 2009/01/21 10:44:34 zsustr Exp $
-module.version=2.0.2
-module.age=1
+module.version=2.0.4
+module.age=2
# DEBUG:=${DEBUG} -DCHECK_GSOAP_VERSION
#endif
-CFLAGS:= ${DEBUG} \
+CFLAGS:= ${CFLAGS} ${DEBUG} \
-DVERSION=\"${version}\" \
-DWITH_NONAMESPACES \
-I. -I${top_srcdir}/interface \
-I${stagedir}/include \
${COVERAGE_FLAGS} -D_GNU_SOURCE -DDATAGRID_EXTENSION -DWITH_IPV6
-LDFLAGS:=${COVERAGE_FLAGS}
+LDFLAGS:=${LDFLAGS} ${COVERAGE_FLAGS}
COMPILE:=libtool --mode=compile ${CC} ${CFLAGS}
COMPILEXX:=libtool --mode=compile ${CXX} ${CFLAGS}
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
'gridsite' => [ qw/apache shared commands core/ ],
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
%obsoletes = (
'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
);
%cvs_prefix = (
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
+ vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
if ($branch) {
$conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
$conftag = $branch;
- $age = '0dev'; }
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
$conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
$defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
}
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
+
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
DEBUG:=-g -O0 -W -Wall -Wno-unused-parameter
# not for globus, gsoap: -Werror
-CFLAGS:= ${DEBUG} \
+CFLAGS:= ${CFLAGS} ${DEBUG} \
-DVERSION=\"${version}\" \
-I. -I${top_srcdir}/interface \
-I${stagedir}/include \
${COVERAGE_FLAGS} -D_GNU_SOURCE -DDATAGRID_EXTENSION
-LDFLAGS:=${COVERAGE_FLAGS}
+LDFLAGS:=${LDFLAGS} ${COVERAGE_FLAGS}
COMPILE:=libtool --mode=compile ${CC} ${CFLAGS}
LINK:=libtool --mode=link ${CC} -rpath ${stagedir}/${libdir} ${LDFLAGS}
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
'gridsite' => [ qw/apache shared commands core/ ],
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
%obsoletes = (
'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
);
%cvs_prefix = (
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
+ vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
if ($branch) {
$conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
$conftag = $branch;
- $age = '0dev'; }
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
$conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
$defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
}
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
+
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
VPATH=${top_srcdir}/src:${top_srcdir}/test:${top_srcdir}/project:${jpproject}
DEBUG:=-g -O0 -W -Wno-sign-compare
-CFLAGS:=${DEBUG} -D_GNU_SOURCE -I. -I${top_srcdir}/interface -I${stagedir}/include
+CFLAGS:=${CFLAGS} ${DEBUG} -D_GNU_SOURCE -I. -I${top_srcdir}/interface -I${stagedir}/include
# In order to use libtool versioning correcty, we must have:
#
clean:
rm -rvf *.o *.lo .libs lib*
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
+ rm -vf type_test type_test.xml
rm -f glite jp
%.thr.lo: %.c
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.ws-interface' => [],
'lb.ws-test' => [ qw/gsoap:B/ ],
'lb.types' => [ qw// ],
- 'lb.harvester' => [ qw/postgresql:R/ ],
- 'lb.yaim' => [ qw/glite-yaim-core:R/ ],
+ 'lb.harvester' => [ qw// ],
+ 'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
jpclient => 'jp.client',
);
+%obsoletes = (
+ 'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
+);
+
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_version=>'glite-version',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
+ yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
- 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema/],
+ vdt=>[qw/globus globus_essentials myproxy/],
+ 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
+ );
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
);
};
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
+};
+ for (@{$obsoletes{"$subsys.$module"}}) {
+ print C "package.obsoletes = $_\n";
+ print C "package.replaces = $_\n";
+ }
-[Platform-default:DynamicDependency]
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+ print C qq{
+[Platform-default:DynamicDependency]
};
for (@{$need_externs{"$subsys.$module"}},@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
2.0.0-1
- Fixed library version numbering
+2.0.1-1
+- Fixed target 'clean' in the Makefile
+
+2.0.2-1
+- Fixed target 'clean' in the Makefile
+- Fixed format of the package description file
+
+2.0.2-2
+- Module rebuilt
+
-Definiton of interfaces required to build plugins for JP services
-and implementation of minimal library of support functions.
+Definiton of interfaces required to build plugins for JP services and implementation of minimal library of support functions.
#: /cvs/jra1mw/org.glite.lbjp-common.jp-interface/project/version.properties,v 1.1.1.1 2009/01/21 14:43:52 zsustr Exp $
-module.version=2.0.0
-module.age=1
+module.version=2.0.2
+module.age=2
DEBUG:=-g -O0 -W -Wall
-CFLAGS:= \
+CFLAGS:= ${CFLAGS} \
${DEBUG} \
-I${stagedir}/include -I${top_srcdir}/src \
-I${top_srcdir}/interface \
${LOG4C_CFLAGS}
-LDFLAGS:=-L${stagedir}/${libdir}
+LDFLAGS:=${LDFLAGS} -L${stagedir}/${libdir}
COMPILE:=libtool --mode=compile ${CC} ${CFLAGS}
LINK:=libtool --mode=link ${CC} -rpath ${stagedir}/${libdir} ${LDFLAGS}
clean:
rm -rvf *.o *.lo .libs lib*
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
check:
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.harvester' => [ qw// ],
'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
%obsoletes = (
'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
);
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
+ vdt=>[qw/globus globus_essentials myproxy/],
'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
);
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
+ );
};
sub mode_etics {
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
};
for (@{$obsoletes{"$subsys.$module"}}) {
print C "package.obsoletes = $_\n";
print C "package.replaces = $_\n";
}
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+
print C qq{
[Platform-default:DynamicDependency]
};
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
1.0.2-1
- A new logging category added for notification interlogger
+1.0.2-2
+- Module rebuilt
+
+1.0.3-1
+- Fixed target 'clean' in the Makefile
+
+1.0.3-2
+- Module rebuilt
+
# $Header$
-module.version=1.0.2
-module.age=1
+module.version=1.0.3
+module.age=2
DEBUG:=-g -O0 -W -Wall
-CFLAGS:= \
+CFLAGS:= ${CFLAGS} \
${DEBUG} \
-DVERSION=\"${version}\" \
-I${stagedir}/include -I${top_srcdir}/src -I. \
${COVERAGE_FLAGS} \
-D_GNU_SOURCE
-LDFLAGS:=-L${stagedir}/${libdir} ${COVERAGE_FLAGS}
+LDFLAGS:=${LDFLAGS} -L${stagedir}/${libdir} ${COVERAGE_FLAGS}
COMPILE:=libtool --mode=compile ${CC} ${CFLAGS}
LINK:=libtool --mode=link ${CC} -rpath ${stagedir}/${libdir} ${LDFLAGS}
clean:
rm -rvf *.o *.lo .libs lib* *.c *.h *.dox C/ CPP/
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
%.o %.lo: %.c
${COMPILE} -c $<
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.ws-interface' => [],
'lb.ws-test' => [ qw/gsoap:B/ ],
'lb.types' => [ qw// ],
- 'lb.harvester' => [ qw/postgresql:R/ ],
- 'lb.yaim' => [ qw/glite-yaim-core:R/ ],
+ 'lb.harvester' => [ qw// ],
+ 'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
- 'lbjp-common.jp-interface' => [ qw/cppunit:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
jpclient => 'jp.client',
);
+%obsoletes = (
+ 'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
+);
+
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_version=>'glite-version',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
+ yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
- 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema/],
+ vdt=>[qw/globus globus_essentials myproxy/],
+ 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
+ );
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
);
};
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
+};
+ for (@{$obsoletes{"$subsys.$module"}}) {
+ print C "package.obsoletes = $_\n";
+ print C "package.replaces = $_\n";
+ }
-[Platform-default:DynamicDependency]
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+ print C qq{
+[Platform-default:DynamicDependency]
};
for (@{$need_externs{"$subsys.$module"}},@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
- Fixed library version numbering
- Improved portability
+2.0.0-2
+- Module rebuilt
+
+2.0.1-1
+- Fixed target 'clean' in the Makefile
+
+2.0.1-2
+- Module rebuilt
+
# : /cvs/jra1mw/org.glite.lbjp-common.maildir/project/version.properties,v 1.1 2007/11/01 20:17:45 valtri Exp $
-module.version=2.0.0
-module.age=1
+module.version=2.0.1
+module.age=2
VPATH=${top_srcdir}/src:${top_srcdir}/examples
DEBUG:=-g -O0 -Wall
-CFLAGS:= ${DEBUG} \
+CFLAGS:= ${CFLAGS} ${DEBUG} \
-I${top_srcdir}/interface \
-I${stagedir}/include \
-D_GNU_SOURCE
-LDFLAGS:=-L${stagedir}/${libdir}
+LDFLAGS:=${LDFLAGS} -L${stagedir}/${libdir}
ifdef LB_PROF
CFLAGS:= ${CFLAGS} -pg -g
clean:
rm -rvf *.o *.lo .libs lib* srv_example cnt_example
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
%.o: %.c
${COMPILE} -c $<
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.ws-interface' => [],
'lb.ws-test' => [ qw/gsoap:B/ ],
'lb.types' => [ qw// ],
- 'lb.harvester' => [ qw/postgresql:R/ ],
- 'lb.yaim' => [ qw/glite-yaim-core:R/ ],
+ 'lb.harvester' => [ qw// ],
+ 'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
- 'lbjp-common.jp-interface' => [ qw/cppunit:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
jpclient => 'jp.client',
);
+%obsoletes = (
+ 'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
+);
+
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_version=>'glite-version',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
+ yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
- 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema/],
+ vdt=>[qw/globus globus_essentials myproxy/],
+ 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
+ );
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
);
};
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
+};
+ for (@{$obsoletes{"$subsys.$module"}}) {
+ print C "package.obsoletes = $_\n";
+ print C "package.replaces = $_\n";
+ }
-[Platform-default:DynamicDependency]
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+ print C qq{
+[Platform-default:DynamicDependency]
};
for (@{$need_externs{"$subsys.$module"}},@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
- Improved portability
- IPv6 compliance
+2.0.0-2
+- Module rebuilt
+
+2.0.1-1
+- Fixed format of the package description file
+- Fixed target 'clean' in the Makefile
+
+2.0.1-2
+- Module rebuilt
+
-Multi-process network server.
-A server listening on multiple ports, passing inbound requests to slaves and maintaining connections to specific slaves if possible. The library provides callback handles on connection init, incoming request, etc.
+Multi-process network server. A server listening on multiple ports, passing inbound requests to slaves and maintaining connections to specific slaves if possible. The library provides callback handles on connection init, incoming request, etc.
# : /cvs/jra1mw/org.glite.lbjp-common.server-bones/project/version.properties,v 1.2 2009/01/21 10:44:34 zsustr Exp $
-module.version=2.0.0
-module.age=1
+module.version=2.0.1
+module.age=2
sendiov.iov_base = sendbuf;
sendiov.iov_len = sizeof(sendbuf);
+ memset(buf, 0, sizeof(buf));
msg.msg_control = buf;
msg.msg_controllen = sizeof buf;
DEBUG:=-g -O0 -Wall
-CFLAGS:=${DEBUG} -I${top_srcdir}/src -I${top_srcdir}/interface -I. -DDATAGRID_EXTENSION
+CFLAGS:=${CFLAGS} ${DEBUG} -I${top_srcdir}/src -I${top_srcdir}/interface -I. -DDATAGRID_EXTENSION
COMPILE:=libtool --mode=compile ${CC}
LINK:=libtool --mode=link ${CC} -rpath ${stagedir}/${libdir} ${LDFLAGS}
trio_test: trio_test.cpp
${CXX} -c ${CFLAGS} ${TEST_INC} $<
${LINKXX} -o $@ trio_test.o ${LTLIB} ${TEST_LIBS}
-
dist: distsrc distbin
clean:
rm -rvf *.o *.lo .libs lib* *.c *.h *.dox C/ CPP/
- rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/
+ rm -vf trio_test
+ rm -rvf log.xml project/ rpmbuild/ RPMS/ tgz/ debian/
%.o: %.c
${COMPILE} ${CFLAGS} -c $<
my $jobid_tag = '';
my $libdir = getlibdir();
-my @nodes = qw/client server logger utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
+my @nodes = qw/client server logger logger-msg utils client-java doc ws-test db jpprimary jpindex jpclient harvester/;
my %enable_nodes;
my %disable_nodes;
cppunit => '/usr',
expat => '/usr',
globus => '/opt/globus',
+ myproxy => '/opt/myproxy',
gsoap => '/usr',
mysql => '/usr',
'mysql-devel' => '',
libtar => '/usr',
axis => '/usr',
log4c => '/usr',
- postgresql => '/usr'
+ postgresql => '/usr',
+ activemq => '/opt/activemq-cpp-library',
+ apr => '/opt/apr',
+ aprutil => '/opt/apr-util'
);
my %jar = (
- 'commons-codec' => '/usr/share/java/commons-codec.jar',
- 'commons-lang' => '/usr/share/java/commons-lang.jar',
+ 'jakarta-commons-codec' => '/usr/share/java/commons-codec.jar',
+ 'jakarta-commons-lang' => '/usr/share/java/commons-lang.jar',
);
my %extranodmod;
my %deps;
my %deps_type;
-my %topbuild;
+my %buildroot;
my %lbmodules = (
- 'lb' => [ qw/client client-java common doc logger server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
- 'security' => [qw/gss gsoap-plugin/],
- 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface/],
+ 'lb' => [ qw/client client-java common doc logger logger-msg server state-machine types utils ws-interface ws-test harvester yaim glite-LB/],
+ 'security' => [qw/proxyrenewal/],
+ 'lbjp-common' => [qw/db log maildir server-bones trio jp-interface gss gsoap-plugin/],
'jobid' => [qw/api-c api-cpp api-java/],
'jp' => [ qw/client doc index primary server-common ws-interface/ ],
+ 'gridsite' => [ qw/apache shared commands core/ ],
);
for (@modules) {
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
- print MAK "\tcd $full$build && \${MAKE} clean\n"
+ print MAK "\tcd $full/$buildroot{$_} && \${MAKE} clean\n"
}
print MAK "\ndistclean:\n";
for (@modules) {
my $full = full($_);
- print MAK $topbuild{$_} ?
- "\tcd $full$build && \${MAKE} distclean\n" :
- "\trm -rf $full$build\n"
+ print MAK $buildroot{$_} eq '' ?
+ "\tcd $full && \${MAKE} distclean\n" :
+ "\trm -rf $full/$buildroot{$_}\n"
}
print MAK "\n";
my @dnames = $module ? () : keys %ldeps;
my $full = full($_);
- my $build = $topbuild{$_} ? '': '/build';
+ my $build = $buildroot{$_};
- print MAK "$_: @dnames\n\tcd $full$build && \${MAKE} && \${MAKE} install\n\n";
+ print MAK "$_: @dnames\n\tcd $full/$build && \${MAKE} && \${MAKE} install\n\n";
}
close MAK;
'lb.common' => [ qw/expat cares:B cppunit:B classads/ ],
'lb.doc' => [],
'lb.logger' => [ qw/cppunit:B/ ],
+ 'lb.logger-msg' => [ qw/cppunit:B activemq apr aprutil/ ],
'lb.server' => [ qw/globus_essentials:R globus:B expat cares mysql:R mysql-server:R mysql-devel:B cppunit:B gsoap:B classads voms lcas gridsite/ ],
'lb.state-machine' => [ qw/classads/ ],
'lb.utils' => [ qw/cppunit:B/ ],
'lb.ws-interface' => [],
'lb.ws-test' => [ qw/gsoap:B/ ],
'lb.types' => [ qw// ],
- 'lb.harvester' => [ qw/postgresql:R/ ],
- 'lb.yaim' => [ qw/glite-yaim-core:R/ ],
+ 'lb.harvester' => [ qw// ],
+ 'lb.yaim' => [ qw/yaim_core:R/ ],
'lb.glite-LB' => [ qw/fetchcrl:R gpt:R gip_release:R gip_service:R bdii:R glite_version:R glite_info_templates:R glue_schema:R/ ],
- 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B/ ],
+ 'lbjp-common.db' => [ qw/mysql:B mysql-devel:B postgresql:B cppunit:B log4c:B/ ],
'lbjp-common.log' => [ qw/log4c/ ],
'lbjp-common.maildir' => [ qw// ],
'lbjp-common.server-bones' => [ qw// ],
'lbjp-common.trio' => [ qw/cppunit:B/ ],
- 'lbjp-common.jp-interface' => [ qw/cppunit:B/ ],
- 'security.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
- 'security.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'lbjp-common.jp-interface' => [ qw/cppunit:B log4c:B/ ],
+ 'lbjp-common.gss' => [ qw/globus_essentials:R globus:B cares cppunit:B/ ],
+ 'lbjp-common.gsoap-plugin' => [ qw/cppunit:B globus_essentials:R globus:B cares:B gsoap:B/ ],
+ 'security.proxyrenewal' => [ qw/voms globus:B myproxy/ ],
'jobid.api-c' => [ qw/cppunit:B/ ],
'jobid.api-cpp' => [ qw/cppunit:B/ ],
'jobid.api-java' => [ qw/ant:B jdk:B/ ],
'jp.primary' => [ qw/classads gsoap libtar globus_essentials:R globus:B/ ],
'jp.server-common' => [],
'jp.ws-interface' => [],
+ 'gridsite.core' => [qw/httpd-devel:B gsoap:B globus:B/ ],
);
for my $ext (keys %need_externs_aux) {
}
%need_jars = (
- 'jobid.api-java' => [ qw/commons-codec/ ],
- 'lb.client-java' => [ qw/commons-lang/ ],
+ 'jobid.api-java' => [ qw/jakarta-commons-codec/ ],
+ 'lb.client-java' => [ qw/jakarta-commons-lang/ ],
);
for my $jar (keys %need_jars) {
lb.types:B lb.common
lbjp-common.trio
jobid.api-cpp:B jobid.api-c
- security.gss
+ lbjp-common.gss
/ ],
'lb.client-java' => [ qw/
lb.types:B
/ ],
'lb.common' => [ qw/
jobid.api-cpp:B jobid.api-c
- lb.types:B lbjp-common.trio security.gss
+ lb.types:B lbjp-common.trio lbjp-common.gss
/ ],
'lb.doc' => [ qw/lb.types:B/ ],
'lb.logger' => [ qw/
lbjp-common.log
jobid.api-c
lb.common
- security.gss
+ lbjp-common.gss
+ / ],
+ 'lb.logger-msg' => [ qw/
+ lb.logger
/ ],
'lb.server' => [ qw/
lb.ws-interface lb.types:B lb.common lb.state-machine
lbjp-common.db lbjp-common.server-bones lbjp-common.trio lbjp-common.maildir lbjp-common.log
jobid.api-c
- security.gsoap-plugin security.gss
+ lbjp-common.gsoap-plugin lbjp-common.gss
/ ],
- 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface security.gss/ ],
+ 'lb.state-machine' => [ qw/lb.types:B lb.common lbjp-common.jp-interface lbjp-common.gss/ ],
'lb.utils' => [ qw/
lbjp-common.jp-interface
jobid.api-c
lbjp-common.trio lbjp-common.maildir
lb.client lb.state-machine
/ ],
- 'lb.ws-test' => [ qw/security.gsoap-plugin lb.ws-interface/ ],
+ 'lb.ws-test' => [ qw/lbjp-common.gsoap-plugin lb.ws-interface/ ],
'lb.ws-interface' => [ qw/lb.types:B/ ],
'lb.types' => [ qw// ],
'lb.harvester' => [ qw/
jobid.api-c lbjp-common.trio lbjp-common.db lb.common lb.client
- security.gss lbjp-common.log
+ lbjp-common.gss lbjp-common.log
/ ],
'lb.yaim' => [ qw// ],
'lb.glite-LB' => [ qw/
lb.logger:R lb.server:R lb.utils:R lb.doc:R
- lb.ws-test:R lb.harvester:R lb.yaim:R
+ lb.ws-test:R lb.harvester:R lb.yaim:R lb.client-java:R
/ ],
'lbjp-common.db' => [ qw/lbjp-common.trio lbjp-common.log/ ],
'lbjp-common.maildir' => [ qw// ],
+ 'lbjp-common.log' => [ qw// ],
'lbjp-common.server-bones' => [ qw/lbjp-common.log/ ],
'lbjp-common.trio' => [ qw// ],
- 'security.gss' => [ qw// ],
- 'security.gsoap-plugin' => [ qw/security.gss/ ],
+ 'lbjp-common.gss' => [ qw// ],
+ 'lbjp-common.gsoap-plugin' => [ qw/lbjp-common.gss/ ],
+ 'security.proxyrenewal' => [ qw// ],
'jobid.api-c' => [ qw// ],
'jobid.api-cpp' => [ qw/jobid.api-c/ ],
'jobid.api-java' => [ qw// ],
jp.ws-interface
lbjp-common.jp-interface lbjp-common.maildir
jobid.api-c
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.doc' => [ qw// ],
'jp.index' => [ qw/
jp.server-common jp.ws-interface
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.primary' => [ qw/
jobid.api-c
jp.server-common jp.ws-interface
lb.state-machine
lbjp-common.jp-interface lbjp-common.trio lbjp-common.db lbjp-common.server-bones
- security.gsoap-plugin
+ lbjp-common.gsoap-plugin
/ ],
'jp.server-common' => [ qw/
lbjp-common.jp-interface lbjp-common.db
/ ],
'jp.ws-interface' => [ qw// ],
+
+ 'gridsite.core' => [ qw/build.common-cpp:B/ ],
);
for my $ext (keys %deps_aux) {
jpclient => 'jp.client',
);
+%obsoletes = (
+ 'lb.yaim' => [ qq/glite-yaim-lb/ ],
+ 'lbjp-common.gss' => [ qq/glite-security-gss/ ],
+ 'lbjp-common.gsoap-plugin' => [ qq/glite-security-gsoap-plugin/ ],
+);
+
+%cvs_prefix = (
+ 'lb' => 'org.glite',
+ 'jp' => 'org.glite',
+ 'jobid' => 'org.glite',
+ 'lbjp-common' => 'org.glite',
+ 'gridsite' => 'org',
+ 'security' => 'org.glite',
+);
+
+%conf_prefix = (
+ 'lb' => 'glite-',
+ 'jp' => 'glite-',
+ 'jobid' => 'glite-',
+ 'lbjp-common' => 'glite-',
+ 'gridsite' => '',
+ 'security' => 'glite-',
+);
+
+my @k = keys %deps_aux;
+@buildroot{@k} = ('build') x ($#k+1);
+
my @t = qw/lb.client-java jobid.api-java lb.types/;
-@topbuild{@t} = (1) x ($#t+1);
+@buildroot{@t} = ('') x ($#t+1);
+
+$buildroot{'gridsite.core'} = 'src';
}
sub full
my %aux;
undef %aux;
my @m=qw/
-lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim
-security.gss security.gsoap-plugin
+lb.client lb.doc lb.state-machine lb.ws-interface lb.logger lb.logger-msg lb.types lb.common lb.server lb.utils lb.ws-test lb.client-java lb.harvester lb.yaim lb.glite-LB
+lbjp-common.gss lbjp-common.gsoap-plugin
jobid.api-c jobid.api-cpp jobid.api-java
lbjp-common.db lbjp-common.log lbjp-common.maildir lbjp-common.server-bones lbjp-common.trio lbjp-common.jp-interface
jp.client jp.doc jp.index jp.primary jp.server-common jp.ws-interface
my $build = '';
- unless ($topbuild{$_}) {
- $build = '/build';
- unless (-d "$full/build") {
- mkdir "$full/build" or die "mkdir $full/build: $!\n";
+ unless ($buildroot{$_} eq '') {
+ $build = "/$buildroot{$_}";
+ unless (-d "$full/$buildroot{$_}") {
+ mkdir "$full/$buildroot{$_}" or die "mkdir $full/$buildroot{$_}: $!\n";
}
- unlink "$full/build/Makefile";
- symlink "../Makefile","$full/build/Makefile" or die "symlink ../Makefile $full/build/Makefile: $!\n";
+ unlink "$full/$buildroot{$_}/Makefile";
+ symlink "../Makefile","$full/$buildroot{$_}/Makefile" or die "symlink ../Makefile $full/$buildroot{$_}/Makefile: $!\n";
}
- open MKINC,">$full$build/Makefile.inc"
- or die "$full$build/Makefile.inc: $!\n";
+ open MKINC,">$full/$buildroot{$_}/Makefile.inc"
+ or die "$full/$buildroot{$_}/Makefile.inc: $!\n";
- print "Creating $full$build/Makefile.inc\n";
+ print "Creating $full/$buildroot{$_}/Makefile.inc\n";
print MKINC qq{
PREFIX = $prefix
%etics_externs = (
globus_essentials=>'vdt_globus_essentials',
globus=>'globus',
+ myproxy=>'myproxy',
cares=>'c-ares',
voms=>'org.glite.security.voms-api-cpp',
gridsite=>'org.gridsite.shared',
glite_version=>'glite-version',
glite_info_templates=>'glite-info-templates',
glue_schema=>'glue-schema',
+ yaim_core=>'org.glite.yaim.core',
+ activemq=>'activemq-cpp-library',
+ apr=>'apr-dev',
+ aprutil=>'aprutil-dev',
);
%etics_projects = (
- vdt=>[qw/globus globus_essentials/],
- 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema/],
+ vdt=>[qw/globus globus_essentials myproxy/],
+ 'org.glite'=>[qw/voms gridsite lcas gpt gip_release gip_service bdii glite_version glite_info_templates glue_schema yaim_core/],
+ );
+
+ %platform_properties = (
+ 'gridsite.core' => {
+ sl5_x86_64_gcc412 => { aprSuffix => '1' },
+ sl5_ia32_gcc412 => { aprSuffix => '1' },
+ deb5_x86_64_gcc432 => { aprSuffix => '1.0' },
+ deb5_ia32_gcc432 => { aprSuffix => '1.0' },
+ slc4_x86_64_gcc346 => { aprSuffix => '0' },
+ slc4_ia32_gcc346 => { aprSuffix => '0' },
+ default => {
+ }
+ },
);
};
($major,$minor,$rev,$age) = ($1,$2,$3,$4);
}
else {
- open V,"org.glite.$subsys.$module/project/version.properties"
- or die "org.glite.$subsys.$module/project/version.properties: $!\n";
+ open V,"$cvs_prefix{$subsys}.$subsys.$module/project/version.properties"
+ or die "$cvs_prefix{$subsys}.$subsys.$module/project/version.properties: $!\n";
while ($_ = <V>) {
chomp;
for (@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
- push @copts,"--with-$_ \${$eext.location}/$_*.jar";
+ push @copts,"--with-$_ \${$eext.location}/usr/share/java/$_*.jar";
}
my $conf;
my $conftag;
+ $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n";
if ($branch) {
- $conf = "glite-${subsys}-${module}_$branch";
- $conftag = $branch;
- $dwpath = ""; }
+ $conf = "$conf_prefix{$subsys}${subsys}-${module}_$branch";
+ $conftag = $branch;
+ # forced low age number
+ $age = $branch eq 'HEAD' ? '0head' : '0dev'; }
else {
- $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
- $conftag = $conf;
- $dwpath = "path = \${projectName}/\${moduleName}/\${version}/\${platformName}/\${packageName}-\${version}-\${age}.tar.gz\n"; }
-# my $conf = "glite-$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+ $conf = "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}_${age}";
+
+# XXX: gridsite hack
+ $conftag = $subsys eq 'gridsite' ? "$conf_prefix{$subsys}$subsys-${module}_R_${major}_${minor}_${rev}" : $conf; }
my $file = $output ? $output : "$conf.ini";
open C,">$file" or die "$file: $!\n";
- my $buildroot = $topbuild{"$subsys.$module"} ? '' : "build.root = build";
+ my $buildroot = $buildroot{"$subsys.$module"} eq '' ? '#no build.root' : "build.root = " . $buildroot{"$subsys.$module"};
- my $confdir = $topbuild{"$subsys.$module"} ? '..' : '../..';
+ my $confdir = $buildroot{"$subsys.$module"} eq '' ? '..' : '../..';
my $package_description = "";
my $package_summary = "";
- if (-e "org.glite.$subsys.$module/project/package.description") {
- open V, "org.glite.$subsys.$module/project/package.description";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.description") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.description";
$package_description = join ("", <V>);
close V;
chomp $package_description;
$package_description =~ s/\n/\\n/g;
- $package_description = "package.description = $package_description";
+ $package_description = "package.description = $package_description\n";
}
else {
print STDERR "package.description not found for $subsys.$module!\n"; }
- if (-e "org.glite.$subsys.$module/project/package.summary") {
- open V, "org.glite.$subsys.$module/project/package.summary";
+ if (-e "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary") {
+ open V, "$cvs_prefix{$subsys}.$subsys.$module/project/package.summary";
$package_summary = join ("", <V>);
close V;
chomp $package_summary;
$package_summary =~ s/\n/\\n/g;
- $package_summary = "package.summary = $package_summary";
+ $package_summary = "package.summary = $package_summary\n";
}
else {
print STDERR "package.summary not found for $subsys.$module!\n"; }
+ my %cmd;
+ @cmd{qw/configure compile test install packaging clean/} = ('None') x 6;
+ $cmd{clean} = 'make clean';
+
+ if ($subsys eq 'gridsite') {
+ if ($module eq 'core') {
+ my $flags = 'RELEASE_VERSION=${age}.${platformFamily} prefix=${prefix} libdir=${libdir} GSOAPDIR=${gsoap.location} OPENSSL_GLOBUS_FLAGS=-I${globus.location}/include/${globus.dbg.nothr.flavor} OPENSSL_GLOBUS_LIBS=-L${globus.location}/${libdir}/ FLAVOR_GLOBUS_EXT=_${globus.dbg.nothr.flavor} HTTPD_FLAGS="-I${httpd-devel.location}/include/httpd -I${httpd-devel.location}/include/apache2 -I${httpd-devel.location}/include/apr-${aprSuffix} -I${httpd-devel.location}/include/pcre"';
+
+ $cmd{compile} = "make $flags build";
+ $cmd{install} = "make $flags install";
+ $cmd{packaging} = "make $flags rpm";
+ }
+ else {
+ $cmd{packaging} = "echo building nothing, org.gridsite.core make rpm step will create this";
+ }
+ }
+ else {
+ $cmd{configure} = "cd $confdir && /usr/bin/perl \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts";
+ $cmd{compile} = 'make';
+ $cmd{test} = 'make check';
+ $cmd{install} = 'make install';
+ }
+
+ my $defprops = '';
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{default}}) {
+ $defprops .= $p . ' = ' . $platform_properties{"$subsys.$module"}->{default}->{$p} . "\n";
+ }
+
+ my $checkoutcmd;
+ if ($conftag eq 'HEAD') {
+ $checkoutcmd = "cvs -d \${vcsroot} co -A \${moduleName}";
+ } else {
+ $checkoutcmd = "cvs -d \${vcsroot} co -r \${tag} \${moduleName}";
+ }
print STDERR "Writing $file\n";
print C qq{
[Configuration-$conf]
profile = None
-moduleName = org.glite.$subsys.$module
+moduleName = $cvs_prefix{$subsys}.$subsys.$module
displayName = $conf
-description = org.glite.$subsys.$module
+description = $cvs_prefix{$subsys}.$subsys.$module
projectName = org.glite
age = $age
deploymentType = None
tag = cvs -d \${vcsroot} tag -R \${tag} \${moduleName}
branch = None
commit = None
-checkout = cvs -d \${vcsroot} co -r \${tag} \${moduleName}
+checkout = $checkoutcmd
[Platform-default:BuildCommand]
postpublish = None
-packaging = None
+packaging = $cmd{packaging}
displayName = None
description = None
doc = None
prepublish = None
publish = None
-compile = make
+compile = $cmd{compile}
init = None
-install = make install
-clean = make clean
-test = make check
-configure = cd $confdir && \${moduleName}/configure --thrflavour=\${globus.thr.flavor} --nothrflavour=\${globus.nothr.flavor} --prefix=\${prefix} --stage=\${stageDir} --libdir=\${libdir} --module $subsys.$module @copts
+install = $cmd{install}
+clean = $cmd{clean}
+test = $cmd{test}
+configure = $cmd{configure}
checkstyle = None
[Platform-default:Property]
$buildroot
-$package_description
-$package_summary
+aprSuffix = 0
+package.RPMSLocation = \${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = \${moduleDir}/RPMTMP/SRPMS
+$package_description$package_summary$defprops
+};
+ for (@{$obsoletes{"$subsys.$module"}}) {
+ print C "package.obsoletes = $_\n";
+ print C "package.replaces = $_\n";
+ }
-[Platform-default:DynamicDependency]
+ for my $pp (keys %{$platform_properties{"$subsys.$module"}}) {
+ next if $pp eq 'default';
+ print C "[Platform-$pp:Property]\n$buildroot\n";
+
+ for my $p (keys %{$platform_properties{"$subsys.$module"}->{$pp}}) {
+ print C $p . ' = ' . $platform_properties{"$subsys.$module"}->{$pp}->{$p} . "\n";
+ }
+ print C q{package.RPMSLocation = ${moduleDir}/RPMTMP/RPMS
+package.SRPMSLocation = ${moduleDir}/RPMTMP/SRPMS
+};
+ print C "$package_description$package_summary\n";
+ }
+ print C qq{
+[Platform-default:DynamicDependency]
};
for (@{$need_externs{"$subsys.$module"}},@{$need_jars{"$subsys.$module"}}) {
my $eext = $etics_externs{$_} ? $etics_externs{$_} : $_;
--thrflavour=flavour
--nothrflavour=flavour threaded and non-treaded flavours [gcc64dbgpthr,gcc64dbg]
--listmodules=subsys list modules of a subsystem
+ --version=maj.min.rev-age specify version here instead of reading version.properties
+ --branch=branch CVS branch/etics name suffix (HEAD, branch_2_1, ...)
--libdir=libdir typically [lib,lib64] postfix
Mode of operation:
2.0.0-1
- Fixed library version numbering
+2.0.1-1
+- Fixed target 'clean' in the Makefile
+
+2.0.2-1
+- Fixed format of the package description file
+- Fixed target 'clean' in the Makefile
+
+2.0.2-2
+- Module rebuilt
+
-Standalone extended implementation of printf and scanf. Provides specialized
-formating options used by LB and JP.
+Standalone extended implementation of printf and scanf. Provides specialized formating options used by LB and JP.
# : /cvs/jra1mw/org.glite.lbjp-common.trio/project/version.properties,v 1.2 2009/01/21 10:44:34 zsustr Exp $
-module.version=2.0.0
-module.age=1
+module.version=2.0.2
+module.age=2
# : /cvs/glite/org.glite.lbjp-common/project/version.properties,v 1.1 2009/01/21 12:57:26 akrenek Exp $
-module.version=2.0.3
-module.age=1
+module.version=2.0.5
+module.age=2