[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.4' - 4 commits - android/CustomTarget_lo_android.mk sw/inc sw/qa sw/source writerfilter/qa writerfilter/source
Miklos Vajna (via logerrit)
logerrit at kemper.freedesktop.org
Mon May 4 09:56:09 UTC 2020
android/CustomTarget_lo_android.mk | 2
sw/inc/doc.hxx | 4 +
sw/qa/extras/ooxmlexport/data/cont-sect-break-header-footer.docx |binary
sw/qa/extras/ooxmlexport/ooxmlexport14.cxx | 26 +++++++++
sw/qa/extras/ooxmlexport/ooxmlexport4.cxx | 4 -
sw/qa/extras/tiledrendering/data/redline-notification-during-save.odt |binary
sw/qa/extras/tiledrendering/tiledrendering.cxx | 21 +++++++
sw/source/core/doc/docnew.cxx | 1
sw/source/core/txtnode/ndtxt.cxx | 4 +
sw/source/filter/basflt/shellio.cxx | 2
writerfilter/qa/cppunittests/dmapper/DomainMapper_Impl.cxx | 27 ++++++++++
writerfilter/qa/cppunittests/dmapper/data/page-break-footer-table.docx |binary
writerfilter/source/dmapper/DomainMapper_Impl.cxx | 9 ++-
writerfilter/source/dmapper/DomainMapper_Impl.hxx | 5 +
writerfilter/source/dmapper/PropertyMap.cxx | 25 ++++++++-
15 files changed, 122 insertions(+), 8 deletions(-)
New commits:
commit eca5e17c62a04fc941ca237799fd6e931be87308
Author: Miklos Vajna <vmiklos at collabora.com>
AuthorDate: Wed Jan 15 17:54:52 2020 +0100
Commit: Miklos Vajna <vmiklos at collabora.com>
CommitDate: Mon May 4 11:55:36 2020 +0200
DOCX import: improve support for headers/footers from cont sect break
A continuous section break in a DOCX file can set new headers/footers
which start appearing from the next page. In general, this is not
something Writer supports, but commit
08f13ab85b5c65b5dc8adfa15918fb3e426fcc3c (tdf#112202 writerfilter,sw:
fix loss of headers, 2019-12-16) improved the situation significantly
here.
Build on top of that and add support for a few more cases:
1) When checking for the last paragraph of the previous section, detect
when that last paragraph is so small so in practice that's not the last
one.
2) Handle when the text node in question has no explicit break type set,
only a SwFormatPageDesc (which implicitly causes a page break).
3) When setting the page style to show the correct header/footer, don't
set the page style on the previous paragraph directly, rather update the
"next style" of the already set page style. (This is safe, as we never
reuse the same Writer page style for multiple Word sections.)
Change-Id: Iede196b864af5123c5637f82432ed6e0f7e7241a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86870
Reviewed-by: Miklos Vajna <vmiklos at collabora.com>
Tested-by: Jenkins
(cherry picked from commit 9a50e8f2bcde95233e4b38707c521ada90fcd6af)
diff --git a/sw/qa/extras/ooxmlexport/data/cont-sect-break-header-footer.docx b/sw/qa/extras/ooxmlexport/data/cont-sect-break-header-footer.docx
new file mode 100644
index 000000000000..61c18298d083
Binary files /dev/null and b/sw/qa/extras/ooxmlexport/data/cont-sect-break-header-footer.docx differ
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport14.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport14.cxx
index 375c6d874021..445f245d0160 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport14.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport14.cxx
@@ -339,6 +339,32 @@ DECLARE_OOXMLEXPORT_TEST(testHyphenationAuto, "hyphenation.odt")
assertXPath(pXmlStyles, "/w:styles/w:docDefaults/w:pPrDefault/w:pPr/w:suppressAutoHyphens", "val", "true");
}
+DECLARE_OOXMLIMPORT_TEST(testContSectBreakHeaderFooter, "cont-sect-break-header-footer.docx")
+{
+ // Load a document with a continuous section break on page 2.
+ CPPUNIT_ASSERT_EQUAL(OUString("First page header, section 1"),
+ parseDump("/root/page[1]/header/txt/text()"));
+ CPPUNIT_ASSERT_EQUAL(OUString("First page footer, section 1"),
+ parseDump("/root/page[1]/footer/txt/text()"));
+ // Make sure the header stays like this; if we naively just update the page style name of the
+ // first para on page 2, then this would be 'Header, section 2', which is incorrect.
+ CPPUNIT_ASSERT_EQUAL(OUString("First page header, section 2"),
+ parseDump("/root/page[2]/header/txt/text()"));
+ CPPUNIT_ASSERT_EQUAL(OUString("First page footer, section 2"),
+ parseDump("/root/page[2]/footer/txt/text()"));
+ // This is inherited from page 2.
+ CPPUNIT_ASSERT_EQUAL(OUString("Header, section 2"),
+ parseDump("/root/page[3]/header/txt/text()"));
+ // Without the accompanying fix in place, this test would have failed with:
+ // - Expected: 1
+ // - Actual : 0
+ // - xpath should match exactly 1 node
+ // i.e. the footer had no text (inherited from page 2), while the correct behavior is to provide
+ // the own footer text.
+ CPPUNIT_ASSERT_EQUAL(OUString("Footer, section 3"),
+ parseDump("/root/page[3]/footer/txt/text()"));
+}
+
CPPUNIT_PLUGIN_IMPLEMENT();
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/writerfilter/source/dmapper/PropertyMap.cxx b/writerfilter/source/dmapper/PropertyMap.cxx
index fbc471415b4c..2d085b5775dd 100644
--- a/writerfilter/source/dmapper/PropertyMap.cxx
+++ b/writerfilter/source/dmapper/PropertyMap.cxx
@@ -1457,9 +1457,11 @@ void SectionPropertyMap::CloseSectionGroup( DomainMapper_Impl& rDM_Impl )
}
}
}
+ uno::Reference<text::XParagraphCursor> const xPCursor(xCursor,
+ uno::UNO_QUERY_THROW);
+ float fCharHeight = 0;
if (!isFound)
{ // HACK: try the last paragraph of the previous section
- uno::Reference<text::XParagraphCursor> const xPCursor(xCursor, uno::UNO_QUERY_THROW);
xPCursor->gotoPreviousParagraph(false);
uno::Reference<beans::XPropertySet> const xPSCursor(xCursor, uno::UNO_QUERY_THROW);
style::BreakType bt;
@@ -1468,6 +1470,27 @@ void SectionPropertyMap::CloseSectionGroup( DomainMapper_Impl& rDM_Impl )
{
xPSCursor->setPropertyValue(getPropertyName(PROP_PAGE_DESC_NAME),
uno::makeAny(m_sFollowPageStyleName));
+ isFound = true;
+ }
+ else
+ {
+ xPSCursor->getPropertyValue("CharHeight") >>= fCharHeight;
+ }
+ }
+ if (!isFound && fCharHeight <= 1.0)
+ {
+ // If still not found, see if the last paragraph is ~invisible, and work with
+ // the last-in-practice paragraph.
+ xPCursor->gotoPreviousParagraph(false);
+ uno::Reference<beans::XPropertySet> xPropertySet(xCursor, uno::UNO_QUERY_THROW);
+ OUString aPageDescName;
+ if ((xPropertySet->getPropertyValue("PageDescName") >>= aPageDescName)
+ && !aPageDescName.isEmpty())
+ {
+ uno::Reference<beans::XPropertySet> xPageStyle(
+ rDM_Impl.GetPageStyles()->getByName(aPageDescName), uno::UNO_QUERY);
+ xPageStyle->setPropertyValue("FollowStyle",
+ uno::makeAny(m_sFollowPageStyleName));
}
}
}
commit 072af1b01c783b4ee7c9005ac2c15355e8a2f74d
Author: Miklos Vajna <vmiklos at collabora.com>
AuthorDate: Wed Jan 8 15:40:32 2020 +0100
Commit: Miklos Vajna <vmiklos at collabora.com>
CommitDate: Mon May 4 11:55:36 2020 +0200
DOCX import: fix lost page break when footer ends with a table
Regression from commit 7d3778e0ef9f54f3c8988f1b84d58e7002d6c625
(bnc#816593 DOCX import: ignore page breaks in tables, 2013-09-02), the
page break was ignored because the preceding footer ended with a table
(no empty paragraph at the end of the footer stream).
Fix the problem by saving/loading the table state around header/footers,
that way the page break is not ignored.
Adjust testTdf102466 to test the page number from Word.
(cherry picked from commit a86a2a1c1ceb7203857d4317913c5b1bb9feb4aa)
Conflicts:
writerfilter/CppunitTest_writerfilter_dmapper.mk
writerfilter/qa/cppunittests/dmapper/DomainMapper_Impl.cxx
Change-Id: Ia4c22452ee2c37f7f941dfd922db04c851644d0c
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx
index 29d4d54534f8..a7a1336dd480 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx
@@ -1079,8 +1079,8 @@ DECLARE_OOXMLEXPORT_TEST(testTdf102466, "tdf102466.docx")
CPPUNIT_ASSERT_MESSAGE("The table is clipped in a fly frame.", nFlyPrtHeight >= nTableHeight);
}
- // check how much pages we have
- CPPUNIT_ASSERT_EQUAL(10, getPages());
+ // check how much pages we have: it should match the Word layout result
+ CPPUNIT_ASSERT_EQUAL(11, getPages());
// check content of the first page
{
diff --git a/writerfilter/qa/cppunittests/dmapper/DomainMapper_Impl.cxx b/writerfilter/qa/cppunittests/dmapper/DomainMapper_Impl.cxx
index a7274c653805..dff03f974a66 100644
--- a/writerfilter/qa/cppunittests/dmapper/DomainMapper_Impl.cxx
+++ b/writerfilter/qa/cppunittests/dmapper/DomainMapper_Impl.cxx
@@ -54,6 +54,33 @@ void Test::tearDown()
char const DATA_DIRECTORY[] = "/writerfilter/qa/cppunittests/dmapper/data/";
+CPPUNIT_TEST_FIXTURE(Test, testPageBreakFooterTable)
+{
+ // Load a document which refers to a footer which ends with a table, and there is a page break
+ // in the body text right after the footer reference.
+ OUString aURL = m_directories.getURLFromSrc(DATA_DIRECTORY) + "page-break-footer-table.docx";
+ getComponent() = loadFromDesktop(aURL);
+
+ // Check the last paragraph.
+ uno::Reference<text::XTextDocument> xTextDocument(getComponent(), uno::UNO_QUERY);
+ uno::Reference<container::XEnumerationAccess> xParaEnumAccess(xTextDocument->getText(),
+ uno::UNO_QUERY);
+ uno::Reference<container::XEnumeration> xParaEnum = xParaEnumAccess->createEnumeration();
+ uno::Reference<beans::XPropertySet> xPara;
+ while (xParaEnum->hasMoreElements())
+ {
+ xPara.set(xParaEnum->nextElement(), uno::UNO_QUERY);
+ }
+ style::BreakType eType = style::BreakType_NONE;
+ xPara->getPropertyValue("BreakType") >>= eType;
+
+ // Without the accompanying fix in place, this test would have failed with:
+ // - Expected: 4
+ // - Actual : 0
+ // i.e. there was no page break before the last paragraph.
+ CPPUNIT_ASSERT_EQUAL(style::BreakType_PAGE_BEFORE, eType);
+}
+
CPPUNIT_TEST_FIXTURE(Test, testNumberingRestartStyleParent)
{
OUString aURL = m_directories.getURLFromSrc(DATA_DIRECTORY) + "num-restart-style-parent.docx";
diff --git a/writerfilter/qa/cppunittests/dmapper/data/page-break-footer-table.docx b/writerfilter/qa/cppunittests/dmapper/data/page-break-footer-table.docx
new file mode 100644
index 000000000000..376a1fb1e483
Binary files /dev/null and b/writerfilter/qa/cppunittests/dmapper/data/page-break-footer-table.docx differ
diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.cxx b/writerfilter/source/dmapper/DomainMapper_Impl.cxx
index a04af3c1c8aa..b04c69d27030 100644
--- a/writerfilter/source/dmapper/DomainMapper_Impl.cxx
+++ b/writerfilter/source/dmapper/DomainMapper_Impl.cxx
@@ -2188,8 +2188,9 @@ void DomainMapper_Impl::appendGlossaryEntry()
void DomainMapper_Impl::PushPageHeaderFooter(bool bHeader, SectionPropertyMap::PageType eType)
{
- m_aHeaderFooterStack.push(HeaderFooterContext(m_bTextInserted));
+ m_aHeaderFooterStack.push(HeaderFooterContext(m_bTextInserted, m_nTableDepth));
m_bTextInserted = false;
+ m_nTableDepth = 0;
const PropertyIds ePropIsOn = bHeader? PROP_HEADER_IS_ON: PROP_FOOTER_IS_ON;
const PropertyIds ePropShared = bHeader? PROP_HEADER_IS_SHARED: PROP_FOOTER_IS_SHARED;
@@ -2278,6 +2279,7 @@ void DomainMapper_Impl::PopPageHeaderFooter()
if (!m_aHeaderFooterStack.empty())
{
m_bTextInserted = m_aHeaderFooterStack.top().getTextInserted();
+ m_nTableDepth = m_aHeaderFooterStack.top().getTableDepth();
m_aHeaderFooterStack.pop();
}
}
@@ -3525,8 +3527,9 @@ void DomainMapper_Impl::SetFieldLocked()
m_aFieldStack.back()->SetFieldLocked();
}
-HeaderFooterContext::HeaderFooterContext(bool bTextInserted)
+HeaderFooterContext::HeaderFooterContext(bool bTextInserted, sal_Int32 nTableDepth)
: m_bTextInserted(bTextInserted)
+ , m_nTableDepth(nTableDepth)
{
}
@@ -3535,6 +3538,8 @@ bool HeaderFooterContext::getTextInserted() const
return m_bTextInserted;
}
+sal_Int32 HeaderFooterContext::getTableDepth() const { return m_nTableDepth; }
+
FieldContext::FieldContext(uno::Reference< text::XTextRange > const& xStart)
: m_bFieldCommandCompleted(false)
, m_xStartRange( xStart )
diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.hxx b/writerfilter/source/dmapper/DomainMapper_Impl.hxx
index 483f8f92715c..e783e9334deb 100644
--- a/writerfilter/source/dmapper/DomainMapper_Impl.hxx
+++ b/writerfilter/source/dmapper/DomainMapper_Impl.hxx
@@ -131,9 +131,12 @@ enum SkipFootnoteSeparator
class HeaderFooterContext
{
bool const m_bTextInserted;
+ sal_Int32 m_nTableDepth;
+
public:
- explicit HeaderFooterContext(bool bTextInserted);
+ explicit HeaderFooterContext(bool bTextInserted, sal_Int32 nTableDepth);
bool getTextInserted() const;
+ sal_Int32 getTableDepth() const;
};
/// Information about a paragraph to be finished after a field end.
commit a30ce1e1e1bc3a46997e31b5fb105510bf558ce9
Author: Miklos Vajna <vmiklos at collabora.com>
AuthorDate: Tue Jan 7 17:26:53 2020 +0100
Commit: Miklos Vajna <vmiklos at collabora.com>
CommitDate: Mon May 4 11:55:35 2020 +0200
sw: don't send LOK notifications about redlines during save
SwXMLWriter::Write_() sets redline flags to show insertion and hide
deletion, but it resets those flags before the function returns. So LOK
notifications for redline changes during save is not useful.
Change-Id: I4bf963bbe9c7003cbe85ea6c5538be733a3e3cdf
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86363
Reviewed-by: Miklos Vajna <vmiklos at collabora.com>
Tested-by: Jenkins
(cherry picked from commit 08a0ede627fbf9bea42165c3de63812e469306b4)
diff --git a/sw/inc/doc.hxx b/sw/inc/doc.hxx
index b80e1157a7c9..cc06333cc51b 100644
--- a/sw/inc/doc.hxx
+++ b/sw/inc/doc.hxx
@@ -299,6 +299,7 @@ private:
frames need deletion. */
bool mbCopyIsMove : 1; //< TRUE: Copy is a hidden Move.
bool mbInReading : 1; //< TRUE: Document is in the process of being read.
+ bool mbInWriting : 1; //< TRUE: Document is in the process of being written.
bool mbInMailMerge : 1; //< TRUE: Document is in the process of being written by mail merge.
bool mbInXMLImport : 1; //< TRUE: During xml import, attribute portion building is not necessary.
bool mbInWriterfilterImport : 1; //< TRUE: writerfilter import (DOCX,RTF)
@@ -951,6 +952,9 @@ public:
bool IsInReading() const { return mbInReading; }
void SetInReading( bool bNew ) { mbInReading = bNew; }
+ bool IsInWriting() const { return mbInWriting; }
+ void SetInWriting(bool bNew) { mbInWriting = bNew; }
+
bool IsInMailMerge() const { return mbInMailMerge; }
void SetInMailMerge( bool bNew ) { mbInMailMerge = bNew; }
diff --git a/sw/qa/extras/tiledrendering/data/redline-notification-during-save.odt b/sw/qa/extras/tiledrendering/data/redline-notification-during-save.odt
new file mode 100644
index 000000000000..df4c30682a6b
Binary files /dev/null and b/sw/qa/extras/tiledrendering/data/redline-notification-during-save.odt differ
diff --git a/sw/qa/extras/tiledrendering/tiledrendering.cxx b/sw/qa/extras/tiledrendering/tiledrendering.cxx
index e6b624a5cb1e..f7a1acb5e4d1 100644
--- a/sw/qa/extras/tiledrendering/tiledrendering.cxx
+++ b/sw/qa/extras/tiledrendering/tiledrendering.cxx
@@ -12,6 +12,7 @@
#include <com/sun/star/frame/DispatchResultState.hpp>
#include <com/sun/star/frame/XDispatchResultListener.hpp>
+#include <com/sun/star/frame/XStorable.hpp>
#include <swmodeltestbase.hxx>
#include <test/helper/transferable.hxx>
#include <LibreOfficeKit/LibreOfficeKitEnums.h>
@@ -121,6 +122,7 @@ public:
void testSemiTransparent();
void testAnchorTypes();
void testLanguageStatus();
+ void testRedlineNotificationDuringSave();
CPPUNIT_TEST_SUITE(SwTiledRenderingTest);
CPPUNIT_TEST(testRegisterCallback);
@@ -182,6 +184,7 @@ public:
CPPUNIT_TEST(testSemiTransparent);
CPPUNIT_TEST(testAnchorTypes);
CPPUNIT_TEST(testLanguageStatus);
+ CPPUNIT_TEST(testRedlineNotificationDuringSave);
CPPUNIT_TEST_SUITE_END();
private:
@@ -2453,6 +2456,24 @@ void SwTiledRenderingTest::testLanguageStatus()
CPPUNIT_ASSERT_EQUAL(OUString("English (USA);en-US"), aList[0]);
}
+void SwTiledRenderingTest::testRedlineNotificationDuringSave()
+{
+ // Load a document with redlines which are hidden at a layout level.
+ // It's an empty document, just settings.xml and content.xml are custom.
+ comphelper::LibreOfficeKit::setActive();
+ SwXTextDocument* pXTextDocument = createDoc("redline-notification-during-save.odt");
+ SwWrtShell* pWrtShell = pXTextDocument->GetDocShell()->GetWrtShell();
+ pWrtShell->GetSfxViewShell()->registerLibreOfficeKitViewCallback(&SwTiledRenderingTest::callback, this);
+
+ // Save the document.
+ utl::MediaDescriptor aMediaDescriptor;
+ aMediaDescriptor["FilterName"] <<= OUString("writer8");
+ uno::Reference<frame::XStorable> xStorable(mxComponent, uno::UNO_QUERY);
+ // Without the accompanying fix in place, this test would have never returned due to an infinite
+ // loop while sending not needed LOK notifications for redline changes during save.
+ xStorable->storeToURL(maTempFile.GetURL(), aMediaDescriptor.getAsConstPropertyValueList());
+}
+
CPPUNIT_TEST_SUITE_REGISTRATION(SwTiledRenderingTest);
CPPUNIT_PLUGIN_IMPLEMENT();
diff --git a/sw/source/core/doc/docnew.cxx b/sw/source/core/doc/docnew.cxx
index 984f2335bc45..f3e7aa8e1ea6 100644
--- a/sw/source/core/doc/docnew.cxx
+++ b/sw/source/core/doc/docnew.cxx
@@ -240,6 +240,7 @@ SwDoc::SwDoc()
mbDtor(false),
mbCopyIsMove(false),
mbInReading(false),
+ mbInWriting(false),
mbInMailMerge(false),
mbInXMLImport(false),
mbInWriterfilterImport(false),
diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx
index 6adb0a93dcf6..7ca26840207e 100644
--- a/sw/source/core/txtnode/ndtxt.cxx
+++ b/sw/source/core/txtnode/ndtxt.cxx
@@ -1542,7 +1542,9 @@ void SwTextNode::Update(
}
// Inform LOK clients about change in position of redlines (if any)
- if (comphelper::LibreOfficeKit::isActive())
+ // Don't emit notifications during save: redline flags are temporarily changed during save, but
+ // it's not useful to let clients know about such changes.
+ if (comphelper::LibreOfficeKit::isActive() && !GetDoc()->IsInWriting())
{
const SwRedlineTable& rTable = GetDoc()->getIDocumentRedlineAccess().GetRedlineTable();
for (SwRedlineTable::size_type nRedlnPos = 0; nRedlnPos < rTable.size(); ++nRedlnPos)
diff --git a/sw/source/filter/basflt/shellio.cxx b/sw/source/filter/basflt/shellio.cxx
index cba064de3e09..f3fe939f634d 100644
--- a/sw/source/filter/basflt/shellio.cxx
+++ b/sw/source/filter/basflt/shellio.cxx
@@ -857,6 +857,7 @@ ErrCode SwWriter::Write( WriterRef const & rxWriter, const OUString* pRealFileNa
const bool bOrigPurgeOle = pOutDoc->getIDocumentSettingAccess().get(DocumentSettingId::PURGE_OLE);
pOutDoc->getIDocumentSettingAccess().set(DocumentSettingId::PURGE_OLE, false);
+ pOutDoc->SetInWriting(true);
ErrCode nError = ERRCODE_NONE;
if( pMedium )
nError = rxWriter->Write( *pPam, *pMedium, pRealFileName );
@@ -864,6 +865,7 @@ ErrCode SwWriter::Write( WriterRef const & rxWriter, const OUString* pRealFileNa
nError = rxWriter->Write( *pPam, *pStrm, pRealFileName );
else if( xStg.is() )
nError = rxWriter->Write( *pPam, xStg, pRealFileName );
+ pOutDoc->SetInWriting(false);
pOutDoc->getIDocumentSettingAccess().set(DocumentSettingId::PURGE_OLE, bOrigPurgeOle );
commit fa24ec47b7a54719b11481c6301f704fa3aec1f3
Author: Miklos Vajna <vmiklos at collabora.com>
AuthorDate: Fri Jan 3 09:23:44 2020 +0100
Commit: Miklos Vajna <vmiklos at collabora.com>
CommitDate: Mon May 4 11:55:35 2020 +0200
android: don't try to copy the apk if it does not exist
Linking obj/local/armeabi-v7a/liblo-native-code.so
cp: cannot stat 'android/source/build/outputs/apk/strippedUI/release/*-release-unsigned.apk': No such file or directory
make[1]: *** [android/CustomTarget_lo_android.mk:19: workdir/CustomTarget/android/source/done] Error 1
Change-Id: I90818d432cab0ef8ef7049b6be175db9e9028261
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86170
Reviewed-by: Miklos Vajna <vmiklos at collabora.com>
Tested-by: Jenkins
(cherry picked from commit 3f5a4c8cf2e24f5da8319ff43d0b7da431ef6cc0)
diff --git a/android/CustomTarget_lo_android.mk b/android/CustomTarget_lo_android.mk
index 4badb659612e..b64c9245aeff 100644
--- a/android/CustomTarget_lo_android.mk
+++ b/android/CustomTarget_lo_android.mk
@@ -20,7 +20,7 @@ $(loandroid3_DIR)/done : $(call gb_Postprocess_get_target,AllModulesButInstsetNa
# still looks for the .apk, and we want fresh daily builds to be uploaded.
# Us "foo" instead of the old INPATH
mkdir -p $(BUILDDIR)/instsetoo_native/foo/bin; \
- cp $(SRCDIR)/android/source/build/outputs/apk/strippedUI$(if $(ENABLE_ANDROID_EDITING),Editing)/$(if $(ENABLE_RELEASE_BUILD),release/*-release-unsigned.apk,debug/*-debug.apk) $(BUILDDIR)/instsetoo_native/foo/bin
+ if test "$$ENABLE_ANDROID_LOK" != "TRUE" ; then cp $(SRCDIR)/android/source/build/outputs/apk/strippedUI$(if $(ENABLE_ANDROID_EDITING),Editing)/$(if $(ENABLE_RELEASE_BUILD),release/*-release-unsigned.apk,debug/*-debug.apk) $(BUILDDIR)/instsetoo_native/foo/bin ; fi
$(call gb_CustomTarget_get_clean_target,android/loandroid3) :
$(call gb_Output_announce,$(subst $(WORKDIR)/Clean/,,$@),$(false),MAK,2)
More information about the Libreoffice-commits
mailing list