| Filename | /cygdrive/c/lo/libo-master/instsetoo_native/util/C:/lo/libo-master/solenv/bin/modules/installer/copyproject.pm |
| Statements | Executed 19 statements in 1.29ms |
| Calls | P | F | Exclusive Time |
Inclusive Time |
Subroutine |
|---|---|---|---|---|---|
| 1 | 1 | 1 | 568µs | 584µs | installer::copyproject::BEGIN@30 |
| 1 | 1 | 1 | 26µs | 48µs | installer::copyproject::BEGIN@31 |
| 1 | 1 | 1 | 19µs | 22µs | installer::copyproject::BEGIN@39 |
| 1 | 1 | 1 | 18µs | 25µs | installer::copyproject::BEGIN@33 |
| 1 | 1 | 1 | 16µs | 18µs | installer::copyproject::BEGIN@38 |
| 1 | 1 | 1 | 16µs | 70µs | installer::copyproject::BEGIN@37 |
| 1 | 1 | 1 | 16µs | 18µs | installer::copyproject::BEGIN@35 |
| 1 | 1 | 1 | 15µs | 17µs | installer::copyproject::BEGIN@34 |
| 1 | 1 | 1 | 15µs | 17µs | installer::copyproject::BEGIN@36 |
| 0 | 0 | 0 | 0s | 0s | installer::copyproject::copy_project |
| 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::copyproject; | ||||
| 29 | |||||
| 30 | 2 | 119µs | 2 | 600µs | # spent 584µs (568+16) within installer::copyproject::BEGIN@30 which was called:
# once (568µs+16µs) by installer::BEGIN@38 at line 30 # spent 584µs making 1 call to installer::copyproject::BEGIN@30
# spent 16µs making 1 call to strict::import |
| 31 | 2 | 70µs | 2 | 70µs | # spent 48µs (26+22) within installer::copyproject::BEGIN@31 which was called:
# once (26µs+22µs) by installer::BEGIN@38 at line 31 # spent 48µs making 1 call to installer::copyproject::BEGIN@31
# spent 22µs making 1 call to warnings::import |
| 32 | |||||
| 33 | 2 | 57µs | 2 | 32µs | # spent 25µs (18+7) within installer::copyproject::BEGIN@33 which was called:
# once (18µs+7µs) by installer::BEGIN@38 at line 33 # spent 25µs making 1 call to installer::copyproject::BEGIN@33
# spent 7µs making 1 call to UNIVERSAL::import |
| 34 | 2 | 56µs | 2 | 20µs | # spent 17µs (15+2) within installer::copyproject::BEGIN@34 which was called:
# once (15µs+2µs) by installer::BEGIN@38 at line 34 # spent 17µs making 1 call to installer::copyproject::BEGIN@34
# spent 2µs making 1 call to UNIVERSAL::import |
| 35 | 2 | 54µs | 2 | 21µs | # spent 18µs (16+3) within installer::copyproject::BEGIN@35 which was called:
# once (16µs+3µs) by installer::BEGIN@38 at line 35 # spent 18µs making 1 call to installer::copyproject::BEGIN@35
# spent 2µs making 1 call to UNIVERSAL::import |
| 36 | 2 | 53µs | 2 | 20µs | # spent 17µs (15+3) within installer::copyproject::BEGIN@36 which was called:
# once (15µs+3µs) by installer::BEGIN@38 at line 36 # spent 17µs making 1 call to installer::copyproject::BEGIN@36
# spent 2µs making 1 call to UNIVERSAL::import |
| 37 | 2 | 59µs | 2 | 123µs | # spent 70µs (16+53) within installer::copyproject::BEGIN@37 which was called:
# once (16µs+53µs) by installer::BEGIN@38 at line 37 # spent 70µs making 1 call to installer::copyproject::BEGIN@37
# spent 53µs making 1 call to Exporter::import |
| 38 | 2 | 86µs | 2 | 20µs | # spent 18µs (16+2) within installer::copyproject::BEGIN@38 which was called:
# once (16µs+2µs) by installer::BEGIN@38 at line 38 # spent 18µs making 1 call to installer::copyproject::BEGIN@38
# spent 2µs making 1 call to UNIVERSAL::import |
| 39 | 2 | 727µs | 2 | 24µs | # spent 22µs (19+3) within installer::copyproject::BEGIN@39 which was called:
# once (19µs+3µs) by installer::BEGIN@38 at line 39 # spent 22µs making 1 call to installer::copyproject::BEGIN@39
# spent 3µs making 1 call to UNIVERSAL::import |
| 40 | |||||
| 41 | #################################################### | ||||
| 42 | # Including header files into the logfile | ||||
| 43 | #################################################### | ||||
| 44 | |||||
| 45 | sub copy_project | ||||
| 46 | { | ||||
| 47 | my ( $filesref, $scpactionsref, $loggingdir, $languagestringref, $shipinstalldir, $allsettingsarrayref ) = @_; | ||||
| 48 | |||||
| 49 | # Creating directories | ||||
| 50 | |||||
| 51 | installer::logger::include_header_into_logfile("Creating installation directory"); | ||||
| 52 | |||||
| 53 | my $current_install_number = ""; | ||||
| 54 | |||||
| 55 | my $installdir = installer::worker::create_installation_directory($shipinstalldir, $languagestringref, \$current_install_number); | ||||
| 56 | |||||
| 57 | my $installlogdir = installer::systemactions::create_directory_next_to_directory($installdir, "log"); | ||||
| 58 | |||||
| 59 | # Copy files and ScpActions | ||||
| 60 | |||||
| 61 | installer::logger::include_header_into_logfile("Copying files:"); | ||||
| 62 | |||||
| 63 | # copy Files | ||||
| 64 | |||||
| 65 | for ( my $i = 0; $i <= $#{$filesref}; $i++ ) | ||||
| 66 | { | ||||
| 67 | my $onefile = ${$filesref}[$i]; | ||||
| 68 | |||||
| 69 | my $source = $onefile->{'sourcepath'}; | ||||
| 70 | my $destination = $installdir . $installer::globals::separator . $onefile->{'Name'}; | ||||
| 71 | |||||
| 72 | installer::systemactions::copy_one_file($source, $destination); | ||||
| 73 | |||||
| 74 | if ( $onefile->{'UnixRights'} ) | ||||
| 75 | { | ||||
| 76 | chmod oct($onefile->{'UnixRights'}), $destination; | ||||
| 77 | } | ||||
| 78 | elsif ( $destination =~ /install\s*$/ ) | ||||
| 79 | { | ||||
| 80 | chmod 0775, $destination; | ||||
| 81 | } | ||||
| 82 | } | ||||
| 83 | |||||
| 84 | # copy ScpActions | ||||
| 85 | |||||
| 86 | for ( my $i = 0; $i <= $#{$scpactionsref}; $i++ ) | ||||
| 87 | { | ||||
| 88 | my $onefile = ${$scpactionsref}[$i]; | ||||
| 89 | |||||
| 90 | my $source = $onefile->{'sourcepath'}; | ||||
| 91 | my $destination = $installdir . $installer::globals::separator . $onefile->{'DestinationName'}; | ||||
| 92 | |||||
| 93 | installer::systemactions::copy_one_file($source, $destination); | ||||
| 94 | |||||
| 95 | if ( $onefile->{'UnixRights'} ) | ||||
| 96 | { | ||||
| 97 | chmod oct($onefile->{'UnixRights'}), $destination; | ||||
| 98 | } | ||||
| 99 | elsif ( $destination =~ /install\s*$/ ) | ||||
| 100 | { | ||||
| 101 | chmod 0775, $destination; | ||||
| 102 | } | ||||
| 103 | } | ||||
| 104 | |||||
| 105 | # Analyzing the log file | ||||
| 106 | |||||
| 107 | installer::worker::analyze_and_save_logfile($loggingdir, $installdir, $installlogdir, $allsettingsarrayref, $languagestringref, $current_install_number); | ||||
| 108 | |||||
| 109 | # That's all | ||||
| 110 | |||||
| 111 | exit(0); | ||||
| 112 | } | ||||
| 113 | |||||
| 114 | 1 | 10µs | 1; |