basctl/uiconfig/basicide/menubar/menubar.xml | 3 bin/pack-debug | 195 ++++++++++++++++++ chart2/uiconfig/menubar/menubar.xml | 3 config_host.mk.in | 1 configure.ac | 3 dbaccess/uiconfig/dbapp/menubar/menubar.xml | 3 dbaccess/uiconfig/dbquery/menubar/menubar.xml | 3 dbaccess/uiconfig/dbrelation/menubar/menubar.xml | 3 dbaccess/uiconfig/dbtable/menubar/menubar.xml | 3 dbaccess/uiconfig/dbtdata/menubar/menubar.xml | 3 extensions/uiconfig/sbibliography/menubar/menubar.xml | 3 framework/uiconfig/startmodule/menubar/menubar.xml | 3 reportdesign/uiconfig/dbreport/menubar/menubar.xml | 3 sc/uiconfig/scalc/menubar/menubar.xml | 3 sd/uiconfig/sdraw/menubar/menubar.xml | 3 sd/uiconfig/simpress/menubar/menubar.xml | 3 sfx2/source/appl/appserv.cxx | 32 ++ sfx2/source/view/viewfrm.cxx | 58 ----- sfx2/uiconfig/ui/licensedialog.ui | 49 +++- solenv/bin/modules/installer.pm | 53 ++++ solenv/bin/modules/installer/environment.pm | 3 solenv/bin/modules/installer/epmfile.pm | 22 +- solenv/bin/modules/installer/splitdbg.pm | 121 +++++++++++ starmath/uiconfig/smath/menubar/menubar.xml | 3 sw/uiconfig/sglobal/menubar/menubar.xml | 3 sw/uiconfig/sweb/menubar/menubar.xml | 3 sw/uiconfig/swform/menubar/menubar.xml | 3 sw/uiconfig/swreport/menubar/menubar.xml | 3 sw/uiconfig/swriter/menubar/menubar.xml | 3 sw/uiconfig/swxform/menubar/menubar.xml | 3 30 files changed, 458 insertions(+), 139 deletions(-)
New commits: commit 3f6fc4285e41311dd79d4f35018c4a6856083e68 Author: Andras Timar <andras.ti...@collabora.com> AuthorDate: Sun Jul 14 20:28:13 2019 +0200 Commit: Andras Timar <andras.ti...@collabora.com> CommitDate: Sat Jan 28 14:49:55 2023 +0100 [cp] remove donate and community involvement infobars Change-Id: I37c9c76eb88dea4effa786b62755ea8738efc3e0 Reviewed-on: https://gerrit.libreoffice.org/75600 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoff...@gmail.com> Reviewed-by: Andras Timar <andras.ti...@collabora.com> diff --git a/sfx2/source/view/viewfrm.cxx b/sfx2/source/view/viewfrm.cxx index 68ea4a3f8933..1268e48643c4 100644 --- a/sfx2/source/view/viewfrm.cxx +++ b/sfx2/source/view/viewfrm.cxx @@ -1449,63 +1449,6 @@ void SfxViewFrame::Notify( SfxBroadcaster& /*rBC*/, const SfxHint& rHint ) GetDispatcher()->ExecuteList(SID_TIPOFTHEDAY, SfxCallMode::SLOT, {}, { &aDocFrame }); } - // inform about the community involvement - const auto t0 = std::chrono::system_clock::now().time_since_epoch(); - const sal_Int64 nLastGetInvolvedShown = officecfg::Setup::Product::LastTimeGetInvolvedShown::get(); - const sal_Int64 nNow = std::chrono::duration_cast<std::chrono::seconds>(t0).count(); - const sal_Int64 nPeriodSec(60 * 60 * 24 * 180); // 180 days in seconds - bool bUpdateLastTimeGetInvolvedShown = false; - - if (nLastGetInvolvedShown == 0) - bUpdateLastTimeGetInvolvedShown = true; - else if (nPeriodSec < nNow && nLastGetInvolvedShown < (nNow + nPeriodSec/2) - nPeriodSec) // 90d alternating with donation - { - bUpdateLastTimeGetInvolvedShown = true; - - VclPtr<SfxInfoBarWindow> pInfoBar = AppendInfoBar("getinvolved", "", SfxResId(STR_GET_INVOLVED_TEXT), InfobarType::INFO); - - if (pInfoBar) - { - weld::Button& rGetInvolvedButton = pInfoBar->addButton(); - rGetInvolvedButton.set_label(SfxResId(STR_GET_INVOLVED_BUTTON)); - rGetInvolvedButton.connect_clicked(LINK(this, SfxViewFrame, GetInvolvedHandler)); - } - } - - if (bUpdateLastTimeGetInvolvedShown - && !officecfg::Setup::Product::LastTimeGetInvolvedShown::isReadOnly()) - { - std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); - officecfg::Setup::Product::LastTimeGetInvolvedShown::set(nNow, batch); - batch->commit(); - } - - // inform about donations - const sal_Int64 nLastDonateShown = officecfg::Setup::Product::LastTimeDonateShown::get(); - bool bUpdateLastTimeDonateShown = false; - - if (nLastDonateShown == 0) - bUpdateLastTimeDonateShown = true; - else if (nPeriodSec < nNow && nLastDonateShown < nNow - nPeriodSec) // 90d alternating with getinvolved - { - bUpdateLastTimeDonateShown = true; - - VclPtr<SfxInfoBarWindow> pInfoBar = AppendInfoBar("donate", "", SfxResId(STR_DONATE_TEXT), InfobarType::INFO); - if (pInfoBar) - { - weld::Button& rDonateButton = pInfoBar->addButton(); - rDonateButton.set_label(SfxResId(STR_DONATE_BUTTON)); - rDonateButton.connect_clicked(LINK(this, SfxViewFrame, DonationHandler)); - } - } - - if (bUpdateLastTimeDonateShown - && !officecfg::Setup::Product::LastTimeDonateShown::isReadOnly()) - { - std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); - officecfg::Setup::Product::LastTimeDonateShown::set(nNow, batch); - batch->commit(); - } #endif if (officecfg::Office::Common::Passwords::HasMaster::get() && officecfg::Office::Common::Passwords::StorageVersion::get() == 0) @@ -1528,7 +1471,6 @@ void SfxViewFrame::Notify( SfxBroadcaster& /*rBC*/, const SfxHint& rHint ) } } } - const bool bEmbedded = m_xObjSh->GetCreateMode() == SfxObjectCreateMode::EMBEDDED; // read-only infobar if necessary commit cbeaa2740dee954a530c0778fe5fa349aca7bea6 Author: Andras Timar <andras.ti...@collabora.com> AuthorDate: Tue Apr 17 13:28:26 2018 +0200 Commit: Andras Timar <andras.ti...@collabora.com> CommitDate: Sat Jan 28 14:41:25 2023 +0100 [cp] Remove Help - Donate to LibreOffice menu item ... and remove Help - Get Involved menu item, too Change-Id: I7a701173f596306ee628ae4a12ad81d2d756caca diff --git a/basctl/uiconfig/basicide/menubar/menubar.xml b/basctl/uiconfig/basicide/menubar/menubar.xml index ac59065c9daf..68f7cbab6742 100644 --- a/basctl/uiconfig/basicide/menubar/menubar.xml +++ b/basctl/uiconfig/basicide/menubar/menubar.xml @@ -166,9 +166,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/chart2/uiconfig/menubar/menubar.xml b/chart2/uiconfig/menubar/menubar.xml index 58c84d6cbc33..bfdf1f77384f 100644 --- a/chart2/uiconfig/menubar/menubar.xml +++ b/chart2/uiconfig/menubar/menubar.xml @@ -167,9 +167,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/dbaccess/uiconfig/dbapp/menubar/menubar.xml b/dbaccess/uiconfig/dbapp/menubar/menubar.xml index 29e65762524c..d424dc3d3be8 100644 --- a/dbaccess/uiconfig/dbapp/menubar/menubar.xml +++ b/dbaccess/uiconfig/dbapp/menubar/menubar.xml @@ -153,9 +153,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/dbaccess/uiconfig/dbquery/menubar/menubar.xml b/dbaccess/uiconfig/dbquery/menubar/menubar.xml index 762a5533de74..5a404026788b 100644 --- a/dbaccess/uiconfig/dbquery/menubar/menubar.xml +++ b/dbaccess/uiconfig/dbquery/menubar/menubar.xml @@ -108,9 +108,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/dbaccess/uiconfig/dbrelation/menubar/menubar.xml b/dbaccess/uiconfig/dbrelation/menubar/menubar.xml index 0c2a73ec31d5..f9fa2b80f436 100644 --- a/dbaccess/uiconfig/dbrelation/menubar/menubar.xml +++ b/dbaccess/uiconfig/dbrelation/menubar/menubar.xml @@ -92,9 +92,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/dbaccess/uiconfig/dbtable/menubar/menubar.xml b/dbaccess/uiconfig/dbtable/menubar/menubar.xml index 80511e8ea4d6..5d34f377e22e 100644 --- a/dbaccess/uiconfig/dbtable/menubar/menubar.xml +++ b/dbaccess/uiconfig/dbtable/menubar/menubar.xml @@ -92,9 +92,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/dbaccess/uiconfig/dbtdata/menubar/menubar.xml b/dbaccess/uiconfig/dbtdata/menubar/menubar.xml index e787d60d7355..4783fcf6a342 100644 --- a/dbaccess/uiconfig/dbtdata/menubar/menubar.xml +++ b/dbaccess/uiconfig/dbtdata/menubar/menubar.xml @@ -117,9 +117,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/extensions/uiconfig/sbibliography/menubar/menubar.xml b/extensions/uiconfig/sbibliography/menubar/menubar.xml index 9b449072ac32..66b245f7b43e 100644 --- a/extensions/uiconfig/sbibliography/menubar/menubar.xml +++ b/extensions/uiconfig/sbibliography/menubar/menubar.xml @@ -66,9 +66,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/framework/uiconfig/startmodule/menubar/menubar.xml b/framework/uiconfig/startmodule/menubar/menubar.xml index 72f0354a79df..c5bea72f2e7e 100644 --- a/framework/uiconfig/startmodule/menubar/menubar.xml +++ b/framework/uiconfig/startmodule/menubar/menubar.xml @@ -68,9 +68,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/reportdesign/uiconfig/dbreport/menubar/menubar.xml b/reportdesign/uiconfig/dbreport/menubar/menubar.xml index e95054ed7889..1d26cebe00d5 100644 --- a/reportdesign/uiconfig/dbreport/menubar/menubar.xml +++ b/reportdesign/uiconfig/dbreport/menubar/menubar.xml @@ -283,9 +283,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/sc/uiconfig/scalc/menubar/menubar.xml b/sc/uiconfig/scalc/menubar/menubar.xml index c16dbf11e73b..8c732452103d 100644 --- a/sc/uiconfig/scalc/menubar/menubar.xml +++ b/sc/uiconfig/scalc/menubar/menubar.xml @@ -785,9 +785,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/sd/uiconfig/sdraw/menubar/menubar.xml b/sd/uiconfig/sdraw/menubar/menubar.xml index c3792e54767d..640a4446e322 100644 --- a/sd/uiconfig/sdraw/menubar/menubar.xml +++ b/sd/uiconfig/sdraw/menubar/menubar.xml @@ -650,9 +650,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/sd/uiconfig/simpress/menubar/menubar.xml b/sd/uiconfig/simpress/menubar/menubar.xml index 1c44f8d5044d..23f80c7276a5 100644 --- a/sd/uiconfig/simpress/menubar/menubar.xml +++ b/sd/uiconfig/simpress/menubar/menubar.xml @@ -681,9 +681,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/starmath/uiconfig/smath/menubar/menubar.xml b/starmath/uiconfig/smath/menubar/menubar.xml index b9ed1026283a..1cb6d84b3f7e 100644 --- a/starmath/uiconfig/smath/menubar/menubar.xml +++ b/starmath/uiconfig/smath/menubar/menubar.xml @@ -160,9 +160,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/sw/uiconfig/sglobal/menubar/menubar.xml b/sw/uiconfig/sglobal/menubar/menubar.xml index 9b9d37689f10..1c67b22e08c8 100644 --- a/sw/uiconfig/sglobal/menubar/menubar.xml +++ b/sw/uiconfig/sglobal/menubar/menubar.xml @@ -798,9 +798,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/sw/uiconfig/sweb/menubar/menubar.xml b/sw/uiconfig/sweb/menubar/menubar.xml index dc0715beeb81..8bde4e44ca62 100644 --- a/sw/uiconfig/sweb/menubar/menubar.xml +++ b/sw/uiconfig/sweb/menubar/menubar.xml @@ -659,9 +659,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/sw/uiconfig/swform/menubar/menubar.xml b/sw/uiconfig/swform/menubar/menubar.xml index 5eebcc9a96a1..e81736dd0f7a 100644 --- a/sw/uiconfig/swform/menubar/menubar.xml +++ b/sw/uiconfig/swform/menubar/menubar.xml @@ -740,9 +740,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/sw/uiconfig/swreport/menubar/menubar.xml b/sw/uiconfig/swreport/menubar/menubar.xml index 92f17fadd3f4..f070764c28ed 100644 --- a/sw/uiconfig/swreport/menubar/menubar.xml +++ b/sw/uiconfig/swreport/menubar/menubar.xml @@ -698,9 +698,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/sw/uiconfig/swriter/menubar/menubar.xml b/sw/uiconfig/swriter/menubar/menubar.xml index 295dfe7280c6..0e7fc10063f5 100644 --- a/sw/uiconfig/swriter/menubar/menubar.xml +++ b/sw/uiconfig/swriter/menubar/menubar.xml @@ -832,9 +832,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> diff --git a/sw/uiconfig/swxform/menubar/menubar.xml b/sw/uiconfig/swxform/menubar/menubar.xml index a4af6780f03d..e41926c58ce8 100644 --- a/sw/uiconfig/swxform/menubar/menubar.xml +++ b/sw/uiconfig/swxform/menubar/menubar.xml @@ -787,9 +787,6 @@ <menu:menuseparator/> <menu:menuitem menu:id=".uno:SafeMode"/> <menu:menuseparator/> - <menu:menuitem menu:id=".uno:GetInvolved"/> - <menu:menuitem menu:id=".uno:Donation"/> - <menu:menuseparator/> <menu:menuitem menu:id=".uno:ShowLicense"/> <menu:menuitem menu:id=".uno:About"/> </menu:menupopup> commit abcfc630127f4cf41e854f0936e7f130353fd289 Author: Andras Timar <andras.ti...@collabora.com> AuthorDate: Tue Apr 17 14:06:38 2018 +0200 Commit: Andras Timar <andras.ti...@collabora.com> CommitDate: Sat Jan 28 14:41:01 2023 +0100 [cp] Send feedback to he...@collaboraoffice.com Change-Id: Ic734235426001e4aa7119476c1e6884b7c39776d diff --git a/sfx2/source/appl/appserv.cxx b/sfx2/source/appl/appserv.cxx index e603b02ee05d..ace3a1434a63 100644 --- a/sfx2/source/appl/appserv.cxx +++ b/sfx2/source/appl/appserv.cxx @@ -519,10 +519,8 @@ void SfxApplication::MiscExec_Impl( SfxRequest& rReq ) case SID_SEND_FEEDBACK: { OUString module = SfxHelp::GetCurrentModuleIdentifier(); - OUString sURL(officecfg::Office::Common::Menus::SendFeedbackURL::get() + //officecfg/registry/data/org/openoffice/Office/Common.xcu => https://hub.libreoffice.org/send-feedback/ - "?LOversion=" + utl::ConfigManager::getAboutBoxProductVersion() + - "&LOlocale=" + utl::ConfigManager::getUILocale() + - "&LOmodule=" + module.subView(module.lastIndexOf('.') + 1 ) ); + OUString sURL("mailto:he...@collaboraoffice.com?Subject=Version:%20" + utl::ConfigManager::getAboutBoxProductVersion() + + ",%20Locale:%20" + utl::ConfigManager::getUILocale() + ",%20Module:%20" + module.subView(module.lastIndexOf('.') + 1 ) ); sfx2::openUriExternally(sURL, false, rReq.GetFrameWeld()); break; } commit 708213b118aa21a26fffcb9264d2cdf1d5d4852b Author: Andras Timar <andras.ti...@collabora.com> AuthorDate: Thu Mar 9 12:28:39 2017 +0100 Commit: Andras Timar <andras.ti...@collabora.com> CommitDate: Sat Jan 28 14:23:35 2023 +0100 [cp] don't allow space in INSTALLDIRNAME (cherry picked from commit 2fc7778ba2ce545ecb6bd2e60a09eeb8fdb44b49) Change-Id: I4c20ab9051b49149d4cd52339a61c98f5f62226b diff --git a/configure.ac b/configure.ac index 24a8c9ec6471..f3d5bc37f2af 100644 --- a/configure.ac +++ b/configure.ac @@ -14186,7 +14186,7 @@ else fi AC_SUBST(WITH_COMPAT_OOWRAPPERS) -INSTALLDIRNAME=`echo AC_PACKAGE_NAME | $AWK '{print tolower($0)}'` +INSTALLDIRNAME=`echo AC_PACKAGE_NAME | $AWK '{gsub(" ", "", $0);print tolower($0)}'` AC_MSG_CHECKING([for install dirname]) if test -n "$with_install_dirname" -a "$with_install_dirname" != "no" -a "$with_install_dirname" != "yes"; then INSTALLDIRNAME="$with_install_dirname" commit 56d6f6f6842c7fbf39a445cc10a59cb0448f2db2 Author: Andras Timar <andras.ti...@collabora.com> AuthorDate: Sat Jul 13 08:02:27 2019 +0200 Commit: Andras Timar <andras.ti...@collabora.com> CommitDate: Sat Jan 28 11:31:28 2023 +0100 [cp] use packagerevision for rpm, too Change-Id: I8e1431e8db870c2782f22f8450b97cef180f1e33 diff --git a/solenv/bin/modules/installer/epmfile.pm b/solenv/bin/modules/installer/epmfile.pm index 904b35a462d6..4a24e6ab2089 100644 --- a/solenv/bin/modules/installer/epmfile.pm +++ b/solenv/bin/modules/installer/epmfile.pm @@ -316,7 +316,7 @@ sub create_epm_header push(@epmheader, $line); $line = "%release" . " " . $installer::globals::packagerevision . "\n"; - if ( $installer::globals::isrpmbuild ) { $line = "%release" . " " . $installer::globals::buildid . "\n"; } + #if ( $installer::globals::isrpmbuild ) { $line = "%release" . " " . $installer::globals::buildid . "\n"; } push(@epmheader, $line); # Description, Copyright and Vendor are multilingual and are defined in commit 34fb73145f0c6eae27fe5da57d71d34b7af6e17e Author: Andras Timar <andras.ti...@collabora.com> AuthorDate: Tue Feb 22 13:22:54 2022 +0100 Commit: Andras Timar <andras.ti...@collabora.com> CommitDate: Sat Jan 28 11:29:44 2023 +0100 eliminate ENABLE_STRIP because it causes build issues in nss (Android) Change-Id: Ie229f444d80a5f441576649e22b0c56c67cd3424 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130347 Tested-by: Andras Timar <andras.ti...@collabora.com> Reviewed-by: Andras Timar <andras.ti...@collabora.com> diff --git a/config_host.mk.in b/config_host.mk.in index 1d5186aee280..addccaeeb44f 100644 --- a/config_host.mk.in +++ b/config_host.mk.in @@ -213,7 +213,6 @@ export ENABLE_CUSTOMTARGET_COMPONENTS=@ENABLE_CUSTOMTARGET_COMPONENTS@ export ENABLE_SILENT_MSI=@ENABLE_SILENT_MSI@ export ENABLE_SKIA=@ENABLE_SKIA@ export ENABLE_SKIA_DEBUG=@ENABLE_SKIA_DEBUG@ -export ENABLE_STRIP=@ENABLE_STRIP@ export ENABLE_SYMBOLS_FOR=@ENABLE_SYMBOLS_FOR@ export ENABLE_VALGRIND=@ENABLE_VALGRIND@ export ENABLE_WASM_EXCEPTIONS=@ENABLE_WASM_EXCEPTIONS@ diff --git a/configure.ac b/configure.ac index 8b3693669c9d..24a8c9ec6471 100644 --- a/configure.ac +++ b/configure.ac @@ -4885,25 +4885,16 @@ if test -z "$enable_symbols"; then fi if test "$enable_symbols" = yes; then ENABLE_SYMBOLS_FOR=all - ENABLE_STRIP= - DISABLE_STRIP=1 AC_MSG_RESULT([yes]) elif test "$enable_symbols" = no; then ENABLE_SYMBOLS_FOR= - ENABLE_STRIP=1 - DISABLE_STRIP= AC_MSG_RESULT([no]) else # Selective debuginfo. ENABLE_SYMBOLS_FOR="$enable_symbols" - ENABLE_STRIP= - DISABLE_STRIP=1 AC_MSG_RESULT([for "$enable_symbols"]) fi AC_SUBST(ENABLE_SYMBOLS_FOR) -AC_SUBST(ENABLE_STRIP) -AC_SUBST(DISABLE_STRIP) - if test -n "$with_android_ndk" -a \( -n "$ENABLE_SYMBOLS" -o -n "$ENABLE_DEBUG" -o -n "$ENABLE_DBGUTIL" \) -a "$ENABLE_DEBUGINFO_FOR" = "all"; then # Building on Android with full symbols: without enough memory the linker never finishes currently. AC_MSG_CHECKING([whether enough memory is available for linking]) diff --git a/solenv/bin/modules/installer/environment.pm b/solenv/bin/modules/installer/environment.pm index 42861e6ac080..c2add9cadb41 100644 --- a/solenv/bin/modules/installer/environment.pm +++ b/solenv/bin/modules/installer/environment.pm @@ -123,8 +123,7 @@ sub set_global_environment_variables if ( $ENV{'RPM'} ) { $installer::globals::rpm = $ENV{'RPM'}; } if ( $ENV{'DONTCOMPRESS'} ) { $installer::globals::solarisdontcompress = 1; } if ( $ENV{'IGNORE_ERROR_IN_LOGFILE'} ) { $installer::globals::ignore_error_in_logfile = 1; } - if (( $ENV{'ENABLE_STRIP'} ) && ( $ENV{'ENABLE_STRIP'} ne '' )) { $installer::globals::strip = 1; } - if (( $ENV{'DISABLE_STRIP'} ) && ( $ENV{'DISABLE_STRIP'} ne '' )) { $installer::globals::strip = 0; } + if (!( $ENV{'ENABLE_SYMBOLS_FOR'} ) || !( $ENV{'ENABLE_SYMBOLS_FOR'} ne '' )) { $installer::globals::strip = 1; } # it is 0 by default if ( $installer::globals::localinstalldir ) { $installer::globals::localinstalldirset = 1; } # Special handling, if LOCALINSTALLDIR contains "~" in the path commit 2d4c01e44842722140995a9a72f2b6bdf1d71212 Author: Andras Timar <andras.ti...@collabora.com> AuthorDate: Mon Apr 23 20:18:45 2018 +0200 Commit: Andras Timar <andras.ti...@collabora.com> CommitDate: Sat Jan 28 11:29:13 2023 +0100 [cp] Allow creation of debuginfo and debugsource rpm/deb packages Change-Id: Idae5128b58e4cd6f61b8e83664098d195ca67072 diff --git a/bin/pack-debug b/bin/pack-debug new file mode 100755 index 000000000000..70e3f80c7ed4 --- /dev/null +++ b/bin/pack-debug @@ -0,0 +1,195 @@ +#!/bin/bash +# +# This file is part of the LibreOffice project. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# create debuginfo and debugsource packages from LO rpm & deb files +# (generated by using --enable-symbols) + +# build path +export BUILD_PATH=$PWD +export BUILD_LOG=$BUILD_PATH/pack-debug.log + +if type -P pigz &>/dev/null; then + GZIP=pigz +else + GZIP=gzip +fi + +if [ $# -gt 0 ] +then + for i in "$@" + do + case $i in +--only-rpm) ONLY_RPM=1;; +--only-deb) ONLY_DEB=1;; +*) echo "Usage: pack-debug [--only-rpm | --only-deb]" && exit 1;; + esac + done +fi + +# set install dirname and product version +if [ ! -f config.log ]; then + echo "config.log not found. Run this script from build root." + exit 1; +fi + +# create pack-debug.log file +echo create debug packages >$BUILD_LOG + +eval $(grep ^INSTALLDIRNAME config.log) + +# set package base name, eg. collaboraoffice +DEBUGSRC_PACKAGENAME=$INSTALLDIRNAME + +################################# +# Function for re-build RPM files +################################# +function repack_rpm { + +# set environment based on config.log +# for find-requires-x11.sh used by rpm __find_requires +eval $(grep ^PLATFORMID config.log) +export PLATFORMID +eval $(grep ^build_cpu config.log) +export build_cpu + +#################################### +echo create RPM debug source package +#################################### + +DEBUGSRC="$(find workdir -name ${DEBUGSRC_PACKAGENAME}.spec.log)" + +# create spec file, based on the spec file of the brand package + +cat $DEBUGSRC | awk ' + /^Name:/ { print "Summary: Debug source for package "$2; print $0"-debugsource";next } + /^Group:/ { print $1" Development/Debug";next } + /^Brand module/ { print gensub("Brand module", "Source files", "");next } + /^%attr/ || /^Summary:/ { next } + {print} + END { + print "%defattr(-,root,root)" + } + ' > ${DEBUGSRC}-debugsource + buildroot=$(cat $DEBUGSRC-debugsource | awk '/^BuildRoot/{print$2}') + topdir=$(dirname $(dirname $buildroot)) + mkdir -p $buildroot $topdir/RPMS/BUILD $topdir/RPMS/RPMS + rm -rf $buildroot + + # create source file list + + find $BUILD_PATH -name '*[.][hc]xx' -o -name '*[.][hc]' | grep -Ev '/(instdir|qa|DEBS)/' | + + # list all directories for complete rpm remove + + awk -v home=$BUILD_PATH ' + { + split($0, a, home "/") + n=split(a[2], b, "/") + c=home + for(i=1;i<n;i++) { + c=c"/"b[i] + if(mem[c]!=1) print "%dir "c + mem[c]=1 + } + print $0 + }' >> ${DEBUGSRC}-debugsource + + # start rpmbuild for debug source package + + ln -s / $buildroot + + # debug build source package + + rpmbuild -bb --define "_unpackaged_files_terminate_build 0" --define "_binary_payload w1T.xzdio" ${DEBUGSRC}-debugsource --target $build_cpu --buildroot=$buildroot + + +echo Update RPM download tar.gz +rpmdir=$(echo $topdir | sed 's/_inprogress$//') +mv $topdir/RPMS/RPMS/*/*.rpm $rpmdir/RPMS/ +cd $rpmdir/.. +TARGET_RPM=$(ls *_download/*.tar.gz) +TARGET_DEBUG=$(echo $TARGET_RPM | sed 's/.tar.gz$/-debug.tar.gz/') +SOURCE_RPM=$(find *_rpm -type f | grep -v debug) +SOURCE_DEBUG=$(find *_rpm -type f | grep -E '(debug|readme|README)') +tar c $SOURCE_RPM | $GZIP >$TARGET_RPM +tar c $SOURCE_DEBUG | $GZIP >$TARGET_DEBUG +cd $BUILD_PATH +rm -rf $topdir +} + +################################# +# Function for re-build DEB files +################################# +function repack_deb { + +#################################### +echo create DEB debug source package +#################################### + +DEBUGSRC=$BUILD_PATH/workdir/installation/CollaboraOffice/deb/listfile/en-US/epm_gid_Module_Root_Brand.lst + +echo Base spec file: $DEBUGSRC + +# create spec file, based on the spec file of the brand package + +cat $DEBUGSRC | awk ' + /^%product/ { print gensub("Brand module", "Debug source package", "", $0) ;next } + /^%description/ { print gensub("Brand module", "Debug source package", "", $0) ;next } + /^[cdf] / { next } + {print} + ' > ${DEBUGSRC}-debugsource + + # create source file list + + find $BUILD_PATH -name '*[.][hc]xx' -o -name '*[.][hc]' | grep -Ev '/(instdir|qa|DEBS)/' | + + # list all directories + + awk -v home=$BUILD_PATH ' + { + split($0, a, home "/") + n=split(a[2], b, "/") + c=home + for(i=1;i<n;i++) { + c=c"/"b[i] + if(mem[c]!=1) print "d 755 root root "c" -" + mem[c]=1 + } + print "f 644 root root "$0" "$0 + }' >> ${DEBUGSRC}-debugsource + + echo Spec file of debug source package: ${DEBUGSRC}-debugsource + + # debug build source package + + $BUILD_PATH/workdir/UnpackedTarball/epm/epm -f deb -g ${INSTALLDIRNAME}-debugsource ${DEBUGSRC}-debugsource --output-dir DEBS -v + +echo Update DEB download tar.gz + +debdir=$(ls -d $BUILD_PATH/workdir/installation/CollaboraOffice/deb/install/*_deb) +mv $BUILD_PATH/DEBS/*.deb $debdir/DEBS/ +cd $debdir/.. +TARGET_DEB=$(ls *_download/*.tar.gz) +TARGET_DEBUG=$(echo $TARGET_DEB | sed 's/.tar.gz$/-debug.tar.gz/') +SOURCE_DEB=$(find *_deb -type f | grep -v debug) +SOURCE_DEBUG=$(find *_deb -type f | grep -E '(debug|readme|README)') +tar c $SOURCE_DEB | $GZIP >$TARGET_DEB +tar c $SOURCE_DEBUG | $GZIP >$TARGET_DEBUG + +cd $BUILD_PATH +rm -rf DEBS +} + +# start deb re-build +test -z "$ONLY_RPM" -a "$(find workdir/installation/CollaboraOffice/deb/listfile -name '*.lst')" != "" && repack_deb >$BUILD_LOG 2>&1 || \ + echo 'Skip DEB debug package generation (--only-rpm or missing EPM lst files).' + +# start rpm re-build +test -z "$ONLY_DEB" -a "$(find workdir -name '*spec.log')" != "" && repack_rpm >>$BUILD_LOG 2>&1 || \ + echo 'Skip RPM debug package generation (--only-deb or missing RPM spec files).' + diff --git a/config_host.mk.in b/config_host.mk.in index 519b472cb2ec..1d5186aee280 100644 --- a/config_host.mk.in +++ b/config_host.mk.in @@ -127,6 +127,7 @@ export DICT_SYSTEM_DIR=@DICT_SYSTEM_DIR@ export DISABLE_CVE_TESTS=@DISABLE_CVE_TESTS@ export DISABLE_DYNLOADING=@DISABLE_DYNLOADING@ export DISABLE_PYTHON=@DISABLE_PYTHON@ +export DLOPEN_LIBS=@DLOPEN_LIBS@ export DOCDIR=@DOCDIR@ export DOXYGEN=@DOXYGEN@ export DO_FETCH_TARBALLS=@DO_FETCH_TARBALLS@ @@ -212,6 +213,7 @@ export ENABLE_CUSTOMTARGET_COMPONENTS=@ENABLE_CUSTOMTARGET_COMPONENTS@ export ENABLE_SILENT_MSI=@ENABLE_SILENT_MSI@ export ENABLE_SKIA=@ENABLE_SKIA@ export ENABLE_SKIA_DEBUG=@ENABLE_SKIA_DEBUG@ +export ENABLE_STRIP=@ENABLE_STRIP@ export ENABLE_SYMBOLS_FOR=@ENABLE_SYMBOLS_FOR@ export ENABLE_VALGRIND=@ENABLE_VALGRIND@ export ENABLE_WASM_EXCEPTIONS=@ENABLE_WASM_EXCEPTIONS@ diff --git a/configure.ac b/configure.ac index 4410d5b21dc0..8b3693669c9d 100644 --- a/configure.ac +++ b/configure.ac @@ -4885,16 +4885,24 @@ if test -z "$enable_symbols"; then fi if test "$enable_symbols" = yes; then ENABLE_SYMBOLS_FOR=all + ENABLE_STRIP= + DISABLE_STRIP=1 AC_MSG_RESULT([yes]) elif test "$enable_symbols" = no; then ENABLE_SYMBOLS_FOR= + ENABLE_STRIP=1 + DISABLE_STRIP= AC_MSG_RESULT([no]) else # Selective debuginfo. ENABLE_SYMBOLS_FOR="$enable_symbols" + ENABLE_STRIP= + DISABLE_STRIP=1 AC_MSG_RESULT([for "$enable_symbols"]) fi AC_SUBST(ENABLE_SYMBOLS_FOR) +AC_SUBST(ENABLE_STRIP) +AC_SUBST(DISABLE_STRIP) if test -n "$with_android_ndk" -a \( -n "$ENABLE_SYMBOLS" -o -n "$ENABLE_DEBUG" -o -n "$ENABLE_DBGUTIL" \) -a "$ENABLE_DEBUGINFO_FOR" = "all"; then # Building on Android with full symbols: without enough memory the linker never finishes currently. diff --git a/solenv/bin/modules/installer.pm b/solenv/bin/modules/installer.pm index a22385924b92..64d18254e777 100644 --- a/solenv/bin/modules/installer.pm +++ b/solenv/bin/modules/installer.pm @@ -48,6 +48,7 @@ use installer::scpzipfiles; use installer::scriptitems; use installer::setupscript; use installer::simplepackage; +use installer::splitdbg qw(splitdbg_libraries); use installer::strip qw(strip_libraries); use installer::systemactions; use installer::windows::assembly; @@ -1044,6 +1045,7 @@ sub run { strip_libraries($filesinpackage, $languagestringref); } + if ( $installer::globals::simple ) { installer::worker::install_simple($onepackagename, $$languagestringref, $dirsinpackage, $filesinpackage, $linksinpackage, $unixlinksinpackage); } @@ -1055,16 +1057,37 @@ sub run { # Example for a link: l 000 root sys /usr/bin/linkname filename # The source field specifies the file to link to + # check if we have to create a debug info package + my $dbg = 0; + my $debugfilelist; + if ( !($installer::globals::strip) ) + { + $debugfilelist = splitdbg_libraries($filesinpackage, $languagestringref); + if ( $#{$debugfilelist} > -1 ) + { + $dbg = 1; + } + } + my $epmfilename = "epm_" . $onepackagename . ".lst"; + my $dbgepmfilename = "epm_" . $onepackagename . ".debug.lst"; installer::logger::print_message( "... creating epm list file $epmfilename ... \n" ); + if ($dbg) + { + installer::logger::print_message( "... creating epm list file $dbgepmfilename ... \n" ); + } my $completeepmfilename = $listfiledir . $installer::globals::separator . $epmfilename; + my $completedbgepmfilename = $listfiledir . $installer::globals::separator . $dbgepmfilename; + my @epmfile = (); + my @dbgepmfile = (); my $epmheaderref = installer::epmfile::create_epm_header($allvariableshashref, $filesinproductlanguageresolvedarrayref, $languagesarrayref, $onepackage); installer::epmfile::adding_header_to_epm_file(\@epmfile, $epmheaderref); + my $dbgepmheaderref; # adding directories, files and links into epm file @@ -1093,6 +1116,17 @@ sub run { installer::epmfile::resolve_path_in_epm_list_before_packaging(\@epmfile, $completeepmfilename, "UREPACKAGEPREFIX", $allvariableshashref->{'UREPACKAGEPREFIX'}); installer::files::save_file($completeepmfilename ,\@epmfile); + if ($dbg) + { + $onepackage->{'packagename'} .= "-debuginfo"; + $onepackage->{'description'} .= " (debug info)"; + $dbgepmheaderref = installer::epmfile::create_epm_header($allvariableshashref, $filesinproductlanguageresolvedarrayref, $languagesarrayref, $onepackage); + installer::epmfile::adding_header_to_epm_file(\@dbgepmfile, $dbgepmheaderref); + installer::epmfile::put_directories_into_epmfile($dirsinpackage, \@dbgepmfile, $allvariableshashref, $packagerootpath); + installer::epmfile::put_files_into_dbgepmfile($debugfilelist, \@dbgepmfile ); + installer::files::save_file($completedbgepmfilename ,\@dbgepmfile); + } + { # changing into the "install" directory to create installation sets @@ -1135,9 +1169,18 @@ sub run { # Install: rpm -i --prefix=/opt/special --nodeps so8m35.rpm installer::epmfile::create_new_directory_structure($newepmdir); - $installer::globals::postprocess_specialepm = 1; - # solaris patch not needed anymore + # package the debug info if required + + if ($dbg) + { + installer::epmfile::call_epm($epmexecutable, $completedbgepmfilename, $packagename . "-debuginfo", $includepatharrayref); + my $newdbgepmdir = installer::epmfile::prepare_packages($loggingdir, $packagename . "-debuginfo", $staticpath, $relocatablepath, $onepackage, $allvariableshashref, $debugfilelist, $languagestringref); + installer::epmfile::create_packages_without_epm($newdbgepmdir, $packagename . "-debuginfo", $includepatharrayref, $allvariableshashref, $languagestringref); + installer::epmfile::remove_temporary_epm_files($newdbgepmdir, $loggingdir, $packagename . "-debuginfo"); + installer::epmfile::create_new_directory_structure($newdbgepmdir); + } + $installer::globals::postprocess_specialepm = 1; } } @@ -1159,7 +1202,11 @@ sub run { installer::logger::print_message( "... starting unpatched epm ... \n" ); } - if ( $installer::globals::call_epm ) { installer::epmfile::call_epm($epmexecutable, $completeepmfilename, $packagename, $includepatharrayref); } + installer::epmfile::call_epm($epmexecutable, $completeepmfilename, $packagename, $includepatharrayref); + if ($dbg) + { + installer::epmfile::call_epm($epmexecutable, $completedbgepmfilename, $packagename . "-debuginfo", $includepatharrayref); + } if (($installer::globals::isrpmbuild) || ($installer::globals::issolarispkgbuild) || ($installer::globals::debian)) { diff --git a/solenv/bin/modules/installer/epmfile.pm b/solenv/bin/modules/installer/epmfile.pm index 51d596dcb519..904b35a462d6 100644 --- a/solenv/bin/modules/installer/epmfile.pm +++ b/solenv/bin/modules/installer/epmfile.pm @@ -199,6 +199,26 @@ sub put_files_into_epmfile } } +sub put_files_into_dbgepmfile +{ + my ($filesinproductarrayref, $epmfileref) = @_; + + for ( my $i = 0; $i <= $#{$filesinproductarrayref}; $i++ ) + { + my $onefile = ${$filesinproductarrayref}[$i]; + + my $unixrights = $onefile->{'UnixRights'}; + my $destination = $onefile->{'destination'} . ".dbg"; + my $sourcepath = $onefile->{'sourcepath'} . ".dbg"; + my $filetype = "f"; + my $group = "root"; + + my $line = "$filetype $unixrights root $group $destination $sourcepath\n"; + + push(@{$epmfileref}, $line); + } +} + sub put_links_into_epmfile { my ($linksinproductarrayref, $epmfileref) = @_; diff --git a/solenv/bin/modules/installer/splitdbg.pm b/solenv/bin/modules/installer/splitdbg.pm new file mode 100644 index 000000000000..60c0c1bde024 --- /dev/null +++ b/solenv/bin/modules/installer/splitdbg.pm @@ -0,0 +1,121 @@ +# +# This file is part of the LibreOffice project. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# + +package installer::splitdbg; + +use strict; +use warnings; + +use base 'Exporter'; + +use installer::globals; +use installer::logger; +use installer::pathanalyzer; +use installer::systemactions; + +our @EXPORT_OK = qw(splitdbg_libraries); + +sub _need_to_splitdbg +{ + my ( $filename ) = @_; + + my $splitdbg = 0; + + # Check using the "file" command + + $filename =~ s/'/'\\''/g; + open (FILE, "file '$filename' |"); + my $fileoutput = <FILE>; + close (FILE); + + if (( $fileoutput =~ /not stripped/i ) && ( $fileoutput =~ /\bELF\b/ )) { $splitdbg = 1; } + + return $splitdbg; +} + +sub _do_splitdbg +{ + my ( $filename ) = @_; + + my $systemcall = "objcopy --only-keep-debug $filename $filename.dbg && "; + $systemcall .= "objcopy --strip-debug $filename && "; + $systemcall .= "objcopy --add-gnu-debuglink=$filename.dbg $filename"; + + my $returnvalue = system($systemcall); + + my $infoline = "Systemcall: $systemcall\n"; + push( @installer::globals::logfileinfo, $infoline); + + if ($returnvalue) + { + $infoline = "ERROR: Could not split debug info of $filename!\n"; + push( @installer::globals::logfileinfo, $infoline); + } + else + { + $infoline = "SUCCESS: Split debug info of $filename!\n"; + push( @installer::globals::logfileinfo, $infoline); + } +} + +sub splitdbg_libraries +{ + my ( $filelist, $languagestringref ) = @_; + + my @debugfilelist = (); + + installer::logger::include_header_into_logfile("Splitting debuginfo from files:"); + + my $splitdbgdirbase = installer::systemactions::create_directories("splitdbg", $languagestringref); + + if (! grep {$_ eq $splitdbgdirbase} @installer::globals::removedirs) + { + push(@installer::globals::removedirs, $splitdbgdirbase); + } + + for ( my $i = 0; $i <= $#{$filelist}; $i++ ) + { + my $sourcefilename = ${$filelist}[$i]->{'sourcepath'}; + + if ( _need_to_splitdbg($sourcefilename) ) + { + my $shortfilename = $sourcefilename; + installer::pathanalyzer::make_absolute_filename_to_relative_filename(\$shortfilename); + + my $infoline = "Split debuginfo: $shortfilename\n"; + push(@installer::globals::logfileinfo, $infoline); + + # copy file into directory for split debuginfo libraries + + my $onelanguage = ${$filelist}[$i]->{'specificlanguage'}; + + # files without language into directory "00" + + if ($onelanguage eq "") { $onelanguage = "00"; } + + my $splitdbgdir = $splitdbgdirbase . $installer::globals::separator . $onelanguage; + installer::systemactions::create_directory($splitdbgdir); # creating language specific subdirectories + + my $destfilename = $splitdbgdir . $installer::globals::separator . $shortfilename; + installer::systemactions::copy_one_file($sourcefilename, $destfilename); + + # change sourcepath in files collector + + ${$filelist}[$i]->{'sourcepath'} = $destfilename; + + # split debuginfo from file + + _do_splitdbg($destfilename); + + push(@debugfilelist, ${$filelist}[$i]); + } + } + return \@debugfilelist; +} + +1; commit 99dc792086d294674b7c1c54eb63b672120af05b Author: Gülşah Köse <gulsah.k...@collabora.com> AuthorDate: Wed Sep 18 23:07:09 2019 +0300 Commit: Andras Timar <andras.ti...@collabora.com> CommitDate: Sat Jan 28 11:22:35 2023 +0100 [cp] add EULA button to Help - License Information... dialog Forward port of acd8acfa89d9 from distro/collabora/cp-6.0 Rewritten for weld API Change-Id: I62b9293c68059389a63e523ea5747fdb267b1a99 28a21f5831e0b2e99eb11f1c1ac2b8845c462669 Reviewed-on: https://gerrit.libreoffice.org/79110 Reviewed-by: Andras Timar <andras.ti...@collabora.com> Tested-by: Andras Timar <andras.ti...@collabora.com> diff --git a/sfx2/source/appl/appserv.cxx b/sfx2/source/appl/appserv.cxx index 31d12cd43520..e603b02ee05d 100644 --- a/sfx2/source/appl/appserv.cxx +++ b/sfx2/source/appl/appserv.cxx @@ -256,21 +256,43 @@ namespace class LicenseDialog : public weld::GenericDialogController { + private: + std::unique_ptr<weld::Button> m_xBtnLicense; + std::unique_ptr<weld::Button> m_xBtnEula; + + DECL_LINK(EulaHdl, weld::Button&, void); + DECL_LINK(LicenseHdl, weld::Button&, void); + public: LicenseDialog(weld::Window* pParent) : GenericDialogController(pParent, "sfx/ui/licensedialog.ui", "LicenseDialog") + , m_xBtnLicense(m_xBuilder->weld_button("license")) + , m_xBtnEula(m_xBuilder->weld_button("eula")) { + m_xBtnLicense->connect_clicked( LINK(this, LicenseDialog, LicenseHdl) ); + m_xBtnEula->connect_clicked( LINK(this, LicenseDialog, EulaHdl) ); } virtual short run() override { short nRet = GenericDialogController::run(); - if (nRet == RET_OK) - showDocument("LICENSE"); return nRet; } }; + IMPL_LINK_NOARG(LicenseDialog, EulaHdl, weld::Button&, void) + { + response(RET_OK); + showDocument("EULA.odt"); + } + + IMPL_LINK_NOARG(LicenseDialog, LicenseHdl, weld::Button&, void) + { + response(RET_OK); + showDocument("LICENSE"); + } + + class SafeModeQueryDialog : public weld::MessageDialogController { public: diff --git a/sfx2/uiconfig/ui/licensedialog.ui b/sfx2/uiconfig/ui/licensedialog.ui index 9253f3c9d290..fe06c7544e92 100644 --- a/sfx2/uiconfig/ui/licensedialog.ui +++ b/sfx2/uiconfig/ui/licensedialog.ui @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8"?> -<!-- Generated with glade 3.20.2 --> +<!-- Generated with glade 3.22.1 --> <interface domain="sfx"> <requires lib="gtk+" version="3.20"/> <object class="GtkDialog" id="LicenseDialog"> @@ -11,6 +11,9 @@ <property name="default_width">0</property> <property name="default_height">0</property> <property name="type_hint">dialog</property> + <child> + <placeholder/> + </child> <child internal-child="vbox"> <object class="GtkBox" id="dialog-vbox1"> <property name="can_focus">False</property> @@ -21,7 +24,7 @@ <property name="can_focus">False</property> <property name="layout_style">end</property> <child> - <object class="GtkButton" id="ok"> + <object class="GtkButton" id="license"> <property name="label" translatable="yes" context="licensedialog|show">_Show License</property> <property name="visible">True</property> <property name="can_focus">True</property> @@ -36,6 +39,23 @@ <property name="secondary">True</property> </packing> </child> + <child> + <object class="GtkButton" id="eula"> + <property name="label" translatable="yes" context="licensedialog|eula">_EULA</property> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="can_default">True</property> + <property name="has_default">True</property> + <property name="receives_default">True</property> + <property name="use_underline">True</property> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="position">1</property> + <property name="secondary">True</property> + </packing> + </child> <child> <object class="GtkButton" id="close"> <property name="label" translatable="yes" context="stock">_Close</property> @@ -50,7 +70,7 @@ <packing> <property name="expand">False</property> <property name="fill">True</property> - <property name="position">1</property> + <property name="position">2</property> </packing> </child> </object> @@ -61,6 +81,24 @@ <property name="position">0</property> </packing> </child> + <child> + <object class="GtkLabel" id="label2"> + <property name="visible">True</property> + <property name="can_focus">False</property> + <property name="label" translatable="yes" context="licensedialog|label2">%PRODUCTNAME binary package is made available subject to the terms of the End User License and Subscription Agreement; choose EULA to see exact details in English.</property> + <property name="use_underline">True</property> + <property name="wrap">True</property> + <property name="mnemonic_widget">eula</property> + <property name="max_width_chars">80</property> + <property name="xalign">0</property> + <property name="yalign">0</property> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="position">0</property> + </packing> + </child> <child> <object class="GtkLabel" id="label"> <property name="visible">True</property> @@ -88,11 +126,8 @@ This product was created by %OOOVENDOR, based on OpenOffice.org, which is Copyri </object> </child> <action-widgets> - <action-widget response="-5">ok</action-widget> + <action-widget response="-5">license</action-widget> <action-widget response="-7">close</action-widget> </action-widgets> - <child> - <placeholder/> - </child> </object> </interface>