[Libreoffice-commits] core.git: 2 commits - basic/Library_sb.mk basic/source ios/CustomTarget_iOS_prelink.mk
jan Iversen
jani at libreoffice.org
Mon Jan 8 12:19:11 UTC 2018
basic/Library_sb.mk | 4 ++--
basic/source/runtime/basrdll.cxx | 3 +++
basic/source/sbx/sbxdate.cxx | 7 +++++++
basic/source/sbx/sbxscan.cxx | 6 ++++++
ios/CustomTarget_iOS_prelink.mk | 26 ++++++++++++++++----------
5 files changed, 34 insertions(+), 12 deletions(-)
New commits:
commit b9bfda051a4248a0e209fa9fa59a4bfe8a48b853
Author: jan Iversen <jani at libreoffice.org>
Date: Mon Jan 8 11:53:31 2018 +0100
iOS, forgot make dependency.
and also added -Objc to allow use of NS functions.
Change-Id: I236cefa53f54531d035881768d2f99749dd00cea
diff --git a/ios/CustomTarget_iOS_prelink.mk b/ios/CustomTarget_iOS_prelink.mk
index a50a1209630b..affd32e5bf59 100644
--- a/ios/CustomTarget_iOS_prelink.mk
+++ b/ios/CustomTarget_iOS_prelink.mk
@@ -7,6 +7,7 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#- Env ------------------------------------------------------------------------
IOSLD = /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld
+IOSCLANG = /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang
IOSOBJ = $(WORKDIR)/CObject/ios/Kit.o
ifeq ($(ENABLE_DEBUG),TRUE)
@@ -31,7 +32,7 @@ $(call gb_CustomTarget_get_target,ios/iOS_prelink): $(IOSKIT)
FORCE:
-$(IOSKIT):
+$(IOSKIT): $(WORKDIR)/CObject/ios/source/LibreOfficeKit.o
$(IOSLD) -r -ios_version_min 11.2 \
-syslibroot $(MACOSX_SDK_PATH) \
-arch `echo $(CPUNAME) | tr '[:upper:]' '[:lower:]'` \
@@ -40,28 +41,33 @@ $(IOSKIT):
`$(SRCDIR)/bin/lo-all-static-libs`
$(AR) -r $(IOSKIT2) $(IOSOBJ)
- $(IOSLD) -dylib -ios_version_min $(IOS_DEPLOYMENT_VERSION) \
- -syslibroot $(MACOSX_SDK_PATH) \
+ $(IOSCLANG) -dynamiclib -mios-simulator-version-min=$(IOS_DEPLOYMENT_VERSION) \
-arch `echo $(CPUNAME) | tr '[:upper:]' '[:lower:]'` \
+ -isysroot $(MACOSX_SDK_PATH) \
+ -Xlinker -rpath -Xlinker @executable_path/Frameworks \
+ -Xlinker -rpath -Xlinker @loader_path/Frameworks \
+ -dead_strip \
+ -Xlinker -export_dynamic \
+ -Xlinker -no_deduplicate \
+ -Xlinker -objc_abi_version -Xlinker 2 \
+ -fobjc-link-runtime \
-framework CoreFoundation \
-framework CoreGraphics \
-framework CoreText \
+ -liconv \
-lc++ \
- -lobjc \
-lz \
- -liconv \
-lpthread \
- -objc_abi_version 2 \
- -rpath @executable_path/Frameworks \
- -rpath @loader_path/Frameworks \
- -export_dynamic \
- -no_deduplicate \
+ -single_module \
+ -compatibility_version 1 \
+ -current_version 1 \
$(WORKDIR)/CObject/ios/source/LibreOfficeKit.o \
`$(SRCDIR)/bin/lo-all-static-libs` \
-o $(IOSKIT)
+
#- clean ios -----------------------------------------------------------------
$(call gb_CustomTarget_get_clean_target,ios/iOS_prelink):
rm -f $(IOSKIT) $(IOSKIT2)
commit ee4b074ce26029092d0e5f27c22a358abe101312
Author: jan Iversen <jani at libreoffice.org>
Date: Mon Jan 8 11:52:17 2018 +0100
basic, solve link problems
When not using scripting, there were a number of
unresolved symbols. First aproach did not work, so this
commit is the more extensive.
Change-Id: Iaf78bde10d9a43862d58d1aa8f46b14aa075eddb
diff --git a/basic/Library_sb.mk b/basic/Library_sb.mk
index 88cae207b166..c1b47e27daa6 100644
--- a/basic/Library_sb.mk
+++ b/basic/Library_sb.mk
@@ -97,15 +97,15 @@ $(eval $(call gb_Library_add_exception_objects,sb,\
basic/source/runtime/props \
basic/source/runtime/stdobj \
basic/source/runtime/stdobj1 \
+ basic/source/runtime/runtime \
+ basic/source/classes/errobject \
))
endif
$(eval $(call gb_Library_add_exception_objects,sb,\
- basic/source/classes/errobject \
basic/source/runtime/basrdll \
basic/source/runtime/methods \
basic/source/runtime/methods1 \
- basic/source/runtime/runtime \
basic/source/classes/sbintern \
basic/source/sbx/sbxarray \
basic/source/sbx/sbxbool \
diff --git a/basic/source/runtime/basrdll.cxx b/basic/source/runtime/basrdll.cxx
index d84e3953284e..e7a639a5a069 100644
--- a/basic/source/runtime/basrdll.cxx
+++ b/basic/source/runtime/basrdll.cxx
@@ -29,6 +29,7 @@
#include <unotools/resmgr.hxx>
#include <strings.hrc>
#include <sbxbase.hxx>
+#include <config_features.h>
struct BasicDLL::Impl
{
@@ -85,6 +86,7 @@ void BasicDLL::BasicBreak()
{
BasicDLL* pThis = BASIC_DLL;
DBG_ASSERT( pThis, "BasicDLL::EnableBreak: No instance yet!" );
+#if HAVE_FEATURE_SCRIPTING
if ( pThis )
{
// bJustStopping: if there's someone pressing STOP like crazy umpteen times,
@@ -99,6 +101,7 @@ void BasicDLL::BasicBreak()
bJustStopping = false;
}
}
+#endif
}
SbxAppData& GetSbxData_Impl()
diff --git a/basic/source/sbx/sbxdate.cxx b/basic/source/sbx/sbxdate.cxx
index 5342d557e1f0..a7f8c0ebc147 100644
--- a/basic/source/sbx/sbxdate.cxx
+++ b/basic/source/sbx/sbxdate.cxx
@@ -31,6 +31,7 @@
#include <math.h>
#include <comphelper/processfactory.hxx>
#include <memory>
+#include <config_features.h>
double ImpGetDate( const SbxValues* p )
@@ -96,6 +97,7 @@ double ImpGetDate( const SbxValues* p )
case SbxBYREF | SbxSTRING:
case SbxSTRING:
case SbxLPSTR:
+#if HAVE_FEATURE_SCRIPTING
if( !p->pOUString )
{
nRes = 0;
@@ -158,6 +160,9 @@ double ImpGetDate( const SbxValues* p )
SbxBase::SetError( ERRCODE_BASIC_CONVERSION ); nRes = 0;
}
}
+#else
+ nRes = 0;
+#endif
break;
case SbxOBJECT:
pVal = dynamic_cast<SbxValue*>( p->pObj );
@@ -273,6 +278,7 @@ start:
case SbxSTRING:
case SbxLPSTR:
{
+#if HAVE_FEATURE_SCRIPTING
if( !p->pOUString )
{
p->pOUString = new OUString;
@@ -334,6 +340,7 @@ start:
LANGUAGE_ENGLISH_US,
eLangType );
pFormatter->GetOutputString( n, nIndex, *p->pOUString, &pColor );
+#endif
break;
}
case SbxOBJECT:
diff --git a/basic/source/sbx/sbxscan.cxx b/basic/source/sbx/sbxscan.cxx
index 370e73c8ae58..2e9a723542d6 100644
--- a/basic/source/sbx/sbxscan.cxx
+++ b/basic/source/sbx/sbxscan.cxx
@@ -629,6 +629,7 @@ const VbaFormatInfo pFormatInfoTable[] =
{ VbaFormatType::Null, OUStringLiteral(""), NF_INDEX_TABLE_ENTRIES, nullptr }
};
+#if HAVE_FEATURE_SCRIPTING
const VbaFormatInfo* getFormatInfo( const OUString& rFmt )
{
const VbaFormatInfo* pInfo = pFormatInfoTable;
@@ -640,9 +641,11 @@ const VbaFormatInfo* getFormatInfo( const OUString& rFmt )
}
return pInfo;
}
+#endif
} // namespace
+#if HAVE_FEATURE_SCRIPTING
#define VBAFORMAT_GENERALDATE "General Date"
#define VBAFORMAT_C "c"
#define VBAFORMAT_N "n"
@@ -651,6 +654,7 @@ const VbaFormatInfo* getFormatInfo( const OUString& rFmt )
#define VBAFORMAT_Y "y"
#define VBAFORMAT_LOWERCASE "<"
#define VBAFORMAT_UPPERCASE ">"
+#endif
void SbxValue::Format( OUString& rRes, const OUString* pFmt ) const
{
@@ -660,6 +664,7 @@ void SbxValue::Format( OUString& rRes, const OUString* pFmt ) const
// pflin, It is better to use SvNumberFormatter to handle the date/time/number format.
// the SvNumberFormatter output is mostly compatible with
// VBA output besides the OOo-basic output
+#if HAVE_FEATURE_SCRIPTING
if( pFmt && !SbxBasicFormater::isBasicFormat( *pFmt ) )
{
OUString aStr = GetOUString();
@@ -784,6 +789,7 @@ void SbxValue::Format( OUString& rRes, const OUString* pFmt ) const
return;
}
}
+#endif
SbxDataType eType = GetType();
switch( eType )
More information about the Libreoffice-commits
mailing list