diff options
author | yye00 <yye00@17b73243-c579-4c4c-a9d2-2d5706c11dac> | 2005-08-16 17:26:48 +0000 |
---|---|---|
committer | yye00 <yye00@17b73243-c579-4c4c-a9d2-2d5706c11dac> | 2005-08-16 17:26:48 +0000 |
commit | 8c8a283caecd5acddb6466c79be1513aae2fb70c (patch) | |
tree | 642b03bc32935a83799268c00a00cd65d7d754c7 /lib/sbin/CST | |
parent | 8bbd884aa6aa78bb0b60eae385f4d9ba0de92982 (diff) |
configuration.ccl fix. Please test and report if anything breaks
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4109 17b73243-c579-4c4c-a9d2-2d5706c11dac
Diffstat (limited to 'lib/sbin/CST')
-rw-r--r-- | lib/sbin/CST | 23 |
1 files changed, 13 insertions, 10 deletions
diff --git a/lib/sbin/CST b/lib/sbin/CST index e3cf03ef..894614b8 100644 --- a/lib/sbin/CST +++ b/lib/sbin/CST @@ -6,7 +6,7 @@ # @desc # Parses the the configuration files for thorns. # @enddesc -# @version $Header: /mnt/data2/cvs2svn/cvs-repositories/Cactus/lib/sbin/CST,v 1.73 2004-11-30 23:22:00 goodale Exp $ +# @version $Header: /mnt/data2/cvs2svn/cvs-repositories/Cactus/lib/sbin/CST,v 1.74 2005-08-16 17:25:52 yye00 Exp $ #@@*/ # Global parameter to track the number of errors from the CST @@ -149,7 +149,7 @@ print "Creating Thorn-Flesh bindings...\n"; &CreateLogFile($config_dir, $configuration_database,\%thorns); # Finally (must be last), create the make.thornlist file. -$make_thornlist = &CreateMakeThornlist(\%thorns, $configuration_database); +$make_thornlist = &CreateMakeThornlist(\%thorns, \%interface_database, $configuration_database); # Stop the make process if there were any errors if ($CST_errors) @@ -316,7 +316,7 @@ sub get_global_parameters sub CreateMakeThornlist { - my($thorns, $config) = @_; + my($thorns ,$interface, $config) = @_; my($thorn); my($thornlist); my($thorn_linklist); @@ -342,8 +342,7 @@ sub CreateMakeThornlist $config_thornlist .= " $1"; } } - - $thorn_linklist .= ' ' . &TopoSort(\%thorns, $config); + $thorn_linklist .= ' ' . &TopoSort($thorns, $interface, $config); $thorn_dependencies = join ("\n", &CreateThornDependencyList($thorns, $config)); return ($thornlist . "\n" . $thorn_linklist . "\n" . $config_thornlist . "\n" . $thorn_dependencies . "\n"); @@ -564,7 +563,7 @@ sub CreateBindings #@@*/ sub TopoSort { - my($thorns, $cfg)= @_; + my($thorns, $interface, $cfg)= @_; my($data) = ''; my($nouse) = ''; my $thorn; @@ -573,9 +572,13 @@ sub TopoSort foreach $thorn (sort keys %thorns) { next if ("\U$thorn\E" eq "CACTUS"); + $thorn_ancestor{"\U$thorn\E"} = ''; + foreach $ancestor_imp ( split(' ', $interface->{"\U$thorn INHERITS\E"})) + { + $thorn_ancestor{"\U$thorn\E"} .= $interface->{"IMPLEMENTATION \U$ancestor_imp\E THORNS"}. ' '; + } - my @uses_thorns = split (' ', $cfg->{"\U$thorn\E USES THORNS"}); - + my @uses_thorns = split (' ', $cfg->{"\U$thorn\E USES THORNS"} . ' ' . $thorn_ancestor{"\U$thorn\E"}); my $uses_thorns = ''; foreach (@uses_thorns) { @@ -607,8 +610,8 @@ sub TopoSort $data =~ s/dummy//; $data =~ s/ / /; } - - return $data; + +return $data; } |