Filename | /cygdrive/c/lo/libo-master/instsetoo_native/util/C:/lo/libo-master/solenv/bin/modules/installer/windows/featurecomponent.pm |
Statements | Executed 434172 statements in 24.6s |
Calls | P | F | Exclusive Time |
Inclusive Time |
Subroutine |
---|---|---|---|---|---|
1 | 1 | 1 | 17.3s | 17.9s | create_featurecomponent_table_from_registry_collector | installer::windows::featurecomponent::
1 | 1 | 1 | 7.26s | 8.12s | create_featurecomponent_table_from_files_collector | installer::windows::featurecomponent::
15890 | 1 | 1 | 123ms | 123ms | CORE:subst (opcode) | installer::windows::featurecomponent::
1 | 1 | 1 | 3.71ms | 26.1s | create_featurecomponent_table | installer::windows::featurecomponent::
1 | 1 | 1 | 492µs | 496µs | BEGIN@30 | installer::windows::featurecomponent::
1 | 1 | 1 | 15µs | 18µs | BEGIN@31 | installer::windows::featurecomponent::
1 | 1 | 1 | 15µs | 17µs | BEGIN@33 | installer::windows::featurecomponent::
1 | 1 | 1 | 14µs | 16µs | BEGIN@32 | installer::windows::featurecomponent::
1 | 1 | 1 | 14µs | 16µs | BEGIN@34 | installer::windows::featurecomponent::
Line | State ments |
Time on line |
Calls | Time in subs |
Code |
---|---|---|---|---|---|
1 | #************************************************************************* | ||||
2 | # | ||||
3 | # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. | ||||
4 | # | ||||
5 | # Copyright 2000, 2010 Oracle and/or its affiliates. | ||||
6 | # | ||||
7 | # OpenOffice.org - a multi-platform office productivity suite | ||||
8 | # | ||||
9 | # This file is part of OpenOffice.org. | ||||
10 | # | ||||
11 | # OpenOffice.org is free software: you can redistribute it and/or modify | ||||
12 | # it under the terms of the GNU Lesser General Public License version 3 | ||||
13 | # only, as published by the Free Software Foundation. | ||||
14 | # | ||||
15 | # OpenOffice.org is distributed in the hope that it will be useful, | ||||
16 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||||
17 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||||
18 | # GNU Lesser General Public License version 3 for more details | ||||
19 | # (a copy is included in the LICENSE file that accompanied this code). | ||||
20 | # | ||||
21 | # You should have received a copy of the GNU Lesser General Public License | ||||
22 | # version 3 along with OpenOffice.org. If not, see | ||||
23 | # <http://www.openoffice.org/license.html> | ||||
24 | # for a copy of the LGPLv3 License. | ||||
25 | # | ||||
26 | #************************************************************************* | ||||
27 | |||||
28 | package installer::windows::featurecomponent; | ||||
29 | |||||
30 | 2 | 65µs | 2 | 499µs | # spent 496µs (492+4) within installer::windows::featurecomponent::BEGIN@30 which was called:
# once (492µs+4µs) by installer::BEGIN@67 at line 30 # spent 496µs making 1 call to installer::windows::featurecomponent::BEGIN@30
# spent 4µs making 1 call to UNIVERSAL::import |
31 | 2 | 56µs | 2 | 22µs | # spent 18µs (15+3) within installer::windows::featurecomponent::BEGIN@31 which was called:
# once (15µs+3µs) by installer::BEGIN@67 at line 31 # spent 18µs making 1 call to installer::windows::featurecomponent::BEGIN@31
# spent 3µs making 1 call to UNIVERSAL::import |
32 | 2 | 59µs | 2 | 19µs | # spent 16µs (14+3) within installer::windows::featurecomponent::BEGIN@32 which was called:
# once (14µs+3µs) by installer::BEGIN@67 at line 32 # spent 16µs making 1 call to installer::windows::featurecomponent::BEGIN@32
# spent 2µs making 1 call to UNIVERSAL::import |
33 | 2 | 53µs | 2 | 20µs | # spent 17µs (15+3) within installer::windows::featurecomponent::BEGIN@33 which was called:
# once (15µs+3µs) by installer::BEGIN@67 at line 33 # spent 17µs making 1 call to installer::windows::featurecomponent::BEGIN@33
# spent 2µs making 1 call to UNIVERSAL::import |
34 | 2 | 1.25ms | 2 | 19µs | # spent 16µs (14+3) within installer::windows::featurecomponent::BEGIN@34 which was called:
# once (14µs+3µs) by installer::BEGIN@67 at line 34 # spent 16µs making 1 call to installer::windows::featurecomponent::BEGIN@34
# spent 3µs making 1 call to UNIVERSAL::import |
35 | |||||
36 | ################################################################################# | ||||
37 | # Collecting all pairs of features and components from the files collector | ||||
38 | ################################################################################# | ||||
39 | |||||
40 | sub create_featurecomponent_table_from_files_collector | ||||
41 | # spent 8.12s (7.26+861ms) within installer::windows::featurecomponent::create_featurecomponent_table_from_files_collector which was called:
# once (7.26s+861ms) by installer::windows::featurecomponent::create_featurecomponent_table at line 159 | ||||
42 | 1 | 2µs | my ($featurecomponenttableref, $filesref) = @_; | ||
43 | |||||
44 | 1 | 19.6ms | for ( my $i = 0; $i <= $#{$filesref}; $i++ ) | ||
45 | { | ||||
46 | 15888 | 14.6ms | my $onefile = ${$filesref}[$i]; | ||
47 | |||||
48 | 15888 | 20.7ms | my $filecomponent = $onefile->{'componentname'}; | ||
49 | 15888 | 19.8ms | my $filemodules = $onefile->{'modules'}; | ||
50 | |||||
51 | 15888 | 7.12ms | if ( $filecomponent eq "" ) | ||
52 | { | ||||
53 | installer::exiter::exit_program("ERROR: No component defined for file $onefile->{'Name'}", "create_featurecomponent_table_from_files_collector"); | ||||
54 | } | ||||
55 | 15888 | 5.93ms | if ( $filemodules eq "" ) | ||
56 | { | ||||
57 | installer::exiter::exit_program("ERROR: No modules found for file $onefile->{'Name'}", "create_featurecomponent_table_from_files_collector"); | ||||
58 | } | ||||
59 | |||||
60 | 15888 | 56.8ms | 15888 | 170ms | my $filemodulesarrayref = installer::converter::convert_stringlist_into_array(\$filemodules, ","); # spent 170ms making 15888 calls to installer::converter::convert_stringlist_into_array, avg 11µs/call |
61 | |||||
62 | 15888 | 63.9ms | for ( my $j = 0; $j <= $#{$filemodulesarrayref}; $j++ ) | ||
63 | { | ||||
64 | 15890 | 11.5ms | my %featurecomponent = (); | ||
65 | |||||
66 | 15890 | 10.8ms | my $onemodule = ${$filemodulesarrayref}[$j]; | ||
67 | 15890 | 183ms | 15890 | 123ms | $onemodule =~ s/\s*$//; # spent 123ms making 15890 calls to installer::windows::featurecomponent::CORE:subst, avg 8µs/call |
68 | 15890 | 20.1ms | $featurecomponent{'Feature'} = $onemodule; | ||
69 | 15890 | 15.0ms | $featurecomponent{'Component'} = $filecomponent; | ||
70 | |||||
71 | # Attention: Features are renamed, because the maximum length is 38. | ||||
72 | # But in the files collector ($filesref), the original names are saved. | ||||
73 | |||||
74 | 15890 | 52.8ms | 15890 | 567ms | installer::windows::idtglobal::shorten_feature_gid(\$featurecomponent{'Feature'}); # spent 567ms making 15890 calls to installer::windows::idtglobal::shorten_feature_gid, avg 36µs/call |
75 | |||||
76 | 15890 | 20.9ms | $oneline = "$featurecomponent{'Feature'}\t$featurecomponent{'Component'}\n"; | ||
77 | |||||
78 | # control of uniqueness | ||||
79 | |||||
80 | 15890 | 6.80s | if (! grep {$_ eq $oneline} @{$featurecomponenttableref}) | ||
81 | { | ||||
82 | push(@{$featurecomponenttableref}, $oneline); | ||||
83 | } | ||||
84 | } | ||||
85 | } | ||||
86 | } | ||||
87 | |||||
88 | ################################################################################# | ||||
89 | # Collecting all pairs of features and components from the registry collector | ||||
90 | ################################################################################# | ||||
91 | |||||
92 | sub create_featurecomponent_table_from_registry_collector | ||||
93 | # spent 17.9s (17.3+659ms) within installer::windows::featurecomponent::create_featurecomponent_table_from_registry_collector which was called:
# once (17.3s+659ms) by installer::windows::featurecomponent::create_featurecomponent_table at line 161 | ||||
94 | 1 | 2µs | my ($featurecomponenttableref, $registryref) = @_; | ||
95 | |||||
96 | 1 | 25.1ms | for ( my $i = 0; $i <= $#{$registryref}; $i++ ) | ||
97 | { | ||||
98 | 17801 | 13.9ms | my $oneregistry = ${$registryref}[$i]; | ||
99 | |||||
100 | 17801 | 28.9ms | my $registrycomponent = $oneregistry->{'componentname'}; | ||
101 | 17801 | 18.2ms | my $registrymodule = $oneregistry->{'ModuleID'}; | ||
102 | |||||
103 | 17801 | 7.48ms | if ( $registrycomponent eq "" ) | ||
104 | { | ||||
105 | installer::exiter::exit_program("ERROR: No component defined for registry $oneregistry->{'gid'}", "create_featurecomponent_table_from_registry_collector"); | ||||
106 | } | ||||
107 | 17801 | 6.67ms | if ( $registrymodule eq "" ) | ||
108 | { | ||||
109 | installer::exiter::exit_program("ERROR: No modules found for registry $oneregistry->{'gid'}", "create_featurecomponent_table_from_registry_collector"); | ||||
110 | } | ||||
111 | |||||
112 | 17801 | 10.7ms | my %featurecomponent = (); | ||
113 | |||||
114 | 17801 | 20.2ms | $featurecomponent{'Feature'} = $registrymodule; | ||
115 | 17801 | 15.7ms | $featurecomponent{'Component'} = $registrycomponent; | ||
116 | |||||
117 | # Attention: Features are renamed, because the maximum length is 38. | ||||
118 | # But in the files collector ($filesref), the original names are saved. | ||||
119 | |||||
120 | 17801 | 49.7ms | 17801 | 659ms | installer::windows::idtglobal::shorten_feature_gid(\$featurecomponent{'Feature'}); # spent 659ms making 17801 calls to installer::windows::idtglobal::shorten_feature_gid, avg 37µs/call |
121 | |||||
122 | 17801 | 22.2ms | $oneline = "$featurecomponent{'Feature'}\t$featurecomponent{'Component'}\n"; | ||
123 | |||||
124 | # control of uniqueness | ||||
125 | |||||
126 | 17801 | 17.0s | if (! grep {$_ eq $oneline} @{$featurecomponenttableref}) | ||
127 | { | ||||
128 | push(@{$featurecomponenttableref}, $oneline); | ||||
129 | } | ||||
130 | } | ||||
131 | } | ||||
132 | |||||
133 | ################################################################################# | ||||
134 | # Creating the file FeatureC.idt dynamically | ||||
135 | # Content: | ||||
136 | # Feature Component | ||||
137 | ################################################################################# | ||||
138 | |||||
139 | sub create_featurecomponent_table | ||||
140 | # spent 26.1s (3.71ms+26.1) within installer::windows::featurecomponent::create_featurecomponent_table which was called:
# once (3.71ms+26.1s) by installer::run at line 1509 of /cygdrive/c/lo/libo-master/instsetoo_native/util/C:/lo/libo-master/solenv/bin/modules/installer.pm | ||||
141 | 1 | 5µs | my ($filesref, $registryref, $basedir) = @_; | ||
142 | |||||
143 | 1 | 500ns | my @featurecomponenttable = (); | ||
144 | 1 | 500ns | my $infoline; | ||
145 | |||||
146 | 1 | 7µs | 1 | 29µs | installer::windows::idtglobal::write_idt_header(\@featurecomponenttable, "featurecomponent"); # spent 29µs making 1 call to installer::windows::idtglobal::write_idt_header |
147 | |||||
148 | # This is the first time, that features and componentes are related | ||||
149 | # Problem: How about created profiles, configurationfiles, services.rdb | ||||
150 | # -> simple solution: putting them all to the root module | ||||
151 | # Otherwise profiles and configurationfiles cannot be created the way, they are now created | ||||
152 | # -> especially a problem for the configurationfiles! # ToDo | ||||
153 | # Very good: All ProfileItems belong to the root | ||||
154 | # services.rdb belongs to the root anyway. | ||||
155 | |||||
156 | # At the moment only the files are related to components (and the files know their modules). | ||||
157 | # The component for each file is written into the files collector $filesinproductlanguageresolvedarrayref | ||||
158 | |||||
159 | 1 | 7µs | 1 | 8.12s | create_featurecomponent_table_from_files_collector(\@featurecomponenttable, $filesref); # spent 8.12s making 1 call to installer::windows::featurecomponent::create_featurecomponent_table_from_files_collector |
160 | |||||
161 | 1 | 7µs | 1 | 17.9s | create_featurecomponent_table_from_registry_collector(\@featurecomponenttable, $registryref); # spent 17.9s making 1 call to installer::windows::featurecomponent::create_featurecomponent_table_from_registry_collector |
162 | |||||
163 | # Additional components have to be added here | ||||
164 | |||||
165 | # Saving the file | ||||
166 | |||||
167 | 1 | 5µs | my $featurecomponenttablename = $basedir . $installer::globals::separator . "FeatureC.idt"; | ||
168 | 1 | 7µs | 1 | 4.07ms | installer::files::save_file($featurecomponenttablename ,\@featurecomponenttable); # spent 4.07ms making 1 call to installer::files::save_file |
169 | 1 | 6µs | $infoline = "Created idt file: $featurecomponenttablename\n"; | ||
170 | 1 | 3.64ms | push(@installer::globals::logfileinfo, $infoline); | ||
171 | |||||
172 | } | ||||
173 | |||||
174 | 1 | 7µs | 1; | ||
# spent 123ms within installer::windows::featurecomponent::CORE:subst which was called 15890 times, avg 8µs/call:
# 15890 times (123ms+0s) by installer::windows::featurecomponent::create_featurecomponent_table_from_files_collector at line 67, avg 8µs/call |