[Libreoffice-commits] core.git: Branch 'aoo/trunk' - 2 commits - accessibility/source chart2/source cui/source editeng/inc editeng/source formula/source sc/source sd/source sfx2/source solenv/bin svtools/source svx/source

Andre Fischer af at apache.org
Fri Nov 29 06:08:02 PST 2013


 accessibility/source/extended/accessiblelistboxentry.cxx    |    5 
 accessibility/source/extended/textwindowaccessibility.cxx   |   15 
 accessibility/source/standard/vclxaccessiblecheckbox.cxx    |    1 
 accessibility/source/standard/vclxaccessiblelist.cxx        |   42 
 chart2/source/controller/dialogs/tp_DataSource.cxx          |    4 
 cui/source/dialogs/cuigrfflt.cxx                            |    6 
 editeng/inc/editeng/unofored.hxx                            |    1 
 editeng/inc/editeng/unoforou.hxx                            |    1 
 editeng/inc/editeng/unotext.hxx                             |    1 
 editeng/source/accessibility/AccessibleEditableTextPara.cxx |    2 
 editeng/source/accessibility/AccessibleStaticTextBase.cxx   |    1 
 editeng/source/editeng/impedit.hxx                          |    2 
 editeng/source/editeng/impedit3.cxx                         |    6 
 editeng/source/uno/unoedprx.cxx                             |   16 
 formula/source/ui/dlg/formdlgs.src                          |    1 
 sc/source/ui/Accessibility/AccessibleCellBase.cxx           |    4 
 sc/source/ui/Accessibility/AccessibleDataPilotControl.cxx   |    1 
 sc/source/ui/Accessibility/AccessibleDocument.cxx           |    2 
 sc/source/ui/Accessibility/AccessibleSpreadsheet.cxx        |  126 
 sc/source/ui/Accessibility/AccessibleTableBase.cxx          |   12 
 sc/source/ui/Accessibility/AccessibleText.cxx               |    4 
 sc/source/ui/inc/AccessibleDocument.hxx                     |    1 
 sc/source/ui/navipi/content.cxx                             |    1 
 sc/source/ui/view/gridwin.cxx                               |    2 
 sc/source/ui/view/gridwin5.cxx                              |    2 
 sc/source/ui/view/output.cxx                                |   23 
 sc/source/ui/view/preview.cxx                               |    2 
 sc/source/ui/view/viewfun2.cxx                              |    2 
 sd/source/ui/accessibility/AccessibleDrawDocumentView.cxx   |    1 
 sd/source/ui/accessibility/AccessibleOutlineEditSource.cxx  |    3 
 sd/source/ui/accessibility/AccessiblePresentationShape.cxx  |   18 
 sd/source/ui/accessibility/AccessibleSlideSorterObject.cxx  |    1 
 sd/source/ui/func/fuediglu.cxx                              |    1 
 sd/source/ui/view/sdwindow.cxx                              |    1 
 sfx2/source/view/viewfrm.cxx                                |    2 
 solenv/bin/make_installer.pl                                | 2837 ++++++------
 solenv/bin/modules/installer/scpzipfiles.pm                 |   31 
 solenv/bin/modules/installer/windows/component.pm           |   40 
 solenv/bin/modules/installer/windows/directory.pm           |   10 
 solenv/bin/modules/installer/windows/file.pm                |   16 
 solenv/bin/modules/installer/windows/msiglobal.pm           |    4 
 svtools/source/brwbox/brwbox3.cxx                           |    2 
 svtools/source/brwbox/editbrowsebox.cxx                     |    1 
 svtools/source/contnr/svtreebx.cxx                          |    8 
 svtools/source/control/valueacc.cxx                         |    2 
 svtools/source/control/valueset.cxx                         |    1 
 svx/source/accessibility/AccessibleGraphicShape.cxx         |    2 
 svx/source/accessibility/AccessibleShape.cxx                |    1 
 svx/source/accessibility/AccessibleTextHelper.cxx           |   20 
 svx/source/accessibility/ChildrenManagerImpl.cxx            |    3 
 svx/source/accessibility/charmapacc.cxx                     |   28 
 svx/source/accessibility/svxrectctaccessiblecontext.cxx     |    2 
 52 files changed, 1504 insertions(+), 1817 deletions(-)

New commits:
commit 6bfb090a3cc4782d4f40f24f078ef4e0853854ae
Author: Andre Fischer <af at apache.org>
Date:   Fri Nov 29 13:55:17 2013 +0000

    123729: Factored building of msi and epm installation sets into functions.

diff --git a/solenv/bin/make_installer.pl b/solenv/bin/make_installer.pl
index 463f2d4f9..d96e8e0 100644
--- a/solenv/bin/make_installer.pl
+++ b/solenv/bin/make_installer.pl
@@ -139,1944 +139,2019 @@ sub GetSetupScriptLines ($$$)
     return $setupscriptref;
 }
 
-#################################################
-# Main program
-#################################################
 
-#################################################
-# Part 1: The platform independent part
-#################################################
 
-#################################################
-# Part 1a: The language independent part
-#################################################
+=head2 MakeWindowsBuild (...)
 
-installer::logger::starttime();
-$installer::logger::Global->add_timestamp("starting logging");
+    Create an MSI installation set for Windows that is based on IDT tables.
 
-# While there is no language set and logger::Lang is not yet tied to a log file,
-# forward its output to logger::Global.
-$installer::logger::Lang->set_forward($installer::logger::Global);
+=cut
+sub MakeWindowsBuild ($$$$$$$$$$$$$$$$$$$$)
+{
+    my (
+        $allvariableshashref,
+        $allsettingsarrayref,
+        $current_install_number,
+        $directoriesforepmarrayref,
+        $filesinproductlanguageresolvedarrayref,
+        $folderitemsinproductlanguageresolvedarrayref,
+        $includepatharrayref,
+        $includepatharrayref_lang,
+        $installdir,
+        $languagesarrayref,
+        $languagestringref,
+        $linksinproductlanguageresolvedarrayref,
+        $loggingdir,
+        $modulesinproductlanguageresolvedarrayref,
+        $packages,
+        $profileitemsinproductlanguageresolvedarrayref,
+        $registryitemsinproductlanguageresolvedarrayref,
+        $shipinstalldir,
+        $windowscustomactionsarrayref,
+        $folderinproductlanguageresolvedarrayref) = @_;
 
-#########################################
-# Checking the environment and setting
-# most important variables
-#########################################
+    ###########################################
+    # Stripping libraries
+    ###########################################
 
-$installer::logger::Info->print( "... checking environment variables ...\n" );
-my $environmentvariableshashref = installer::control::check_system_environment();
+    # Building for gcc build in cws requires, that all files are stripped before packaging:
+    # 1. copy all files that need to be stripped locally
+    # 2. strip all these files
 
-installer::environment::set_global_environment_variables($environmentvariableshashref);
+    if ( $installer::globals::compiler =~ /wntgcci/ )
+    {
+        installer::windows::strip::strip_binaries($filesinproductlanguageresolvedarrayref, $languagestringref);
+    }
 
-#################################
-# Check and output of parameter
-#################################
+    $installdir = installer::worker::create_installation_directory($shipinstalldir, $languagestringref, \$current_install_number);
 
-installer::parameter::saveparameter();
-installer::parameter::getparameter();
+    my $idtdirbase = installer::systemactions::create_directories("idt_files", $languagestringref);
+    $installer::globals::infodirectory = installer::systemactions::create_directories("info_files", $languagestringref);
+    my $installlogdir = installer::systemactions::create_directory_next_to_directory($installdir, "log");
+    # my $installchecksumdir = installer::systemactions::create_directory_next_to_directory($installdir, "checksum");
 
-# debugging can start after function "getparameter"
+    #################################################################################
+    # Preparing cabinet files from package definitions
+    #################################################################################
 
-installer::parameter::control_fundamental_parameter();
-installer::parameter::setglobalvariables();
-installer::parameter::control_required_parameter();
+    # installer::packagelist::prepare_cabinet_files($packages, $allvariableshashref, $$languagestringref);
+    installer::packagelist::prepare_cabinet_files($packages, $allvariableshashref);
+    # printing packages content:
+    installer::packagelist::log_cabinet_assignments();
 
-if (!($installer::globals::languages_defined_in_productlist)) { installer::languages::analyze_languagelist(); }
-installer::parameter::outputparameter();
+    #################################################################################
+    # Begin of functions that are used for the creation of idt files (Windows only)
+    #################################################################################
 
-installer::control::check_updatepack();
+    $installer::logger::Info->print( "... creating idt files ...\n" );
 
-$installer::globals::build = uc($installer::globals::build);    # using "SRC680" instead of "src680"
+    installer::logger::include_header_into_logfile("Creating idt files:");
 
-######################################
-# Creating the log directory
-######################################
+    my $newidtdir = $idtdirbase . $installer::globals::separator . "00";    # new files into language independent directory "00"
+    installer::systemactions::create_directory($newidtdir);
 
-my $loggingdir = installer::systemactions::create_directories("logging", "");
-$loggingdir = $loggingdir . $installer::globals::separator;
-$installer::globals::exitlog = $loggingdir;
+    my @allfilecomponents = ();
+    my @allregistrycomponents = ();
 
-my $installdir = "";
-my $currentdir = cwd();
-my $shipinstalldir = "";
-my $current_install_number = "";
+    # Collecting all files with flag "BINARYTABLE"
+    my $binarytablefiles = installer::worker::collect_all_items_with_special_flag($filesinproductlanguageresolvedarrayref ,"BINARYTABLE");
 
-######################################
-# Checking the system requirements
-######################################
+    # Removing all files with flag "BINARYTABLE_ONLY"
+    @installer::globals::binarytableonlyfiles = ();
+    $filesinproductlanguageresolvedarrayref = installer::worker::remove_all_items_with_special_flag($filesinproductlanguageresolvedarrayref ,"BINARYTABLE_ONLY");
 
-$installer::logger::Info->print( "... checking required files ...\n" );
-installer::control::check_system_path();
+    # Collecting all profileitems with flag "INIFILETABLE" for table "IniFile"
+    my $inifiletableentries = installer::worker::collect_all_items_with_special_flag($profileitemsinproductlanguageresolvedarrayref ,"INIFILETABLE");
 
-my $pathvariableshashref = installer::environment::create_pathvariables($environmentvariableshashref);
+    # Creating the important dynamic idt files
+    installer::windows::msiglobal::set_msiproductversion($allvariableshashref);
+    installer::windows::msiglobal::put_msiproductversion_into_bootstrapfile($filesinproductlanguageresolvedarrayref);
 
-###############################################
-# Checking saved setting for Windows patches
-###############################################
+    # Add cabinet assignments to files
+    installer::windows::file::assign_cab_to_files($filesinproductlanguageresolvedarrayref);
+    installer::windows::file::assign_sequencenumbers_to_files($filesinproductlanguageresolvedarrayref);
 
-if (( $installer::globals::iswindowsbuild ) &&  ( $installer::globals::prepare_winpatch )) { installer::windows::msiglobal::read_saved_mappings(); }
+    # Collection all available directory trees
+    installer::windows::directory::collectdirectorytrees($directoriesforepmarrayref);
 
-###################################################
-# Analyzing the settings and variables in zip.lst
-###################################################
+    $filesinproductlanguageresolvedarrayref = installer::windows::file::create_files_table(
+        $filesinproductlanguageresolvedarrayref,
+        \@allfilecomponents,
+        $newidtdir,
+        $allvariableshashref);
 
-installer::logger::globallog("zip list file: $installer::globals::ziplistname");
+    installer::windows::directory::create_directory_table(
+        $directoriesforepmarrayref,
+        $newidtdir,
+        $allvariableshashref,
+        $loggingdir);
 
-my $ziplistref = installer::files::read_file($installer::globals::ziplistname);
+    # Attention: The table "Registry.idt" contains language specific strings -> parameter: $languagesarrayref !
+    installer::windows::registry::create_registry_table($registryitemsinproductlanguageresolvedarrayref, \@allregistrycomponents, $newidtdir, $languagesarrayref, $allvariableshashref);
 
-$installer::logger::Info->print( "... analyzing $installer::globals::ziplistname ... \n" );
+    installer::windows::component::create_component_table($filesinproductlanguageresolvedarrayref, $registryitemsinproductlanguageresolvedarrayref, $directoriesforepmarrayref, \@allfilecomponents, \@allregistrycomponents, $newidtdir, $allvariableshashref);
 
-my ($productblockref, $parent) = installer::ziplist::getproductblock($ziplistref, $installer::globals::product, 1);     # product block from zip.lst
+    # Attention: The table "Feature.idt" contains language specific strings -> parameter: $languagesarrayref !
+    installer::windows::feature::add_uniquekey($modulesinproductlanguageresolvedarrayref);
+    $modulesinproductlanguageresolvedarrayref = installer::windows::feature::sort_feature($modulesinproductlanguageresolvedarrayref);
+    installer::windows::feature::create_feature_table($modulesinproductlanguageresolvedarrayref, $newidtdir, $languagesarrayref, $allvariableshashref);
 
-my ($settingsblockref, undef) = installer::ziplist::getproductblock($productblockref, "Settings", 0);       # settings block from zip.lst
+    installer::windows::featurecomponent::create_featurecomponent_table($filesinproductlanguageresolvedarrayref, $registryitemsinproductlanguageresolvedarrayref, $newidtdir);
 
-$settingsblockref = installer::ziplist::analyze_settings_block($settingsblockref);              # select data from settings block in zip.lst
+    installer::windows::media::create_media_table($filesinproductlanguageresolvedarrayref, $newidtdir, $allvariableshashref);
 
-my $allsettingsarrayref = installer::ziplist::get_settings_from_ziplist($settingsblockref);
+    installer::windows::font::create_font_table($filesinproductlanguageresolvedarrayref, $newidtdir);
 
-my $allvariablesarrayref = installer::ziplist::get_variables_from_ziplist($settingsblockref);
+    # Attention: The table "Shortcut.idt" contains language specific strings -> parameter: $languagesarrayref !
+    # Attention: Shortcuts (Folderitems) have icon files, that have to be copied into the Icon directory (last parameter)
+    my @iconfilecollector = ();
 
-my ($globalproductblockref, undef) = installer::ziplist::getproductblock($ziplistref, $installer::globals::globalblock, 0);     # global product block from zip.lst
+    installer::windows::shortcut::create_shortcut_table($filesinproductlanguageresolvedarrayref, $linksinproductlanguageresolvedarrayref, $folderinproductlanguageresolvedarrayref, $folderitemsinproductlanguageresolvedarrayref, $directoriesforepmarrayref, $newidtdir, $languagesarrayref, $includepatharrayref, \@iconfilecollector);
 
-while (defined $parent)
-{
-    my $parentproductblockref;
-    ($parentproductblockref, $parent) = installer::ziplist::getproductblock(
-        $ziplistref, $parent, 1);
-    my ($parentsettingsblockref, undef) = installer::ziplist::getproductblock(
-        $parentproductblockref, "Settings", 0);
-    $parentsettingsblockref = installer::ziplist::analyze_settings_block(
-        $parentsettingsblockref);
-    my $allparentsettingsarrayref =
-        installer::ziplist::get_settings_from_ziplist($parentsettingsblockref);
-    my $allparentvariablesarrayref =
-        installer::ziplist::get_variables_from_ziplist($parentsettingsblockref);
-    $allsettingsarrayref =
-        installer::converter::combine_arrays_from_references_first_win(
-            $allsettingsarrayref, $allparentsettingsarrayref)
-        if $#{$allparentsettingsarrayref} > -1;
-    $allvariablesarrayref =
-        installer::converter::combine_arrays_from_references_first_win(
-            $allvariablesarrayref, $allparentvariablesarrayref)
-        if $#{$allparentvariablesarrayref} > -1;
-}
+    installer::windows::inifile::create_inifile_table($inifiletableentries, $filesinproductlanguageresolvedarrayref, $newidtdir);
 
-if ( $#{$globalproductblockref} > -1 )
-{
-    my ($globalsettingsblockref, undef) = installer::ziplist::getproductblock($globalproductblockref, "Settings", 0);       # settings block from zip.lst
+    installer::windows::icon::create_icon_table(\@iconfilecollector, $newidtdir);    # creating the icon table with all iconfiles used as shortcuts (FolderItems)
 
-    $globalsettingsblockref = installer::ziplist::analyze_settings_block($globalsettingsblockref);              # select data from settings block in zip.lst
+    installer::windows::createfolder::create_createfolder_table($directoriesforepmarrayref, $filesinproductlanguageresolvedarrayref, $newidtdir, $allvariableshashref);
 
-    my $allglobalsettingsarrayref = installer::ziplist::get_settings_from_ziplist($globalsettingsblockref);
+    installer::windows::upgrade::create_upgrade_table($newidtdir, $allvariableshashref);
 
-    my $allglobalvariablesarrayref = installer::ziplist::get_variables_from_ziplist($globalsettingsblockref);
+    if ( ! $installer::globals::languagepack )   # the following tables not for language packs
+    {
+        installer::windows::removefile::create_removefile_table($folderitemsinproductlanguageresolvedarrayref, $newidtdir);
 
-    if ( $#{$allglobalsettingsarrayref} > -1 ) { $allsettingsarrayref = installer::converter::combine_arrays_from_references_first_win($allsettingsarrayref, $allglobalsettingsarrayref); }
-    if ( $#{$allglobalvariablesarrayref} > -1 ) { $allvariablesarrayref = installer::converter::combine_arrays_from_references_first_win($allvariablesarrayref, $allglobalvariablesarrayref); }
-}
+        installer::windows::selfreg::create_selfreg_table($filesinproductlanguageresolvedarrayref, $newidtdir);
 
-$allsettingsarrayref = installer::ziplist::remove_multiples_from_ziplist($allsettingsarrayref); # the settings from the zip.lst
+        # Adding Assemblies into the tables MsiAssembly and MsiAssemblyName dynamically
+        installer::windows::assembly::create_msiassembly_table($filesinproductlanguageresolvedarrayref, $newidtdir);
+        installer::windows::assembly::create_msiassemblyname_table($filesinproductlanguageresolvedarrayref, $newidtdir);
+        installer::windows::assembly::add_assembly_condition_into_component_table($filesinproductlanguageresolvedarrayref, $newidtdir);
+    }
 
-$allvariablesarrayref = installer::ziplist::remove_multiples_from_ziplist($allvariablesarrayref);
+    $installer::logger::Lang->print("\n");
 
-installer::ziplist::replace_variables_in_ziplist_variables($allvariablesarrayref);
+    # Localizing the language dependent idt files
+    # For every language there will be a localized msi database
+    # For multilingual installation sets, the differences of this
+    # databases have to be stored in transforms.
 
-my $allvariableshashref = installer::converter::convert_array_to_hash($allvariablesarrayref);   # the variables from the zip.lst
+    for ( my $m = 0; $m <= $#{$languagesarrayref}; $m++ )
+    {
+        my $onelanguage = ${$languagesarrayref}[$m];
 
-installer::ziplist::set_default_productversion_if_required($allvariableshashref);
+        my $is_bidi = 0;
+        if ( installer::existence::exists_in_array($onelanguage, \@installer::globals::bidilanguages) ) { $is_bidi = 1; }
 
-installer::ziplist::add_variables_to_allvariableshashref($allvariableshashref);
+        my $languageidtdir = $idtdirbase . $installer::globals::separator . $onelanguage;
+        if ( -d $languageidtdir ) { installer::systemactions::remove_complete_directory($languageidtdir, 1); }
+        installer::systemactions::create_directory($languageidtdir);
 
-installer::ziplist::overwrite_ooovendor( $allvariableshashref );
+        # Copy the template idt files and the new created idt files into this language directory
 
-########################################################
-# Check if this is simple packaging mechanism
-########################################################
+        $installer::logger::Info->print( "... copying idt files ...\n" );
 
-installer::simplepackage::check_simple_packager_project($allvariableshashref);
+        installer::logger::include_header_into_logfile("Copying idt files to $languageidtdir:");
 
-####################################################################
-# setting global variables
-####################################################################
+        installer::windows::idtglobal::prepare_language_idt_directory($languageidtdir, $newidtdir, $onelanguage, $filesinproductlanguageresolvedarrayref, \@iconfilecollector, $binarytablefiles, $allvariableshashref);
 
-installer::control::set_addchildprojects($allvariableshashref);
-installer::control::set_addjavainstaller($allvariableshashref);
-installer::control::set_addsystemintegration($allvariableshashref);
+        if (( ! $installer::globals::languagepack ) && ( ! $allvariableshashref->{'NOLANGUAGESELECTIONPRODUCT'} ))
+        {
+            # For multilingual installation sets, the dialog for the language selection can now be prepared, with
+            # a checkbox for each available language. This has to happen before the following translation.
+            # The new controls have to be added into the Control.idt
+
+            my $controlidttablename = $languageidtdir . $installer::globals::separator . "Control.idt";
+            my $controlidttable = installer::files::read_file($controlidttablename);
+            installer::windows::idtglobal::add_language_checkboxes_to_database($controlidttable, $languagesarrayref);
+            installer::files::save_file($controlidttablename, $controlidttable);
+            $installer::logger::Lang->printf("Added checkboxes for language selection dialog into table %s\n",
+                $controlidttablename);
+        }
 
-########################################################
-# Re-define logging dir, after all variables are set
-########################################################
+        # Now all files are copied into a language specific directory
+        # The template idt files can be translated
 
-my $oldloggingdir = $loggingdir;
-installer::systemactions::remove_empty_directory($oldloggingdir);
-$loggingdir = installer::systemactions::create_directories("logging", "");
-$loggingdir = $loggingdir . $installer::globals::separator;
-$installer::globals::exitlog = $loggingdir;
+        $installer::logger::Info->print( "... localizing idt files (language: $onelanguage) ...\n" );
 
-# checking, whether this is an opensource product
+        installer::logger::include_header_into_logfile("Localizing idt files (Language: $onelanguage):");
 
-if (!($installer::globals::is_copy_only_project)) { installer::ziplist::set_manufacturer($allvariableshashref); }
+        my @translationfiles = ();          # all idt files, that need a translation
+        push(@translationfiles, "ActionTe.idt");
+        push(@translationfiles, "Control.idt");
+        push(@translationfiles, "CustomAc.idt");
+        push(@translationfiles, "Error.idt");
+        push(@translationfiles, "LaunchCo.idt");
+        push(@translationfiles, "RadioBut.idt");
+        push(@translationfiles, "Property.idt");
+        push(@translationfiles, "UIText.idt");
 
-##############################################
-# Checking version of makecab.exe
-##############################################
+        my $oneidtfilename;
+        my $oneidtfile;
 
-if ( $installer::globals::iswindowsbuild ) { installer::control::check_makecab_version(); }
+        foreach $oneidtfilename (@translationfiles)
+        {
+            my $languagefilename = installer::windows::idtglobal::get_languagefilename($oneidtfilename, $installer::globals::idtlanguagepath);
+            my $languagefile = installer::files::read_file($languagefilename);
 
-##########################################################
-# Getting the include path from the settings in zip list
-##########################################################
+            $oneidtfilename = $languageidtdir . $installer::globals::separator . $oneidtfilename;
+            $oneidtfile = installer::files::read_file($oneidtfilename);
 
-my $includepathref = installer::ziplist::getinfofromziplist($allsettingsarrayref, "include");
-if ( $$includepathref eq "" )
-{
-    installer::exiter::exit_program("ERROR: Definition for \"include\" not found in $installer::globals::ziplistname", "Main");
-}
+            # Now the substitution can start
+            installer::windows::idtglobal::translate_idtfile($oneidtfile, $languagefile, $onelanguage);
 
-my $includepatharrayref = installer::converter::convert_stringlist_into_array($includepathref, ",");
+            installer::files::save_file($oneidtfilename, $oneidtfile);
 
-installer::ziplist::replace_all_variables_in_pathes($includepatharrayref, $pathvariableshashref);
+            $installer::logger::Lang->printf("Translated idt file: %s into language %s\n",
+                $oneidtfilename,
+                $onelanguage);
+            $installer::logger::Lang->printf("Used languagefile: %s\n", $languagefilename);
+        }
 
-installer::ziplist::replace_minor_in_pathes($includepatharrayref);
+        # setting the encoding in every table (replacing WINDOWSENCODINGTEMPLATE)
 
-installer::ziplist::replace_packagetype_in_pathes($includepatharrayref);
+        installer::windows::idtglobal::setencoding($languageidtdir, $onelanguage);
 
-installer::ziplist::resolve_relative_pathes($includepatharrayref);
+        # setting bidi attributes, if required
 
-installer::ziplist::remove_ending_separator($includepatharrayref);
+        if ( $is_bidi ) { installer::windows::idtglobal::setbidiattributes($languageidtdir, $onelanguage); }
 
-##############################################
-# Collecting all files from all include
-# pathes in global hashes.
-##############################################
+        # setting the encoding in every table (replacing WINDOWSENCODINGTEMPLATE)
+        installer::windows::idtglobal::set_multilanguageonly_condition($languageidtdir);
 
-installer::worker::collect_all_files_from_includepathes($includepatharrayref);
+        # include the license text into the table Control.idt
 
-##############################################
-# Analyzing languages in zip.lst if required
-# Probably no longer used.
-##############################################
+        if ( ! $allvariableshashref->{'HIDELICENSEDIALOG'} )
+        {
+            my $licensefilesource = installer::windows::idtglobal::get_rtflicensefilesource($onelanguage, $includepatharrayref_lang);
+            my $licensefile = installer::files::read_file($licensefilesource);
+            installer::scpzipfiles::replace_all_ziplistvariables_in_rtffile($licensefile, $allvariableshashref);
+            my $controltablename = $languageidtdir . $installer::globals::separator . "Control.idt";
+            my $controltable = installer::files::read_file($controltablename);
+            installer::windows::idtglobal::add_licensefile_to_database($licensefile, $controltable);
+            installer::files::save_file($controltablename, $controltable);
+
+            $installer::logger::Lang->printf("Added licensefile %s into database %s\n",
+                $licensefilesource,
+                $controltablename);
+        }
 
-if ($installer::globals::languages_defined_in_productlist) { installer::languages::get_info_about_languages($allsettingsarrayref); }
+        # include a component into environment table if required
 
-#####################################
-# Windows requires the encoding list
-#####################################
+        installer::windows::component::set_component_in_environment_table($languageidtdir, $filesinproductlanguageresolvedarrayref);
 
-if ( $installer::globals::iswindowsbuild ) { installer::control::read_encodinglist($includepatharrayref); }
+        # include the ProductCode and the UpgradeCode from codes-file into the Property.idt
 
-####################################################################
-# MacOS dmg build requires special DS_Store file to arrange icons
-####################################################################
-if (($installer::globals::ismacdmgbuild) && ($installer::globals::product =~ /OpenOffice_Dev/)) { $installer::globals::devsnapshotbuild = 1; }
+        installer::windows::property::set_codes_in_property_table($languageidtdir);
 
-#####################################################################
-# Including additional inc files for variable settings, if defined
-#####################################################################
+        # the language specific properties can now be set in the Property.idt
 
-if ( $allvariableshashref->{'ADD_INCLUDE_FILES'} ) { installer::worker::add_variables_from_inc_to_hashref($allvariableshashref, $includepatharrayref); }
+        installer::windows::property::update_property_table($languageidtdir, $onelanguage, $allvariableshashref, $languagestringref);
 
-################################################
-# Disable xpd installer, if SOLAR_JAVA not set
-################################################
+        # replacing variables in RegLocat.idt
 
-installer::control::check_java_for_xpd($allvariableshashref);
+        installer::windows::msiglobal::update_reglocat_table($languageidtdir, $allvariableshashref);
 
-#####################################
-# Analyzing the setup script
-#####################################
+        # replacing variables in RemoveRe.idt (RemoveRegistry.idt)
 
-my $setupscriptref = GetSetupScriptLines($allsettingsarrayref, $allvariableshashref, $includepatharrayref);
+        installer::windows::msiglobal::update_removere_table($languageidtdir);
 
-installer::logger::log_hashref($allvariableshashref);
+        # adding language specific properties for multilingual installation sets
 
-$installer::logger::Info->print( "... analyzing directories ... \n" );
+        installer::windows::property::set_languages_in_property_table($languageidtdir, $languagesarrayref);
 
-# Collect all directories in the script to get the destination dirs
+        # adding settings into CheckBox.idt
+        installer::windows::property::update_checkbox_table($languageidtdir, $allvariableshashref);
 
-my $dirsinproductarrayref = installer::setupscript::get_all_items_from_script($setupscriptref, "Directory");
+        # adding the files from the binary directory into the binary table
+        installer::windows::binary::update_binary_table($languageidtdir, $filesinproductlanguageresolvedarrayref, $binarytablefiles);
 
-if ( $installer::globals::languagepack ) { installer::scriptitems::use_langpack_hostname($dirsinproductarrayref); }
-if ( $installer::globals::patch ) { installer::scriptitems::use_patch_hostname($dirsinproductarrayref); }
+        # setting patch codes to detect installed products
 
-if ( $allvariableshashref->{'SHIFT_BASIS_INTO_BRAND_LAYER'} ) { $dirsinproductarrayref = installer::scriptitems::shift_basis_directory_parents($dirsinproductarrayref); }
-if ( $allvariableshashref->{'OFFICEDIRECTORYNAME'} ) { installer::scriptitems::set_officedirectory_name($dirsinproductarrayref, $allvariableshashref->{'OFFICEDIRECTORYNAME'}); }
+        if (( $installer::globals::patch ) || ( $installer::globals::languagepack ) || ( $allvariableshashref->{'PDFCONVERTER'} )) { installer::windows::patch::update_patch_tables($languageidtdir, $allvariableshashref); }
 
+        # Adding Windows Installer CustomActions
 
-installer::scriptitems::resolve_all_directory_names($dirsinproductarrayref);
+        installer::windows::idtglobal::addcustomactions($languageidtdir, $windowscustomactionsarrayref, $filesinproductlanguageresolvedarrayref);
 
-$installer::logger::Info->print( "... analyzing files ... \n" );
+        # Adding child projects if specified
 
-my $filesinproductarrayref = installer::setupscript::get_all_items_from_script($setupscriptref, "File");
+        if ($installer::globals::addchildprojects)
+        {
+            # Adding child projects to installation dynamically (also in feature table)
+            installer::windows::idtglobal::add_childprojects($languageidtdir, $filesinproductlanguageresolvedarrayref, $allvariableshashref);
+            # setting Java variables for Java products
+            if ( $allvariableshashref->{'JAVAPRODUCT'} ) { installer::windows::java::update_java_tables($languageidtdir, $allvariableshashref); }
+        }
 
-$filesinproductarrayref = installer::scriptitems::remove_delete_only_files_from_productlists($filesinproductarrayref);
+        # Then the language specific msi database can be created
 
-if (( ! $installer::globals::iswindowsbuild ) &&
-    ( ! $installer::globals::islinuxrpmbuild ) &&
-    ( ! $installer::globals::islinuxdebbuild ) &&
-    ( ! $installer::globals::issolarispkgbuild ) &&
-    ( $installer::globals::packageformat ne "installed" ) &&
-    ( $installer::globals::packageformat ne "dmg" ) &&
-    ( $installer::globals::packageformat ne "archive" ))
-    { installer::control::check_oxtfiles($filesinproductarrayref); }
+        if ( $installer::globals::iswin )   # only possible on a Windows platform
+        {
+            my $msidatabasename = installer::windows::msiglobal::get_msidatabasename($allvariableshashref, $onelanguage);
+            my $msifilename = $languageidtdir . $installer::globals::separator . $msidatabasename;
 
-if ($installer::globals::product =~ /suite/i ) { $filesinproductarrayref = installer::scriptitems::remove_notinsuite_files_from_productlists($filesinproductarrayref); }
+            $installer::logger::Info->print( "... creating msi database (language $onelanguage) ... \n" );
 
-if (! $installer::globals::languagepack)
-{
-    $filesinproductarrayref = installer::scriptitems::remove_Languagepacklibraries_from_Installset($filesinproductarrayref);
-}
+            installer::windows::msiglobal::set_uuid_into_component_table($languageidtdir, $allvariableshashref);    # setting new GUID for the components using the tool uuidgen.exe
+            installer::windows::msiglobal::prepare_64bit_database($languageidtdir, $allvariableshashref);   # making last 64 bit changes
+            installer::windows::msiglobal::create_msi_database($languageidtdir ,$msifilename);
 
-if (! $installer::globals::patch)
-{
-    $filesinproductarrayref = installer::scriptitems::remove_patchonlyfiles_from_Installset($filesinproductarrayref);
-}
+            # validating the database   # ToDo
 
-if (! $installer::globals::tab)
-{
-    $filesinproductarrayref = installer::scriptitems::remove_tabonlyfiles_from_Installset($filesinproductarrayref);
-}
+            my $languagefile = installer::files::read_file($installer::globals::idtlanguagepath . $installer::globals::separator . "SIS.mlf");
+            # my $languagefile = installer::files::read_file($installer::globals::idtlanguagepath . $installer::globals::separator . "SIS.ulf");
 
-if (( $installer::globals::packageformat ne "installed" ) && ( $installer::globals::packageformat ne "archive" ))
-{
-    $filesinproductarrayref = installer::scriptitems::remove_installedproductonlyfiles_from_Installset($filesinproductarrayref);
-}
+            installer::windows::msiglobal::write_summary_into_msi_database($msifilename, $onelanguage, $languagefile, $allvariableshashref);
 
-$installer::logger::Info->print( "... analyzing scpactions ... \n" );
+            # copy msi database into installation directory
 
-my $scpactionsinproductarrayref = installer::setupscript::get_all_items_from_script($setupscriptref, "ScpAction");
+            my $msidestfilename = $installdir . $installer::globals::separator . $msidatabasename;
+            installer::systemactions::copy_one_file($msifilename, $msidestfilename);
+        }
+    }
 
-if (( ! $allvariableshashref->{'XPDINSTALLER'} ) || ( ! $installer::globals::isxpdplatform ))
-{
-    $scpactionsinproductarrayref = installer::scriptitems::remove_Xpdonly_Items($scpactionsinproductarrayref);
-}
+    # Creating transforms, if the installation set has more than one language
+    # renaming the msi database and generating the setup.ini file
 
-if ( $installer::globals::languagepack ) { installer::scriptitems::use_langpack_copy_scpaction($scpactionsinproductarrayref); }
-if ( $installer::globals::patch ) { installer::scriptitems::use_patch_copy_scpaction($scpactionsinproductarrayref); }
-if (($installer::globals::devsnapshotbuild)) { installer::scriptitems::use_dev_copy_scpaction($scpactionsinproductarrayref); }
+    my $defaultlanguage = installer::languages::get_default_language($languagesarrayref);
 
-# $scpactionsinproductarrayref = installer::scriptitems::remove_scpactions_without_name($scpactionsinproductarrayref);
+    if ( $installer::globals::iswin )   # only possible on a Windows platform
+    {
+        if  ( $#{$languagesarrayref} > 0 )
+        {
+            installer::windows::msiglobal::create_transforms($languagesarrayref, $defaultlanguage, $installdir, $allvariableshashref);
+        }
 
-installer::scriptitems::change_keys_of_scpactions($scpactionsinproductarrayref);
+        installer::windows::msiglobal::rename_msi_database_in_installset($defaultlanguage, $installdir, $allvariableshashref);
 
-$installer::logger::Info->print( "... analyzing shortcuts ... \n" );
+        if ( $allvariableshashref->{'ADDLANGUAGEINDATABASENAME'} ) { installer::windows::msiglobal::add_language_to_msi_database($defaultlanguage, $installdir, $allvariableshashref); }
 
-my $linksinproductarrayref = installer::setupscript::get_all_items_from_script($setupscriptref, "Shortcut");
+        $installer::logger::Info->print( "... generating setup.ini ...\n" );
 
-$installer::logger::Info->print( "... analyzing unix links ... \n" );
+        if ( ! $allvariableshashref->{'NOLOADERREQUIRED'} ) { installer::windows::msiglobal::create_setup_ini($languagesarrayref, $defaultlanguage, $installdir, $allvariableshashref); }
+    }
 
-my $unixlinksinproductarrayref = installer::setupscript::get_all_items_from_script($setupscriptref, "Unixlink");
+    # Analyzing the ScpActions and copying the files into the installation set
+    # At least the loader.exe
 
-# $unixlinksinproductarrayref = installer::scriptitems::filter_layerlinks_from_unixlinks($unixlinksinproductarrayref);
+    $installer::logger::Info->print( "... copying files into installation set ...\n" );
 
-$installer::logger::Info->print( "... analyzing profile ... \n" );
+    # installer::windows::msiglobal::copy_scpactions_into_installset($defaultlanguage, $installdir, $scpactionsinproductlanguageresolvedarrayref);
+    installer::worker::put_scpactions_into_installset($installdir);
 
-my $profilesinproductarrayref = installer::setupscript::get_all_items_from_script($setupscriptref, "Profile");
+    # ... copying the setup.exe
 
-$installer::logger::Info->print( "... analyzing profileitems ... \n" );
+    installer::windows::msiglobal::copy_windows_installer_files_into_installset($installdir, $includepatharrayref, $allvariableshashref);
 
-my $profileitemsinproductarrayref = installer::setupscript::get_all_items_from_script($setupscriptref, "ProfileItem");
+    # ... copying the child projects
 
-my $folderinproductarrayref;
-my $folderitemsinproductarrayref;
-my $registryitemsinproductarrayref;
-my $windowscustomactionsarrayref;
+    if ($installer::globals::addchildprojects)
+    {
+        installer::windows::msiglobal::copy_child_projects_into_installset($installdir, $allvariableshashref);
+    }
 
-if ( $installer::globals::iswindowsbuild )  # Windows specific items: Folder, FolderItem, RegistryItem, WindowsCustomAction
-{
-    $installer::logger::Info->print( "... analyzing folders ... \n" );
+    $installer::logger::Info->print( "... creating ddf files ...\n" );
 
-    $folderinproductarrayref = installer::setupscript::get_all_items_from_script($setupscriptref, "Folder");
+    # Creating all needed ddf files and generating a list
+    # for the package process containing all system calls
 
-    $installer::logger::Info->print( "... analyzing folderitems ... \n" );
+    my $ddfdir = installer::systemactions::create_directories("ddf", $languagestringref);
 
-    $folderitemsinproductarrayref = installer::setupscript::get_all_items_from_script($setupscriptref, "FolderItem");
+    $installer::globals::packjobref = installer::windows::msiglobal::generate_cab_file_list($filesinproductlanguageresolvedarrayref, $installdir, $ddfdir, $allvariableshashref);
 
-    installer::setupscript::add_predefined_folder($folderitemsinproductarrayref, $folderinproductarrayref);
+    # Update and patch reasons the pack order needs to be saved
+    installer::windows::msiglobal::save_packorder();
 
-    installer::setupscript::prepare_non_advertised_files($folderitemsinproductarrayref, $filesinproductarrayref);
+    $installer::logger::Info->print("\n");
 
-    $installer::logger::Info->print( "... analyzing registryitems ... \n" );
+    #######################################################
+    # Finally really create the installation packages,
+    # Only for Windows and only on a windows platform.
+    #######################################################
 
-    $registryitemsinproductarrayref = installer::setupscript::get_all_items_from_script($setupscriptref, "RegistryItem");
+    if ( $installer::globals::iswin )   # only possible on a Windows platform
+    {
+        $installer::logger::Info->print( "... packaging installation set ... \n" );
+        installer::windows::msiglobal::execute_packaging($installer::globals::packjobref, $loggingdir, $allvariableshashref);
+        if ( $installer::globals::include_cab_in_msi ) { installer::windows::msiglobal::include_cabs_into_msi($installdir); }
+    }
 
-    $registryitemsinproductarrayref = installer::scriptitems::remove_uninstall_regitems_from_script($registryitemsinproductarrayref);
+    #######################################################
+    # Analyzing the log file
+    #######################################################
 
-    $installer::logger::Info->print( "... analyzing Windows custom actions ... \n" );
+    my $is_success = 0;
+    my $finalinstalldir = "";
+    installer::worker::clean_output_tree(); # removing directories created in the output tree
+    ($is_success, $finalinstalldir) = installer::worker::analyze_and_save_logfile($loggingdir, $installdir, $installlogdir, $allsettingsarrayref, $languagestringref, $current_install_number);
 
-    $windowscustomactionsarrayref = installer::setupscript::get_all_items_from_script($setupscriptref, "WindowsCustomAction");
-}
 
-my $modulesinproductarrayref;
+    #######################################################
+    # Creating download installation set
+    #######################################################
 
-if (!($installer::globals::is_copy_only_project))
-{
-    $installer::logger::Info->print( "... analyzing modules ... \n" );
+    my $create_download = 0;
+    my $downloadname = installer::ziplist::getinfofromziplist($allsettingsarrayref, "downloadname");
+    if ( $installer::globals::languagepack ) { $downloadname = installer::ziplist::getinfofromziplist($allsettingsarrayref, "langpackdownloadname"); }
+    if ( $installer::globals::patch ) { $downloadname = installer::ziplist::getinfofromziplist($allsettingsarrayref, "patchdownloadname"); }
 
-    $modulesinproductarrayref = installer::setupscript::get_all_items_from_script($setupscriptref, "Module");
+    if ( $is_success ) { installer::followme::save_followme_info($finalinstalldir, $includepatharrayref, $allvariableshashref, $$downloadname, $languagestringref, $languagesarrayref, $current_install_number, $loggingdir, $installlogdir); }
 
-    if (( ! $allvariableshashref->{'XPDINSTALLER'} ) || ( ! $installer::globals::isxpdplatform ))
+    if ( $$downloadname ne "" ) { $create_download = 1; }
+    if (( $is_success ) && ( $create_download ) && ( $ENV{'ENABLE_DOWNLOADSETS'} ))
     {
-        $modulesinproductarrayref = installer::scriptitems::remove_Xpdonly_Items($modulesinproductarrayref);
+        my $downloaddir = installer::download::create_download_sets($finalinstalldir, $includepatharrayref, $allvariableshashref, $$downloadname, $languagestringref, $languagesarrayref);
+        installer::worker::analyze_and_save_logfile($loggingdir, $downloaddir, $installlogdir, $allsettingsarrayref, $languagestringref, $current_install_number);
     }
+}
 
-    installer::scriptitems::resolve_assigned_modules($modulesinproductarrayref);
 
-    $modulesinproductarrayref = installer::scriptitems::remove_template_modules($modulesinproductarrayref);
 
-    installer::scriptitems::set_children_flag($modulesinproductarrayref);
 
-    installer::scriptitems::collect_all_languagemodules($modulesinproductarrayref);
+=head2 MakeNonWindowsBuild (...)
 
-    # Assigning the modules to the items
+    Create an installation set for non-windows platforms based on EPM files.
 
-    installer::scriptitems::assigning_modules_to_items($modulesinproductarrayref, $filesinproductarrayref, "Files");
+=cut
+sub MakeNonWindowsBuild ($$$$$$$$$$$$$$$)
+{
+    my (
+        $allvariableshashref,
+        $allsettingsarrayref,
+        $current_install_number,
+        $directoriesforepmarrayref,
+        $filesinproductlanguageresolvedarrayref,
+        $includepatharrayref,
+        $languagesarrayref,
+        $languagestringref,
+        $linksinproductlanguageresolvedarrayref,
+        $unixlinksinproductlanguageresolvedarrayref,
+        $loggingdir,
+        $modulesinproductarrayref,
+        $packages,
+        $shipinstalldir,
+        $currentdir
+        ) = @_;
+
+    ####################################################
+    # Creating directories
+    ####################################################
+
+    my $installdir = installer::worker::create_installation_directory($shipinstalldir, $languagestringref, \$current_install_number);
+
+    my $listfiledir = installer::systemactions::create_directories("listfile", $languagestringref);
+    my $installlogdir = installer::systemactions::create_directory_next_to_directory($installdir, "log");
+
+    ####################################################
+    # Reading for Solaris all package descriptions
+    # from file defined in property PACKAGEMAP
+    ####################################################
+
+    if (  $installer::globals::issolarisbuild ) { installer::epmfile::read_packagemap($allvariableshashref, $includepatharrayref, $languagesarrayref); }
+
+    my $epmexecutable = "";
+    my $found_epm = 0;
+
+    # shuffle array to reduce parallel packaging process in pool
+    installer::worker::shuffle_array($packages);
+
+    # iterating over all packages
+    for ( my $k = 0; $k <= $#{$packages}; $k++ )
+    {
+        my $onepackage = ${$packages}[$k];
 
-    installer::scriptitems::assigning_modules_to_items($modulesinproductarrayref, $unixlinksinproductarrayref, "Unixlinks");
+        # checking, if this is a language pack or a project pack.
+        # Creating language packs only, if $installer::globals::languagepack is set. Parameter: -languagepack
 
-    installer::scriptitems::assigning_modules_to_items($modulesinproductarrayref, $dirsinproductarrayref, "Dirs");
-}
+        if ( $installer::globals::languagepack ) { installer::languagepack::replace_languagestring_variable($onepackage, $languagestringref); }
 
+        my $onepackagename = $onepackage->{'module'};           # name of the top module (required)
 
-# saving debug info, before staring part 1b
-if ( $installer::globals::debug ) { installer::logger::savedebug($installer::globals::exitlog); }
+        my $shellscriptsfilename = "";
+        if ( $onepackage->{'script'} ) { $shellscriptsfilename = $onepackage->{'script'}; }
+        # no scripts for Solaris patches!
+        if (( $installer::globals::patch ) && ( $installer::globals::issolarispkgbuild )) { $shellscriptsfilename = ""; }
 
-#################################################
-# Part 1b: The language dependent part
-# (still platform independent)
-#################################################
+        ###########################
+        # package name
+        ###########################
 
-# Now starts the language dependent part, if more than one product is defined on the command line
-# Example -l en-US,de#es,fr,it defines two multilingual products
+        my $packagename = "";
 
-###############################################################################
-# Beginning of language dependent part
-# The for iterates over all products, separated by an # in the language list
-###############################################################################
+        if ( $installer::globals::issolarisbuild )   # only for Solaris
+        {
+            if ( $onepackage->{'solarispackagename'} ) { $packagename = $onepackage->{'solarispackagename'}; }
+        }
+        else # not Solaris
+        {
+            if ( $onepackage->{'packagename'} ) { $packagename = $onepackage->{'packagename'}; }
+        }
 
+        if (!($packagename eq ""))
+        {
+            installer::packagelist::resolve_packagevariables(\$packagename, $allvariableshashref, 0);
+        }
 
-# Run the following code block exactly once.
-# This strange version of a do{}while(false) loop exists only to allow (legacy) next statements.
-for (;1;last)
-{
-    my $languagesarrayref = installer::languages::get_all_languages_for_one_product($installer::globals::languageproduct, $allvariableshashref);
+        # Debian allows no underline in package name
+        if ( $installer::globals::debian ) { $packagename =~ s/_/-/g; }
 
-    $installer::globals::alllanguagesinproductarrayref = $languagesarrayref;
-    my $languagestringref = installer::languages::get_language_string($languagesarrayref);
-    $installer::logger::Info->print( "------------------------------------\n" );
-    $installer::logger::Info->print( "... languages $$languagestringref ... \n" );
+        # Debian allows no underline in package name
+        if ( $installer::globals::debian ) { $packagename =~ s/_/-/g; }
 
-    if ( $installer::globals::patch )
-    {
-        $installer::globals::addlicensefile = 0;    # no license files for patches
-        $installer::globals::makedownload = 0;
-        $installer::globals::makejds = 0;
-    }
+        my $linkaddon = "";
+        my $linkpackage = 0;
+        $installer::globals::add_required_package = "";
+        $installer::globals::linuxlinkrpmprocess = 0;
 
-    if ( $installer::globals::languagepack )
-    {
-        $installer::globals::addchildprojects = 0;
-        $installer::globals::addsystemintegration = 0;
-        $installer::globals::makejds = 0;
-        $installer::globals::addlicensefile = 0;
+        if ( $installer::globals::makelinuxlinkrpm )
+        {
+            my $oldpackagename = $packagename;
+            $installer::globals::add_required_package = $oldpackagename;    # the link rpm requires the non-linked version
+            if ( $installer::globals::languagepack ) { $packagename = $packagename . "_u"; }
+            else { $packagename = $packagename . "u"; }
+            my $savestring = $oldpackagename . "\t" . $packagename;
+            push(@installer::globals::linkrpms, $savestring);
+            $linkaddon = "_links";
+            $installer::globals::linuxlinkrpmprocess = 1;
+            $linkpackage = 1;
+        }
 
-        if ( $allvariableshashref->{'OPENSOURCE'} ) { $installer::globals::makedownload = 1; }
-        else { $installer::globals::makedownload = 0; }
-    }
+        ####################################################
+        # Header for this package into log file
+        ####################################################
 
-    ############################################################
-    # Beginning of language specific logging mechanism
-    # Until now only global logging into default: logfile.txt
-    ############################################################
+        installer::logger::include_header_into_logfile("Creating package: $packagename ($k)");
 
-    installer::logger::copy_globalinfo_into_logfile();
-    $installer::globals::globalinfo_copied = 1;
+        ####################################################
+        # Pool check: If package is created at the moment
+        # try it again later.
+        ####################################################
 
-    my $logminor = "";
-    if ( $installer::globals::updatepack ) { $logminor = $installer::globals::lastminor; }
-    else { $logminor = $installer::globals::minor; }
+        if (( $installer::globals::patch ) ||
+            ( $installer::globals::languagepack ) ||
+            ( $installer::globals::packageformat eq "native" ) ||
+            ( $installer::globals::packageformat eq "portable" ) ||
+            ( $installer::globals::packageformat eq "osx" )) { $allvariableshashref->{'POOLPRODUCT'} = 0; }
 
-    my $loglanguagestring = $$languagestringref;
-    my $loglanguagestring_orig = $loglanguagestring;
-    if (length($loglanguagestring) > $installer::globals::max_lang_length)
-    {
-        my $number_of_languages = installer::systemactions::get_number_of_langs($loglanguagestring);
-        chomp(my $shorter = `echo $loglanguagestring | md5sum | sed -e "s/ .*//g"`);
-        my $id = substr($shorter, 0, 8); # taking only the first 8 digits
-        $loglanguagestring = "lang_" . $number_of_languages . "_id_" . $id;
-    }
+        if ( $allvariableshashref->{'POOLPRODUCT'} )
+        {
+            if ( ! $installer::globals::sessionidset ) { installer::packagepool::set_sessionid(); }
+            if ( ! $installer::globals::poolpathset ) { installer::packagepool::set_pool_path(); }
+            if (( ! $installer::globals::getuidpathset ) && ( $installer::globals::issolarisbuild )) { installer::worker::set_getuid_path($includepatharrayref); }
 
-    # Setup the directory where the language dependent log file will be stored.
-    $loggingdir = $loggingdir . $loglanguagestring . $installer::globals::separator;
-    installer::systemactions::create_directory($loggingdir);
+            my $package_is_creatable = installer::packagepool::check_package_availability($packagename);
 
-    # Set language dependent logging.
-    $installer::globals::logfilename = sprintf("log_%s%s_%s.log",
-        $installer::globals::build,
-        $logminor ne "" ? "_" . $logminor : "",
-        $loglanguagestring);
-    $installer::logger::Lang->set_filename($loggingdir . $installer::globals::logfilename);
-    $installer::logger::Lang->copy_lines_from($installer::logger::Global);
-    $installer::logger::Lang->set_filter(\&installer::control::filter_log_error);
-    installer::control::prepare_error_processing();
-    # All logging to the console is also forwarded to the language dependen log.
-    $installer::logger::Lang->set_forward(undef);
-    $installer::logger::Info->set_forward($installer::logger::Lang);
-    # Scan all log lines for error messages.
-    $installer::logger::Lang->add_timestamp("starting log for language ".$loglanguagestring);
+            if (( ! $package_is_creatable ) && ( ! exists($installer::globals::poolshiftedpackages{$packagename}) ))
+            {
+                splice(@{$packages}, $k, 1);    # removing package ...
+                push(@{$packages}, $onepackage);  # ... and adding it to the end
+                $installer::globals::poolshiftedpackages{$packagename} = 1; # only shifting each package once
+                $k--;                                                       # decreasing the counter
+                $installer::logger::Info->printf("Pool: Package \"%s\" cannot be created at the moment. Trying again later (1).\n", $packagename);
+                $installer::logger::Lang->printf("Pool: Package \"%s\" cannot be created at the moment. Trying again later (1).\n", $packagename);
+                next;                                                       # repeating this iteration with new package
+            }
+        }
 
-    if ($loglanguagestring ne $loglanguagestring_orig) {
-        (my $dir = $loggingdir) =~ s!/$!!;
-        open(my $F1, "> $dir.dir");
-        open(my $F2, "> " . $loggingdir . $installer::globals::logfilename . '.file');
-        my @s = map { "$_\n" } split('_', $loglanguagestring_orig);
-        print $F1 @s;
-        print $F2 @s;
-    }
+        ###########################################
+        # Root path, can be defined as parameter
+        ###########################################
 
-    $installer::globals::exitlog = $loggingdir;
+        my $packagerootpath = "";
 
-    ##############################################################
-    # Determining the ship location, if this is an update pack
-    ##############################################################
+        if ($installer::globals::rootpath eq "")
+        {
+            $packagerootpath = $onepackage->{'destpath'};
+            installer::packagelist::resolve_packagevariables(\$packagerootpath, $allvariableshashref, 1);
+            if ( $^O =~ /darwin/i ) { $packagerootpath =~ s/\/opt\//\/Applications\//; }
+        }
+        else
+        {
+            $packagerootpath = $installer::globals::rootpath;
+        }
 
-    if ( $installer::globals::updatepack ) { $shipinstalldir = installer::control::determine_ship_directory($languagestringref); }
+        #############################################
+        # copying the collectors for each package
+        #############################################
 
-    ###################################################################
-    # Reading an existing msi database, to prepare update and patch
-    ###################################################################
+        my $filesinpackage = installer::converter::copy_collector($filesinproductlanguageresolvedarrayref);
+        my $linksinpackage = installer::converter::copy_collector($linksinproductlanguageresolvedarrayref);
+        my $unixlinksinpackage = installer::converter::copy_collector($unixlinksinproductlanguageresolvedarrayref);
+        my $dirsinpackage = installer::converter::copy_collector($directoriesforepmarrayref);
 
-    my $refdatabase = "";
-    my $uniquefilename = "";
-    my $revuniquefilename = "";
-    my $revshortfilename = "";
-    my $allupdatecomponentorder = "";
-    my $shortdirname = "";
-    my $componentid = "";
-    my $componentidkeypath = "";
-    my $alloldproperties = "";
+        ###########################################
+        # setting the root path for the packages
+        ###########################################
 
-    ##############################################
-    # Setting global code variables for Windows
-    ##############################################
+        installer::scriptitems::add_rootpath_to_directories($dirsinpackage, $packagerootpath);
+        installer::scriptitems::add_rootpath_to_files($filesinpackage, $packagerootpath);
+        installer::scriptitems::add_rootpath_to_links($linksinpackage, $packagerootpath);
+        installer::scriptitems::add_rootpath_to_files($unixlinksinpackage, $packagerootpath);
 
-    if (!($installer::globals::is_copy_only_project))
-    {
-        if (( $installer::globals::iswindowsbuild ) && ( $installer::globals::packageformat ne "archive" ) && ( $installer::globals::packageformat ne "installed" ))
+        #################################
+        # collecting items for package
+        #################################
+
+        $filesinpackage = installer::packagelist::find_files_for_package($filesinpackage, $onepackage);
+        $unixlinksinpackage = installer::packagelist::find_files_for_package($unixlinksinpackage, $onepackage);
+        $linksinpackage = installer::packagelist::find_links_for_package($linksinpackage, $filesinpackage);
+        $dirsinpackage = installer::packagelist::find_dirs_for_package($dirsinpackage, $onepackage);
+
+        ###############################################
+        # nothing to do, if $filesinpackage is empty
+        ###############################################
+
+        if ( ! ( $#{$filesinpackage} > -1 ))
         {
-            installer::windows::msiglobal::set_global_code_variables($languagesarrayref, $languagestringref, $allvariableshashref, $alloldproperties);
+            push(@installer::globals::emptypackages, $packagename);
+            $installer::logger::Lang->print("\n");
+            $installer::logger::Lang->print("\n");
+            $installer::logger::Lang->print("No file in package: %s \-\> Skipping\n\n", $packagename);
+            next;   # next package, end of loop !
         }
-    }
 
-    ################################################
-    # Resolving include paths (language dependent)
-    ################################################
+        #################################################################
+        # nothing to do for Linux patches, if no file has flag PATCH
+        #################################################################
 
-    my $includepatharrayref_lang = installer::ziplist::replace_languages_in_pathes($includepatharrayref, $languagesarrayref);
+        # Linux Patch: The complete RPM has to be built, if one file in the RPM has the flag PATCH (also for DEBs)
+        if (( $installer::globals::patch ) && (( $installer::globals::islinuxrpmbuild ) || ( $installer::globals::islinuxdebbuild )))
+        {
+            my $patchfiles = installer::worker::collect_all_items_with_special_flag($filesinpackage ,"PATCH");
+            if ( ! ( $#{$patchfiles} > -1 ))
+            {
+                $installer::logger::Lang->print("\n");
+                $installer::logger::Lang->print("\n");
+                $installer::logger::Lang->print("Linux Patch: No patch file in package: %s \-\> Skipping\n\n",
+                    $packagename);
+                next;
+            }
+        }
 
-    if ( $installer::globals::refresh_includepathes ) { installer::worker::collect_all_files_from_includepathes($includepatharrayref_lang); }
+        ###########################################
+        # Stripping libraries
+        ###########################################
 
-    installer::ziplist::list_all_files_from_include_path($includepatharrayref_lang);
+        # Building for non Windows platforms in cws requires, that all files are stripped before packaging:
+        # 1. copy all files that need to be stripped locally
+        # 2. strip all these files
 
-    ##############################################
-    # Analyzing spellchecker languages
-    ##############################################
+        if ( $installer::globals::strip )
+        {
+            installer::strip::strip_libraries($filesinpackage, $languagestringref);
+        }
 
-    if ( $allvariableshashref->{'SPELLCHECKERFILE'} ) { installer::worker::set_spellcheckerlanguages($languagesarrayref, $allvariableshashref); }
+        ###############################################################
+        # Searching for files in $filesinpackage with flag LINUXLINK
+        ###############################################################
 
-    #####################################
-    # Language dependent directory part
-    #####################################
+        if (( $installer::globals::islinuxbuild ) && ( ! $installer::globals::simple )) # for rpms and debian packages
+        {
+            # special handling for all RPMs in $installer::globals::linuxlinkrpms
 
-    my $dirsinproductlanguageresolvedarrayref = installer::scriptitems::resolving_all_languages_in_productlists($dirsinproductarrayref, $languagesarrayref);
+            # if (( $installer::globals::linuxlinkrpms =~ /\b$onepackagename\b/ ) || ( $installer::globals::languagepack ))
+            if ( $installer::globals::linuxlinkrpms =~ /\b$onepackagename\b/ )
+            {
+                my $run = 0;
 
-    # A new directory array is needed ($dirsinproductlanguageresolvedarrayref instead of $dirsinproductarrayref)
-    # because $dirsinproductarrayref is needed in get_Destination_Directory_For_Item_From_Directorylist
+                if (( $installer::globals::makelinuxlinkrpm ) && ( ! $run ))
+                {
+                    $filesinpackage = \@installer::globals::linuxpatchfiles;
+                    $linksinpackage = \@installer::globals::linuxlinks;
+                    $installer::globals::makelinuxlinkrpm = 0;
+                    if ( $installer::globals::patch ) { $installer::globals::call_epm = 1; }     # enabling packing again
+                    $run = 1;
 
-    installer::scriptitems::changing_name_of_language_dependent_keys($dirsinproductlanguageresolvedarrayref);
+                }
 
-    installer::scriptitems::checking_directories_with_corrupt_hostname($dirsinproductlanguageresolvedarrayref, $languagesarrayref);
+                if (( ! $installer::globals::makelinuxlinkrpm ) && ( ! $run ))
+                {
+                    $filesinpackage = installer::worker::prepare_linuxlinkfiles($filesinpackage);
+                    $linksinpackage = installer::worker::prepare_forced_linuxlinkfiles($linksinpackage);
+                    $installer::globals::makelinuxlinkrpm = 1;
+                    if ( $allvariableshashref->{'OPENSOURCE'} ) { $installer::globals::add_required_package = $packagename . "u"; }
+                    if ( $installer::globals::patch ) { $installer::globals::call_epm = 0; }     # no packing of core module in patch
+                    $shellscriptsfilename = ""; # shell scripts only need to be included into the link rpm
+                    $run = 1;
 
-    installer::scriptitems::set_global_directory_hostnames($dirsinproductlanguageresolvedarrayref, $allvariableshashref);
+                }
+            }
+        }
 
-    #####################################
-    # files part, language dependent
-    #####################################
+        ###########################################
+        # Simple installation mechanism
+        ###########################################
 
-    $installer::logger::Info->print( "... analyzing files ...\n" );
+        if ( $installer::globals::simple ) { installer::worker::install_simple($onepackagename, $$languagestringref, $dirsinpackage, $filesinpackage, $linksinpackage, $unixlinksinpackage); }
 
-    my $filesinproductlanguageresolvedarrayref = installer::scriptitems::resolving_all_languages_in_productlists($filesinproductarrayref, $languagesarrayref);
+        ###########################################
+        # Checking epm state
+        ###########################################
 
-    if ( ! $installer::globals::set_office_start_language )
-    {
-        $filesinproductlanguageresolvedarrayref = installer::scriptitems::remove_office_start_language_files($filesinproductlanguageresolvedarrayref);
-    }
+        if (( $installer::globals::call_epm ) && ( ! $found_epm ))
+        {
+            $epmexecutable = installer::epmfile::find_epm_on_system($includepatharrayref);
+            installer::epmfile::set_patch_state($epmexecutable);    # setting $installer::globals::is_special_epm
+            $found_epm = 1; # searching only once
+        }
 
-    installer::scriptitems::changing_name_of_language_dependent_keys($filesinproductlanguageresolvedarrayref);
+        ###########################################
+        # Creating epm list file
+        ###########################################
 
-    if ( $installer::globals::iswin and $^O =~ /MSWin/i ) { installer::converter::convert_slash_to_backslash($filesinproductlanguageresolvedarrayref); }
+        if ( ! $installer::globals::simple )
+        {
+            # epm list file format:
+            # type mode owner group destination source options
+            # Example for a file: f 755 root sys /usr/bin/foo foo
+            # Example for a directory: d 755 root sys /var/spool/foo -
+            # Example for a link: l 000 root sys /usr/bin/linkname filename
+            # The source field specifies the file to link to
 
-    $filesinproductlanguageresolvedarrayref = installer::scriptitems::remove_non_existent_languages_in_productlists($filesinproductlanguageresolvedarrayref, $languagestringref, "Name", "file");
+            my $epmfilename = "epm_" . $onepackagename . $linkaddon . ".lst";
 
-    installer::scriptitems::get_Source_Directory_For_Files_From_Includepathlist($filesinproductlanguageresolvedarrayref, $includepatharrayref_lang, $dirsinproductlanguageresolvedarrayref, "Files");
+            $installer::logger::Info->print( "... creating epm list file $epmfilename ... \n" );
 
-    $filesinproductlanguageresolvedarrayref = installer::scriptitems::add_bundled_extension_blobs( $filesinproductlanguageresolvedarrayref);
-    ($filesinproductlanguageresolvedarrayref,$dirsinproductarrayref) = installer::scriptitems::add_bundled_prereg_extensions(
-        $filesinproductlanguageresolvedarrayref, $dirsinproductarrayref);
+            my $completeepmfilename = $listfiledir . $installer::globals::separator . $epmfilename;
 
-    installer::scriptitems::get_Destination_Directory_For_Item_From_Directorylist($filesinproductlanguageresolvedarrayref, $dirsinproductarrayref);
+            my @epmfile = ();
 
-    $filesinproductlanguageresolvedarrayref = installer::scriptitems::remove_Files_Without_Sourcedirectory($filesinproductlanguageresolvedarrayref);
+            my $epmheaderref = installer::epmfile::create_epm_header($allvariableshashref, $filesinproductlanguageresolvedarrayref, $languagesarrayref, $onepackage);
+            installer::epmfile::adding_header_to_epm_file(\@epmfile, $epmheaderref);
 
-    if ($installer::globals::languagepack)
-    {
-        $filesinproductlanguageresolvedarrayref = installer::scriptitems::remove_Files_For_Languagepacks($filesinproductlanguageresolvedarrayref);
-    }
+            if (( $installer::globals::patch ) && ( $installer::globals::issolarispkgbuild ))
+            {
+                $filesinpackage = installer::worker::analyze_patch_files($filesinpackage);
 
+                if ( ! ( $#{$filesinpackage} > -1 ))
+                {
+                    push(@installer::globals::emptypackages, $packagename);
+                    $installer::logger::Lang->print("\n");
+                    $installer::logger::Lang->print("No file in package: %s \-\> Skipping\n", $packagename);
+                    next;   # next package, end of loop !
+                }
+            }
 
-    if ( ! $allvariableshashref->{'NO_README_IN_ROOTDIR'} )
-    {
-        $filesinproductlanguageresolvedarrayref = installer::scriptitems::add_License_Files_into_Installdir($filesinproductlanguageresolvedarrayref, $dirsinproductlanguageresolvedarrayref, $languagesarrayref);
-    }
+            # adding directories, files and links into epm file
 
-    $filesinproductlanguageresolvedarrayref = installer::scriptitems::remove_onlyasialanguage_files_from_productlists($filesinproductlanguageresolvedarrayref);
+            installer::epmfile::put_directories_into_epmfile($dirsinpackage, \@epmfile, $allvariableshashref, $packagerootpath);
+            installer::epmfile::put_files_into_epmfile($filesinpackage, \@epmfile );
+            installer::epmfile::put_links_into_epmfile($linksinpackage, \@epmfile );
+            installer::epmfile::put_unixlinks_into_epmfile($unixlinksinpackage, \@epmfile );
 
-    $filesinproductlanguageresolvedarrayref = installer::scriptitems::remove_onlywesternlanguage_files_from_productlists($filesinproductlanguageresolvedarrayref);
+            if ((!( $shellscriptsfilename eq "" )) && (!($installer::globals::iswindowsbuild))) { installer::epmfile::adding_shellscripts_to_epm_file(\@epmfile, $shellscriptsfilename, $packagerootpath, $allvariableshashref, $filesinpackage); }
 
-    installer::scriptitems::make_filename_language_specific($filesinproductlanguageresolvedarrayref);
+            installer::files::save_file($completeepmfilename ,\@epmfile);
 
-    ######################################################################################
-    # Unzipping files with flag ARCHIVE and putting all included files into the file list
-    ######################################################################################
+            # ... splitting the rootpath into a relocatable part and a static part, if possible
 
-    $installer::logger::Info->print( "... analyzing files with flag ARCHIVE ...\n" );
+            my $staticpath = "";
+            my $relocatablepath = "";
+            # relocatable path can be defined in package list
+            if ( $onepackage->{'relocatablepath'} ) { $relocatablepath = $onepackage->{'relocatablepath'}; }
+            # setting fix part and variable part of destination path
+            installer::epmfile::analyze_rootpath($packagerootpath, \$staticpath, \$relocatablepath, $allvariableshashref);
 
-    my @additional_paths_from_zipfiles = ();
+            # ... replacing the variable PRODUCTDIRECTORYNAME in the shellscriptfile by $staticpath
 
-    $filesinproductlanguageresolvedarrayref = installer::archivefiles::resolving_archive_flag($filesinproductlanguageresolvedarrayref, \@additional_paths_from_zipfiles, $languagestringref, $loggingdir);
+            installer::epmfile::resolve_path_in_epm_list_before_packaging(\@epmfile, $completeepmfilename, "PRODUCTDIRECTORYNAME", $staticpath);
+            installer::epmfile::resolve_path_in_epm_list_before_packaging(\@epmfile, $completeepmfilename, "SOLSUREPACKAGEPREFIX", $allvariableshashref->{'SOLSUREPACKAGEPREFIX'});
+            installer::epmfile::resolve_path_in_epm_list_before_packaging(\@epmfile, $completeepmfilename, "UREPACKAGEPREFIX", $allvariableshashref->{'UREPACKAGEPREFIX'});
+            # installer::epmfile::resolve_path_in_epm_list_before_packaging(\@epmfile, $completeepmfilename, "BASISDIRECTORYVERSION", $allvariableshashref->{'OOOBASEVERSION'});
+            installer::files::save_file($completeepmfilename ,\@epmfile);
 
-    # packed files sometimes contain a "$" in their name: HighlightText$1.class. For epm the "$" has to be quoted by "$$"
+            #######################################################
+            # Now the complete content of the package is known,
+            # including variables and shell scripts.
+            # Create the package or using the package pool?
+            #######################################################
 
-    if (!( $installer::globals::iswindowsbuild || $installer::globals::simple ) )
-    {
-        installer::scriptitems::quoting_illegal_filenames($filesinproductlanguageresolvedarrayref);
-    }
+            my $use_package_from_pool = 0;
+            if ( $allvariableshashref->{'POOLPRODUCT'} ) { $use_package_from_pool = installer::packagepool::package_is_up_to_date($allvariableshashref, $onepackage, $packagename, \@epmfile, $filesinpackage, $installdir, $installer::globals::epmoutpath, $languagestringref); }
 
-    #####################################
-    # Files with flag SUBST_FILENAME
-    #####################################
-
-    $installer::logger::Info->print( "... analyzing files with flag SUBST_FILENAME ...\n" );
+            if ( $use_package_from_pool == 3 ) # repeat this package later
+            {
+                my $package_is_creatable = installer::packagepool::check_package_availability($packagename);
 
-    installer::substfilenamefiles::resolving_subst_filename_flag($filesinproductlanguageresolvedarrayref, $allvariableshashref, $languagestringref);
+                if (( ! $package_is_creatable ) && ( ! exists($installer::globals::poolshiftedpackages{$packagename}) ))
+                {
+                    splice(@{$packages}, $k, 1);    # removing package ...
+                    push(@{$packages}, $onepackage);  # ... and adding it to the end
+                    $installer::globals::poolshiftedpackages{$packagename} = 1; # only shifting each package once
+                    $k--;                                                       # decreasing the counter
+                    $installer::logger::Info->print("\n");
+                    $installer::logger::Info->print("Pool: Package \"%s\" cannot be created at the moment. Trying again later (2).\n", $packagename);
+                    $installer::logger::Lang->print("\n");
+                    $installer::logger::Lang->print("Pool: Package \"%s\" cannot be created at the moment. Trying again later (2).\n", $packagename);
+                    next;                                                       # repeating this iteration with new package
+                }
+            }
 
-    #####################################
-    # Files with flag SCPZIP_REPLACE
-    #####################################
+            if ( $use_package_from_pool == 4 ) # There was a problem with pooling. Repeat this package immediately.
+            {
+                $k--;                                                       # decreasing the counter
+                $installer::logger::Info->print("\n");
+                $installer::logger::Info->print("Pool: Package \"%s\" had pooling problems. Repeating packaging immediately (3).\n", $packagename);
+                $installer::logger::Lang->print("\n");
+                $installer::logger::Lang->print("Pool: Package \"%s\" had pooling problems. Repeating packaging immediately (3).\n", $packagename);
+                next;                                                       # repeating this iteration
+            }
 
-    $installer::logger::Info->print( "... analyzing files with flag SCPZIP_REPLACE ...\n" );
+            if ( $use_package_from_pool == 0 )
+            {
+                # changing into the "install" directory to create installation sets
 
-    # Editing files with flag SCPZIP_REPLACE.
+                $currentdir = cwd();    # $currentdir is global in this file
 
-    installer::scpzipfiles::resolving_scpzip_replace_flag($filesinproductlanguageresolvedarrayref, $allvariableshashref, "File", $languagestringref);
+                chdir($installdir);     # changing into install directory ($installdir is global in this file)
 
-    #####################################
-    # Files with flag PATCH_SO_NAME
-    #####################################
+                ###########################################
+                # Starting epm
+                ###########################################
 
-    $installer::logger::Info->print( "... analyzing files with flag PATCH_SO_NAME ...\n" );
+                # With a patched epm, it is now possible to set the relocatable directory, change
+                # the directory in which the packages are created, setting "requires" and "provides"
+                # (Linux) or creating the "depend" file (Solaris) and finally to begin
+                # the packaging process with standard tooling and standard parameter
+                # Linux: Adding into the spec file: Prefix: /opt
+                # Solaris: Adding into the pkginfo file: BASEDIR=/opt
+                # Attention: Changing of the path can influence the shell scripts
 
-    # Editing files with flag PATCH_SO_NAME.
+                if (( $installer::globals::is_special_epm ) && ( ($installer::globals::islinuxrpmbuild) || ($installer::globals::issolarispkgbuild) ))  # special handling only for Linux RPMs and Solaris Packages
+                {
+                    if ( $installer::globals::call_epm )    # only do something, if epm is really executed
+                    {
+                        # ... now epm can be started, to create the installation sets
 
-    installer::scppatchsoname::resolving_patchsoname_flag($filesinproductlanguageresolvedarrayref, $allvariableshashref, "File", $languagestringref);
+                        $installer::logger::Info->print( "... starting patched epm ... \n" );
 
-    #####################################
-    # Files with flag HIDDEN
-    #####################################
+                        installer::epmfile::call_epm($epmexecutable, $completeepmfilename, $packagename, $includepatharrayref);
 
-    $installer::logger::Info->print( "... analyzing files with flag HIDDEN ...\n" );
+                        my $newepmdir = installer::epmfile::prepare_packages($loggingdir, $packagename, $staticpath, $relocatablepath, $onepackage, $allvariableshashref, $filesinpackage, $languagestringref); # adding the line for Prefix / Basedir, include rpmdir
 
-    installer::worker::resolving_hidden_flag($filesinproductlanguageresolvedarrayref, $allvariableshashref, "File", $languagestringref);
+                        installer::epmfile::create_packages_without_epm($newepmdir, $packagename, $includepatharrayref, $allvariableshashref, $languagestringref);  # start to package
 
-    ############################################
-    # Collecting directories for epm list file
-    ############################################
+                        # finally removing all temporary files
 
-    $installer::logger::Info->print( "... analyzing all directories for this product ...\n" );
+                        installer::epmfile::remove_temporary_epm_files($newepmdir, $loggingdir, $packagename);
 
-    # There are two ways for a directory to be included into the epm directory list:
-    # 1. Looking for all destination paths in the files array
-    # 2. Looking for directories with CREATE flag in the directory array
-    # Advantage: Many pathes are hidden in zip files, they are not defined in the setup script.
-    # It will be possible, that in the setup script only those directoies have to be defined,
-    # that have a CREATE flag. All other directories are created, if they contain at least one file.
+                        # Installation:
+                        # Install: pkgadd -a myAdminfile -d ./SUNWso8m34.pkg
+                        # Install: rpm -i --prefix=/opt/special --nodeps so8m35.rpm
 
-    my ($directoriesforepmarrayref, $alldirectoryhash) = installer::scriptitems::collect_directories_from_filesarray($filesinproductlanguageresolvedarrayref);
+                        installer::epmfile::create_new_directory_structure($newepmdir);
+                        $installer::globals::postprocess_specialepm = 1;
 
-    ($directoriesforepmarrayref, $alldirectoryhash) = installer::scriptitems::collect_directories_with_create_flag_from_directoryarray($dirsinproductlanguageresolvedarrayref, $alldirectoryhash);
+                        # solaris patch not needed anymore
+                        # if (( $installer::globals::patch ) && ( $installer::globals::issolarisx86build )) { installer::worker::fix2_solaris_x86_patch($packagename, $installer::globals::epmoutpath); }
+                    }
+                }
+                else    # this is the standard epm (not relocatable) or ( nonlinux and nonsolaris )
+                {
+                    installer::epmfile::resolve_path_in_epm_list_before_packaging(\@epmfile, $completeepmfilename, "\$\$PRODUCTINSTALLLOCATION", $relocatablepath);
+                    installer::files::save_file($completeepmfilename ,\@epmfile);   # Warning for pool, content of epm file is changed.
 
-    # installer::sorter::sorting_array_of_hashes($directoriesforepmarrayref, "HostName");
+                    if ( $installer::globals::call_epm )
+                    {
+                        # ... now epm can be started, to create the installation sets
 
-    #########################################################
-    # language dependent scpactions part
-    #########################################################
+                        $installer::logger::Info->print( "... starting unpatched epm ... \n" );
 
-    my $scpactionsinproductlanguageresolvedarrayref = installer::scriptitems::resolving_all_languages_in_productlists($scpactionsinproductarrayref, $languagesarrayref);
+                        if ( $installer::globals::call_epm ) { installer::epmfile::call_epm($epmexecutable, $completeepmfilename, $packagename, $includepatharrayref); }
 
-    installer::scriptitems::changing_name_of_language_dependent_keys($scpactionsinproductlanguageresolvedarrayref);
+                        if (($installer::globals::islinuxrpmbuild) || ($installer::globals::issolarispkgbuild) || ($installer::globals::debian))
+                        {
+                            $installer::globals::postprocess_standardepm = 1;
+                        }
+                    }
+                }
 
-    installer::scriptitems::get_Source_Directory_For_Files_From_Includepathlist($scpactionsinproductlanguageresolvedarrayref, $includepatharrayref_lang, $dirsinproductlanguageresolvedarrayref, "ScpActions");
+                if ( $allvariableshashref->{'POOLPRODUCT'} ) { installer::packagepool::put_content_into_pool($packagename, $installdir, $installer::globals::epmoutpath, $filesinpackage, \@epmfile); }
 
-    # Editing scpactions with flag SCPZIP_REPLACE and PATCH_SO_NAME.
+                chdir($currentdir); # changing back into start directory
 
-    installer::scpzipfiles::resolving_scpzip_replace_flag($scpactionsinproductlanguageresolvedarrayref, $allvariableshashref, "ScpAction", $languagestringref);
+            } # end of "if ( ! $use_package_from_pool )
 
-    installer::scppatchsoname::resolving_patchsoname_flag($scpactionsinproductlanguageresolvedarrayref, $allvariableshashref, "ScpAction", $languagestringref);
+        } # end of "if ( ! $installer::globals::simple )
 
-    #########################################################
-    # language dependent links part
-    #########################################################
+        ###########################################
+        # xpd installation mechanism
+        ###########################################
 
-    $installer::logger::Info->print( "... analyzing links ...\n" );
+        # Creating the xpd file for the package. This has to happen always, not determined by $use_package_from_pool
 
-    my $linksinproductlanguageresolvedarrayref = installer::scriptitems::resolving_all_languages_in_productlists($linksinproductarrayref, $languagesarrayref);
+        if ( $installer::globals::isxpdplatform )
+        {
+            if (( ! $installer::globals::languagepack ) && ( ! $installer::globals::patch ))
+            {
+                if (( $allvariableshashref->{'XPDINSTALLER'} ) && ( $installer::globals::call_epm != 0 ))
+                {
+                    installer::xpdinstaller::create_xpd_file($onepackage, $packages, $languagestringref, $allvariableshashref, $modulesinproductarrayref, $installdir, $installer::globals::epmoutpath, $linkpackage, \%installer::globals::xpdpackageinfo);
+                    $installer::globals::xpd_files_prepared = 1;
+                    %installer::globals::xpdpackageinfo = ();
+                }
+            }
+        }
 
-    installer::scriptitems::changing_name_of_language_dependent_keys($linksinproductlanguageresolvedarrayref);
+        if ( $installer::globals::makelinuxlinkrpm ) { $k--; }  # decreasing the counter to create the link rpm!
 
-    installer::scriptitems::get_destination_file_path_for_links($linksinproductlanguageresolvedarrayref, $filesinproductlanguageresolvedarrayref);
+    }   # end of "for ( my $k = 0; $k <= $#{$packages}; $k++ )"
 
-    installer::scriptitems::get_Destination_Directory_For_Item_From_Directorylist($linksinproductlanguageresolvedarrayref, $dirsinproductarrayref);
+    installer::packagepool::log_pool_statistics();
 
-    # Now taking all links that have no FileID but a ShortcutID, linking to another link
+    ##############################################################
+    # Post epm functionality, after the last package is packed
+    ##############################################################
 
-    installer::scriptitems::get_destination_link_path_for_links($linksinproductlanguageresolvedarrayref);
+    if ( $installer::globals::postprocess_specialepm )
+    {
+        installer::logger::include_header_into_logfile("Post EPM processes (Patched EPM):");
 
-    $linksinproductlanguageresolvedarrayref = installer::scriptitems::remove_workstation_only_items($linksinproductlanguageresolvedarrayref);
+        chdir($installdir);
 
-    installer::scriptitems::resolve_links_with_flag_relative($linksinproductlanguageresolvedarrayref);
+        # Copying the cde, kde and gnome packages into the installation set
+        if ( $installer::globals::addsystemintegration ) { installer::epmfile::put_systemintegration_into_installset($installer::globals::epmoutpath, $includepatharrayref, $allvariableshashref, $modulesinproductarrayref); }
 
-    #########################################################
-    # language dependent unix links part
-    #########################################################
+        # Adding license and readme into installation set
+        # if ($installer::globals::addlicensefile) { installer::epmfile::put_installsetfiles_into_installset($installer::globals::epmoutpath); }
+        if ($installer::globals::addlicensefile) { installer::worker::put_scpactions_into_installset("."); }
 
-    $installer::logger::Info->print( "... analyzing unix links ...\n" );
+        # Adding child projects to installation dynamically
+        if ($installer::globals::addchildprojects) { installer::epmfile::put_childprojects_into_installset($installer::globals::epmoutpath, $allvariableshashref, $modulesinproductarrayref, $includepatharrayref); }
 
-    my $unixlinksinproductlanguageresolvedarrayref = installer::scriptitems::resolving_all_languages_in_productlists($unixlinksinproductarrayref, $languagesarrayref);
+        # Adding license file into setup
+        if ( $allvariableshashref->{'PUT_LICENSE_INTO_SETUP'} ) { installer::worker::put_license_into_setup(".", $includepatharrayref); }
 
-    installer::scriptitems::changing_name_of_language_dependent_keys($unixlinksinproductlanguageresolvedarrayref);
+        # Creating installation set for Unix language packs, that are not part of multi lingual installation sets
+        if ( ( $installer::globals::languagepack ) && ( ! $installer::globals::debian ) && ( ! $installer::globals::makedownload ) ) { installer::languagepack::build_installer_for_languagepack($installer::globals::epmoutpath, $allvariableshashref, $includepatharrayref, $languagesarrayref, $languagestringref); }
 
-    installer::scriptitems::get_Destination_Directory_For_Item_From_Directorylist($unixlinksinproductlanguageresolvedarrayref, $dirsinproductarrayref);
+        # Finalizing patch installation sets
+        if (( $installer::globals::patch ) && ( $installer::globals::issolarispkgbuild )) { installer::epmfile::finalize_patch($installer::globals::epmoutpath, $allvariableshashref); }
+        if (( $installer::globals::patch ) && ( $installer::globals::islinuxrpmbuild )) { installer::epmfile::finalize_linux_patch($installer::globals::epmoutpath, $allvariableshashref, $includepatharrayref); }
 
-    #########################################################
-    # language dependent part for profiles and profileitems
-    #########################################################
+        # Copying the xpd installer into the installation set
+        if (( $allvariableshashref->{'XPDINSTALLER'} ) && ( $installer::globals::isxpdplatform ) && ( $installer::globals::xpd_files_prepared ))
+        {
+            installer::xpdinstaller::create_xpd_installer($installdir, $allvariableshashref, $languagestringref);
+            $installer::globals::addjavainstaller = 0;  # only one java installer possible
+        }
 
-    my $profilesinproductlanguageresolvedarrayref;
-    my $profileitemsinproductlanguageresolvedarrayref;
+        # Copying the java installer into the installation set
+        chdir($currentdir); # changing back into start directory
+        if ( $installer::globals::addjavainstaller ) { installer::javainstaller::create_java_installer($installdir, $installer::globals::epmoutpath, $languagestringref, $languagesarrayref, $allvariableshashref, $includepatharrayref, $modulesinproductarrayref); }
+    }
 
-    if ((!($installer::globals::is_copy_only_project)) && (!($installer::globals::product =~ /ada/i )) && (!($installer::globals::languagepack)))
+    if ( $installer::globals::postprocess_standardepm )
     {
-        $installer::logger::Info->print( "... creating profiles ...\n" );
-
-        $profilesinproductlanguageresolvedarrayref = installer::scriptitems::resolving_all_languages_in_productlists($profilesinproductarrayref, $languagesarrayref);
+        installer::logger::include_header_into_logfile("Post EPM processes (Standard EPM):");
 
-        $profileitemsinproductlanguageresolvedarrayref = installer::scriptitems::resolving_all_languages_in_productlists($profileitemsinproductarrayref, $languagesarrayref);
-
-        installer::scriptitems::changing_name_of_language_dependent_keys($profilesinproductlanguageresolvedarrayref);
+        chdir($installdir);
 
-        installer::scriptitems::changing_name_of_language_dependent_keys($profileitemsinproductlanguageresolvedarrayref);
+        # determine the destination directory
+        my $newepmdir = installer::epmfile::determine_installdir_ooo();
 
-        installer::scriptitems::replace_setup_variables($profileitemsinproductlanguageresolvedarrayref, $languagestringref, $allvariableshashref);
+        # Copying the cde, kde and gnome packages into the installation set
+        if ( $installer::globals::addsystemintegration ) { installer::epmfile::put_systemintegration_into_installset($newepmdir, $includepatharrayref, $allvariableshashref, $modulesinproductarrayref); }
 
-        if ( $installer::globals::patch_user_dir )
-        {
-            installer::scriptitems::replace_userdir_variable($profileitemsinproductlanguageresolvedarrayref);
-        }
+        # Adding license and readme into installation set
+        # if ($installer::globals::addlicensefile) { installer::epmfile::put_installsetfiles_into_installset($newepmdir); }
+        if ($installer::globals::addlicensefile) { installer::worker::put_scpactions_into_installset("."); }
 
-        installer::scriptitems::get_Destination_Directory_For_Item_From_Directorylist($profilesinproductlanguageresolvedarrayref, $dirsinproductarrayref);
+        # Adding license file into setup
+        if ( $allvariableshashref->{'PUT_LICENSE_INTO_SETUP'} ) { installer::worker::put_license_into_setup(".", $includepatharrayref); }
 
-        # Now the Profiles can be created
+        # Creating installation set for Unix language packs, that are not part of multi lingual installation sets
+        if ( ( $installer::globals::languagepack ) && ( ! $installer::globals::debian ) && ( ! $installer::globals::makedownload ) ) { installer::languagepack::build_installer_for_languagepack($newepmdir, $allvariableshashref, $includepatharrayref, $languagesarrayref, $languagestringref); }
 
-        installer::profiles::create_profiles($profilesinproductlanguageresolvedarrayref, $profileitemsinproductlanguageresolvedarrayref, $filesinproductlanguageresolvedarrayref, $languagestringref, $allvariableshashref);
+        chdir($currentdir); # changing back into start directory
     }
 
-    my $registryitemsinproductlanguageresolvedarrayref; # cannot be defined in the following "if ( $installer::globals::iswindowsbuild )"
-    my $folderinproductlanguageresolvedarrayref;        # cannot be defined in the following "if ( $installer::globals::iswindowsbuild )"
-    my $folderitemsinproductlanguageresolvedarrayref;   # cannot be defined in the following "if ( $installer::globals::iswindowsbuild )"
-
-    if ( $installer::globals::iswindowsbuild )  # Windows specific items: Folder, FolderItem, RegistryItem
-    {
-        #########################################################
-        # language dependent part for folder
-        #########################################################
-
-        $installer::logger::Info->print( "... analyzing folder ...\n" );
+    if (( $installer::globals::issolarispkgbuild ) && ( $allvariableshashref->{'COLLECT_PKGMAP'} )) { installer::worker::collectpackagemaps($installdir, $languagestringref, $allvariableshashref); }
 
-        $folderinproductlanguageresolvedarrayref = installer::scriptitems::resolving_all_languages_in_productlists($folderinproductarrayref, $languagesarrayref);
+    #######################################################
+    # Analyzing the log file
+    #######################################################
 
-        installer::scriptitems::changing_name_of_language_dependent_keys($folderinproductlanguageresolvedarrayref);
+    my $is_success = 0;
+    my $finalinstalldir = "";
 
-        #########################################################
-        # language dependent part for folderitems
-        #########################################################
+    installer::worker::clean_output_tree(); # removing directories created in the output tree
+    ($is_success, $finalinstalldir) = installer::worker::analyze_and_save_logfile($loggingdir, $installdir, $installlogdir, $allsettingsarrayref, $languagestringref, $current_install_number);
+    my $downloadname = installer::ziplist::getinfofromziplist($allsettingsarrayref, "downloadname");
+    if ( $is_success ) { installer::followme::save_followme_info($finalinstalldir, $includepatharrayref, $allvariableshashref, $$downloadname, $languagestringref, $languagesarrayref, $current_install_number, $loggingdir, $installlogdir); }
 
-        $installer::logger::Info->print( "... analyzing folderitems ...\n" );
+    #######################################################
+    # Creating download installation set
+    #######################################################
 
-        $folderitemsinproductlanguageresolvedarrayref = installer::scriptitems::resolving_all_languages_in_productlists($folderitemsinproductarrayref, $languagesarrayref);
+    if ( $installer::globals::makedownload )
+    {
+        my $create_download = 0;
+        if ( $$downloadname ne "" ) { $create_download = 1; }
+        if (( $is_success ) && ( $create_download ) && ( $ENV{'ENABLE_DOWNLOADSETS'} ))
+        {
+            my $downloaddir = installer::download::create_download_sets($finalinstalldir, $includepatharrayref, $allvariableshashref, $$downloadname, $languagestringref, $languagesarrayref);
+            installer::worker::analyze_and_save_logfile($loggingdir, $downloaddir, $installlogdir, $allsettingsarrayref, $languagestringref, $current_install_number);
+        }
+    }
 
-        installer::scriptitems::changing_name_of_language_dependent_keys($folderitemsinproductlanguageresolvedarrayref);
+    #######################################################
+    # Creating jds installation set
+    #######################################################
 
-        #########################################################
-        # language dependent part for registryitems
-        #########################################################
+    if ( $installer::globals::makejds )
+    {
+        my $create_jds = 0;
 
-        $installer::logger::Info->print( "... analyzing registryitems ...\n" );
+        if ( $allvariableshashref->{'JDSBUILD'} ) { $create_jds = 1; }
+        if (! $installer::globals::issolarispkgbuild ) { $create_jds = 0; }
 
-        $registryitemsinproductlanguageresolvedarrayref = installer::scriptitems::resolving_all_languages_in_productlists($registryitemsinproductarrayref, $languagesarrayref);
+        if (( $is_success ) && ( $create_jds ))
+        {
+            if ( ! $installer::globals::jds_language_controlled )
+            {
+                my $correct_language = installer::worker::check_jds_language($allvariableshashref, $languagestringref);
+                $installer::globals::correct_jds_language = $correct_language;
+                $installer::globals::jds_language_controlled = 1;
+            }
 
-        installer::scriptitems::changing_name_of_language_dependent_keys($registryitemsinproductlanguageresolvedarrayref);
+            if ( $installer::globals::correct_jds_language )
+            {
+                my $jdsdir = installer::worker::create_jds_sets($finalinstalldir, $allvariableshashref, $languagestringref, $languagesarrayref, $includepatharrayref);
+                installer::worker::clean_jds_temp_dirs();
+                installer::worker::analyze_and_save_logfile($loggingdir, $jdsdir, $installlogdir, $allsettingsarrayref, $languagestringref, $current_install_number);
+            }
+        }
     }
+}
 
-    #########################################################
-    # language dependent part for modules
-    #########################################################
-
-    my $modulesinproductlanguageresolvedarrayref;
 
-    if (!($installer::globals::is_copy_only_project))
-    {
-        $installer::logger::Info->print( "... analyzing modules ...\n" );
 
-        $modulesinproductlanguageresolvedarrayref = installer::scriptitems::resolving_all_languages_in_productlists($modulesinproductarrayref, $languagesarrayref);
 
-        $modulesinproductlanguageresolvedarrayref = installer::scriptitems::remove_not_required_language_modules($modulesinproductlanguageresolvedarrayref, $languagesarrayref);
+#################################################
+# Main program
+#################################################
 
-        installer::scriptitems::changing_name_of_language_dependent_keys($modulesinproductlanguageresolvedarrayref);
+#################################################
+# Part 1: The platform independent part
+#################################################
 
-        # installer::scriptitems::collect_language_specific_names($modulesinproductlanguageresolvedarrayref);
-        installer::scriptitems::select_required_language_strings($modulesinproductlanguageresolvedarrayref);    # using english strings
-    }
+#################################################
+# Part 1a: The language independent part
+#################################################
 
-    # Copy-only projects can now start to copy all items File and ScpAction
-    if ( $installer::globals::is_copy_only_project ) { installer::copyproject::copy_project($filesinproductlanguageresolvedarrayref, $scpactionsinproductlanguageresolvedarrayref, $loggingdir, $languagestringref, $shipinstalldir, $allsettingsarrayref); }
+installer::logger::starttime();
+$installer::logger::Global->add_timestamp("starting logging");
 
-    # Language pack projects can now start to select the required information
-    if ( $installer::globals::languagepack )
-    {
-        $filesinproductlanguageresolvedarrayref = installer::languagepack::select_language_items($filesinproductlanguageresolvedarrayref, $languagesarrayref, "File");
-        $scpactionsinproductlanguageresolvedarrayref = installer::languagepack::select_language_items($scpactionsinproductlanguageresolvedarrayref, $languagesarrayref, "ScpAction");

... etc. - the rest is truncated


More information about the Libreoffice-commits mailing list