diff options
-rw-r--r-- | config_host/config_features.h.in | 8 | ||||
-rw-r--r-- | configure.ac | 1 | ||||
-rw-r--r-- | desktop/source/app/app.cxx | 4 | ||||
-rw-r--r-- | solenv/gbuild/gbuild.mk | 1 |
4 files changed, 11 insertions, 3 deletions
diff --git a/config_host/config_features.h.in b/config_host/config_features.h.in index 3437e13cfa2c..29da64cbf05b 100644 --- a/config_host/config_features.h.in +++ b/config_host/config_features.h.in @@ -80,4 +80,12 @@ #define HAVE_FEATURE_AVAHI 0 +/* MACOSX_SANDBOX - whether LibreOffice runs in an OS X sandbox + * + * When building LibreOffice for distribution through the Mac App Store, + * it must be sandboxed. + */ + +#define HAVE_FEATURE_MACOSX_SANDBOX 0 + #endif diff --git a/configure.ac b/configure.ac index 9eb04ea4a61e..ade9c2655671 100644 --- a/configure.ac +++ b/configure.ac @@ -2742,6 +2742,7 @@ if test $_os = Darwin; then AC_MSG_ERROR([OS X sandboxing requires code signing]) elif test -n "$MACOSX_CODESIGNING_IDENTITY" -a "$enable_macosx_sandbox" = yes; then ENABLE_MACOSX_SANDBOX=YES + AC_DEFINE(HAVE_FEATURE_MACOSX_SANDBOX) AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx index a6888b5180df..137dbac24979 100644 --- a/desktop/source/app/app.cxx +++ b/desktop/source/app/app.cxx @@ -598,7 +598,7 @@ void Desktop::Init() OfficeIPCThread::Status aStatus = OfficeIPCThread::EnableOfficeIPCThread(); if ( aStatus == OfficeIPCThread::IPC_STATUS_PIPE_ERROR ) { -#ifdef MACOSX +#if HAVE_FEATURE_MACOSX_SANDBOX // In a sandboxed LO, on 10.8.2 at least, creating the // Unix domain socket fails. Ignore that as hopefully // people running a sandboxed LO won't attempt starting it @@ -1159,7 +1159,7 @@ namespace { void restartOnMac(bool passArguments) { #if defined MACOSX OfficeIPCThread::DisableOfficeIPCThread(); -#ifdef ENABLE_MACOSX_SANDBOX +#if HAVE_FEATURE_MACOSX_SANDBOX (void) passArguments; // avoid warnings ResMgr *resMgr = Desktop::GetDesktopResManager(); OUString aMessage = OUString( String( ResId( STR_LO_MUST_BE_RESTARTED, *resMgr ))); diff --git a/solenv/gbuild/gbuild.mk b/solenv/gbuild/gbuild.mk index 47d6e6e9727e..c489ee49d150 100644 --- a/solenv/gbuild/gbuild.mk +++ b/solenv/gbuild/gbuild.mk @@ -261,7 +261,6 @@ gb_GLOBALDEFS += \ DISABLE_DYNLOADING \ DISABLE_EXPORT \ DISABLE_SCRIPTING \ - ENABLE_MACOSX_SANDBOX \ ENABLE_READONLY_INSTALLSET \ ) |