[Libreoffice-commits] core.git: 2 commits - desktop/source ios/CustomTarget_iOS_setup.mk
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Wed Sep 5 18:58:27 UTC 2018
desktop/source/lib/init.cxx | 8 ++++++++
ios/CustomTarget_iOS_setup.mk | 4 ++--
2 files changed, 10 insertions(+), 2 deletions(-)
New commits:
commit 46b2350cb303a84ffd549447d313c7ced50e7032
Author: Tor Lillqvist <tml at iki.fi>
AuthorDate: Wed Sep 5 21:57:29 2018 +0300
Commit: Tor Lillqvist <tml at iki.fi>
CommitDate: Wed Sep 5 21:57:59 2018 +0300
Handle passing a null pAppPath to lo_initialize() on iOS
Change-Id: I293ede0dbac4b36a1b91b86100bc11593b402d06
diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index 416b42f3ce04..5c89c1dbd386 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -3857,6 +3857,14 @@ static int lo_initialize(LibreOfficeKit* pThis, const char* pAppPath, const char
::osl::Module::getUrlFromAddress( reinterpret_cast< oslGenericFunction >(lo_initialize),
aAppURL);
osl::FileBase::getSystemPathFromFileURL( aAppURL, aAppPath );
+#ifdef IOS
+ // The above gives something like
+ // "/private/var/containers/Bundle/Application/953AA851-CC15-4C60-A2CB-C2C6F24E6F71/Foo.app/Foo",
+ // and we want to drop the final component (the binary name).
+ sal_Int32 lastSlash = aAppPath.lastIndexOf('/');
+ assert(lastSlash > 0);
+ aAppPath = aAppPath.copy(0, lastSlash);
+#endif
}
OUString aAppURL;
commit 60569747d57cb1eb5b67ec57198b7f9ab7b87fb0
Author: Tor Lillqvist <tml at iki.fi>
AuthorDate: Wed Sep 5 20:30:24 2018 +0300
Commit: Tor Lillqvist <tml at iki.fi>
CommitDate: Wed Sep 5 21:57:59 2018 +0300
Don't copy files into the source directory, use workdir
(The LibreOfficeLight Xcode project still needs to be adapted
correspondingly.)
Change-Id: I0b17c595fc0d169f6393ab8734a1eecb241f59be
diff --git a/ios/CustomTarget_iOS_setup.mk b/ios/CustomTarget_iOS_setup.mk
index 4f4449e6eaaa..94fffd34349e 100644
--- a/ios/CustomTarget_iOS_setup.mk
+++ b/ios/CustomTarget_iOS_setup.mk
@@ -9,7 +9,7 @@
#- Env ------------------------------------------------------------------------
-IOSGEN = $(SRCDIR)/ios/generated
+IOSGEN = $(BUILDDIR)/workdir/CustomTarget/ios
IOSRES = $(IOSGEN)/resources
IOSDIRS = $(IOSGEN) \
$(IOSGEN)/Debug_x86_64 \
@@ -105,7 +105,7 @@ $(IOSGEN)/native-code.h: $(BUILDDIR)/config_host.mk \
) > $(IOSRES)/program/versionrc
$(SRCDIR)/bin/lo-all-static-libs | sed -e 's/ /\
-/g' >$(WORKDIR)/ios-all-static-libs.list
+/g' >$(IOSGEN)/ios-all-static-libs.list
#- clean ios -----------------------------------------------------------------
$(call gb_CustomTarget_get_clean_target,ios/iOS_setup):
More information about the Libreoffice-commits
mailing list